Skip to content

Commit

Permalink
Merge pull request #24 from stuartcampbell/proposal-directory-skeleton
Browse files Browse the repository at this point in the history
Add beamline and cycle to list of directory fields
  • Loading branch information
danielballan authored Feb 1, 2024
2 parents dcbf445 + 428f35a commit 5ec6da5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/nsls2api/api/models/proposal_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,10 @@ class ProposalUser(pydantic.BaseModel):
class ProposalDirectories(pydantic.BaseModel):
path: str
owner: str
group: str | None = ""
group: str | None = None
group_writable: bool | None = False
beamline: str | None = None
cycle: str | None = None
users: list[dict[str, str]]
groups: list[dict[str, str]]

Expand Down
2 changes: 2 additions & 0 deletions src/nsls2api/services/proposal_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,8 @@ async def directories(proposal_id: int):
"path": str(
data_root / "proposals" / str(cycle) / proposal.data_session
),
"beamline": beamline.upper(),
"cycle": str(cycle),
"owner": "nsls2data",
"group": proposal.data_session,
"group_writable": True,
Expand Down

0 comments on commit 5ec6da5

Please sign in to comment.