Skip to content

Commit 4d4075e

Browse files
authored
Merge pull request #65 from sanderegg/odeimaiz-feature/user-access-rights
Odeimaiz feature/user access rights
2 parents f9041fe + 5d8a869 commit 4d4075e

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

services/web/server/src/simcore_service_webserver/projects/projects_db.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,9 @@ async def make_unique_project_uuid(self) -> str:
494494
break
495495
return project_uuid
496496

497-
async def _get_user_email(self, conn: SAConnection, user_id: str) -> str:
497+
async def _get_user_email(self, conn: SAConnection, user_id: Optional[str]) -> str:
498+
if not user_id:
499+
498500
stmt = sa.select([users.c.email]).where(users.c.id == user_id)
499501
result: ResultProxy = await conn.execute(stmt)
500502
row: RowProxy = await result.first()
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
id,type,uuid,name,description,thumbnail,prj_owner,creation_date,last_change_date,workbench,published
2-
10,TEMPLATE,template-uuid-5203-915e-1ae8ae0c9991,Sleepers,5 sleepers interconnected,"","",2019-06-06 14:34:19.631,2019-06-06 14:34:28.647,"{""template-uuid-5f7e-92b0-5a14e84401e9"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 0"", ""inputs"": {""in_2"": 2}, ""inputAccess"": {""in_1"": ""Invisible"", ""in_2"": ""ReadOnly""}, ""inputNodes"": [], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 50, ""y"": 300}}, ""template-uuid-5d8a-812c-44dacf56840e"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 1"", ""inputs"": {""in_1"": {""nodeUuid"": ""template-uuid-5f7e-92b0-5a14e84401e9"", ""output"": ""out_1""}, ""in_2"": 2}, ""inputNodes"": [""template-uuid-5f7e-92b0-5a14e84401e9""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 300, ""y"": 200}}, ""template-uuid-5706-b741-4073a4454f0d"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 2"", ""inputs"": {""in_1"": {""nodeUuid"": ""template-uuid-5d8a-812c-44dacf56840e"", ""output"": ""out_1""}, ""in_2"": {""nodeUuid"": ""template-uuid-5d8a-812c-44dacf56840e"", ""output"": ""out_2""}}, ""inputNodes"": [""template-uuid-5d8a-812c-44dacf56840e""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 550, ""y"": 200}}, ""template-uuid-5065-a079-a5a0476e3c10"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 3"", ""inputs"": {""in_2"": {""nodeUuid"": ""template-uuid-5f7e-92b0-5a14e84401e9"", ""output"": ""out_2""}}, ""inputNodes"": [""template-uuid-5f7e-92b0-5a14e84401e9""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 420, ""y"": 400}}, ""template-uuid-559d-aa19-dc9293e10e4c"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 4"", ""inputs"": {""in_1"": {""nodeUuid"": ""template-uuid-5706-b741-4073a4454f0d"", ""output"": ""out_1""}, ""in_2"": {""nodeUuid"": ""template-uuid-5065-a079-a5a0476e3c10"", ""output"": ""out_2""}}, ""inputNodes"": [""template-uuid-5706-b741-4073a4454f0d"", ""template-uuid-5065-a079-a5a0476e3c10""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 800, ""y"": 300}}}",true
1+
id,type,uuid,name,description,thumbnail,prj_owner,creation_date,last_change_date,workbench,published,accessRights
2+
10,TEMPLATE,template-uuid-5203-915e-1ae8ae0c9991,Sleepers,5 sleepers interconnected,"",,2019-06-06 14:34:19.631,2019-06-06 14:34:28.647,"{""template-uuid-5f7e-92b0-5a14e84401e9"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 0"", ""inputs"": {""in_2"": 2}, ""inputAccess"": {""in_1"": ""Invisible"", ""in_2"": ""ReadOnly""}, ""inputNodes"": [], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 50, ""y"": 300}}, ""template-uuid-5d8a-812c-44dacf56840e"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 1"", ""inputs"": {""in_1"": {""nodeUuid"": ""template-uuid-5f7e-92b0-5a14e84401e9"", ""output"": ""out_1""}, ""in_2"": 2}, ""inputNodes"": [""template-uuid-5f7e-92b0-5a14e84401e9""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 300, ""y"": 200}}, ""template-uuid-5706-b741-4073a4454f0d"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 2"", ""inputs"": {""in_1"": {""nodeUuid"": ""template-uuid-5d8a-812c-44dacf56840e"", ""output"": ""out_1""}, ""in_2"": {""nodeUuid"": ""template-uuid-5d8a-812c-44dacf56840e"", ""output"": ""out_2""}}, ""inputNodes"": [""template-uuid-5d8a-812c-44dacf56840e""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 550, ""y"": 200}}, ""template-uuid-5065-a079-a5a0476e3c10"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 3"", ""inputs"": {""in_2"": {""nodeUuid"": ""template-uuid-5f7e-92b0-5a14e84401e9"", ""output"": ""out_2""}}, ""inputNodes"": [""template-uuid-5f7e-92b0-5a14e84401e9""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 420, ""y"": 400}}, ""template-uuid-559d-aa19-dc9293e10e4c"": {""key"": ""simcore/services/comp/itis/sleeper"", ""version"": ""1.0.0"", ""label"": ""sleeper 4"", ""inputs"": {""in_1"": {""nodeUuid"": ""template-uuid-5706-b741-4073a4454f0d"", ""output"": ""out_1""}, ""in_2"": {""nodeUuid"": ""template-uuid-5065-a079-a5a0476e3c10"", ""output"": ""out_2""}}, ""inputNodes"": [""template-uuid-5706-b741-4073a4454f0d"", ""template-uuid-5065-a079-a5a0476e3c10""], ""outputs"": {}, ""progress"": 0, ""thumbnail"": """", ""position"": {""x"": 800, ""y"": 300}}}",true,"{""1"": ""rwx""}"

0 commit comments

Comments
 (0)