Skip to content

Commit

Permalink
Merge pull request #60 from bitovi/change-instance
Browse files Browse the repository at this point in the history
round numbers and sort correctly
  • Loading branch information
justinbmeyer authored Jun 13, 2024
2 parents 5f75fd0 + 88ff381 commit 31174c0
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 11 deletions.
10 changes: 6 additions & 4 deletions public/critical-path-report.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class CriticalPathReport extends StacheElement {
<a class="link cursor-pointer"
href="{{criticalPath.workItem.work.issue.url}}">{{criticalPath.workItem.work.issue.Summary}}</a>
</div>
<div>{{criticalPath.totalDaysInCriticalPath}}</div>
<div>{{this.round(criticalPath.totalDaysInCriticalPath)}}</div>
<div>
<ul>
{{# for(workItem of criticalPath.blockedPath) }}
Expand All @@ -29,7 +29,7 @@ class CriticalPathReport extends StacheElement {
{{/ }}
</ul>
</div>
<div>{{criticalPath.totalDaysAcrossAllBlockedWork}}</div>
<div>{{this.round(criticalPath.totalDaysAcrossAllBlockedWork)}}</div>
<div>
<ul>
{{# for(workItem of criticalPath.otherBlockedWork) }}
Expand All @@ -49,7 +49,9 @@ class CriticalPathReport extends StacheElement {
workItems: type.Any,
showing: false,
};

round(number){
return Math.round(number);
}
get criticalPaths(){
console.log(this.workItems)

Expand Down Expand Up @@ -112,7 +114,7 @@ class CriticalPathReport extends StacheElement {
// these are the critical blocks of work
const isolatedCriticalPaths = criticalPaths.filter( cp => cp.include).map( cp => {
return {...cp, otherBlockedWork: [...cp.otherBlockedWork]}
});
}).sort((cpA, cpB)=> cpB.totalDaysInCriticalPath - cpA.totalDaysInCriticalPath);
console.log(isolatedCriticalPaths)
return isolatedCriticalPaths;
}
Expand Down
4 changes: 2 additions & 2 deletions public/dist/main-4wwoLG4f.js → public/dist/main-Do6sF2Ym.js

Large diffs are not rendered by default.

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/dist/main.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 31174c0

Please sign in to comment.