Advertisement
Guest User

Untitled

a guest
Sep 21st, 2017
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.86 KB | None | 0 0
  1. function deleteAssignmentById(assignmentId, folderId){
  2. removeAssignment('#removeAssignment', assignmentId, folderId);
  3. }
  4.  
  5. function removeAssignment(infoHtml_, assignmentId, folderId) {
  6.  
  7.  
  8. //infoHtml = infoHtml_;
  9.  
  10. infoHtml = $j(infoHtml_).html();
  11.  
  12.  
  13. function send(ok) {
  14.  
  15. if (!ok) return ;
  16. $j.ajax({
  17. url : '<?php echo url_for('bespoke/EditAssignmentData'); ?>',
  18. data: {assignmentToDeleteId: assignmentId, assignmentToDeleteFolderId: folderId, typeOfActionId : '6'},
  19. type: 'POST',
  20. success: function()
  21. { window.location.reload(); }
  22. });
  23. }
  24.  
  25. var buttons = {};
  26. buttons[__('res_ok')] = 1;
  27. buttons[__('res_cancel')] = 0;
  28. $j.prompt(infoHtml, {
  29. buttons : buttons,
  30. submit : send
  31. });
  32. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement