Index: trunk/extensions/ArticleFeedbackv5/modules/jquery.articleFeedbackv5/jquery.articleFeedbackv5.special.js |
— | — | @@ -1138,8 +1138,17 @@ |
1139 | 1139 | 'apiFlagType': 'delete', |
1140 | 1140 | 'apiFlagDir': 1, |
1141 | 1141 | 'onSuccess': function( id, data ) { |
| 1142 | + // if there is a "decline oversight" just hide it |
| 1143 | + var $link = $( '#articleFeedbackv5-declineoversight-link-' + id ).hide(); |
1142 | 1144 | |
1143 | | - // First we must possibly show |
| 1145 | + // Oversight is going to hide this as well, do the unhide/hide toggle |
| 1146 | + var $link = $( '#articleFeedbackv5-hide-link-' + id ) |
| 1147 | + .attr( 'action', 'show' ) |
| 1148 | + .attr( 'id', 'articleFeedbackv5-show-link-' + id ) |
| 1149 | + .text( mw.msg( 'articlefeedbackv5-form-unhide' ) ) |
| 1150 | + .removeClass( 'articleFeedbackv5-hide-link' ) |
| 1151 | + .addClass( 'articleFeedbackv5-show-link' ); |
| 1152 | + |
1144 | 1153 | var $link = $( '#articleFeedbackv5-oversight-link-' + id ) |
1145 | 1154 | .attr( 'action', 'unoversight' ) |
1146 | 1155 | .attr( 'id', 'articleFeedbackv5-unoversight-link-' + id ) |
— | — | @@ -1162,6 +1171,9 @@ |
1163 | 1172 | 'apiFlagType': 'delete', |
1164 | 1173 | 'apiFlagDir': -1, |
1165 | 1174 | 'onSuccess': function( id, data ) { |
| 1175 | + // if there is a "decline oversight" just show it |
| 1176 | + var $link = $( '#articleFeedbackv5-declineoversight-link-' + id ).show(); |
| 1177 | + |
1166 | 1178 | var $link = $( '#articleFeedbackv5-unoversight-link-' + id ) |
1167 | 1179 | .attr( 'action', 'oversight' ) |
1168 | 1180 | .attr( 'id', 'articleFeedbackv5-oversight-link-' + id ) |