1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-01-03 03:11:01 +01:00

Add a task count to workboards

Summary: See Q335. This might need some tweaking, but the JS works now so we can move/style the node now.

Test Plan:
{F1169168}

  - Also dragged stuff around, saw counts update properly.

Reviewers: chad

Reviewed By: chad

Differential Revision: https://secure.phabricator.com/D15462
This commit is contained in:
epriestley 2016-03-10 18:54:17 -08:00
parent d511308a79
commit 5df5f33909
2 changed files with 13 additions and 6 deletions

View file

@ -421,7 +421,7 @@ return array(
'rsrc/js/application/policy/behavior-policy-rule-editor.js' => '5e9f347c',
'rsrc/js/application/projects/WorkboardBoard.js' => '52291776',
'rsrc/js/application/projects/WorkboardCard.js' => 'c587b80f',
'rsrc/js/application/projects/WorkboardColumn.js' => 'f05d6e5d',
'rsrc/js/application/projects/WorkboardColumn.js' => 'bae58312',
'rsrc/js/application/projects/WorkboardController.js' => '55baf5ed',
'rsrc/js/application/projects/behavior-project-boards.js' => '14a1faae',
'rsrc/js/application/projects/behavior-project-create.js' => '065227cc',
@ -732,7 +732,7 @@ return array(
'javelin-websocket' => 'e292eaf4',
'javelin-workboard-board' => '52291776',
'javelin-workboard-card' => 'c587b80f',
'javelin-workboard-column' => 'f05d6e5d',
'javelin-workboard-column' => 'bae58312',
'javelin-workboard-controller' => '55baf5ed',
'javelin-workflow' => '5b2e3e2b',
'lightbox-attachment-css' => '7acac05d',
@ -1794,6 +1794,10 @@ return array(
'b6b0d1bb' => array(
'phui-inline-comment-view-css',
),
'bae58312' => array(
'javelin-install',
'javelin-workboard-card',
),
'bcaccd64' => array(
'javelin-behavior',
'javelin-behavior-device',
@ -2062,10 +2066,6 @@ return array(
'javelin-workflow',
'javelin-json',
),
'f05d6e5d' => array(
'javelin-install',
'javelin-workboard-card',
),
'f411b6ae' => array(
'javelin-behavior',
'javelin-stratcom',

View file

@ -221,6 +221,7 @@ JX.install('WorkboardColumn', {
var board = this.getBoard();
var points = {};
var count = 0;
for (var phid in cards) {
var card = cards[phid];
@ -238,6 +239,8 @@ JX.install('WorkboardColumn', {
}
points[status] += card_points;
}
count++;
}
var total_points = 0;
@ -254,6 +257,10 @@ JX.install('WorkboardColumn', {
display_value = total_points;
}
if (board.getPointsEnabled()) {
display_value = count + ' | ' + display_value;
}
var over_limit = ((limit !== null) && (total_points > limit));
var content_node = this.getPointsContentNode();