60 } |
58 } |
61 }); |
59 }); |
62 } |
60 } |
63 else { |
61 else { |
64 if (!newVersion) { |
62 if (!newVersion) { |
|
63 |
65 var message = gettext("You chose not to create a new version all comments will be deleted") ; |
64 var message = gettext("You chose not to create a new version all comments will be deleted") ; |
66 message += '<br />' ; |
65 message += '<br />' ; |
67 message += gettext( 'Do you want to continue?') ; |
66 message += gettext( 'Do you want to continue?') ; |
68 $('#confirm_all_removed').html(message) ; |
67 $('#confirm_all_removed_dlg').html(message) ; |
69 $('#confirm_all_removed').dialog('open') ; |
68 $('#confirm_all_removed_dlg').dialog('open') ; |
70 } |
69 } |
71 else { |
70 else { |
72 $('#edit_form').submit(); |
71 $('#edit_form').submit(); |
73 } |
72 } |
74 } |
73 } |
75 } |
74 } |
76 |
75 |
77 $(function() { |
76 $(function() { |
78 var buttons = {}; |
77 var buttons = {}; |
79 buttons[gettext('No')] = function() {$(this).dialog('close');} ; |
78 buttons[gettext('No')] = function() { |
80 buttons[gettext('Yes')] = function() {$(this).dialog('close');$('#edit_form').submit();} ; |
79 $(this).dialog('close'); |
|
80 } ; |
|
81 buttons[gettext('Yes')] = function() { |
|
82 needToConfirm = false; |
|
83 $(this).dialog('close');$('#edit_form').submit(); |
|
84 } ; |
81 |
85 |
82 $('#confirm_all_removed').dialog({ |
86 $('#confirm_all_removed_dlg').dialog({ |
83 bgiframe: true, |
87 bgiframe: true, |
84 autoOpen: false, |
88 autoOpen: false, |
85 title :gettext('Warning'), |
89 title :gettext('Warning'), |
86 modal: true, |
90 modal: true, |
87 buttons:buttons |
91 buttons:buttons |
88 }) ; |
92 }) ; |
89 |
93 |
90 var buttons0 = {}; |
94 var buttons0 = {}; |
91 buttons0[gettext('Detach')] = function() {$(this).dialog('close');$('#cancel_modified_scopes').val("1");$('#edit_form').submit();} ; |
95 buttons0[gettext('Detach')] = function() { |
92 buttons0[gettext('Remove')] = function() {$(this).dialog('close');$('#cancel_modified_scopes').val("0");$('#edit_form').submit();} ; |
96 needToConfirm = false; |
|
97 $(this).dialog('close');$('#cancel_modified_scopes').val("1");$('#edit_form').submit(); |
|
98 } ; |
|
99 buttons0[gettext('Remove')] = function() { |
|
100 needToConfirm = false; |
|
101 $(this).dialog('close');$('#cancel_modified_scopes').val("0");$('#edit_form').submit(); |
|
102 } ; |
93 buttons0[gettext('Cancel')] = function() {$(this).dialog('close');} ; |
103 buttons0[gettext('Cancel')] = function() {$(this).dialog('close');} ; |
94 |
104 |
95 $('#remove_scope_choice_dlg').dialog({ |
105 $('#remove_scope_choice_dlg').dialog({ |
96 bgiframe: true, |
106 bgiframe: true, |
97 autoOpen: false, |
107 autoOpen: false, |