mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-23 07:09:20 +01:00
fixed editing of versions other then the latest version
This commit is contained in:
parent
9d9de69793
commit
88577483bd
@ -1529,13 +1529,16 @@
|
|||||||
if (is_array($content))
|
if (is_array($content))
|
||||||
{
|
{
|
||||||
$path = $content['goto'] ? $content['goto'] : ($content['goto2'] ? $content['goto2'] : $content['path']);
|
$path = $content['goto'] ? $content['goto'] : ($content['goto2'] ? $content['goto2'] : $content['path']);
|
||||||
$Ok = $this->etemplate->read($content['name'],$content['template'],$content['lang'],$content['old_version']);
|
$Ok = $this->etemplate->read($content['name'],$content['template'],$content['lang'],0,$path ? $content['version'] : $content['old_version']);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//echo "<p><b>".($_GET['path']).":</b></p>\n";
|
//echo "<p><b>".($_GET['path']).":</b></p>\n";
|
||||||
list($name,$path) = explode(':',$_GET['path'],2); // <name>:<path>
|
list($name,$version,$path) = explode(':',$_GET['path'],3); // <name>:<version>:<path>
|
||||||
$Ok = $this->etemplate->read($name);
|
$Ok = $this->etemplate->read(array(
|
||||||
|
'name' => $name,
|
||||||
|
'version' => $version,
|
||||||
|
));
|
||||||
}
|
}
|
||||||
if (!$Ok && !$content['cancel'])
|
if (!$Ok && !$content['cancel'])
|
||||||
{
|
{
|
||||||
|
@ -958,7 +958,7 @@
|
|||||||
if (!isset($cell['obj']->onclick_handler)) $cell['obj']->onclick_handler = $this->onclick_handler;
|
if (!isset($cell['obj']->onclick_handler)) $cell['obj']->onclick_handler = $this->onclick_handler;
|
||||||
if ($cell['obj']->no_onclick)
|
if ($cell['obj']->no_onclick)
|
||||||
{
|
{
|
||||||
$cell['obj']->onclick_proxy = $this->onclick_proxy ? $this->onclick_proxy : $this->name.':'.$path;
|
$cell['obj']->onclick_proxy = $this->onclick_proxy ? $this->onclick_proxy : $this->name.':'.$this->version.':'.$path;
|
||||||
}
|
}
|
||||||
$html = $cell['obj']->show($content,$this->sel_options,$readonlys,$cname,$show_c,$show_row);
|
$html = $cell['obj']->show($content,$this->sel_options,$readonlys,$cname,$show_c,$show_row);
|
||||||
break;
|
break;
|
||||||
@ -1253,7 +1253,7 @@
|
|||||||
//echo "<p>$this->name($this->onclick_handler:$this->no_onclick:$this->onclick_proxy): $cell[type]/$cell[name]</p>\n";
|
//echo "<p>$this->name($this->onclick_handler:$this->no_onclick:$this->onclick_proxy): $cell[type]/$cell[name]</p>\n";
|
||||||
if ($this->onclick_handler && !isset($this->widgets_with_children[$cell['type']]))
|
if ($this->onclick_handler && !isset($this->widgets_with_children[$cell['type']]))
|
||||||
{
|
{
|
||||||
$handler = str_replace('%p',$this->no_onclick ? $this->onclick_proxy : $this->name.':'.$path,
|
$handler = str_replace('%p',$this->no_onclick ? $this->onclick_proxy : $this->name.':'.$this->version.':'.$path,
|
||||||
$this->onclick_handler);
|
$this->onclick_handler);
|
||||||
if ($type == 'button' || !$label) // add something to click on
|
if ($type == 'button' || !$label) // add something to click on
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user