mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-24 06:20:56 +01:00
Straighten out some stacked action removal behaviors
Summary: Fixes T12065. Some of the normal behavior of these actions got juggled when I made "Accept" and "Reject" conflict. Test Plan: - Added "Accept". - Added "Reject", saw it remove "Accept". - Added "Change Projects". - Added "Assign/Claim". - Removed "Assign/Claim". - Removed "Accept". Reviewers: chad Reviewed By: chad Maniphest Tasks: T12065 Differential Revision: https://secure.phabricator.com/D17143
This commit is contained in:
parent
96fbf37dcc
commit
4b94ae15e0
1 changed files with 3 additions and 3 deletions
|
@ -146,7 +146,7 @@ JX.behavior('comment-actions', function(config) {
|
||||||
var conflict_key = action.conflictKey || null;
|
var conflict_key = action.conflictKey || null;
|
||||||
if (conflict_key !== null) {
|
if (conflict_key !== null) {
|
||||||
for (var k in action_map) {
|
for (var k in action_map) {
|
||||||
if (k === action) {
|
if (k === action.key) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (action_map[k].conflictKey !== conflict_key) {
|
if (action_map[k].conflictKey !== conflict_key) {
|
||||||
|
@ -189,7 +189,7 @@ JX.behavior('comment-actions', function(config) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
remove_action(action);
|
remove_action(action.key);
|
||||||
});
|
});
|
||||||
|
|
||||||
rows[action.key] = {
|
rows[action.key] = {
|
||||||
|
@ -200,7 +200,7 @@ JX.behavior('comment-actions', function(config) {
|
||||||
|
|
||||||
JX.DOM.listen(remove, 'click', null, function(e) {
|
JX.DOM.listen(remove, 'click', null, function(e) {
|
||||||
e.kill();
|
e.kill();
|
||||||
remove_action(action);
|
remove_action(action.key);
|
||||||
});
|
});
|
||||||
|
|
||||||
place_node.parentNode.insertBefore(node, place_node);
|
place_node.parentNode.insertBefore(node, place_node);
|
||||||
|
|
Loading…
Reference in a new issue