30 Commits

Author SHA1 Message Date
Casper Lamboo
7e2fc1ac5b
Update plugins/Marketplace/RemotePackageList.py 2023-07-25 13:29:22 +02:00
Casper Lamboo
8c54d44cbb
Apply suggestions from code review 2023-07-25 13:27:08 +02:00
HellAholic
afc0f7c615 Update to add sort_by option
Added a class attribute "last_updated" for sort_by
Added an instance attribute for search_sort
Added if statement to add the sort_by string, currently by default.
2023-07-25 13:11:43 +02:00
c.lamboo
9c02f6500d Use API endpoint for requesting package_ids
Use new api endpoint for requesting specific package_ids so we don't have to filter ourselves.

CURA-6990
2022-06-02 15:19:00 +02:00
Jaime van Kessel
86534e78a0 Prevent error message when no further pages in marketplace could be loaded
Contributes to #11858
2022-04-22 11:00:45 +02:00
Jelle Spijker
3f8907d02a
Merge branch 'master' into CURA-8640_PyQt6
# Conflicts:
#	cura/CuraApplication.py
#	resources/qml/Preferences/Materials/MaterialsSyncDialog.qml
#	resources/qml/Preferences/Materials/MaterialsView.qml
2022-03-24 11:53:44 +01:00
Remco Burema
99449dbc34 Get rid of some errors first.
Was using Qt5 still, even though we're dumping that. Need a bit of a level playing field for an update to the way we handle libArcus and libSavitar.

part of CURA-7924
2022-02-25 13:25:35 +01:00
Jaime van Kessel
095b8dc5dd Show install, uninstall & disable buttons in packages list
This splits up the single show controls property into three seperate ones
and no longer hides installed packages from the plugin & materials list

CURA-8834
2022-02-23 16:51:26 +01:00
Jelle Spijker
8abeb24ccc
Remove a recently installed and then uninstalled package from the manage list
Contributes to CURA-8587
2021-12-16 12:21:36 +01:00
Jaime van Kessel
d50dc59aac Simplifications and cleanup
CURA-8587
2021-12-13 15:13:00 +01:00
Jelle Spijker
11c2ccd227
Use the ongoing_request queue
Contributes to CURA-8587
2021-12-10 12:41:37 +01:00
Jelle Spijker
9f41115bc1
Rework of the ManageButton
Now uses the internal signal

Contributes to: CURA-8587
2021-12-08 18:47:56 +01:00
Jelle Spijker
e0ca0d5446
Renamed recently_install to better depict the usage
This flag is an indication if the package. was recently un-/installed

Contributes to: CURA-8587
2021-12-08 14:46:34 +01:00
Jelle Spijker
7be2da587b
Automatic abortRequest for each API request
Defensive programming

Contributes to: CURA-8587
2021-12-08 10:18:08 +01:00
Jelle Spijker
9e4258ef8b
Set the is_recently_installed flag
Contributes to: CURA-8587
2021-12-07 16:22:31 +01:00
Jelle Spijker
013e0b51e9
Storing multiple ongoing_requests
A bit of defensive programming

Contributes to: CURA-8587
2021-12-07 15:56:35 +01:00
Jelle Spijker
325783ca46
Persistent handled state across Package Lists
Contributes to: CURA-8587
2021-12-06 10:19:14 +01:00
Jelle Spijker
305fb4ab09
renamed locally_installed property
Contributes to: CURA-8587
2021-12-05 16:23:23 +01:00
Jelle Spijker
bd2f270803
Added typing
Contributes to: CURA-8587
2021-12-05 15:18:51 +01:00
Jelle Spijker
743ac67cdb
un-/subscribe the user to installed packages
Contributes to: CURA-8587
2021-12-03 17:08:28 +01:00
Jelle Spijker
ff5a4a4f5a
Adding functionality to the manageButtons
Contributes to: CURA-8587
2021-12-03 13:27:16 +01:00
Jelle Spijker
02e2e0a1c6
Filter already installed packages from the install listviews
Contributes to: CURA-8587
2021-12-03 13:25:46 +01:00
Jelle Spijker
6514fdf9f2
Check the server if a package can be updated
The server is queried using the local packages_id and version to
determine if they can be updated. The Manage button state is set
accordingly. This is done in an async way to keep the UI responsive

A.t.m I'm not sure if I might need to move this logic out, since
we also need to make this query when check periodically for updates.
when the list is not shown. But that would also entail creating
the installed packages list before the Manage Packages tab is ever
created in the Marketplace.

Contributes to: CURA-8587
2021-12-03 13:25:43 +01:00
Remco Burema
44242dcd02
Auto-load next batch with searched-for text in Marketplace.
part of CURA-8559
2021-11-12 15:20:46 +01:00
Remco Burema
79f7724923
Actually set search string + fix code style warnings.
It now works! Sort of. Turns out you have to manually click 'Load More' each time now :-) This is also at least partially explains the 'cases' mentioned in previous commit (when switching tabs).

part of CURA-8559
2021-11-12 14:30:09 +01:00
Remco Burema
d7ac307ace
Type in the search-bar and the remote package list reacts.
It doesn't do any actual searching yet though. Also switching between page doesn't work like it's supposed to yet (and probalby more of that sort of cases).

part of CURA-8559
2021-11-12 14:01:05 +01:00
Jelle Spijker
a0467cd66f
Fixed hard crash when deconstructing RemotePackageList while parsing
Contributes to CURA-8558
2021-11-04 10:39:00 +01:00
Jelle Spijker
a58891ce58
Fixed the loading spinner not spinning at first construction
Contributes to CURA-8558
2021-11-04 08:23:47 +01:00
Jelle Spijker
11b3b08198
Implemented code review suggestions
Contributes to CURA-8558
2021-11-04 08:23:46 +01:00
Jelle Spijker
86d5d315bc
Differentiate between local and remote packages
There is a distinction between packages which are already
installed on the local machine and packages which are
available on the remote server. Even with this difference
it is important that they are handled the same and can be
reused in the same GUI elements.

In order to reduce code duplication I created a parent object
PackageList which contains the base logic and interface for
the QML and let both RemotePackageList and LocalPackageList
inherit from this.

UX specified that the gear icon (Settings.svg) should be
separate from the tabs of material and plugins. This also
ment that the current tab  item couldn't set the pageTitle
anymore. This is now defined in the Package component and
set when the loader has loaded the external QML file.

Contributes to CURA-8558
2021-11-01 17:12:18 +01:00