Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
dream
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
dream
Commits
423cf03c
Commit
423cf03c
authored
Jun 25, 2015
by
Georgios Dagkakis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sort the gantts for stations according to entrance times
parent
ba032769
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
dream/plugins/CapacityStations/CapacityStationGantt.py
dream/plugins/CapacityStations/CapacityStationGantt.py
+11
-1
No files found.
dream/plugins/CapacityStations/CapacityStationGantt.py
View file @
423cf03c
...
...
@@ -54,6 +54,16 @@ class CapacityStationGantt(plugin.OutputPreparationPlugin, TimeSupportMixin):
entranceTime
=
entranceTime
)
# sort the tasks for an order according to the entrance time of the first component
for
task_id
,
task
in
task_dict
.
iteritems
():
if
not
task
.
get
(
'entranceTime'
,
None
):
childrenTimes
=
[]
for
t_id
,
t
in
task_dict
.
iteritems
():
if
t
.
get
(
'parent'
,
None
)
==
task_id
and
not
(
t
.
get
(
'entranceTime'
,
None
)
==
None
):
childrenTimes
.
append
(
t
[
'entranceTime'
])
if
childrenTimes
:
task
[
'entranceTime'
]
=
min
(
childrenTimes
)
# return the result to the gadget
result
[
self
.
configuration_dict
[
'output_id'
]]
=
dict
(
time_unit
=
self
.
getTimeUnitText
(),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment