moved javascript action implementation into and object defined in app.js file

This commit is contained in:
Ralf Becker 2013-04-09 16:20:06 +00:00
parent 26f54eb8ce
commit 188ebbaec6
4 changed files with 122 additions and 103 deletions

View File

@ -5,7 +5,7 @@
* @link http://www.egroupware.org
* @package filemanager
* @author Ralf Becker <RalfBecker-AT-outdoor-training.de>
* @copyright (c) 2008-11 by Ralf Becker <RalfBecker-AT-outdoor-training.de>
* @copyright (c) 2008-13 by Ralf Becker <RalfBecker-AT-outdoor-training.de>
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
* @version $Id$
*/
@ -34,7 +34,7 @@ class filemanager_ui
'filemanager_ui::listview' => 'Listview',
);
public static $views_init = false;
/**
* vfs namespace for document merge properties
*
@ -127,7 +127,7 @@ class filemanager_ui
'group' => $group,
'allowOnMultiple' => false,
'icon' => 'filesave',
'onExecute' => 'javaScript:force_download',
'onExecute' => 'javaScript:app.filemanager.force_download',
'disableClass' => 'isDir',
),
'edit' => array(
@ -141,23 +141,23 @@ class filemanager_ui
'caption' => lang('Mail files'),
'icon' => 'filemanager/mail_post_to',
'group' => $group,
'onExecute' => 'javaScript:egw_fileman_mail',
'onExecute' => 'javaScript:app.filemanager.mail',
),
'copy' => array(
'caption' => lang('Copy'),
'group' => ++$group,
'onExecute' => 'javaScript:do_clipboard',
'onExecute' => 'javaScript:app.filemanager.clipboard',
),
'add' => array(
'caption' => lang('Add to clipboard'),
'group' => $group,
'icon' => 'copy',
'onExecute' => 'javaScript:do_clipboard',
'onExecute' => 'javaScript:app.filemanager.clipboard',
),
'cut' => array(
'caption' => lang('Cut'),
'group' => $group,
'onExecute' => 'javaScript:do_clipboard',
'onExecute' => 'javaScript:app.filemanager.clipboard',
),
'documents' => filemanager_merge::document_action(
$GLOBALS['egw_info']['user']['preferences']['filemanager']['document_dir'],
@ -176,7 +176,7 @@ class filemanager_ui
}
return $actions;
}
/**
* Get mergeapp property for given path
*
@ -211,7 +211,7 @@ class filemanager_ui
}
break;
}
return $app;
}
@ -228,7 +228,7 @@ class filemanager_ui
$content = array(
'nm' => egw_session::appsession('index','filemanager'),
);
if (!is_array($content['nm']))
// if (!is_array($content['nm']))
{
$content['nm'] = array(
'get_rows' => 'filemanager.filemanager_ui.get_rows', // I method/callback to request the data for the rows eg. 'notes.bo.get_rows'
@ -486,91 +486,6 @@ class filemanager_ui
'3' => 'Show hidden files',
'' => 'Files from subdirectories',
);
if ($GLOBALS['egw_info']['user']['apps']['felamimail'])
{
list($width,$height) = explode('x',egw_link::get_registry('felamimail','add_popup'));
$GLOBALS['egw_info']['flags']['java_script'] .= "<script type=\"text/javascript\">
function open_mail(attachments)
{
if (typeof attachments == 'undefined') attachments = clipboard_files;
var link = '".egw::link('/index.php',array('menuaction' => 'felamimail.uicompose.compose'))."';
if (!(attachments instanceof Array)) attachments = [ attachments ];
for(var i=0; i < attachments.length; i++)
{
link += '&preset[file][]='+encodeURIComponent('vfs://default'+attachments[i]);
}
egw_openWindowCentered2(link, '_blank', $width, $height, 'yes');
}
function egw_fileman_mail(_action, _elems)
{
var ids = [];
for (var i = 0; i < _elems.length; i++)
{
ids.push(_elems[i].id);
}
open_mail(ids);
}
function egw_fileman_setMsg(_msg)
{
\$j(document.getElementById('nm[msg]')).text(_msg);
}
</script>\n";
}
$GLOBALS['egw_info']['flags']['java_script'] .= '<script type="text/javascript">
var clipboard_files = [];
function check_files(upload, path_id)
{
var files = [];
if (upload.files)
{
for(var i = 0; i < upload.files.length; ++i)
{
files.push(upload.files[i].name || upload.files[i].fileName);
}
}
else if (upload.value)
{
files = upload.value;
}
var path = document.getElementById(path_id ? path_id : upload.id.replace(/upload\]\[/,"nm][path"));
xajax_doXMLHTTP("filemanager_ui::ajax_check_upload_target",upload.id, files, path.value);
}
function clipboard_tooltip(link)
{
xajax_doXMLHTTP("filemanager_ui::ajax_clipboard_tooltip", link.id);
window.setTimeout(UnTip, 3000);
}
function do_clipboard(_action, _elems)
{
if (_action.id != "cut") clipboard_files = [];
var ids = [];
for (var i = 0; i < _elems.length; i++)
{
clipboard_files.push(_elems[i].id);
ids.push(_elems[i].id);
}
xajax_doXMLHTTP("filemanager_ui::ajax_clipboard", _action.id, ids);
}
function force_download(_action, _senders)
{
var a_href = $j(_senders[0].iface.getDOMNode()).find("a:first").attr("href");
if (a_href.indexOf("menuaction=") != -1)
{
a_href = a_href.replace(/index.php?.*$/, "webdav.php"+_senders[0].id);
}
window.location = a_href+"?download";
}
</script>'."\n";
$tpl->exec('filemanager.filemanager_ui.index',$content,$sel_options,$readonlys,array('nm' => $content['nm']));
}
@ -944,6 +859,8 @@ function force_download(_action, _senders)
{
$readonlys["mail[$path_quoted]"] = true;
}
$row['download_url'] = egw_vfs::download_url($path);
$rows[++$n] = $row;
$path2n[$path] = $n;
}
@ -1286,7 +1203,7 @@ function force_download(_action, _senders)
0 => lang('No access'),
);
}
// mergeapp
$content['mergeapp'] = self::get_mergeapp($path, 'self');
$content['mergeapp_parent'] = self::get_mergeapp($path, 'parents');
@ -1311,7 +1228,7 @@ function force_download(_action, _senders)
$sel_options['mergeapp'] = $sel_options['mergeapp'] + $mergeapp_list;
// mergeapp other gui options
$content['mergeapp_itempicker_disabled'] = $content['is_dir'] || empty($content['mergeapp_effective']);
$preserve = $content;
if (!isset($preserve['old']))
{

102
filemanager/js/app.js Normal file
View File

@ -0,0 +1,102 @@
/**
* EGroupware - Filemanager - Javascript actions
*
* @link http://www.egroupware.org
* @package filemanager
* @author Ralf Becker <RalfBecker-AT-outdoor-training.de>
* @copyright (c) 2008-13 by Ralf Becker <RalfBecker-AT-outdoor-training.de>
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
* @version $Id$
*/
app.filemanager = AppJS.extend(
{
appname: 'filemanager',
/**
* Initialize javascript for this application
*/
init: function()
{
this._super.apply(this,arguments);
//window.register_app_refresh("mail", this.app_refresh);
}/*,
remove_prefix: /^filemanager::/,
open_mail: function(attachments)
{
if (typeof attachments == 'undefined') attachments = clipboard_files;
var params = {};
if (!(attachments instanceof Array)) attachments = [ attachments ];
for(var i=0; i < attachments.length; i++)
{
params['preset[file]['+i+']'] = 'vfs://default'+attachments[i].replace(this.remove_prefix,'');
}
egw.open('', 'felamimail', 'add', params);
},
mail: function(_action, _elems)
{
var ids = [];
for (var i = 0; i < _elems.length; i++)
{
ids.push(_elems[i].id);
}
this.open_mail(ids);
},
setMsg: function(_msg)
{
$j(document.getElementById('nm[msg]')).text(_msg);
},
clipboard_files: [],
check_files: function(upload, path_id)
{
var files = [];
if (upload.files)
{
for(var i = 0; i < upload.files.length; ++i)
{
files.push(upload.files[i].name || upload.files[i].fileName);
}
}
else if (upload.value)
{
files = upload.value;
}
var path = document.getElementById(path_id ? path_id : upload.id.replace(/upload\]\[/,"nm][path"));
xajax_doXMLHTTP("filemanager_ui::ajax_check_upload_target",upload.id, files, path.value);
},
clipboard_tooltip: function(link)
{
xajax_doXMLHTTP("filemanager_ui::ajax_clipboard_tooltip", link.id);
window.setTimeout(UnTip, 3000);
},
clipboard: function(_action, _elems)
{
if (_action.id != "cut") clipboard_files = [];
var ids = [];
for (var i = 0; i < _elems.length; i++)
{
clipboard_files.push(_elems[i].id);
ids.push(_elems[i].id);
}
xajax_doXMLHTTP("filemanager_ui::ajax_clipboard", _action.id, ids);
},
force_download: function(_action, _senders)
{
var data = egw.dataGetUIDdata(_senders[0].id);
var url = data ? data.data.download_url : '/webdav.php'+_senders[0].id.replace(this.remove_prefix,'');
if (url[0] == '/') url = egw.link(url);
window.location = url+"?download";
}*/
});

View File

@ -2,7 +2,7 @@
/**
* EGroupware - eTemplates for Application filemanager
* http://www.egroupware.org
* generated by soetemplate::dump4setup() 2012-10-31 19:17
* generated by soetemplate::dump4setup() 2013-04-09 18:00
*
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
* @package filemanager
@ -33,11 +33,11 @@ $templ_data[] = array('name' => 'filemanager.file.perms','template' => '','lang'
$templ_data[] = array('name' => 'filemanager.file.preview','template' => '','lang' => '','group' => '0','version' => '1.5.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:4:{i:0;a:5:{s:2:"c1";s:4:",top";s:2:"h1";s:16:",!@mime=/^image/";s:2:"h3";s:22:",@mime=/^(image|text)/";s:2:"h2";s:18:"280,!@text_content";s:2:"c2";s:4:",top";}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:5:"image";s:4:"name";s:4:"link";s:4:"span";s:13:",previewImage";}}i:2;a:1:{s:1:"A";a:4:{s:4:"type";s:8:"textarea";s:4:"name";s:12:"text_content";s:4:"span";s:12:",previewText";s:8:"readonly";s:1:"1";}}i:3;a:1:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:20:"No preview available";}}}s:4:"rows";i:3;s:4:"cols";i:1;s:4:"size";s:18:"450,300,,,10,,auto";s:7:"options";a:4:{i:0;s:3:"450";i:1;s:3:"300";i:6;s:4:"auto";i:4;s:2:"10";}}}','size' => '450,300,,,10,,auto','style' => '','modified' => '1204567479',);
$templ_data[] = array('name' => 'filemanager.index','template' => '','lang' => '','group' => '0','version' => '1.9.002','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:6:{i:0;a:3:{s:1:"A";s:3:"250";s:2:"c4";s:7:",bottom";s:2:"h4";s:34:",!@nm[selectcols]=/legacy_actions/";}i:1;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"span";s:13:"all,redItalic";s:4:"name";s:7:"nm[msg]";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:2;a:2:{s:1:"A";a:15:{s:4:"type";s:4:"hbox";s:4:"size";s:2:"12";i:1;a:4:{s:4:"type";s:5:"image";s:5:"label";s:2:"Up";s:4:"name";s:4:"goup";s:4:"size";s:40:"filemanager.filemanager_ui.index&path=..";}i:2;a:4:{s:4:"type";s:5:"image";s:4:"name";s:6:"gohome";s:4:"size";s:39:"filemanager.filemanager_ui.index&path=~";s:5:"label";s:25:"Go to your home directory";}s:4:"span";s:3:"all";i:3;a:6:{s:4:"type";s:8:"vfs-name";s:4:"name";s:8:"nm[path]";s:4:"size";s:5:"80,,1";s:5:"label";s:4:"Path";s:8:"onchange";i:1;s:4:"span";s:8:",address";}i:4;a:4:{s:4:"type";s:6:"button";s:4:"name";s:10:"button[go]";s:4:"size";s:9:"key_enter";s:5:"label";s:5:"Go to";}i:5;a:2:{s:4:"type";s:5:"image";s:4:"name";s:15:"buttonseparator";}i:6;a:6:{s:4:"type";s:6:"button";s:4:"size";s:4:"edit";s:5:"label";s:13:"Edit settings";s:4:"name";s:23:"edit[{$cont[nm][path]}]";s:4:"help";s:39:"Rename, change permissions or ownership";s:7:"onclick";s:194:"window.open(egw::link(\'/index.php\',\'menuaction=filemanager.filemanager_ui.file&path={$cont[nm][path]}\'),\'fileprefs\',\'dependent=yes,width=495,height=425,scrollbars=yes,status=yes\'); return false;";}i:7;a:5:{s:4:"type";s:6:"button";s:4:"name";s:17:"button[createdir]";s:4:"size";s:35:"button_createdir,createdir_disabled";s:5:"label";s:16:"Create directory";s:7:"onclick";s:128:"var dir = prompt(egw::lang(\'New directory\')); if (!dir) return false; document.getElementById(form::name(\'nm[path]\')).value=dir;";}i:8;a:5:{s:4:"type";s:6:"button";s:4:"size";s:18:"link,link_disabled";s:5:"label";s:13:"Create a link";s:4:"name";s:15:"button[symlink]";s:7:"onclick";s:129:"var link = prompt(egw::lang(\'Link target\')); if (!link) return false; document.getElementById(form::name(\'nm[path]\')).value=link;";}i:9;a:5:{s:4:"type";s:6:"button";s:4:"name";s:13:"button[paste]";s:4:"size";s:28:"editpaste,editpaste_disabled";s:4:"help";s:29:"call:clipboard_tooltip(this);";s:7:"onclick";s:34:"return clipboard_files.length > 0;";}i:10;a:5:{s:4:"type";s:6:"button";s:4:"name";s:17:"button[linkpaste]";s:4:"size";s:28:"linkpaste,linkpaste_disabled";s:4:"help";s:29:"call:clipboard_tooltip(this);";s:7:"onclick";s:34:"return clipboard_files.length > 0;";}i:11;a:5:{s:4:"type";s:6:"button";s:4:"name";s:17:"button[mailpaste]";s:4:"size";s:28:"mailpaste,mailpaste_disabled";s:4:"help";s:29:"call:clipboard_tooltip(this);";s:7:"onclick";s:54:"if (clipboard_files.length) open_mail(); return false;";}i:12;a:4:{s:4:"type";s:6:"button";s:4:"size";s:6:"upload";s:5:"label";s:11:"File a file";s:7:"onclick";s:171:"window.open(egw::link(\'/index.php\',\'menuaction=stylite.stylite_filemanager.upload\'),\'_blank\',\'dependent=yes,width=550,height=350,scrollbars=yes,status=yes\'); return false;";}}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:3;a:2:{s:1:"A";a:4:{s:4:"type";s:9:"nextmatch";s:4:"size";s:22:"filemanager.index.rows";s:4:"span";s:3:"all";s:4:"name";s:2:"nm";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:4;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"size";s:1:"1";i:1;a:1:{s:4:"type";s:5:"label";}}s:1:"B";a:5:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";s:5:"align";s:5:"right";i:1;a:5:{s:5:"label";s:13:"Select action";s:7:"onclick";s:187:"if (!egw_globalObjectManager.getObjectById(\'filemanager.index.rows\').executeActionImplementation(this, \'popup\')) alert(egw::lang(\'You need to select some entries first!\')); return false;;";s:4:"name";s:14:"legacy_actions";s:4:"type";s:10:"buttononly";s:4:"help";s:13:"Select action";}i:2;a:8:{s:4:"type";s:6:"button";s:4:"size";s:9:"arrow_ltr";s:5:"label";s:9:"Check all";s:4:"name";s:9:"check_all";s:4:"help";s:9:"Check all";s:7:"onclick";s:98:"egw_globalObjectManager.getObjectById(\'filemanager.index.rows\').toggleAllSelected(); return false;";s:6:"needed";s:1:"1";s:4:"span";s:14:",checkAllArrow";}}}i:5;a:2:{s:1:"A";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";i:1;a:4:{s:4:"type";s:4:"file";s:4:"name";s:8:"upload[]";s:4:"help";s:42:"Select file to upload in current directory";s:8:"onchange";s:18:"check_files(this);";}i:2;a:3:{s:4:"type";s:6:"button";s:5:"label";s:6:"Upload";s:4:"name";s:14:"button[upload]";}}s:1:"B";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:5;s:4:"cols";i:2;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => 'input[type=\'file\'] {
$templ_data[] = array('name' => 'filemanager.index','template' => '','lang' => '','group' => '0','version' => '1.9.002','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:6:{i:0;a:3:{s:1:"A";s:3:"250";s:2:"c4";s:7:",bottom";s:2:"h4";s:34:",!@nm[selectcols]=/legacy_actions/";}i:1;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"span";s:13:"all,redItalic";s:4:"name";s:7:"nm[msg]";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:2;a:2:{s:1:"A";a:15:{s:4:"type";s:4:"hbox";s:4:"size";s:2:"12";i:1;a:4:{s:4:"type";s:5:"image";s:5:"label";s:2:"Up";s:4:"name";s:4:"goup";s:4:"size";s:40:"filemanager.filemanager_ui.index&path=..";}i:2;a:4:{s:4:"type";s:5:"image";s:4:"name";s:6:"gohome";s:4:"size";s:39:"filemanager.filemanager_ui.index&path=~";s:5:"label";s:25:"Go to your home directory";}s:4:"span";s:3:"all";i:3;a:6:{s:4:"type";s:8:"vfs-name";s:4:"name";s:8:"nm[path]";s:4:"size";s:5:"80,,1";s:5:"label";s:4:"Path";s:8:"onchange";i:1;s:4:"span";s:8:",address";}i:4;a:4:{s:4:"type";s:6:"button";s:4:"name";s:10:"button[go]";s:4:"size";s:9:"key_enter";s:5:"label";s:5:"Go to";}i:5;a:2:{s:4:"type";s:5:"image";s:4:"name";s:15:"buttonseparator";}i:6;a:6:{s:4:"type";s:6:"button";s:4:"size";s:4:"edit";s:5:"label";s:13:"Edit settings";s:4:"name";s:23:"edit[{$cont[nm][path]}]";s:4:"help";s:39:"Rename, change permissions or ownership";s:7:"onclick";s:194:"window.open(egw::link(\'/index.php\',\'menuaction=filemanager.filemanager_ui.file&path={$cont[nm][path]}\'),\'fileprefs\',\'dependent=yes,width=495,height=425,scrollbars=yes,status=yes\'); return false;";}i:7;a:5:{s:4:"type";s:6:"button";s:4:"name";s:17:"button[createdir]";s:4:"size";s:35:"button_createdir,createdir_disabled";s:5:"label";s:16:"Create directory";s:7:"onclick";s:128:"var dir = prompt(egw::lang(\'New directory\')); if (!dir) return false; document.getElementById(form::name(\'nm[path]\')).value=dir;";}i:8;a:5:{s:4:"type";s:6:"button";s:4:"size";s:18:"link,link_disabled";s:5:"label";s:13:"Create a link";s:4:"name";s:15:"button[symlink]";s:7:"onclick";s:129:"var link = prompt(egw::lang(\'Link target\')); if (!link) return false; document.getElementById(form::name(\'nm[path]\')).value=link;";}i:9;a:5:{s:4:"type";s:6:"button";s:4:"name";s:13:"button[paste]";s:4:"size";s:28:"editpaste,editpaste_disabled";s:4:"help";s:29:"call:clipboard_tooltip(this);";s:7:"onclick";s:34:"return clipboard_files.length > 0;";}i:10;a:5:{s:4:"type";s:6:"button";s:4:"name";s:17:"button[linkpaste]";s:4:"size";s:28:"linkpaste,linkpaste_disabled";s:4:"help";s:29:"call:clipboard_tooltip(this);";s:7:"onclick";s:34:"return clipboard_files.length > 0;";}i:11;a:5:{s:4:"type";s:6:"button";s:4:"name";s:17:"button[mailpaste]";s:4:"size";s:28:"mailpaste,mailpaste_disabled";s:4:"help";s:29:"call:clipboard_tooltip(this);";s:7:"onclick";s:70:"if (clipboard_files.length) app.filemanager.open_mail(); return false;";}i:12;a:4:{s:4:"type";s:6:"button";s:4:"size";s:6:"upload";s:5:"label";s:11:"File a file";s:7:"onclick";s:171:"window.open(egw::link(\'/index.php\',\'menuaction=stylite.stylite_filemanager.upload\'),\'_blank\',\'dependent=yes,width=550,height=350,scrollbars=yes,status=yes\'); return false;";}}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:3;a:2:{s:1:"A";a:4:{s:4:"type";s:9:"nextmatch";s:4:"size";s:22:"filemanager.index.rows";s:4:"span";s:3:"all";s:4:"name";s:2:"nm";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:4;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"size";s:1:"1";i:1;a:1:{s:4:"type";s:5:"label";}}s:1:"B";a:5:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";s:5:"align";s:5:"right";i:1;a:5:{s:5:"label";s:13:"Select action";s:7:"onclick";s:187:"if (!egw_globalObjectManager.getObjectById(\'filemanager.index.rows\').executeActionImplementation(this, \'popup\')) alert(egw::lang(\'You need to select some entries first!\')); return false;;";s:4:"name";s:14:"legacy_actions";s:4:"type";s:10:"buttononly";s:4:"help";s:13:"Select action";}i:2;a:8:{s:4:"type";s:6:"button";s:4:"size";s:9:"arrow_ltr";s:5:"label";s:9:"Check all";s:4:"name";s:9:"check_all";s:4:"help";s:9:"Check all";s:7:"onclick";s:98:"egw_globalObjectManager.getObjectById(\'filemanager.index.rows\').toggleAllSelected(); return false;";s:6:"needed";s:1:"1";s:4:"span";s:14:",checkAllArrow";}}}i:5;a:2:{s:1:"A";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";i:1;a:4:{s:4:"type";s:4:"file";s:4:"name";s:8:"upload[]";s:4:"help";s:42:"Select file to upload in current directory";s:8:"onchange";s:18:"check_files(this);";}i:2;a:3:{s:4:"type";s:6:"button";s:5:"label";s:6:"Upload";s:4:"name";s:14:"button[upload]";}}s:1:"B";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:5;s:4:"cols";i:2;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => 'input[type=\'file\'] {
width: 50ex
}','modified' => '1237464702',);
$templ_data[] = array('name' => 'filemanager.index.rows','template' => '','lang' => '','group' => '0','version' => '1.7.002','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:6:{s:2:"c1";s:2:"th";s:2:"c2";s:20:"row $row_cont[class]";s:1:"B";s:3:"30%";s:1:"D";s:3:"120";s:1:"E";s:3:"120";s:1:"K";s:2:"70";}i:1;a:11:{s:1:"A";a:4:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Type";s:4:"name";s:4:"mime";s:5:"align";s:6:"center";}s:1:"B";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Name";s:4:"name";s:4:"name";}s:1:"C";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Size";s:4:"name";s:4:"size";}s:1:"D";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Modified";s:4:"name";s:5:"mtime";}s:1:"E";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:7:"Created";s:4:"name";s:5:"ctime";}s:1:"F";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:11:"Permissions";s:4:"name";s:4:"mode";}s:1:"G";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:4:"name";s:3:"uid";s:5:"label";s:5:"Owner";}s:1:"H";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:4:"name";s:3:"gid";s:5:"label";s:5:"Group";}s:1:"I";a:3:{s:4:"type";s:16:"nextmatch-header";s:5:"label";s:7:"Comment";s:4:"name";s:7:"comment";}s:1:"J";a:3:{s:4:"type";s:22:"nextmatch-customfields";s:8:"readonly";s:1:"1";s:4:"name";s:12:"customfields";}s:1:"K";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:6:"2,,0,0";i:1;a:3:{s:4:"type";s:16:"nextmatch-header";s:5:"label";s:7:"Actions";s:4:"name";s:14:"legacy_actions";}i:2;a:8:{s:4:"type";s:6:"button";s:4:"size";s:5:"check";s:5:"label";s:9:"Check all";s:4:"name";s:9:"check_all";s:4:"help";s:9:"Check all";s:7:"onclick";s:98:"egw_globalObjectManager.getObjectById(\'filemanager.index.rows\').toggleAllSelected(); return false;";s:6:"needed";s:1:"1";s:5:"align";s:5:"right";}}}i:2;a:11:{s:1:"A";a:3:{s:4:"type";s:8:"vfs-mime";s:4:"name";s:12:"${row}[path]";s:5:"align";s:6:"center";}s:1:"B";a:3:{s:4:"type";s:3:"vfs";s:4:"name";s:4:"$row";s:7:"no_lang";s:1:"1";}s:1:"C";a:3:{s:4:"type";s:8:"vfs-size";s:4:"name";s:12:"${row}[size]";s:5:"align";s:5:"right";}s:1:"D";a:3:{s:4:"type";s:9:"date-time";s:4:"name";s:13:"${row}[mtime]";s:8:"readonly";s:1:"1";}s:1:"E";a:3:{s:4:"type";s:9:"date-time";s:4:"name";s:13:"${row}[ctime]";s:8:"readonly";s:1:"1";}s:1:"F";a:2:{s:4:"type";s:8:"vfs-mode";s:4:"name";s:12:"${row}[mode]";}s:1:"G";a:3:{s:4:"type";s:7:"vfs-uid";s:4:"name";s:11:"${row}[uid]";s:7:"no_lang";s:1:"1";}s:1:"H";a:3:{s:4:"type";s:7:"vfs-gid";s:4:"name";s:11:"${row}[gid]";s:7:"no_lang";s:1:"1";}s:1:"I";a:2:{s:4:"type";s:5:"label";s:4:"name";s:15:"${row}[comment]";}s:1:"J";a:3:{s:4:"type";s:17:"customfields-list";s:4:"name";s:4:"$row";s:4:"span";s:13:",customfields";}s:1:"K";a:7:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"4";i:1;a:6:{s:4:"type";s:6:"button";s:4:"size";s:4:"edit";s:5:"label";s:13:"Edit settings";s:4:"name";s:21:"edit[$row_cont[path]]";s:4:"help";s:39:"Rename, change permissions or ownership";s:7:"onclick";s:192:"window.open(egw::link(\'/index.php\',\'menuaction=filemanager.filemanager_ui.file&path=$row_cont[path]\'),\'fileprefs\',\'dependent=yes,width=495,height=425,scrollbars=yes,status=yes\'); return false;";}i:2;a:5:{s:4:"type";s:10:"buttononly";s:4:"size";s:12:"mail_post_to";s:4:"name";s:21:"mail[$row_cont[path]]";s:7:"onclick";s:43:"open_mail(\'$row_cont[path]\'); return false;";s:5:"align";s:6:"center";}i:3;a:7:{s:4:"type";s:6:"button";s:4:"name";s:23:"delete[$row_cont[path]]";s:4:"size";s:6:"delete";s:5:"label";s:6:"Delete";s:4:"help";s:29:"Delete this file or directory";s:7:"onclick";s:48:"return confirm(\'Delete this file or directory\');";s:5:"align";s:6:"center";}s:5:"align";s:5:"right";i:4;a:4:{s:4:"type";s:8:"checkbox";s:4:"name";s:9:"checked[]";s:5:"align";s:5:"right";s:4:"size";s:17:""$row_cont[path]"";}}}}s:4:"rows";i:2;s:4:"cols";i:11;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => '','modified' => '1259329664',);
$templ_data[] = array('name' => 'filemanager.index.rows','template' => '','lang' => '','group' => '0','version' => '1.7.002','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:6:{s:2:"c1";s:2:"th";s:2:"c2";s:20:"row $row_cont[class]";s:1:"B";s:3:"30%";s:1:"D";s:3:"120";s:1:"E";s:3:"120";s:1:"K";s:2:"70";}i:1;a:11:{s:1:"A";a:4:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Type";s:4:"name";s:4:"mime";s:5:"align";s:6:"center";}s:1:"B";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Name";s:4:"name";s:4:"name";}s:1:"C";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Size";s:4:"name";s:4:"size";}s:1:"D";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Modified";s:4:"name";s:5:"mtime";}s:1:"E";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:7:"Created";s:4:"name";s:5:"ctime";}s:1:"F";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:11:"Permissions";s:4:"name";s:4:"mode";}s:1:"G";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:4:"name";s:3:"uid";s:5:"label";s:5:"Owner";}s:1:"H";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:4:"name";s:3:"gid";s:5:"label";s:5:"Group";}s:1:"I";a:3:{s:4:"type";s:16:"nextmatch-header";s:5:"label";s:7:"Comment";s:4:"name";s:7:"comment";}s:1:"J";a:3:{s:4:"type";s:22:"nextmatch-customfields";s:8:"readonly";s:1:"1";s:4:"name";s:12:"customfields";}s:1:"K";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:6:"2,,0,0";i:1;a:3:{s:4:"type";s:16:"nextmatch-header";s:5:"label";s:7:"Actions";s:4:"name";s:14:"legacy_actions";}i:2;a:8:{s:4:"type";s:6:"button";s:4:"size";s:5:"check";s:5:"label";s:9:"Check all";s:4:"name";s:9:"check_all";s:4:"help";s:9:"Check all";s:7:"onclick";s:98:"egw_globalObjectManager.getObjectById(\'filemanager.index.rows\').toggleAllSelected(); return false;";s:6:"needed";s:1:"1";s:5:"align";s:5:"right";}}}i:2;a:11:{s:1:"A";a:3:{s:4:"type";s:8:"vfs-mime";s:4:"name";s:4:"$row";s:5:"align";s:6:"center";}s:1:"B";a:3:{s:4:"type";s:3:"vfs";s:4:"name";s:4:"$row";s:7:"no_lang";s:1:"1";}s:1:"C";a:3:{s:4:"type";s:8:"vfs-size";s:4:"name";s:12:"${row}[size]";s:5:"align";s:5:"right";}s:1:"D";a:3:{s:4:"type";s:9:"date-time";s:4:"name";s:13:"${row}[mtime]";s:8:"readonly";s:1:"1";}s:1:"E";a:3:{s:4:"type";s:9:"date-time";s:4:"name";s:13:"${row}[ctime]";s:8:"readonly";s:1:"1";}s:1:"F";a:2:{s:4:"type";s:8:"vfs-mode";s:4:"name";s:12:"${row}[mode]";}s:1:"G";a:3:{s:4:"type";s:7:"vfs-uid";s:4:"name";s:11:"${row}[uid]";s:7:"no_lang";s:1:"1";}s:1:"H";a:3:{s:4:"type";s:7:"vfs-gid";s:4:"name";s:11:"${row}[gid]";s:7:"no_lang";s:1:"1";}s:1:"I";a:2:{s:4:"type";s:5:"label";s:4:"name";s:15:"${row}[comment]";}s:1:"J";a:3:{s:4:"type";s:17:"customfields-list";s:4:"name";s:4:"$row";s:4:"span";s:13:",customfields";}s:1:"K";a:7:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"4";i:1;a:6:{s:4:"type";s:6:"button";s:4:"size";s:4:"edit";s:5:"label";s:13:"Edit settings";s:4:"name";s:21:"edit[$row_cont[path]]";s:4:"help";s:39:"Rename, change permissions or ownership";s:7:"onclick";s:192:"window.open(egw::link(\'/index.php\',\'menuaction=filemanager.filemanager_ui.file&path=$row_cont[path]\'),\'fileprefs\',\'dependent=yes,width=495,height=425,scrollbars=yes,status=yes\'); return false;";}i:2;a:5:{s:4:"type";s:10:"buttononly";s:4:"size";s:12:"mail_post_to";s:4:"name";s:21:"mail[$row_cont[path]]";s:7:"onclick";s:43:"open_mail(\'$row_cont[path]\'); return false;";s:5:"align";s:6:"center";}i:3;a:7:{s:4:"type";s:6:"button";s:4:"name";s:23:"delete[$row_cont[path]]";s:4:"size";s:6:"delete";s:5:"label";s:6:"Delete";s:4:"help";s:29:"Delete this file or directory";s:7:"onclick";s:48:"return confirm(\'Delete this file or directory\');";s:5:"align";s:6:"center";}s:5:"align";s:5:"right";i:4;a:4:{s:4:"type";s:8:"checkbox";s:4:"name";s:9:"checked[]";s:5:"align";s:5:"right";s:4:"size";s:17:""$row_cont[path]"";}}}}s:4:"rows";i:2;s:4:"cols";i:11;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => '','modified' => '1259329664',);
$templ_data[] = array('name' => 'filemanager.search','template' => '','lang' => '','group' => '0','version' => '1.3.001','data' => 'a:4:{i:0;a:9:{s:4:"type";s:8:"groupbox";s:4:"name";s:10:"debuginfos";s:4:"size";s:1:"4";s:5:"label";s:10:"Debuginfos";s:8:"disabled";s:1:"1";i:1;a:3:{s:4:"type";s:8:"textarea";s:4:"name";s:7:"message";s:8:"readonly";s:1:"1";}i:2;a:1:{s:4:"type";s:5:"label";}i:3;a:1:{s:4:"type";s:5:"label";}i:4;a:1:{s:4:"type";s:5:"label";}}i:1;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:7:{i:0;a:2:{s:1:"C";s:3:"120";s:1:"D";s:3:"120";}i:1;a:5:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:12:"searchstring";s:4:"name";s:17:"searchstringlabel";}s:1:"B";a:3:{s:4:"type";s:4:"text";s:4:"span";s:1:"2";s:4:"name";s:12:"searchstring";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:3:{s:4:"type";s:6:"button";s:5:"label";s:12:"start search";s:4:"name";s:12:"start_search";}s:1:"E";a:1:{s:4:"type";s:5:"label";}}i:2;a:5:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:9:"mime type";}s:1:"B";a:2:{s:4:"type";s:8:"checkbox";s:4:"name";s:8:"checkall";}s:1:"C";a:3:{s:4:"type";s:5:"label";s:5:"label";s:3:"All";s:4:"name";s:8:"alllabel";}s:1:"D";a:4:{s:4:"type";s:5:"label";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:8:"checkbox";s:5:"label";s:5:"files";s:4:"name";s:14:"checkonlyfiles";}}}s:4:"rows";i:1;s:4:"cols";i:1;}s:1:"E";a:1:{s:4:"type";s:5:"label";}}i:3;a:5:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:2:{s:4:"type";s:8:"checkbox";s:4:"name";s:14:"checkonlyfiles";}s:1:"C";a:3:{s:4:"type";s:5:"label";s:5:"label";s:5:"files";s:4:"name";s:9:"filelabel";}s:1:"D";a:4:{s:4:"type";s:6:"button";s:5:"label";s:12:"clear search";s:4:"name";s:12:"clear_search";s:7:"onclick";s:71:"menuaction=filemanager.uifilemanager.index&action=search&actioncd=clear";}s:1:"E";a:1:{s:4:"type";s:5:"label";}}i:4;a:5:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:2:{s:4:"type";s:8:"checkbox";s:4:"name";s:13:"checkonlydirs";}s:1:"C";a:3:{s:4:"type";s:5:"label";s:5:"label";s:9:"directory";s:4:"name";s:8:"dirlabel";}s:1:"D";a:4:{s:4:"type";s:8:"checkbox";s:5:"label";s:5:"Debug";s:4:"name";s:5:"debug";s:8:"disabled";s:1:"1";}s:1:"E";a:1:{s:4:"type";s:5:"label";}}i:5;a:5:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:15:"created between";s:4:"name";s:12:"createdlabel";}s:1:"B";a:2:{s:4:"type";s:8:"checkbox";s:4:"name";s:13:"searchcreated";}s:1:"C";a:3:{s:4:"type";s:4:"date";s:4:"name";s:15:"datecreatedfrom";s:4:"size";s:2:",8";}s:1:"D";a:3:{s:4:"type";s:4:"date";s:4:"name";s:13:"datecreatedto";s:4:"size";s:2:",8";}s:1:"E";a:4:{s:4:"type";s:8:"textarea";s:4:"name";s:17:"searchcreatedtext";s:8:"readonly";s:1:"1";s:7:"no_lang";s:1:"1";}}i:6;a:5:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:16:"modified between";s:4:"name";s:13:"modifiedlabel";}s:1:"B";a:2:{s:4:"type";s:8:"checkbox";s:4:"name";s:14:"searchmodified";}s:1:"C";a:3:{s:4:"type";s:4:"date";s:4:"name";s:16:"datemodifiedfrom";s:4:"size";s:2:",8";}s:1:"D";a:3:{s:4:"type";s:4:"date";s:4:"name";s:14:"datemodifiedto";s:4:"size";s:2:",8";}s:1:"E";a:4:{s:4:"type";s:8:"textarea";s:4:"name";s:18:"searchmodifiedtext";s:8:"readonly";s:1:"1";s:7:"no_lang";s:1:"1";}}}s:4:"rows";i:6;s:4:"cols";i:5;}i:2;a:1:{s:4:"type";s:5:"hrule";}i:3;a:3:{s:4:"type";s:9:"nextmatch";s:4:"size";s:4:"rows";s:4:"name";s:2:"nm";}}','size' => '','style' => '','modified' => '1173101430',);

View File

@ -77,7 +77,7 @@
<button label="Create a link" id="button[symlink]" onclick="var link = prompt(egw::lang('Link target')); if (!link) return false; document.getElementById(form::name('nm[path]')).value=link;" image="link" ro_image="link_disabled"/>
<button statustext="call:clipboard_tooltip(this);" id="button[paste]" onclick="return clipboard_files.length &gt; 0;" image="editpaste" ro_image="editpaste_disabled"/>
<button statustext="call:clipboard_tooltip(this);" id="button[linkpaste]" onclick="return clipboard_files.length &gt; 0;" image="linkpaste" ro_image="linkpaste_disabled"/>
<button statustext="call:clipboard_tooltip(this);" id="button[mailpaste]" onclick="if (clipboard_files.length) open_mail(); return false;" image="mailpaste" ro_image="mailpaste_disabled"/>
<button statustext="call:clipboard_tooltip(this);" id="button[mailpaste]" onclick="if (clipboard_files.length) app.filemanager.open_mail(); return false;" image="mailpaste" ro_image="mailpaste_disabled"/>
<button label="File a file" onclick="window.open(egw::link('/index.php','menuaction=stylite.stylite_filemanager.upload'),'_blank','dependent=yes,width=550,height=350,scrollbars=yes,status=yes'); return false;" image="upload"/>
</hbox>
</row>
@ -93,7 +93,7 @@
</row>
<row>
<hbox>
<file statustext="Select file to upload in current directory" id="upload[]" onchange="check_files(this, form::name('nm[path]'));"/>
<file statustext="Select file to upload in current directory" id="upload[]" onchange="check_files(this);"/>
<button label="Upload" id="button[upload]"/>
</hbox>
<description/>
@ -106,4 +106,4 @@ width: 50ex
}
</styles>
</template>
</overlay>
</overlay>