zou 0.20.73__py3-none-any.whl → 0.20.74__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- zou/__init__.py +1 -1
- zou/app/blueprints/comments/resources.py +4 -1
- zou/app/blueprints/entities/resources.py +142 -21
- zou/app/blueprints/files/resources.py +876 -380
- zou/app/blueprints/index/resources.py +205 -20
- zou/app/blueprints/news/resources.py +187 -51
- zou/app/blueprints/persons/resources.py +301 -166
- zou/app/blueprints/playlists/resources.py +313 -147
- zou/app/blueprints/projects/__init__.py +7 -0
- zou/app/blueprints/projects/resources.py +597 -152
- zou/app/blueprints/source/csv/assets.py +4 -0
- zou/app/blueprints/source/csv/shots.py +4 -0
- zou/app/blueprints/tasks/resources.py +8 -13
- zou/app/blueprints/user/resources.py +13 -12
- zou/app/services/comments_service.py +6 -3
- zou/app/services/time_spents_service.py +61 -1
- {zou-0.20.73.dist-info → zou-0.20.74.dist-info}/METADATA +13 -13
- {zou-0.20.73.dist-info → zou-0.20.74.dist-info}/RECORD +22 -22
- {zou-0.20.73.dist-info → zou-0.20.74.dist-info}/WHEEL +0 -0
- {zou-0.20.73.dist-info → zou-0.20.74.dist-info}/entry_points.txt +0 -0
- {zou-0.20.73.dist-info → zou-0.20.74.dist-info}/licenses/LICENSE +0 -0
- {zou-0.20.73.dist-info → zou-0.20.74.dist-info}/top_level.txt +0 -0
zou/__init__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "0.20.
|
|
1
|
+
__version__ = "0.20.74"
|
|
@@ -497,7 +497,10 @@ class ReplyCommentResource(Resource, ArgsMixin):
|
|
|
497
497
|
current_user = persons_service.get_current_user()
|
|
498
498
|
if comment["person_id"] != current_user["id"]:
|
|
499
499
|
if permissions.has_client_permissions():
|
|
500
|
-
|
|
500
|
+
author = persons_service.get_person(comment["person_id"])
|
|
501
|
+
if current_user["studio_id"] != author["studio_id"] and \
|
|
502
|
+
author["role"] == "client":
|
|
503
|
+
raise permissions.PermissionDenied()
|
|
501
504
|
user_service.check_task_action_access(task_id)
|
|
502
505
|
|
|
503
506
|
args = self.get_args(
|
|
@@ -22,13 +22,39 @@ class EntityNewsResource(Resource):
|
|
|
22
22
|
parameters:
|
|
23
23
|
- in: path
|
|
24
24
|
name: entity_id
|
|
25
|
-
required:
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
required: true
|
|
26
|
+
schema:
|
|
27
|
+
type: string
|
|
28
|
+
format: uuid
|
|
28
29
|
example: a24a6ea4-ce75-4665-a070-57453082c25
|
|
29
30
|
responses:
|
|
30
|
-
|
|
31
|
-
|
|
31
|
+
'200':
|
|
32
|
+
description: All news linked to given entity
|
|
33
|
+
content:
|
|
34
|
+
application/json:
|
|
35
|
+
schema:
|
|
36
|
+
type: array
|
|
37
|
+
items:
|
|
38
|
+
type: object
|
|
39
|
+
properties:
|
|
40
|
+
id:
|
|
41
|
+
type: string
|
|
42
|
+
format: uuid
|
|
43
|
+
title:
|
|
44
|
+
type: string
|
|
45
|
+
content:
|
|
46
|
+
type: string
|
|
47
|
+
created_at:
|
|
48
|
+
type: string
|
|
49
|
+
format: date-time
|
|
50
|
+
author_id:
|
|
51
|
+
type: string
|
|
52
|
+
format: uuid
|
|
53
|
+
entity_id:
|
|
54
|
+
type: string
|
|
55
|
+
format: uuid
|
|
56
|
+
'404':
|
|
57
|
+
description: Entity not found
|
|
32
58
|
"""
|
|
33
59
|
entity = entities_service.get_entity(entity_id)
|
|
34
60
|
user_service.check_project_access(entity["project_id"])
|
|
@@ -46,13 +72,41 @@ class EntityPreviewFilesResource(Resource):
|
|
|
46
72
|
parameters:
|
|
47
73
|
- in: path
|
|
48
74
|
name: entity_id
|
|
49
|
-
required:
|
|
50
|
-
|
|
51
|
-
|
|
75
|
+
required: true
|
|
76
|
+
schema:
|
|
77
|
+
type: string
|
|
78
|
+
format: uuid
|
|
52
79
|
example: a24a6ea4-ce75-4665-a070-57453082c25
|
|
53
80
|
responses:
|
|
54
|
-
|
|
55
|
-
|
|
81
|
+
'200':
|
|
82
|
+
description: All preview files linked to given entity
|
|
83
|
+
content:
|
|
84
|
+
application/json:
|
|
85
|
+
schema:
|
|
86
|
+
type: array
|
|
87
|
+
items:
|
|
88
|
+
type: object
|
|
89
|
+
properties:
|
|
90
|
+
id:
|
|
91
|
+
type: string
|
|
92
|
+
format: uuid
|
|
93
|
+
name:
|
|
94
|
+
type: string
|
|
95
|
+
path:
|
|
96
|
+
type: string
|
|
97
|
+
revision:
|
|
98
|
+
type: integer
|
|
99
|
+
created_at:
|
|
100
|
+
type: string
|
|
101
|
+
format: date-time
|
|
102
|
+
entity_id:
|
|
103
|
+
type: string
|
|
104
|
+
format: uuid
|
|
105
|
+
task_id:
|
|
106
|
+
type: string
|
|
107
|
+
format: uuid
|
|
108
|
+
'404':
|
|
109
|
+
description: Entity not found
|
|
56
110
|
"""
|
|
57
111
|
entity = entities_service.get_entity(entity_id)
|
|
58
112
|
user_service.check_project_access(entity["project_id"])
|
|
@@ -70,13 +124,43 @@ class EntityTimeSpentsResource(Resource):
|
|
|
70
124
|
parameters:
|
|
71
125
|
- in: path
|
|
72
126
|
name: entity_id
|
|
73
|
-
required:
|
|
74
|
-
|
|
75
|
-
|
|
127
|
+
required: true
|
|
128
|
+
schema:
|
|
129
|
+
type: string
|
|
130
|
+
format: uuid
|
|
76
131
|
example: a24a6ea4-ce75-4665-a070-57453082c25
|
|
77
132
|
responses:
|
|
78
|
-
|
|
79
|
-
|
|
133
|
+
'200':
|
|
134
|
+
description: All time spents linked to given entity
|
|
135
|
+
content:
|
|
136
|
+
application/json:
|
|
137
|
+
schema:
|
|
138
|
+
type: array
|
|
139
|
+
items:
|
|
140
|
+
type: object
|
|
141
|
+
properties:
|
|
142
|
+
id:
|
|
143
|
+
type: string
|
|
144
|
+
format: uuid
|
|
145
|
+
duration:
|
|
146
|
+
type: number
|
|
147
|
+
format: float
|
|
148
|
+
example: 2.5
|
|
149
|
+
date:
|
|
150
|
+
type: string
|
|
151
|
+
format: date
|
|
152
|
+
example: "2023-12-07"
|
|
153
|
+
created_at:
|
|
154
|
+
type: string
|
|
155
|
+
format: date-time
|
|
156
|
+
person_id:
|
|
157
|
+
type: string
|
|
158
|
+
format: uuid
|
|
159
|
+
entity_id:
|
|
160
|
+
type: string
|
|
161
|
+
format: uuid
|
|
162
|
+
'404':
|
|
163
|
+
description: Entity not found
|
|
80
164
|
"""
|
|
81
165
|
entity = entities_service.get_entity(entity_id)
|
|
82
166
|
user_service.check_project_access(entity["project_id"])
|
|
@@ -90,17 +174,54 @@ class EntitiesLinkedWithTasksResource(Resource):
|
|
|
90
174
|
Resource to retrieve the entities linked on a given entity.
|
|
91
175
|
---
|
|
92
176
|
tags:
|
|
93
|
-
|
|
177
|
+
- Entities
|
|
94
178
|
parameters:
|
|
95
179
|
- in: path
|
|
96
180
|
name: entity_id
|
|
97
|
-
required:
|
|
98
|
-
|
|
99
|
-
|
|
181
|
+
required: true
|
|
182
|
+
schema:
|
|
183
|
+
type: string
|
|
184
|
+
format: uuid
|
|
100
185
|
example: a24a6ea4-ce75-4665-a070-57453082c25
|
|
101
186
|
responses:
|
|
102
|
-
|
|
103
|
-
|
|
187
|
+
'200':
|
|
188
|
+
description: Entities linked on given entity
|
|
189
|
+
content:
|
|
190
|
+
application/json:
|
|
191
|
+
schema:
|
|
192
|
+
type: array
|
|
193
|
+
items:
|
|
194
|
+
type: object
|
|
195
|
+
properties:
|
|
196
|
+
id:
|
|
197
|
+
type: string
|
|
198
|
+
format: uuid
|
|
199
|
+
name:
|
|
200
|
+
type: string
|
|
201
|
+
entity_type_id:
|
|
202
|
+
type: string
|
|
203
|
+
format: uuid
|
|
204
|
+
project_id:
|
|
205
|
+
type: string
|
|
206
|
+
format: uuid
|
|
207
|
+
parent_id:
|
|
208
|
+
type: string
|
|
209
|
+
format: uuid
|
|
210
|
+
tasks:
|
|
211
|
+
type: array
|
|
212
|
+
items:
|
|
213
|
+
type: object
|
|
214
|
+
properties:
|
|
215
|
+
id:
|
|
216
|
+
type: string
|
|
217
|
+
format: uuid
|
|
218
|
+
name:
|
|
219
|
+
type: string
|
|
220
|
+
task_type_id:
|
|
221
|
+
type: string
|
|
222
|
+
format: uuid
|
|
223
|
+
'404':
|
|
224
|
+
description: Entity not found
|
|
104
225
|
"""
|
|
105
226
|
entity = entities_service.get_entity(entity_id)
|
|
106
227
|
user_service.check_project_access(entity["project_id"])
|