mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-26 07:49:28 +01:00
nextmatch_widget:
- 2 header-templates left and right from the range-display - optional nextmatch-line with arrows, search, cats, ... after the rows link_widget: - new sub-type link-string Updateted the documenations and lang-files.
This commit is contained in:
parent
a205036c1d
commit
7073ae95c2
@ -14,7 +14,7 @@ body { background-color: white; color: black; }
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1>eTemplate - Templates and Dialog-Editor for phpGroupware</h1>
|
<h1>eTemplate - Templates and Dialog-Editor for phpGroupware</h1>
|
||||||
<h3>by Ralf Becker <a href="mailto:RalfBecker@outdoor-training.de">RalfBecker@outdoor-training.de</a></h3>
|
<h3>by Ralf Becker <a href="#" onClick="document.location='mai'+'lto:RalfBecker'+unescape('%40')+'outdoor-training'+unescape('%2E')+'de'; return false;">RalfBecker AT outdoor-training DOT de</a></h3>
|
||||||
<p>A developers tutorial how to write an application with the new eTemplates.<br>
|
<p>A developers tutorial how to write an application with the new eTemplates.<br>
|
||||||
It is also an introduction how to write a phpgw- and setup(3)-compatible app.</p>
|
It is also an introduction how to write a phpgw- and setup(3)-compatible app.</p>
|
||||||
<hr>
|
<hr>
|
||||||
@ -146,7 +146,7 @@ Create the file <b>/et_media/index.php</b> with the following content:</p>
|
|||||||
<span>/**************************************************************************\
|
<span>/**************************************************************************\
|
||||||
* phpGroupWare - eTemplates - Tutoria Example - a simple MediaDB *
|
* phpGroupWare - eTemplates - Tutoria Example - a simple MediaDB *
|
||||||
* http://www.phpgroupware.org *
|
* http://www.phpgroupware.org *
|
||||||
* Written by Ralf Becker <RalfBecker@outdoor-training.de> *
|
* Written by Ralf Becker <RalfBecker AT outdoor-training DOT de> *
|
||||||
* -------------------------------------------- *
|
* -------------------------------------------- *
|
||||||
* This program is free software; you can redistribute it and/or modify it *
|
* This program is free software; you can redistribute it and/or modify it *
|
||||||
* under the terms of the GNU General Public License as published by the *
|
* under the terms of the GNU General Public License as published by the *
|
||||||
@ -472,7 +472,7 @@ a new version automaticaly.</p>
|
|||||||
<a href="../../setup/doc/setup3.html">docu of setup3</a> in the doc-dir of the setup app.
|
<a href="../../setup/doc/setup3.html">docu of setup3</a> in the doc-dir of the setup app.
|
||||||
</ol>
|
</ol>
|
||||||
|
|
||||||
<h2><i>That's it</i> - please <a href="mailto:RalfBecker@outdoor-training.de">contact me</a> if you have further questions or comments about the tutorial</h2>
|
<h2><i>That's it</i> - please <a href="#" onClick="document.location='mai'+'lto:RalfBecker'+unescape('%40')+'outdoor-training'+unescape('%2E')+'de'; return false;">contact me</a> if you have further questions or comments about the tutorial</h2>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
@ -14,7 +14,7 @@ body { background-color: white; color: black; }
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1>eTemplate-Referenz - Templates and Dialog-Editor for phpGroupware</h1>
|
<h1>eTemplate-Referenz - Templates and Dialog-Editor for phpGroupware</h1>
|
||||||
<h3>by Ralf Becker <a href="mailto:RalfBecker@outdoor-training.de">RalfBecker@outdoor-training.de</a></h3>
|
<h3>by Ralf Becker <a href="#" onClick="document.location='mai'+'lto:RalfBecker'+unescape('%40')+'outdoor-training'+unescape('%2E')+'de'; return false;">RalfBecker AT outdoor-training DOT de</a></h3>
|
||||||
<p>A referenz documentation about the new eTemplates and the <a href="#referenz">syntax and parameters</a>
|
<p>A referenz documentation about the new eTemplates and the <a href="#referenz">syntax and parameters</a>
|
||||||
of the several widgets.</p>
|
of the several widgets.</p>
|
||||||
<hr>
|
<hr>
|
||||||
@ -213,6 +213,8 @@ implement only a subset of XUL. Here are the main differences:</p>
|
|||||||
<td>
|
<td>
|
||||||
This attribute controls certain aspects of the different widgets. It's meaning and xml / xul-values
|
This attribute controls certain aspects of the different widgets. It's meaning and xml / xul-values
|
||||||
are document with the widgets.
|
are document with the widgets.
|
||||||
|
If the options-string starts with a '@' it is replaced by the value of the content-array at this
|
||||||
|
index (with the '@'-removed).
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
@ -659,16 +661,22 @@ implement only a subset of XUL. Here are the main differences:</p>
|
|||||||
<tr>
|
<tr>
|
||||||
<td colspan="5">
|
<td colspan="5">
|
||||||
<pre>
|
<pre>
|
||||||
$content[$id] = array( <span>// I = value set by the app, 0 = value on return / output, </span>
|
$content[$id] = array( <span>// I = value set by the app, 0 = value on return / output</span>
|
||||||
'get_rows' => <span>// I method/callback to request the data for the rows eg. 'notes.bo.get_rows'</span>
|
'get_rows' => <span>// I method/callback to request the data for the rows eg. 'notes.bo.get_rows'</span>
|
||||||
'filter_label' => <span>// I label for filter (optional)</span>
|
'filter_label' => <span>// I label for filter (optional)</span>
|
||||||
'filter_help' => <span>// I help-msg for filter (optional)</span>
|
'filter_help' => <span>// I help-msg for filter (optional)</span>
|
||||||
|
'no_filter' => True <span>// I disable the 1. filter</span>
|
||||||
'no_filter2' => True <span>// I disable the 2. filter (params are the same as for filter)</span>
|
'no_filter2' => True <span>// I disable the 2. filter (params are the same as for filter)</span>
|
||||||
|
'no_cat' => True <span>// I disable the cat-selectbox</span>
|
||||||
'template' => <span>// I template to use for the rows, if not set via options</span>
|
'template' => <span>// I template to use for the rows, if not set via options</span>
|
||||||
|
'header_left' => <span>// I template to show left of the range-value, left-aligned (optional)</span>
|
||||||
|
'header_right' => <span>// I template to show right of the range-value, right-aligned (optional)</span>
|
||||||
|
'bottom_too' => True <span>// I show the nextmatch-line (arrows, filters, search, ...) again after the rows</span>
|
||||||
'start' => <span>// IO position in list</span>
|
'start' => <span>// IO position in list</span>
|
||||||
'cat_id' => <span>// IO category, if not 'no_cat' => True</span>
|
'cat_id' => <span>// IO category, if not 'no_cat' => True</span>
|
||||||
'search' => <span>// IO search pattern</span>
|
'search' => <span>// IO search pattern</span>
|
||||||
'filter' => <span>// IO filter, if not 'no_filter' => True</span>
|
'filter' => <span>// IO filter, if not 'no_filter' => True</span>
|
||||||
|
'filter2' => <span>// IO filter2, if not 'no_filter2' => True</span>
|
||||||
'rows' => <span>// O content set by callback</span>
|
'rows' => <span>// O content set by callback</span>
|
||||||
'total' => <span>// O the total number of entries</span>
|
'total' => <span>// O the total number of entries</span>
|
||||||
);
|
);
|
||||||
@ -742,7 +750,41 @@ function index($content = 0)
|
|||||||
</pre>
|
</pre>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td><b>LinkWidgets</b></td>
|
||||||
|
<td>
|
||||||
|
<link type="link-to" id="name"/><p>
|
||||||
|
<link type="link-list" id="name"/><p>
|
||||||
|
<link type="link-string" id="name"/><p>
|
||||||
|
</td>
|
||||||
|
<td>no</td>
|
||||||
|
<td>link-to<p>link-list<p>link-string</td>
|
||||||
|
<td>
|
||||||
|
These widget are the UI-part of the link-class ({bo|so}link) in InfoLog and maybe the API soon.<p>
|
||||||
|
<b>link-to</b><br>
|
||||||
|
Widget to make a links to other entries of link-aware apps and to attach files.<p>
|
||||||
|
<b>link-list</b><br>
|
||||||
|
Widget to shows the links to an entry and a Unlink Button for each link. <p>
|
||||||
|
<i><u>Note</u>:</i> Both Widgets can be used on the same template with the <u>same</u> name. They share
|
||||||
|
the content of that variable, which contains just the id of the entry in the current app.<p>
|
||||||
|
|
||||||
|
<b>link-string</b><br>
|
||||||
|
Comma-separated list of link-titles with a link to its view-method, value is like the return
|
||||||
|
of bolink::get_links().
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
<h3>One remark about cross-site-scripting</h3>
|
||||||
|
The following eTemplate Widgets are parsing its content before displaying through <b>htmlentities()</b> to
|
||||||
|
correctly display the content and to gard against malecious data (like scripts etc.):
|
||||||
|
<ul>
|
||||||
|
<li>Label
|
||||||
|
<li>Text, Textarea
|
||||||
|
<li>Integer, Float
|
||||||
|
<li>SelectBoxes (it's options-strings)
|
||||||
|
<li>LinkWidgets: link-to, link-list, link-string
|
||||||
|
</ul>
|
||||||
|
This is done in most cases by the underlaying html-class and not direct in eTemplate.
|
||||||
<p>
|
<p>
|
||||||
<hr>
|
<hr>
|
||||||
<a name="extensions">
|
<a name="extensions">
|
||||||
@ -751,9 +793,10 @@ function index($content = 0)
|
|||||||
eTemplates to define the UI of the new widget and are stored in the eTemplate's inc-dir or the inc-dir of a
|
eTemplates to define the UI of the new widget and are stored in the eTemplate's inc-dir or the inc-dir of a
|
||||||
phpGroupWare application. The editor and the etemplate-class autoload the existing extensions.</p>
|
phpGroupWare application. The editor and the etemplate-class autoload the existing extensions.</p>
|
||||||
|
|
||||||
<i>I will made more documentation about the interface availible soon.</i>
|
<i>I will made more documentation about the interface availible soon. For now have a look for the source
|
||||||
|
of the existing extensions.</i>
|
||||||
|
|
||||||
<h2>please <a href="mailto:RalfBecker@outdoor-training.de">contact me</a> if you have further questions or comments about the eTemplates</h2>
|
<h2>please <a href="#" onClick="document.location='mai'+'lto:RalfBecker'+unescape('%40')+'outdoor-training'+unescape('%2E')+'de'; return false;">contact me</a> if you have further questions or comments about the eTemplates</h2>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
@ -15,10 +15,11 @@
|
|||||||
/*!
|
/*!
|
||||||
@class link_widget
|
@class link_widget
|
||||||
@author ralfbecker
|
@author ralfbecker
|
||||||
@abstract link-to: widget that enable you to make a link to an other entry of a link-aware app
|
@abstract link-to: Widget to create links to an other entries of link-aware apps
|
||||||
@abstract link-list: widget that shows the links to an entry and a Unlink Button for each entry
|
@abstract link-list: Widget to shows the links to an entry and a Unlink Button for each link
|
||||||
|
@abstract link-string: comma-separated list of link-titles with a link to its view method, value is like get_links()
|
||||||
@discussion This widget is independent of the UI as it only uses etemplate-widgets and has therefor no
|
@discussion This widget is independent of the UI as it only uses etemplate-widgets and has therefor no
|
||||||
@discussion render-function.
|
render-function.
|
||||||
*/
|
*/
|
||||||
class link_widget
|
class link_widget
|
||||||
{
|
{
|
||||||
@ -27,8 +28,9 @@
|
|||||||
'post_process' => True
|
'post_process' => True
|
||||||
);
|
);
|
||||||
var $human_name = array( // this are the names for the editor
|
var $human_name = array( // this are the names for the editor
|
||||||
'link-to' => 'LinkTo',
|
'link-to' => 'LinkTo',
|
||||||
'link-list' => 'LinkList'
|
'link-list' => 'LinkList',
|
||||||
|
'link-string' => 'LinkString'
|
||||||
);
|
);
|
||||||
var $debug = False;
|
var $debug = False;
|
||||||
|
|
||||||
@ -39,6 +41,24 @@
|
|||||||
|
|
||||||
function pre_process($name,&$value,&$cell,&$readonlys,&$extension_data,&$tmpl)
|
function pre_process($name,&$value,&$cell,&$readonlys,&$extension_data,&$tmpl)
|
||||||
{
|
{
|
||||||
|
if ($cell['type'] == 'link-string')
|
||||||
|
{
|
||||||
|
$str = '';
|
||||||
|
if (is_array($value))
|
||||||
|
{
|
||||||
|
foreach ($value as $link)
|
||||||
|
{
|
||||||
|
$str .= ($str !== '' ? ', ' : '') . $tmpl->html->a_href(
|
||||||
|
htmlentities($this->link->title($link['app'],$link['id'])),
|
||||||
|
$this->link->view($link['app'],$link['id'],$link));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$cell['type'] = 'html';
|
||||||
|
$cell['readonly'] = True; // is allways readonly
|
||||||
|
$value = $str;
|
||||||
|
|
||||||
|
return True;
|
||||||
|
}
|
||||||
if (!is_array($value))
|
if (!is_array($value))
|
||||||
{
|
{
|
||||||
$value = array(
|
$value = array(
|
||||||
|
@ -70,9 +70,19 @@
|
|||||||
($value['no_filter'] || !$value['filter'] || $value['filter'] == 'none') &&
|
($value['no_filter'] || !$value['filter'] || $value['filter'] == 'none') &&
|
||||||
($value['no_filter2'] || !$value['filter2'] || $value['filter2'] == 'none'))
|
($value['no_filter2'] || !$value['filter2'] || $value['filter2'] == 'none'))
|
||||||
{ // disable whole nextmatch line if no scrolling necessary
|
{ // disable whole nextmatch line if no scrolling necessary
|
||||||
$cell['size'] = $cell['name'].'[rows]';
|
if ($value['header_left'] || $value['header_right'])
|
||||||
$cell['obj'] = &$value['template'];
|
{
|
||||||
$cell['name'] = $value['template']->name;
|
$nextmatch = new etemplate('etemplate.nextmatch_widget.header_only');
|
||||||
|
$cell['size'] = $cell['name'];
|
||||||
|
$cell['obj'] = &$nextmatch;
|
||||||
|
$cell['name'] = $nextmatch->name;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$cell['size'] = $cell['name'].'[rows]';
|
||||||
|
$cell['obj'] = &$value['template'];
|
||||||
|
$cell['name'] = $value['template']->name;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -107,6 +117,8 @@
|
|||||||
|
|
||||||
// save values in persistent extension_data to be able use it in post_process
|
// save values in persistent extension_data to be able use it in post_process
|
||||||
$extension_data = $value;
|
$extension_data = $value;
|
||||||
|
|
||||||
|
$value['bottom'] = $value; // copy the values for the bottom-bar
|
||||||
|
|
||||||
return False; // NO extra Label
|
return False; // NO extra Label
|
||||||
}
|
}
|
||||||
@ -120,6 +132,26 @@
|
|||||||
$loop = False;
|
$loop = False;
|
||||||
$value['start'] = $old_value['start']; // need to be set, to be reported back
|
$value['start'] = $old_value['start']; // need to be set, to be reported back
|
||||||
|
|
||||||
|
if (is_array($value['bottom'])) // we have a second bottom-bar
|
||||||
|
{
|
||||||
|
$inputs = array('search','cat_id','filter','filter2');
|
||||||
|
foreach($inputs as $name)
|
||||||
|
{
|
||||||
|
if (isset($value['bottom'][$name]) && $value['bottom'][$name] != $old_value[$name])
|
||||||
|
{
|
||||||
|
$value[$name] = $value['bottom'][$name];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$buttons = array('start_search','first','left','right','last');
|
||||||
|
foreach($buttons as $name)
|
||||||
|
{
|
||||||
|
if (isset($value['bottom'][$name]) && $value['bottom'][$name])
|
||||||
|
{
|
||||||
|
$value[$name] = $value['bottom'][$name];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
unset($value['bottom']);
|
||||||
|
}
|
||||||
if ($value['start_search'] ||
|
if ($value['start_search'] ||
|
||||||
isset($value['cat_id']) && $value['cat_id'] != $old_value['cat_id'] ||
|
isset($value['cat_id']) && $value['cat_id'] != $old_value['cat_id'] ||
|
||||||
$old_value['filter'] != '' && isset($value['filter']) && $value['filter'] != $old_value['filter'] ||
|
$old_value['filter'] != '' && isset($value['filter']) && $value['filter'] != $old_value['filter'] ||
|
||||||
|
@ -500,8 +500,14 @@
|
|||||||
$ext_type = $type;
|
$ext_type = $type;
|
||||||
$extra_label = $this->extensionPreProcess($ext_type,$form_name,$value,$cell,$readonlys[$name]);
|
$extra_label = $this->extensionPreProcess($ext_type,$form_name,$value,$cell,$readonlys[$name]);
|
||||||
|
|
||||||
|
$readonly = $readonly || $cell['readonly']; // might be set be extension
|
||||||
$this->set_array($content,$name,$value);
|
$this->set_array($content,$name,$value);
|
||||||
}
|
}
|
||||||
|
$cell_options = $cell['size'];
|
||||||
|
if ($cell_options[0] == '@')
|
||||||
|
{
|
||||||
|
$cell_options = $this->get_array($content,substr($cell_options,1));
|
||||||
|
}
|
||||||
$label = $this->expand_name($cell['label'],$show_c,$show_row,$content['.c'],$content['.row'],$content);
|
$label = $this->expand_name($cell['label'],$show_c,$show_row,$content['.c'],$content['.row'],$content);
|
||||||
$help = $cell['help'];
|
$help = $cell['help'];
|
||||||
if ($help[0] == '@')
|
if ($help[0] == '@')
|
||||||
@ -535,7 +541,7 @@
|
|||||||
case 'label': // size: [[b]old][[i]talic][,link]
|
case 'label': // size: [[b]old][[i]talic][,link]
|
||||||
if (is_array($value))
|
if (is_array($value))
|
||||||
break;
|
break;
|
||||||
list($style,$extra_link) = explode(',',$cell['size']);
|
list($style,$extra_link) = explode(',',$cell_options);
|
||||||
$value = strlen($value) > 1 && !$cell['no_lang'] ? lang($value) : $value;
|
$value = strlen($value) > 1 && !$cell['no_lang'] ? lang($value) : $value;
|
||||||
$value = nl2br(htmlentities($value));
|
$value = nl2br(htmlentities($value));
|
||||||
if ($value != '' && strstr($style,'b')) $value = $this->html->bold($value);
|
if ($value != '' && strstr($style,'b')) $value = $this->html->bold($value);
|
||||||
@ -543,15 +549,15 @@
|
|||||||
$html .= $value;
|
$html .= $value;
|
||||||
break;
|
break;
|
||||||
case 'html':
|
case 'html':
|
||||||
$extra_link = $cell['size'];
|
$extra_link = $cell_options;
|
||||||
$html .= $value;
|
$html .= $value;
|
||||||
break;
|
break;
|
||||||
case 'int': // size: [min][,[max][,len]]
|
case 'int': // size: [min][,[max][,len]]
|
||||||
case 'float':
|
case 'float':
|
||||||
list($min,$max,$cell['size']) = explode(',',$cell['size']);
|
list($min,$max,$cell_options) = explode(',',$cell_options);
|
||||||
if ($cell['size'] == '')
|
if ($cell_options == '')
|
||||||
{
|
{
|
||||||
$cell['size'] = $cell['type'] == 'int' ? 5 : 8;
|
$cell_options = $cell['type'] == 'int' ? 5 : 8;
|
||||||
}
|
}
|
||||||
// fall-through
|
// fall-through
|
||||||
case 'text': // size: [length][,maxLength]
|
case 'text': // size: [length][,maxLength]
|
||||||
@ -562,20 +568,20 @@
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$html .= $this->html->input($form_name,$value,'',
|
$html .= $this->html->input($form_name,$value,'',
|
||||||
$options.$this->html->formatOptions($cell['size'],'SIZE,MAXLENGTH'));
|
$options.$this->html->formatOptions($cell_options,'SIZE,MAXLENGTH'));
|
||||||
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = $cell['type'];
|
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = $cell['type'];
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'textarea': // Multiline Text Input, size: [rows][,cols]
|
case 'textarea': // Multiline Text Input, size: [rows][,cols]
|
||||||
$html .= $this->html->textarea($form_name,$value,
|
$html .= $this->html->textarea($form_name,$value,
|
||||||
$options.$this->html->formatOptions($cell['size'],'ROWS,COLS'));
|
$options.$this->html->formatOptions($cell_options,'ROWS,COLS'));
|
||||||
if (!$readonly)
|
if (!$readonly)
|
||||||
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = $cell['type'];
|
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = $cell['type'];
|
||||||
break;
|
break;
|
||||||
case 'checkbox':
|
case 'checkbox':
|
||||||
if (!empty($cell['size']))
|
if (!empty($cell_options))
|
||||||
{
|
{
|
||||||
list($true_val,$false_val,$ro_true,$ro_false) = explode(',',$cell['size']);
|
list($true_val,$false_val,$ro_true,$ro_false) = explode(',',$cell_options);
|
||||||
$value = $value == $true_val;
|
$value = $value == $true_val;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -596,12 +602,12 @@
|
|||||||
$html .= $this->html->input($form_name,'1','CHECKBOX',$options);
|
$html .= $this->html->input($form_name,'1','CHECKBOX',$options);
|
||||||
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = array(
|
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = array(
|
||||||
'type' => $cell['type'],
|
'type' => $cell['type'],
|
||||||
'values' => $cell['size']
|
'values' => $cell_options
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'radio': // size: value if checked
|
case 'radio': // size: value if checked
|
||||||
$set_val = $this->expand_name($cell['size'],$show_c,$show_row,$content['.c'],$content['.row'],$content);
|
$set_val = $this->expand_name($cell_options,$show_c,$show_row,$content['.c'],$content['.row'],$content);
|
||||||
|
|
||||||
if ($value == $set_val)
|
if ($value == $set_val)
|
||||||
{
|
{
|
||||||
@ -635,7 +641,7 @@
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
list($img,$ro_img) = explode(',',$cell['size']);
|
list($img,$ro_img) = explode(',',$cell_options);
|
||||||
if (!empty($img))
|
if (!empty($img))
|
||||||
{
|
{
|
||||||
$options .= ' TITLE="'.(strlen($label)<=1||$cell['no_lang']?$label:lang($label)).'"';
|
$options .= ' TITLE="'.(strlen($label)<=1||$cell['no_lang']?$label:lang($label)).'"';
|
||||||
@ -649,7 +655,7 @@
|
|||||||
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = $cell['type'];
|
$GLOBALS['phpgw_info']['etemplate']['to_process'][$form_name] = $cell['type'];
|
||||||
break;
|
break;
|
||||||
case 'hrule':
|
case 'hrule':
|
||||||
$html .= $this->html->hr($cell['size']);
|
$html .= $this->html->hr($cell_options);
|
||||||
break;
|
break;
|
||||||
case 'template': // size: index in content-array (if not full content is past further on)
|
case 'template': // size: index in content-array (if not full content is past further on)
|
||||||
if (is_object($cell['name']))
|
if (is_object($cell['name']))
|
||||||
@ -680,7 +686,7 @@
|
|||||||
{
|
{
|
||||||
echo "<p>show_cell::template(tpl=$this->name,name=$cell[name]): $obj_read</p>\n";
|
echo "<p>show_cell::template(tpl=$this->name,name=$cell[name]): $obj_read</p>\n";
|
||||||
}
|
}
|
||||||
if ($this->autorepeat_idx($cell,$show_c,$show_row,$idx,$idx_cname) || $cell['size'] != '')
|
if ($this->autorepeat_idx($cell,$show_c,$show_row,$idx,$idx_cname) || $cell_options != '')
|
||||||
{
|
{
|
||||||
if ($span == '' && isset($content[$idx]['span']))
|
if ($span == '' && isset($content[$idx]['span']))
|
||||||
{ // this allows a colspan in autorepeated cells like the editor
|
{ // this allows a colspan in autorepeated cells like the editor
|
||||||
@ -706,7 +712,7 @@
|
|||||||
break;
|
break;
|
||||||
case 'select': // size:[linesOnMultiselect]
|
case 'select': // size:[linesOnMultiselect]
|
||||||
$sels = array();
|
$sels = array();
|
||||||
list($multiple) = explode(',',$cell['size']);
|
list($multiple) = explode(',',$cell_options);
|
||||||
if (!empty($multiple) && 0+$multiple <= 0)
|
if (!empty($multiple) && 0+$multiple <= 0)
|
||||||
{
|
{
|
||||||
$sels[''] = $multiple < 0 ? lang('all') : lang($multiple);
|
$sels[''] = $multiple < 0 ? lang('all') : lang($multiple);
|
||||||
@ -760,7 +766,7 @@
|
|||||||
$image = $this->html->image(substr($this->name,0,strpos($this->name,'.')),
|
$image = $this->html->image(substr($this->name,0,strpos($this->name,'.')),
|
||||||
$image,strlen($label) > 1 && !$cell['no_lang'] ? lang($label) : $label,'BORDER="0"');
|
$image,strlen($label) > 1 && !$cell['no_lang'] ? lang($label) : $label,'BORDER="0"');
|
||||||
$html .= $image;
|
$html .= $image;
|
||||||
$extra_link = $cell['size'];
|
$extra_link = $cell_options;
|
||||||
$extra_label = False;
|
$extra_label = False;
|
||||||
break;
|
break;
|
||||||
case 'file':
|
case 'file':
|
||||||
@ -776,7 +782,7 @@
|
|||||||
$box_row = 1;
|
$box_row = 1;
|
||||||
$box_col = 'A';
|
$box_col = 'A';
|
||||||
$box_anz = 0;
|
$box_anz = 0;
|
||||||
for ($n = 1; $n <= $cell['size']; ++$n)
|
for ($n = 1; $n <= $cell_options; ++$n)
|
||||||
{
|
{
|
||||||
$h = $this->show_cell($cell[$n],$content,$sel_options,$readonlys,$cname,$show_c,$show_row,$nul);
|
$h = $this->show_cell($cell[$n],$content,$sel_options,$readonlys,$cname,$show_c,$show_row,$nul);
|
||||||
if ($h != '' && $h != ' ')
|
if ($h != '' && $h != ' ')
|
||||||
@ -804,14 +810,14 @@
|
|||||||
if ($box_anz > 1) // a single cell is NOT placed into a table
|
if ($box_anz > 1) // a single cell is NOT placed into a table
|
||||||
{
|
{
|
||||||
$html = "\n\n<!-- BEGIN $cell[type] -->\n\n".
|
$html = "\n\n<!-- BEGIN $cell[type] -->\n\n".
|
||||||
$this->html->table($rows,$this->html->formatOptions($cell['size'],',CELLPADDING,CELLSPACING').
|
$this->html->table($rows,$this->html->formatOptions($cell_options,',CELLPADDING,CELLSPACING').
|
||||||
($cell['align'] ? ' WIDTH="100%"' : '')). // alignment only works if table has full width
|
($cell['align'] && $type == 'vbox' ? ' WIDTH="100%"' : '')). // alignment only works if table has full width
|
||||||
"\n\n<!-- END $cell[type] -->\n\n";
|
"\n\n<!-- END $cell[type] -->\n\n";
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'deck':
|
case 'deck':
|
||||||
for ($n = 1; $n <= $cell['size'] && (empty($value) || $value != $cell[$n]['name']); ++$n) ;
|
for ($n = 1; $n <= $cell_options && (empty($value) || $value != $cell[$n]['name']); ++$n) ;
|
||||||
if ($n > $cell['size'])
|
if ($n > $cell_options)
|
||||||
{
|
{
|
||||||
$value = $cell[1]['name'];
|
$value = $cell[1]['name'];
|
||||||
}
|
}
|
||||||
@ -823,10 +829,10 @@
|
|||||||
{
|
{
|
||||||
$s_height = "height: $s_height".(substr($s_height,-1) != '%' ? 'px' : '').';';
|
$s_height = "height: $s_height".(substr($s_height,-1) != '%' ? 'px' : '').';';
|
||||||
}
|
}
|
||||||
for ($n = 1; $n <= $cell['size']; ++$n)
|
for ($n = 1; $n <= $cell_options; ++$n)
|
||||||
{
|
{
|
||||||
$h = $this->show_cell($cell[$n],$content,$sel_options,$readonlys,$cname,$show_c,$show_row,$nul);
|
$h = $this->show_cell($cell[$n],$content,$sel_options,$readonlys,$cname,$show_c,$show_row,$nul);
|
||||||
$vis = !empty($value) && $value == $cell['size'][$n]['name'] || $n == 1 && $first ? 'visible' : 'hidden';
|
$vis = !empty($value) && $value == $cell_options[$n]['name'] || $n == 1 && $first ? 'visible' : 'hidden';
|
||||||
list (,$cl) = explode(',',$cell[$n]['span']);
|
list (,$cl) = explode(',',$cell[$n]['span']);
|
||||||
$html .= $this->html->div($h,$this->html->formatOptions(array(
|
$html .= $this->html->div($h,$this->html->formatOptions(array(
|
||||||
$cl.($cl ? ' ':'').'tab_body',
|
$cl.($cl ? ' ':'').'tab_body',
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
// eTemplates for Application 'etemplate', generated by etemplate.dump() 2003-05-30 20:55
|
// eTemplates for Application 'etemplate', generated by etemplate.dump() 2003-06-29 18:47
|
||||||
|
|
||||||
/* $Id$ */
|
/* $Id$ */
|
||||||
|
|
||||||
@ -129,3 +129,7 @@ $templ_data[] = array('name' => 'etemplate.tab_widget','template' => '','lang' =
|
|||||||
|
|
||||||
$templ_data[] = array('name' => 'etemplate.link_widget.search','template' => '','lang' => '','group' => '0','version' => '0.9.15.003','data' => 'a:3:{i:0;a:2:{s:2:\"c1\";s:6:\"row_on\";s:2:\"c2\";s:7:\"row_off\";}i:1;a:4:{s:1:\"A\";a:5:{s:4:\"type\";s:6:\"select\";s:5:\"label\";s:6:\"Search\";s:7:\"no_lang\";s:1:\"1\";s:4:\"name\";s:3:\"app\";s:4:\"help\";s:26:\"Select an App to search in\";}s:1:\"B\";a:4:{s:4:\"type\";s:4:\"text\";s:4:\"size\";s:2:\"25\";s:4:\"name\";s:5:\"query\";s:4:\"help\";s:22:\"Enter a search pattern\";}s:1:\"C\";a:4:{s:4:\"type\";s:6:\"button\";s:5:\"label\";s:6:\"Search\";s:4:\"name\";s:6:\"search\";s:4:\"help\";s:30:\"Click here to start the search\";}s:1:\"D\";a:4:{s:4:\"type\";s:5:\"label\";s:4:\"span\";s:10:\",error_msg\";s:5:\"label\";s:29:\"Nothing found - try again !!!\";s:4:\"name\";s:3:\"msg\";}}i:2;a:4:{s:1:\"A\";a:2:{s:4:\"type\";s:5:\"label\";s:5:\"label\";s:11:\"attach file\";}s:1:\"B\";a:3:{s:4:\"type\";s:4:\"file\";s:4:\"name\";s:4:\"file\";s:4:\"help\";s:69:\"Enter filename to upload and attach, use [Browse...] to search for it\";}s:1:\"C\";a:4:{s:4:\"type\";s:6:\"button\";s:5:\"label\";s:6:\"Upload\";s:4:\"name\";s:6:\"upload\";s:4:\"help\";s:29:\"Click here to upload the file\";}s:1:\"D\";a:1:{s:4:\"type\";s:5:\"label\";}}}','size' => '','style' => '.error_msg { font-style: italic; color: red; }','modified' => '1054320872',);
|
$templ_data[] = array('name' => 'etemplate.link_widget.search','template' => '','lang' => '','group' => '0','version' => '0.9.15.003','data' => 'a:3:{i:0;a:2:{s:2:\"c1\";s:6:\"row_on\";s:2:\"c2\";s:7:\"row_off\";}i:1;a:4:{s:1:\"A\";a:5:{s:4:\"type\";s:6:\"select\";s:5:\"label\";s:6:\"Search\";s:7:\"no_lang\";s:1:\"1\";s:4:\"name\";s:3:\"app\";s:4:\"help\";s:26:\"Select an App to search in\";}s:1:\"B\";a:4:{s:4:\"type\";s:4:\"text\";s:4:\"size\";s:2:\"25\";s:4:\"name\";s:5:\"query\";s:4:\"help\";s:22:\"Enter a search pattern\";}s:1:\"C\";a:4:{s:4:\"type\";s:6:\"button\";s:5:\"label\";s:6:\"Search\";s:4:\"name\";s:6:\"search\";s:4:\"help\";s:30:\"Click here to start the search\";}s:1:\"D\";a:4:{s:4:\"type\";s:5:\"label\";s:4:\"span\";s:10:\",error_msg\";s:5:\"label\";s:29:\"Nothing found - try again !!!\";s:4:\"name\";s:3:\"msg\";}}i:2;a:4:{s:1:\"A\";a:2:{s:4:\"type\";s:5:\"label\";s:5:\"label\";s:11:\"attach file\";}s:1:\"B\";a:3:{s:4:\"type\";s:4:\"file\";s:4:\"name\";s:4:\"file\";s:4:\"help\";s:69:\"Enter filename to upload and attach, use [Browse...] to search for it\";}s:1:\"C\";a:4:{s:4:\"type\";s:6:\"button\";s:5:\"label\";s:6:\"Upload\";s:4:\"name\";s:6:\"upload\";s:4:\"help\";s:29:\"Click here to upload the file\";}s:1:\"D\";a:1:{s:4:\"type\";s:5:\"label\";}}}','size' => '','style' => '.error_msg { font-style: italic; color: red; }','modified' => '1054320872',);
|
||||||
|
|
||||||
|
$templ_data[] = array('name' => 'etemplate.nextmatch_widget','template' => '','lang' => '','group' => '0','version' => '0.9.15.007','data' => 'a:5:{i:0;a:3:{s:1:\"A\";s:3:\"40%\";s:1:\"C\";s:3:\"40%\";s:2:\"h4\";s:13:\",!@bottom_too\";}i:1;a:3:{s:1:\"A\";a:2:{s:4:\"type\";s:8:\"template\";s:4:\"name\";s:12:\"@header_left\";}s:1:\"B\";a:5:{s:4:\"type\";s:4:\"hbox\";s:4:\"size\";s:1:\"2\";s:5:\"align\";s:6:\"center\";i:1;a:4:{s:4:\"type\";s:5:\"label\";s:5:\"label\";s:7:\"showing\";s:7:\"no_lang\";s:1:\"1\";s:4:\"name\";s:5:\"range\";}i:2;a:4:{s:4:\"type\";s:5:\"label\";s:5:\"label\";s:2:\"of\";s:7:\"no_lang\";s:1:\"1\";s:4:\"name\";s:5:\"total\";}}s:1:\"C\";a:3:{s:4:\"type\";s:8:\"template\";s:5:\"align\";s:5:\"right\";s:4:\"name\";s:13:\"@header_right\";}}i:2;a:3:{s:1:\"A\";a:4:{s:4:\"type\";s:8:\"template\";s:4:\"span\";s:3:\"all\";s:5:\"align\";s:6:\"center\";s:4:\"name\";s:33:\"etemplate.nextmatch_widget.nm_row\";}s:1:\"B\";a:2:{s:4:\"type\";s:5:\"label\";s:8:\"onchange\";s:1:\"1\";}s:1:\"C\";a:1:{s:4:\"type\";s:5:\"label\";}}i:3;a:3:{s:1:\"A\";a:5:{s:4:\"type\";s:8:\"template\";s:4:\"size\";s:4:\"rows\";s:4:\"span\";s:3:\"all\";s:5:\"align\";s:6:\"center\";s:4:\"name\";s:9:\"@template\";}s:1:\"B\";a:1:{s:4:\"type\";s:5:\"label\";}s:1:\"C\";a:1:{s:4:\"type\";s:5:\"label\";}}i:4;a:3:{s:1:\"A\";a:5:{s:4:\"type\";s:8:\"template\";s:4:\"size\";s:6:\"bottom\";s:4:\"span\";s:3:\"all\";s:5:\"align\";s:6:\"center\";s:4:\"name\";s:33:\"etemplate.nextmatch_widget.nm_row\";}s:1:\"B\";a:1:{s:4:\"type\";s:5:\"label\";}s:1:\"C\";a:1:{s:4:\"type\";s:5:\"label\";}}}','size' => '100%','style' => '','modified' => '1056897420',);
|
||||||
|
|
||||||
|
$templ_data[] = array('name' => 'etemplate.nextmatch_widget.header_only','template' => '','lang' => '','group' => '0','version' => '0.9.15.001','data' => 'a:3:{i:0;a:2:{s:1:\"A\";s:3:\"50%\";s:1:\"B\";s:3:\"50%\";}i:1;a:2:{s:1:\"A\";a:2:{s:4:\"type\";s:8:\"template\";s:4:\"name\";s:12:\"@header_left\";}s:1:\"B\";a:3:{s:4:\"type\";s:8:\"template\";s:5:\"align\";s:5:\"right\";s:4:\"name\";s:13:\"@header_right\";}}i:2;a:2:{s:1:\"A\";a:5:{s:4:\"type\";s:8:\"template\";s:4:\"size\";s:4:\"rows\";s:4:\"span\";s:3:\"all\";s:5:\"align\";s:6:\"center\";s:4:\"name\";s:9:\"@template\";}s:1:\"B\";a:1:{s:4:\"type\";s:5:\"label\";}}}','size' => '100%','style' => '','modified' => '1056877177',);
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
|
%1 disabled etemplate de %1 deaktiviert
|
||||||
%1 etemplates deleted etemplate de %1 eTemplates gelöscht
|
%1 etemplates deleted etemplate de %1 eTemplates gelöscht
|
||||||
%1 etemplates found etemplate de %1 eTemplates gefunden
|
%1 etemplates found etemplate de %1 eTemplates gefunden
|
||||||
%1 disabled etemplate de %1 deaktiviert
|
|
||||||
%1 needed etemplate de %1 benötigt
|
%1 needed etemplate de %1 benötigt
|
||||||
%1 notranslation etemplate de %1 nicht übersetzen
|
%1 notranslation etemplate de %1 nicht übersetzen
|
||||||
%1 onchange etemplate de %1 onChange
|
%1 onchange etemplate de %1 onChange
|
||||||
@ -22,7 +22,7 @@ border etemplate de Rand
|
|||||||
border-line-thickness for the table-tag etemplate de Randbreite (border) für die Tabelle
|
border-line-thickness for the table-tag etemplate de Randbreite (border) für die Tabelle
|
||||||
can have special sql-value null etemplate de darf speziellen SQL Wert NULL annehmen
|
can have special sql-value null etemplate de darf speziellen SQL Wert NULL annehmen
|
||||||
cancel etemplate de Abbruch
|
cancel etemplate de Abbruch
|
||||||
category etemplate de Kategori
|
category etemplate de Kategorie
|
||||||
cellpadding for the table-tag etemplate de Innenabstand (cellpadding) der Tabelle
|
cellpadding for the table-tag etemplate de Innenabstand (cellpadding) der Tabelle
|
||||||
cells etemplate de Zellen
|
cells etemplate de Zellen
|
||||||
cellspacing for the table-tag etemplate de Zellenabstand (cellspacing) der Tabelle
|
cellspacing for the table-tag etemplate de Zellenabstand (cellspacing) der Tabelle
|
||||||
@ -51,6 +51,7 @@ db-tools etemplate de DB-Tools
|
|||||||
deck etemplate de Deck (intern)
|
deck etemplate de Deck (intern)
|
||||||
default etemplate de Vorgabe
|
default etemplate de Vorgabe
|
||||||
delete etemplate de Löschen
|
delete etemplate de Löschen
|
||||||
|
delete a single entry by passing the id. etemplate de
|
||||||
delete all selected etemplates, without further inquiry etemplate de löscht ALLE ausgewählten eTemplates OHNE weitere Rückfrage
|
delete all selected etemplates, without further inquiry etemplate de löscht ALLE ausgewählten eTemplates OHNE weitere Rückfrage
|
||||||
delete column etemplate de Spalte löschen
|
delete column etemplate de Spalte löschen
|
||||||
delete this etemplate etemplate de dieses eTemplate löschen
|
delete this etemplate etemplate de dieses eTemplate löschen
|
||||||
@ -132,7 +133,8 @@ last etemplate de Letzte
|
|||||||
left etemplate de Links
|
left etemplate de Links
|
||||||
length for char+varchar, precisions int: 2, 4, 8 and float: 4, 8 etemplate de Länge für char+varchar, Genauigkeit für int: 2, 4, 8 und float: 4, 8
|
length for char+varchar, precisions int: 2, 4, 8 and float: 4, 8 etemplate de Länge für char+varchar, Genauigkeit für int: 2, 4, 8 und float: 4, 8
|
||||||
link etemplate de Verknüpfung
|
link etemplate de Verknüpfung
|
||||||
linklist etemplate de ListeVerknüpfungen
|
linklist etemplate de VerknüpfungListe
|
||||||
|
linkstring etemplate de VerküpfungZeichenkette
|
||||||
linkto etemplate de VerküpfungZu
|
linkto etemplate de VerküpfungZu
|
||||||
load this template into the editor etemplate de lädt diese Template zum Bearbeiten
|
load this template into the editor etemplate de lädt diese Template zum Bearbeiten
|
||||||
minute etemplate de Minute
|
minute etemplate de Minute
|
||||||
@ -147,6 +149,7 @@ new search etemplate de Neue Suche
|
|||||||
new table created etemplate de Neue Tabelle erzeugt
|
new table created etemplate de Neue Tabelle erzeugt
|
||||||
newer version '%1' exists !!! etemplate de Neuere Version '%1' existiert !!!
|
newer version '%1' exists !!! etemplate de Neuere Version '%1' existiert !!!
|
||||||
nextmatch etemplate de Nextmatch
|
nextmatch etemplate de Nextmatch
|
||||||
|
no file etemplate de keine Datei
|
||||||
no filename given or selected via browse... etemplate de kein Dateiname angegeben oder mit [Browse...] ausgewählt
|
no filename given or selected via browse... etemplate de kein Dateiname angegeben oder mit [Browse...] ausgewählt
|
||||||
nothing found - try again !!! etemplate de Nichts gefunden - nochmal versuchen !!!
|
nothing found - try again !!! etemplate de Nichts gefunden - nochmal versuchen !!!
|
||||||
nullable etemplate de Nullable
|
nullable etemplate de Nullable
|
||||||
@ -165,6 +168,8 @@ primary key etemplate de Primary Key
|
|||||||
primary key for the table, gets automaticaly indexed etemplate de Hauptindex (Primary Key) der Tabelle, wird automatisch indiziert
|
primary key for the table, gets automaticaly indexed etemplate de Hauptindex (Primary Key) der Tabelle, wird automatisch indiziert
|
||||||
radiobutton etemplate de Radioknopf
|
radiobutton etemplate de Radioknopf
|
||||||
read etemplate de Lesen
|
read etemplate de Lesen
|
||||||
|
read a list of entries. etemplate de Liest eine Liste von Einträgen.
|
||||||
|
read a single entry by passing the id and fieldlist. etemplate de Liste einen einzelnen Eintrag durch übergabe seiner Id und Feldliste.
|
||||||
read etemplate from database (for the keys above) etemplate de ließt ein eTemplate aus der Datenbank (für die Schlüssel darüber)
|
read etemplate from database (for the keys above) etemplate de ließt ein eTemplate aus der Datenbank (für die Schlüssel darüber)
|
||||||
remove row (can not be undone!!!) etemplate de löscht eine Zeile (NICHT rückgängig zu machen)
|
remove row (can not be undone!!!) etemplate de löscht eine Zeile (NICHT rückgängig zu machen)
|
||||||
remove this link (not the entry itself) etemplate de entfernt diese Verknüpfung (nicht den Eintrag selbst)
|
remove this link (not the entry itself) etemplate de entfernt diese Verknüpfung (nicht den Eintrag selbst)
|
||||||
@ -231,6 +236,7 @@ type of the column etemplate de Typ der Spalte
|
|||||||
type of the field (select label if field should be empty) etemplate de Type des Feldes (Beschriftung auswählen wenn Feld leer sein soll)
|
type of the field (select label if field should be empty) etemplate de Type des Feldes (Beschriftung auswählen wenn Feld leer sein soll)
|
||||||
unique etemplate de Unique
|
unique etemplate de Unique
|
||||||
unlink etemplate de Lösen
|
unlink etemplate de Lösen
|
||||||
|
update a single entry by passing the fields. etemplate de Aktualisert einen einzelnen Eintrag über seine Felder.
|
||||||
update from version '%1' to etemplate de Update von Version '%1' auf
|
update from version '%1' to etemplate de Update von Version '%1' auf
|
||||||
upload etemplate de Hochladen
|
upload etemplate de Hochladen
|
||||||
value etemplate de Wert
|
value etemplate de Wert
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
|
%1 disabled etemplate en %1 disabled
|
||||||
%1 etemplates deleted etemplate en %1 eTemplates deleted
|
%1 etemplates deleted etemplate en %1 eTemplates deleted
|
||||||
%1 etemplates found etemplate en %1 eTemplates found
|
%1 etemplates found etemplate en %1 eTemplates found
|
||||||
%1 disabled etemplate en %1 disabled
|
|
||||||
%1 needed etemplate en %1 needed
|
%1 needed etemplate en %1 needed
|
||||||
%1 notranslation etemplate en %1 NoTranslation
|
%1 notranslation etemplate en %1 NoTranslation
|
||||||
%1 onchange etemplate en %1 onChange
|
%1 onchange etemplate en %1 onChange
|
||||||
@ -134,6 +134,7 @@ left etemplate en Left
|
|||||||
length for char+varchar, precisions int: 2, 4, 8 and float: 4, 8 etemplate en length for char+varchar, precisions int: 2, 4, 8 and float: 4, 8
|
length for char+varchar, precisions int: 2, 4, 8 and float: 4, 8 etemplate en length for char+varchar, precisions int: 2, 4, 8 and float: 4, 8
|
||||||
link etemplate en Link
|
link etemplate en Link
|
||||||
linklist etemplate en LinkList
|
linklist etemplate en LinkList
|
||||||
|
linkstring etemplate en LinkString
|
||||||
linkto etemplate en LinkTo
|
linkto etemplate en LinkTo
|
||||||
load this template into the editor etemplate en load this template into the editor
|
load this template into the editor etemplate en load this template into the editor
|
||||||
minute etemplate en Minute
|
minute etemplate en Minute
|
||||||
|
Loading…
Reference in New Issue
Block a user