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
ba032769
Commit
ba032769
authored
Jun 25, 2015
by
Georgios Dagkakis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
reading of earliest start made more flexible
parent
4d9d99b5
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
dream/plugins/CapacityStations/CapacityProjectSpreadsheet.py
dream/plugins/CapacityStations/CapacityProjectSpreadsheet.py
+11
-1
No files found.
dream/plugins/CapacityStations/CapacityProjectSpreadsheet.py
View file @
ba032769
...
@@ -19,6 +19,15 @@ class CapacityProjectSpreadsheet(plugin.InputPreparationPlugin):
...
@@ -19,6 +19,15 @@ class CapacityProjectSpreadsheet(plugin.InputPreparationPlugin):
data
[
'input'
][
'BOM'
][
'productionOrders'
]
=
[]
data
[
'input'
][
'BOM'
][
'productionOrders'
]
=
[]
node
=
data
[
'graph'
][
'node'
]
node
=
data
[
'graph'
][
'node'
]
now
=
strptime
(
data
[
'general'
][
'currentDate'
],
'%Y/%m/%d'
)
now
=
strptime
(
data
[
'general'
][
'currentDate'
],
'%Y/%m/%d'
)
# find the column where the earliest start is given
i
=
0
for
element
in
projectData
[
0
]:
if
element
==
'Earliest Start Date'
:
earliestStartColumn
=
i
break
i
+=
1
if
projectData
:
if
projectData
:
alreadyConsideredProjects
=
[]
alreadyConsideredProjects
=
[]
for
row
in
range
(
1
,
len
(
projectData
)):
for
row
in
range
(
1
,
len
(
projectData
)):
...
@@ -46,11 +55,12 @@ class CapacityProjectSpreadsheet(plugin.InputPreparationPlugin):
...
@@ -46,11 +55,12 @@ class CapacityProjectSpreadsheet(plugin.InputPreparationPlugin):
break
break
numberOfOperations
+=
1
numberOfOperations
+=
1
i
+=
1
i
+=
1
# for every operation get capacityRequirementDict and earliestStartDict
# for every operation get capacityRequirementDict and earliestStartDict
for
stationRecord
in
range
(
numberOfOperations
):
for
stationRecord
in
range
(
numberOfOperations
):
stationId
=
projectData
[
row
+
stationRecord
][
4
]
stationId
=
projectData
[
row
+
stationRecord
][
4
]
requiredCapacity
=
projectData
[
row
+
stationRecord
][
5
]
requiredCapacity
=
projectData
[
row
+
stationRecord
][
5
]
earliestStart
=
projectData
[
row
+
stationRecord
][
6
]
earliestStart
=
projectData
[
row
+
stationRecord
][
earliestStartColumn
]
capacityRequirementDict
[
stationId
]
=
float
(
requiredCapacity
)
capacityRequirementDict
[
stationId
]
=
float
(
requiredCapacity
)
if
earliestStart
:
if
earliestStart
:
earliestStart
=
strptime
(
earliestStart
,
'%Y/%m/%d'
)
earliestStart
=
strptime
(
earliestStart
,
'%Y/%m/%d'
)
...
...
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