mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-26 18:03:39 +01:00
Open series popup at mouse click instead of in the middle
This commit is contained in:
parent
eb40104d5b
commit
819da0ec6f
@ -1027,7 +1027,7 @@ class calendar_uiviews extends calendar_ui
|
|||||||
return $tpl->show(array()).'<script type="text/javascript">
|
return $tpl->show(array()).'<script type="text/javascript">
|
||||||
var calendar_edit_id;
|
var calendar_edit_id;
|
||||||
var calendar_edit_date;
|
var calendar_edit_date;
|
||||||
function edit_series(id,date)
|
function edit_series(event,id,date)
|
||||||
{
|
{
|
||||||
calendar_edit_id = id;
|
calendar_edit_id = id;
|
||||||
calendar_edit_date = date;
|
calendar_edit_date = date;
|
||||||
@ -1035,8 +1035,8 @@ function edit_series(id,date)
|
|||||||
var popup = jQuery("#edit_series").show();
|
var popup = jQuery("#edit_series").show();
|
||||||
popup.css({
|
popup.css({
|
||||||
position: "absolute",
|
position: "absolute",
|
||||||
top: $j(window).height()/2-popup.height()/2,
|
top: event.pageY,
|
||||||
left: $j(window).width()/2-popup.width()/2
|
left: (event.pageX + popup.width() > $j(window).width() ? $j(window).width() - popup.width() : event.pageX)
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
function open_edit(series)
|
function open_edit(series)
|
||||||
@ -1842,7 +1842,7 @@ function open_edit(series)
|
|||||||
{
|
{
|
||||||
if ($event['recur_type'] != MCAL_RECUR_NONE)
|
if ($event['recur_type'] != MCAL_RECUR_NONE)
|
||||||
{
|
{
|
||||||
$popup = ' onclick="edit_series('.$event['id'].','.$this->bo->date2string($event['start']).');"';
|
$popup = ' onclick="edit_series(event,'.$event['id'].','.$this->bo->date2string($event['start']).');"';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user