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
18225f88
Commit
18225f88
authored
Jan 12, 2021
by
Project Open
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Fixed issue with wrong intra-project overassignment warnings
parent
28c7e60d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
8 deletions
+12
-8
GanttBarPanel.adp
www/view/GanttBarPanel.adp
+12
-8
No files found.
www/view/GanttBarPanel.adp
View file @
18225f88
...
...
@@ -483,14 +483,21 @@ Ext.define('GanttEditor.view.GanttBarPanel', {
userHash[objectId] = {startX: startX, endX: endX, name: objectName, type: type, userName: user_name, contextId: context_id, context: context};
});
// Iterate through all children of the root node and check if they are visible
var rootNode = me.objectStore.getRootNode();
rootNode.cascadeBy(function(task) {
// Skip summary activities (tasks with children)
var children = task.childNodes;
if (Array.isArray(children)) {
var numChildren = children.length;
if (numChildren > 0) return;
}
var task_id = task.get('id');
var taskId = parseInt(task_id); if (!taskId) return;
var taskName = task.get('project_name');
var assignees = task.get('assignees'); // Array of {id, percent, name, email, initials}
var assignees = task.get('assignees');
// Array of {id, percent, name, email, initials}
var startDate, endDate;
// Get start- and end date (look at parents if necessary...)
...
...
@@ -502,7 +509,7 @@ Ext.define('GanttEditor.view.GanttBarPanel', {
var startDate = PO.Utilities.pgToDate(startDate);
var endDate = PO.Utilities.pgToDate(endDate);
if (!startDate) return;
// skip if invalid for some reason...
if (!startDate) return;
// skip if invalid for some reason...
if (!endDate) return;
var startTime = startDate.getTime();
var endTime = endDate.getTime();
...
...
@@ -510,14 +517,12 @@ Ext.define('GanttEditor.view.GanttBarPanel', {
var endX = me.date2x(endTime); // X position based on time scale
assignees.forEach(function(assignee) {
if (0 == assignee.percent) { return; } // Don't show empty assignments
if (0 == assignee.percent) { return; }
// Don't show empty assignments
var userId = assignee.user_id;
var userModel = projectMemberStore.getById(""+assignee.user_id);
if (!userModel) return;
var userName = userModel.get('name');
// Write to hash
var userHash = overHash[userId];
var userHash = overHash[userId]; // Write to hash
if (!userHash) {
userHash = {};
overHash[userId] = userHash;
...
...
@@ -526,7 +531,6 @@ Ext.define('GanttEditor.view.GanttBarPanel', {
});
});
me.overassignmentHash = overHash;
if (me.debug) { if (me.debug) console.log('PO.view.gantt.GanttBarPanel.setupOverassignments: Finished'); }
...
...
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