2 Commits

Author SHA1 Message Date
Konstantinos Karmas
9d8286d90c Set the correct initial value in the feature budget attributes
They were defined as `Optional[int]` but started with the default value as `False`.

CURA-8112
2021-07-13 16:52:36 +02:00
Remco Burema
c78618bc15
Digital Library: Allow 'personal users' to DL.
Users with an account and an UM printer should have some basic access to the Digital Library. To this end, and to remain future proof, the online team has made an extension to its API so now feature budgets can be gauge. At the moment it's only checked wether the user has any access to personal projects at all. If so, the interface shows Digital Library functionality. Known issue: Removing the last printer from DF while still logged in leaves the DL access in the Cura interface until logged out or Cura restarted. Additionally, I think the response for a logged in user without any printer from the API is just 'data = empty list' instead of everything set to False and 0 (which should be the case as they're all listed as required fields in their docs ... maybe I'm missing something). In any case, the code as is now can handle that as well.

CURA-8138
2021-07-09 21:06:49 +02:00