Changeset 25479 for trunk/admin/themes/default
- Timestamp:
- Nov 13, 2013, 8:43:49 PM (10 years ago)
- Location:
- trunk/admin/themes/default
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/themes/default/template/user_list.tpl
r25475 r25479 113 113 userDetails += '<div class="userActions">'; 114 114 userDetails += '<a class="icon-key" href="#">Change password</a>'; 115 userDetails += '<br><a href="#" class="icon-lock">Permissions</a>';116 userDetails += '<br>< a href="#" class="icon-trash">Delete</a>';115 userDetails += '<br><a target="_blank" href="admin.php?page=user_perm&user_id='+userId+'" class="icon-lock">Permissions</a>'; 116 userDetails += '<br><span class="userDelete"><img class="loading" src="themes/default/images/ajax-loader-small.gif" style="display:none;"><a href="#" class="icon-trash" data-user_id="'+userId+'">Delete</a></span>'; 117 117 userDetails += '</div>'; 118 userDetails += '<strong >'+user.username+'</strong> <span class="icon-pencil"></span>';118 userDetails += '<strong class="username">'+user.username+'</strong> <span class="icon-pencil"></span>'; 119 119 userDetails += '<br><br>'; 120 120 userDetails += sprintf(registeredOn_pattern, user.registration_date_string, user.registration_date_since); … … 227 227 userDetails += '<div style="clear:both"></div></div>'; 228 228 229 userDetails += '<span class="infos" style="display:none">✔ User updated</span>';230 userDetails += '<input type="submit" value="{/literal}{' Save Settings'|translate}{literal}" style="display:none;" data-user_id="'+userId+'">';229 userDetails += '<span class="infos" style="display:none">✔ User '+user.username+' updated</span>'; 230 userDetails += '<input type="submit" value="{/literal}{'Update user'|translate}{literal}" style="display:none;" data-user_id="'+userId+'">'; 231 231 userDetails += '<img class="submitWait" src="themes/default/images/ajax-loader-small.gif" style="display:none">' 232 232 userDetails += '</form>'; … … 252 252 jQuery('#user'+userId+' input[type=submit]').show(); 253 253 jQuery('#user'+userId+' .infos').hide(); 254 }); 255 256 jQuery(document).on('click', '.userDelete a', function() { 257 if (!confirm("{/literal}{'Are you sure?'|translate|escape:javascript}{literal}")) { 258 return false; 259 } 260 261 var userId = jQuery(this).data('user_id'); 262 var username = jQuery('#user'+userId+' .username').html(); 263 264 jQuery.ajax({ 265 url: "ws.php?format=json&method=pwg.users.delete", 266 type:"POST", 267 data: { 268 user_id:userId, 269 pwg_token:pwg_token 270 }, 271 beforeSend: function() { 272 jQuery('#user'+userId+' .userDelete .loading').show(); 273 }, 274 success:function(data) { 275 oTable.fnDraw(); 276 jQuery('#showAddUser .infos').html('✔ User '+username+' deleted').show(); 277 }, 278 error:function(XMLHttpRequest, textStatus, errorThrows) { 279 jQuery('#user'+userId+' .userDelete .loading').hide(); 280 } 281 }); 282 283 return false; 254 284 }); 255 285 … … 594 624 #applyActionBlock .actionButtons {margin-left:0;} 595 625 span.infos, span.errors {background-image:none; padding:2px 5px; margin:0;border-radius:5px;} 596 597 .userProperties {max-width:730px;}598 .userPropertiesContainer {border-top:1px solid #ddd;margin-top:1em;}599 .userPropertiesSet {width:350px;float:left;padding-top:5px}600 .userPropertiesSetTitle {font-weight:bold;margin-bottom:1em;}601 .userPrefs {border-left:1px solid #ddd;padding-left:10px;}602 .userProperty {width:220px;float:left;margin-bottom:15px;}603 604 .userActions {float:right;text-align:right;}605 626 </style> 606 627 {/literal} -
trunk/admin/themes/default/theme.css
r25457 r25479 1146 1146 cursor:pointer; 1147 1147 } 1148 1149 .userProperties {max-width:730px;} 1150 .userPropertiesContainer {border-top:1px solid #ddd;margin-top:1em;} 1151 .userPropertiesSet {width:350px;float:left;padding-top:5px} 1152 .userPropertiesSetTitle {font-weight:bold;margin-bottom:1em;} 1153 .userPrefs {border-left:1px solid #ddd;padding-left:10px;} 1154 .userProperty {width:220px;float:left;margin-bottom:15px;} 1155 .userActions {float:right;text-align:right;} 1156
Note: See TracChangeset
for help on using the changeset viewer.