Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
intranet-gantt-editor
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
project-open
intranet-gantt-editor
Commits
9f98ba69
Commit
9f98ba69
authored
Aug 05, 2020
by
Frank Bergmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Implemented scheduling of lag times
parent
8056c3ae
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
0 deletions
+21
-0
GanttSchedulingController.js
www/controller/GanttSchedulingController.js
+21
-0
No files found.
www/controller/GanttSchedulingController.js
View file @
9f98ba69
...
...
@@ -751,6 +751,23 @@ Ext.define('GanttEditor.controller.GanttSchedulingController', {
************************************************************************************** */
/**
* Returns the "time" milliseconds of a dependency lag
*/
dependencyLagTime
:
function
(
depModel
)
{
var
me
=
this
;
var
diff
=
depModel
.
diff
;
if
(
!
diff
)
diff
=
0.0
;
var
diff_factor
=
me
.
dependencyPropertyPanel
.
dependencyFormatFactor
(
depModel
.
diff_format_id
);
var
result
=
1000.0
*
diff
*
diff_factor
;
if
(
result
!=
0.0
)
{
console
.
log
(
'dependencyLagTime: lag='
+
result
);
}
return
result
;
},
/**
* Check the planned units vs. assigned resources percentage.
...
...
@@ -848,6 +865,10 @@ Ext.define('GanttEditor.controller.GanttSchedulingController', {
return
;
}
// Calculage the time (milliseconds) of the lag time in the dependency
var
lagTime
=
me
.
dependencyLagTime
(
dep
);
diff
=
diff
+
lagTime
;
if
(
diff
>
0
)
{
// Round the diff to the next hour and check if the difference is max. 1 minute
var
diffRoundedByHour
=
Math
.
round
(
diff
/
(
3600.0
*
1000.0
))
*
(
3600.0
*
1000.0
);
...
...
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