+ }); // post rest/use
+
+ $('button#addusers').click(function() {
+ $.post("/update/slice/",{'filters':{'slice_hrn':'{{slice}}'},'params':{'users':slice_users}}, function(data) {
+ if(data.success){
+ // TODO: highlight row after success
+ //$('tr[id="'+record_id+'"]').highlight();
+ mysliceAlert('Success: slice updated','success', true);
+ }else{
+ mysliceAlert('Rest Error for: '+data.error,'warning', true);
+ }
+ }); // post update slice
+ emails = slice_users_emails.concat(slice_users_emails_removed);
+ $.post("/credentials/clear/",{'emails':emails}, function(data) {
+ }); // post credentials clear
+
+ }); // button#addusers click
+
+ } // get_users_in_slice