Page MenuHomePhabricator

D18447.diff
No OneTemporary

D18447.diff

diff --git a/src/applications/diffusion/view/DiffusionBranchListView.php b/src/applications/diffusion/view/DiffusionBranchListView.php
--- a/src/applications/diffusion/view/DiffusionBranchListView.php
+++ b/src/applications/diffusion/view/DiffusionBranchListView.php
@@ -74,14 +74,6 @@
}
}
- $fields = $branch->getRawFields();
- $closed = idx($fields, 'closed');
- if ($closed) {
- $status = pht('Closed');
- } else {
- $status = pht('Open');
- }
-
$browse_href = $drequest->generateURI(
array(
'action' => 'browse',
@@ -129,6 +121,18 @@
}
$item->addAttribute(array($datetime));
+ if ($can_close_branches) {
+ $fields = $branch->getRawFields();
+ $closed = idx($fields, 'closed');
+ if ($closed) {
+ $status = pht('Branch Closed');
+ $item->setDisabled(true);
+ } else {
+ $status = pht('Branch Open');
+ }
+ $item->addAttribute($status);
+ }
+
$list->addItem($item);
}

File Metadata

Mime Type
text/plain
Expires
Thu, Nov 7, 12:02 AM (1 w, 1 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6720722
Default Alt Text
D18447.diff (1 KB)

Event Timeline