mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-08 00:54:50 +01:00
Retrive accidentally removed delete and undelete nm_popup templates from calendar listview temp by commit 45376. Additionally, fix error calling cal_delete for deleting recurrent events from listview
This commit is contained in:
parent
d948e10598
commit
7f5af09f87
@ -925,46 +925,16 @@ app.classes.calendar = AppJS.extend(
|
|||||||
}
|
}
|
||||||
if (matches)
|
if (matches)
|
||||||
{
|
{
|
||||||
var id = matches[1];
|
var popup = jQuery('#calendar-list_delete_popup').get(0);
|
||||||
var date = matches[2];
|
if (typeof popup != 'undefined')
|
||||||
var popup = jQuery(document.getElementById(_action.getManager().etemplate_var_prefix + '[' + _action.id + '_popup]'));
|
|
||||||
var row = null;
|
|
||||||
|
|
||||||
// Cancel normal confirm
|
|
||||||
delete _action.data.confirm;
|
|
||||||
delete _action.data.confirm_multiple;
|
|
||||||
|
|
||||||
// nm action - show popup
|
|
||||||
nm_open_popup(_action,_senders);
|
|
||||||
|
|
||||||
if(!popup)
|
|
||||||
{
|
{
|
||||||
return;
|
// nm action - show popup
|
||||||
}
|
nm_open_popup(_action,_senders);
|
||||||
row = jQuery("#"+id+"\\:"+date);
|
|
||||||
if (row)
|
|
||||||
{
|
|
||||||
// Open at row
|
|
||||||
popup.css({
|
|
||||||
position: "absolute",
|
|
||||||
top: row.position().top + row.height() -popup.height()/2,
|
|
||||||
left: $j(window).width()/2-popup.width()/2
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
// Open popup in the middle
|
|
||||||
popup.css({
|
|
||||||
position: "absolute",
|
|
||||||
top: $j(window).height()/2-popup.height()/2,
|
|
||||||
left: $j(window).width()/2-popup.width()/2
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log(_action);
|
|
||||||
nm_action(_action, _senders);
|
nm_action(_action, _senders);
|
||||||
|
|
||||||
_action.data = backup; // restore url, width, height, nm_action
|
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -118,6 +118,33 @@
|
|||||||
<row>
|
<row>
|
||||||
<nextmatch id="nm" template="calendar.list.rows" span="all"/>
|
<nextmatch id="nm" template="calendar.list.rows" span="all"/>
|
||||||
</row>
|
</row>
|
||||||
|
<row>
|
||||||
|
<hbox>
|
||||||
|
<box class="action_popup prompt" id="delete_popup">
|
||||||
|
<vbox>
|
||||||
|
<description value="Delete" class="promptheader"/>
|
||||||
|
<description value="Do you want to delete this event as an exception, or delete the whole series?"/>
|
||||||
|
<hbox>
|
||||||
|
<button label="Delete exception" id="delete" onclick="nm_submit_popup(this); return false;"/>
|
||||||
|
<button label="Delete series" id="delete_series" onclick="nm_popup_action.id = 'delete_series'; nm_submit_popup(this); return false;"/>
|
||||||
|
<buttononly label="Cancel" onclick="nm_hide_popup(this,'delete_popup');"/>
|
||||||
|
</hbox>
|
||||||
|
</vbox>
|
||||||
|
</box>
|
||||||
|
<box class="action_popup prompt" id="undelete_popup">
|
||||||
|
<vbox>
|
||||||
|
<description value="Un-delete" class="promptheader"/>
|
||||||
|
<description value="Do you want to Un-delete this event as an exception, or un-delete the whole series?"/>
|
||||||
|
<hbox>
|
||||||
|
<button label="Un-delete exception" id="undelete" onclick="nm_submit_popup(this); return false;"/>
|
||||||
|
<button label="Un-delete series" id="undelete_series" onclick="nm_popup_action.id = 'undelete_series'; nm_submit_popup(this); return false;"/>
|
||||||
|
<buttononly label="Cancel" onclick="nm_hide_popup(this,'undelete_popup');"/>
|
||||||
|
</hbox>
|
||||||
|
</vbox>
|
||||||
|
</box>
|
||||||
|
</hbox>
|
||||||
|
<description/>
|
||||||
|
</row>
|
||||||
</rows>
|
</rows>
|
||||||
</grid>
|
</grid>
|
||||||
<styles>
|
<styles>
|
||||||
|
Loading…
Reference in New Issue
Block a user