Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
LOFAR
Manage
Activity
Members
Labels
Plan
Issues
Wiki
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RadioObservatory
LOFAR
Commits
595a9a94
Commit
595a9a94
authored
4 years ago
by
Fabio Vitello
Browse files
Options
Downloads
Patches
Plain Diff
TMSS-234
: Renamed copy_scheduling_unit_draft to copy_scheduling_unit_drafts
parent
4b0bf2ca
No related branches found
No related tags found
1 merge request
!181
Resolve TMSS-234
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
SAS/TMSS/src/tmss/tmssapp/viewsets/specification.py
+2
-2
2 additions, 2 deletions
SAS/TMSS/src/tmss/tmssapp/viewsets/specification.py
SAS/TMSS/src/tmss/urls.py
+1
-1
1 addition, 1 deletion
SAS/TMSS/src/tmss/urls.py
with
3 additions
and
3 deletions
SAS/TMSS/src/tmss/tmssapp/viewsets/specification.py
+
2
−
2
View file @
595a9a94
...
...
@@ -470,8 +470,8 @@ class SchedulingUnitDraftCopyFromSchedulingSetViewSet(LOFARCopyViewSet):
scheduling_unit_draft_copy
=
copy_scheduling_unit_draft
(
scheduling_unit_draft
,
scheduling_set
,
copy_reason
)
# url path magic to construct the new scheduling_unit_draft url
copy_scheduling_unit_draft_path
=
request
.
_request
.
path
base_path
=
copy_scheduling_unit_draft_path
[:
copy_scheduling_unit_draft_path
.
find
(
'
/copy_scheduling_unit_draft
'
)]
scheduling_unit_draft_copy_path
+=
[
'
%s/copy_scheduling_unit_draft/%s/
'
%
(
base_path
,
scheduling_unit_draft_copy
.
id
,)]
base_path
=
copy_scheduling_unit_draft_path
[:
copy_scheduling_unit_draft_path
.
find
(
'
/copy_scheduling_unit_draft
s
'
)]
scheduling_unit_draft_copy_path
+=
[
'
%s/copy_scheduling_unit_draft
s
/%s/
'
%
(
base_path
,
scheduling_unit_draft_copy
.
id
,)]
# just return as a response the serialized scheduling_set (with references to the created copy_scheduling_unit_draft(s)
return
Response
(
serializers
.
SchedulingSetSerializer
(
scheduling_set
,
context
=
{
'
request
'
:
request
}).
data
,
status
=
status
.
HTTP_201_CREATED
)
...
...
This diff is collapsed.
Click to expand it.
SAS/TMSS/src/tmss/urls.py
+
1
−
1
View file @
595a9a94
...
...
@@ -141,7 +141,7 @@ router.register(r'task_blueprint/(?P<task_blueprint_id>\d+)/task_relation_bluepr
router
.
register
(
r
'
task_blueprint/(?P<task_blueprint_id>\d+)/subtask
'
,
viewsets
.
SubtaskNestedViewSet
)
# copy
router
.
register
(
r
'
scheduling_set/(?P<scheduling_set_id>\d+)/copy_scheduling_unit_draft
'
,
viewsets
.
SchedulingUnitDraftCopyFromSchedulingSetViewSet
)
router
.
register
(
r
'
scheduling_set/(?P<scheduling_set_id>\d+)/copy_scheduling_unit_draft
s
'
,
viewsets
.
SchedulingUnitDraftCopyFromSchedulingSetViewSet
)
router
.
register
(
r
'
scheduling_unit_draft/(?P<scheduling_unit_draft_id>\d+)/copy
'
,
viewsets
.
SchedulingUnitDraftCopyViewSet
)
router
.
register
(
r
'
scheduling_unit_blueprint/(?P<scheduling_unit_blueprint_id>\d+)/copy_to_scheduling_unit_draft
'
,
viewsets
.
SchedulingUnitBlueprintCopyToSchedulingUnitDraftViewSet
)
router
.
register
(
r
'
task_blueprint/(?P<task_blueprint_id>\d+)/copy_to_task_draft
'
,
viewsets
.
TaskBlueprintCopyToTaskDraftViewSet
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment