mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-26 16:48:49 +01:00
replace no longer used and existing <et2-tree-multiple.../> with <et2-tree multiple="true".../>
This commit is contained in:
parent
16b98ce4d1
commit
1913b66b2c
@ -420,22 +420,24 @@ function send_template()
|
||||
return "<et2-date$matches[1] $matches[2]></et2-date$matches[1]>";
|
||||
}, $str);
|
||||
|
||||
// replace <tree(-cat)? multiple="..." with <et2-tree(-cat)(-multiple) and fix attributes
|
||||
// replace <tree(-cat)? multiple="..." with <et2-tree(-cat) and fix attributes
|
||||
$str = preg_replace_callback('#<tree(-cat)?\s(.*?)\s*/>#s', static function (array $matches)
|
||||
{
|
||||
$tag = 'et2-tree'.($matches[1] ?? '');
|
||||
$attrs = parseAttrs($matches[2]);
|
||||
if (!empty($attrs['multiple']) && $attrs['multiple'] !== 'false' ||
|
||||
!empty($attrs['options']) && (int)$attrs['options'] > 1)
|
||||
if (!empty($attrs['options']) && (int)$attrs['options'] > 1)
|
||||
{
|
||||
$tag .= '-multiple';
|
||||
$attrs['multiple'] = 'true';
|
||||
}
|
||||
// fix renamed attrs, thought regular under_score to camelCase happens later
|
||||
if (!empty($attrs['parent_node'])) $attrs['parentId'] = $attrs['parent_node'];
|
||||
unset($attrs['multiple'], $attrs['options'], $attrs['parent_node']);
|
||||
unset($attrs['options'], $attrs['parent_node']);
|
||||
return "<$tag" . stringAttrs($attrs) . "></$tag>";
|
||||
}, $str);
|
||||
|
||||
// replace no longer used <et2-tree-multiple.../> with <et2-tree multiple="true".../>
|
||||
$str = preg_replace('#<et2-tree-multiple ([^>]+)(/>|</et2-tree-multiple>)#', '<et2-tree multiple="true" $1></et2-tree>', $str);
|
||||
|
||||
if ($template === 'mobile')
|
||||
{
|
||||
}
|
||||
|
@ -6,7 +6,9 @@
|
||||
<et2-description value="Folder Management" class="mail_folder_management_header"></et2-description>
|
||||
</et2-hbox>
|
||||
<et2-hbox class="treeContainer">
|
||||
<et2-tree-multiple id="tree" multiple="true" autoloading="mail_ui::ajax_folderMgmtTree_autoloading" multimarking="strict" oncheck="app.mail.folderMgmt_onCheck" onselect="app.mail.folderMgmt_onSelect" onopenstart="app.mail.folderMgmt_autoloadingStart" onopenend="app.mail.folderMgmt_autoloadingEnd" highlighting="true"/>
|
||||
<et2-tree id="tree" multiple="true" autoloading="mail_ui::ajax_folderMgmtTree_autoloading" multimarking="strict"
|
||||
oncheck="app.mail.folderMgmt_onCheck" onselect="app.mail.folderMgmt_onSelect" onopenstart="app.mail.folderMgmt_autoloadingStart"
|
||||
onopenend="app.mail.folderMgmt_autoloadingEnd" highlighting="true"></et2-tree>
|
||||
</et2-hbox>
|
||||
<et2-hbox class="dialogFooterToolbar">
|
||||
<et2-button statustext="Delete" label="Delete" id="button[delete]" onclick="app.mail.folderMgmt_deleteBtn"></et2-button>
|
||||
|
@ -6,7 +6,10 @@
|
||||
<et2-description value="Subscription folders" class="mail_subscription_header"></et2-description>
|
||||
</et2-hbox>
|
||||
<et2-hbox class="treeContainer">
|
||||
<et2-tree-multiple id="foldertree" multiple="true" autoloading="mail_ui::ajax_tree_autoloading" onopenstart="app.mail.subscription_autoloadingStart" onopenend="app.mail.subscription_autoloadingEnd" multimarking="strict" highlighting="true" oncheck="app.mail.folderMgmt_onCheck" onselect="app.mail.folderMgmt_onSelect"/>
|
||||
<et2-tree id="foldertree" multiple="true" autoloading="mail_ui::ajax_tree_autoloading"
|
||||
onopenstart="app.mail.subscription_autoloadingStart" onopenend="app.mail.subscription_autoloadingEnd"
|
||||
multimarking="strict" highlighting="true" oncheck="app.mail.folderMgmt_onCheck"
|
||||
onselect="app.mail.folderMgmt_onSelect"></et2-tree>
|
||||
</et2-hbox>
|
||||
<et2-hbox class="dialogFooterToolbar">
|
||||
<et2-button statustext="Saves subscription changes" label="Save" id="button[save]"></et2-button>
|
||||
|
Loading…
Reference in New Issue
Block a user