mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
CURA-5035 Enjoy Lipu
This commit is contained in:
parent
e13c45daee
commit
f510603cb5
4 changed files with 206 additions and 64 deletions
|
@ -18,7 +18,7 @@ class AuthorsModel(ListModel):
|
|||
def __init__(self, parent = None):
|
||||
super().__init__(parent)
|
||||
|
||||
self._authors_metadata = None
|
||||
self._metadata = None
|
||||
|
||||
self.addRoleName(AuthorsModel.NameRole, "name")
|
||||
self.addRoleName(AuthorsModel.EmailRole, "email")
|
||||
|
@ -29,13 +29,13 @@ class AuthorsModel(ListModel):
|
|||
self._filter = {} # type: Dict[str,str]
|
||||
|
||||
def setMetadata(self, data):
|
||||
self._authors_metadata = data
|
||||
self._metadata = data
|
||||
self._update()
|
||||
|
||||
def _update(self):
|
||||
items = []
|
||||
|
||||
for author in self._authors_metadata:
|
||||
for author in self._metadata:
|
||||
items.append({
|
||||
"name": author["name"],
|
||||
"email": author["email"],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue