Jaime van Kessel
f4c4b52d9b
Update typing to reflect new message that is being used
...
CURA-8463
2022-08-30 11:49:09 +02:00
Jaime van Kessel
ce3ab62c91
Move RemovedprintersMessage to it's own class
...
The OutputDeviceManager is just too bloated to properly make sense of.
So I'm trying to move as much code out of it so I can start to make sense of it
CURA-8463
2022-08-30 11:45:30 +02:00
Jaime van Kessel
45e7d15c80
Add documentation for _onDiscoveredDeviceRemoved
2022-08-30 11:36:47 +02:00
Jaime van Kessel
7f9984cd16
Also move remainder of NewPrinterDetected logic to it's own class
...
This should make the CloudOutputDeviceManager a bit more readable
CURA-8463
2022-08-30 11:33:20 +02:00
Jaime van Kessel
a429a93e94
Move new printers detected message to it's own class
...
CURA-8463
2022-08-30 11:26:09 +02:00
Jaime van Kessel
8e9056df71
Rename function to better reflect what it does
...
CURA-8463
2022-08-30 11:11:00 +02:00
Jaime van Kessel
d35441603b
Rename variables so it's easier to understand what is what
...
CURA-8463
2022-08-30 11:06:09 +02:00
Jaime van Kessel
30bc0d04bf
Add more typing & documentation
...
Even more boyscouting. This code seems to be far too complex for what it should be...
CURA-8463
2022-08-30 11:04:15 +02:00
Jaime van Kessel
21b8f083f2
Ensure that UI actually updates when adding remote printers
...
More boyscouting. The documentation that it had before was actually false...
CURA-8463
2022-08-30 11:03:04 +02:00
Jaime van Kessel
24f85bae06
Use new style string formating
...
Moar boyscouting
CURA-8463
2022-08-30 10:52:21 +02:00
Jaime van Kessel
ed33596357
Rename device to global_stack
...
Device was used in the rest of this class for the output device, not
for a machine. This was a bit confusing
CURA-8463
2022-08-30 10:46:10 +02:00
Jaime van Kessel
f8ebf98df3
Update typing hints to new style
...
More boyscouting as I try to understand this code
CURA-8463
2022-08-30 10:43:53 +02:00
Jaime van Kessel
4ac8229c33
Clean up codestyle violations
...
Boyscouting! CURA-8463
2022-08-30 10:28:22 +02:00
Jaime van Kessel
36d3a92fc0
Fix gramar mistake in documentation
...
CURA-8463
2022-08-26 13:27:58 +02:00
joeydelarago
9c599870e3
Move message triggering into CloudOutputDevice so that the campaign link can include the cluster_id.
...
CURA-9221
2022-08-26 10:59:03 +02:00
Joey de l'Arago
119fb32681
Update plugins/UM3NetworkPrinting/src/Messages/PrintJobAwaitingApprovalMessage.py
...
Co-authored-by: Jaime van Kessel <nallath@gmail.com>
2022-08-26 10:14:36 +02:00
joeydelarago
0993dc99f9
Remove unused import
...
CURA-9221
2022-08-26 09:00:17 +02:00
joeydelarago
a6f459b0f6
Update links
...
CURA-9221
2022-08-26 08:55:12 +02:00
joeydelarago
a58690c774
change _parseModels -> _parseResponse since it now parses responses with no models included.
...
Move status check into _parseResponse
Don't give PrintJobUploadSuccessMessage() if printis awaiting approval. The print has successfully uploaded but it is pending approval instead so it does not make sense to display both messages.
CURA-9221
2022-08-25 14:49:40 +02:00
joeydelarago
30692bb4b8
Add link out to learn more
...
CURA-9221
2022-08-25 14:13:25 +02:00
joeydelarago
1a023f7285
Swap text and title for message.
...
Move link opening code into the PrintJobAwaitingApprovalMessage.py
CURA-9221
2022-08-24 17:02:17 +02:00
joeydelarago
9b20a1b37f
Merge branch 'main' into CURA-9221_show_message_cloud_approval
2022-08-24 16:15:24 +02:00
joeydelarago
abb6d20beb
Remove enum, python has no build in support for getting enum from string value. This will be in Python 3.11 though.
...
CURA-9221
2022-08-24 14:06:30 +02:00
joeydelarago
17e6bccf51
Create abstract printers when adding lan printers.
...
CURA-9514
2022-08-24 10:07:17 +02:00
jspijker
54e9dbf827
Show device name of failed machine creation in log
...
CURA-9277 Detect and Load Specific printers and Cloud Printer Types
2022-08-22 14:57:37 +02:00
Casper Lamboo
12f3581337
Assign result of createAbstractMachine
to a variable
...
With prepended underscore to highlight the result of the function is not being used.
CURA-9277
2022-08-22 14:44:45 +02:00
c.lamboo
d7f119415f
Use pretty-printed string for the AbstractMachine
name
...
Cura-9277
Co-authored-by: joeydelarago <joeydelarago@gmail.com>
2022-08-19 16:35:00 +02:00
c.lamboo
761bf3b8fa
Fix creating abstract machines on account sync
...
Cura-9277
Co-authored-by: joeydelarago <joeydelarago@gmail.com>
2022-08-19 14:44:19 +02:00
joeydelarago
b82f1f4a8c
Add new Abstract machine stack type. This represents a type of printers (ultimaker_s3 etc).
...
These are created whenever a cloud printer of a new printer type is added.
CURA-9277
Co-authored-by: casperlamboo <c.lamboo@ultimaker.com>
2022-08-19 13:53:43 +02:00
joeydelarago
ad70566dc6
Added a message for pending approval status.
...
Updated CloudPrintJobResponse to use an enum for status
CURA-9221
2022-08-10 17:34:48 +02:00
Ghostkeeper
8a55a2aff6
Further review suggestions
...
Contributes to issue CURA-9220.
2022-08-01 10:49:29 +02:00
Ghostkeeper
19ba092340
Add property of whether the printer details can be read
...
We'd assume so, but there is a permissions node for it. If it can't be read by the user, they can't navigate to the printer's overview page. So we should hide the button then.
Contributes to issue CURA-9220.
2022-07-26 16:56:19 +02:00
Ghostkeeper
5eb340e3f0
Check permissions before showing abort/pause/delete context buttons
...
The user needs permissions to do these things, so don't show them if the user can't use them.
Contributes to issue CURA-9220.
2022-07-25 17:34:34 +02:00
Ghostkeeper
99d93fa58a
Check if the user can change the queue before showing option
...
If the user can't change the queue of other prints, then it can't move prints to the top.
Contributes to issue CURA-9220.
2022-07-25 17:07:52 +02:00
Ghostkeeper
9e1940dd4b
Move default behaviour up in inheritance hierarchy
...
This way, any new printer types we define will automatically get these properties that are used by the monitor stage anyway.
Contributes to issue CURA-9220.
2022-07-25 16:55:05 +02:00
Ghostkeeper
b4c4371929
Add properties of whether the queue can be manipulated
...
Not all printers can do that.
Contributes to issue CURA-9220.
2022-07-25 16:51:13 +02:00
Ghostkeeper
483911dc4a
Fix error of undefined property when using LAN printers
...
This property was defined for Cloud printers, but not for Network printers. In QML this then resulted in an error saying that null cannot be assigned to a bool (for the 'visible' property). The visible property then defaulted to its default, true. And so it was always visible, but still had an error.
The error is now solved so that I can also check for other properties in this visible check.
Contributes to issue CURA-9220.
2022-07-25 16:49:48 +02:00
Ghostkeeper
fb3f065fe0
Catch ValueErrors from removing callbacks that were already removed
...
This can happen from asynchronous access.
Fixes Sentry issue CURA-3YV.
2022-06-07 13:55:56 +02:00
Jelle Spijker
334fca6691
Merge remote-tracking branch 'origin/gracefully_fail_cloud_printer' into 5.0
2022-05-09 10:54:07 +02:00
Jaime van Kessel
0c98ce2384
Use correct role for standardbutton
...
Otherwise the no won't register...
CURA-9229
2022-05-04 11:09:49 +02:00
Jaime van Kessel
e4e993a44e
Fail gracefully when adding unknown cloud printer
2022-04-19 15:43:31 +02:00
Jaime van Kessel
c9e625767b
Use right enum for message dialog
2022-04-13 16:40:14 +02:00
Ghostkeeper
70fdffb1c9
Allow redirects when talking with printer API
...
Because newer firmware will redirect this API call.
Contributes to issue CURA-9119.
2022-04-11 13:23:03 +02:00
Ghostkeeper
0deac84ec2
NetworkError is an enum, no longer comparable as int
...
With the Qt6 upgrade, we have to treat enums as full enums, within their normal class namespace and such. They are no longer just integer-globals static in the QtCore.Qt class. They are no longer treated as integers by PyQt.
Other places that checked for such errors were already doing it like this.
Contributes to issue CURA-9100.
2022-04-11 10:00:32 +02:00
Remco Burema
20b435af76
Qt5->Qt6: More renamed stuff.
...
part of CURA-8591
2021-12-29 11:18:49 +01:00
Remco Burema
abe7c1bf7f
Search/replace Qt5->Qt6.
...
part of upgrading Qt to v6.2: CURA-8591
2021-12-28 14:46:02 +01:00
Ghostkeeper
9674c54efb
Better type checking and handling of optionals
...
Adds type checking here and there to catch such errors in the future.
This makes it handle the optional fields of this model better.
Contributes to issue CURA-8730.
2021-12-08 17:36:09 +01:00
Ghostkeeper
770adb2c02
Don't store None as capabilities, but empty list
...
This makes a few things easier. You could see None as being a signalling value to indicate that we don't know capabilities, but this signalling would get lost anyway in the serialising to the metadata. So just an empty list is fine for now.
Contributes to issue CURA-8671.
2021-12-03 13:36:06 +01:00
Ghostkeeper
6d9142579a
Add debuging repr to print more nicely
...
Otherwise you just see <CloudClusterResponse object> when you try to print this.
Contributes to issue CURA-8671.
2021-12-03 13:26:29 +01:00
Ghostkeeper
0477ba44b2
Encode capabilities as comma-separated list
...
Previously it was encoded as a stringified Python list of strings, which is much harder to parse.
This would go wrong if any of these capabilities have a comma in them, but I think that would be bad practice for keywords like this anyway.
Contributes to issue CURA-8671.
2021-12-03 13:25:41 +01:00