+ \$().ready(function() {
+ \$('#${id}').multiselect2side({ ${vars} });
+ });
+
+EOCODE
+
+ return $code;
+}
+
+sub online_help_tag {
+ my ($self, $tag, @slurp) = @_;
+ my %params = _hashify(@slurp);
+ my $cc = $::myconfig{countrycode};
+ my $file = "doc/online/$cc/$tag.html";
+ my $text = $params{text} || $::locale->text('Help');
+
+ die 'malformed help tag' unless $tag =~ /^[a-zA-Z0-9_]+$/;
+ return unless -f $file;
+ return $self->html_tag('a', $text, href => $file, target => '_blank');
+}
+
+sub dump {
+ my $self = shift;
+ require Data::Dumper;
+ return '' . Data::Dumper::Dumper(@_) . '
';
+}
+
1;
__END__
@@ -280,8 +476,10 @@ Creates a HTML 'select' tag named C<$name> with the contents
C<$options_string> and with arbitrary HTML attributes from
C<%attributes>. The tag's C defaults to C.
-The $options_string is usually created by the C
-function.
+The C<$options_string> is usually created by the
+L function. If C<$options_string> is an array
+reference then it will be passed to L
+automatically.
=item C
@@ -289,6 +487,23 @@ Creates a HTML 'input type=text' tag named C<$name> with the value
C<$value> and with arbitrary HTML attributes from C<%attributes>. The
tag's C defaults to C.
+=item C
+
+Creates a HTML 'input type=hidden' tag named C<$name> with the value
+C<$value> and with arbitrary HTML attributes from C<%attributes>. The
+tag's C defaults to C.
+
+=item C
+
+Creates a HTML 'input type=submit class=submit' tag named C<$name> with the
+value C<$value> and with arbitrary HTML attributes from C<%attributes>. The
+tag's C defaults to C.
+
+If C<$attributes{confirm}> is set then a JavaScript popup dialog will
+be added via the C handler asking the question given with
+C<$attributes{confirm}>. If request is only submitted if the user
+clicks the dialog's ok/yes button.
+
=item C
Creates a HTML 'textarea' tag named C<$name> with the content
@@ -330,6 +545,68 @@ tag for each file name parameter passed. Each file name will be
postfixed with '.js' if it isn't already and prefixed with 'js/' if it
doesn't contain a slash.
+=item C
+
+Creates a HTML 'Elink rel="text/stylesheet" href="..."E' tag
+for each file name parameter passed. Each file name will be postfixed
+with '.css' if it isn't already and prefixed with 'css/' if it doesn't
+contain a slash.
+
+=item C $align_code, %attributes>
+
+Creates a date input field, with an attached javascript that will open a
+calendar on click. The javascript ist by default anchoered at the bottom right
+sight. This can be overridden with C, see Calendar documentation for
+the details, usually you'll want a two letter abbreviation of the alignment.
+Right + Bottom becomes C.
+
+=item C
+
+Will create a tabbed area. The tabs should be created with the helper function
+C. Example:
+
+ [% L.tabbed([
+ L.tab(LxERP.t8('Basic Data'), 'part/_main_tab.html'),
+ L.tab(LxERP.t8('Custom Variables'), 'part/_cvar_tab.html', if => SELF.display_cvar_tab),
+ ]) %]
+
+An optional attribute is C, which accepts the ordinal of a tab which
+should be selected by default.
+
+=item C
+
+Creates a generic input tag or textarea tag, depending on content size. The
+mount of desired rows must be given with C parameter, Accpeted parameters
+include C for rendering a minimum of rows if a textarea is displayed.
+
+You can force input by setting rows to 1, and you can force textarea by setting
+rows to anything >1.
+
+=item C
+
+Creates a JavaScript snippet calling the jQuery function
+C on the select control with the ID C<$id>. The
+select itself is not created. C<%params> can contain the following
+entries:
+
+=over 2
+
+=item C
+
+The label of the list of available options. Defaults to the
+translation of 'Available'.
+
+=item C
+
+The label of the list of selected options. Defaults to the
+translation of 'Selected'.
+
+=back
+
+=item C
+
+Dumps the Argument using L into a EpreE block.
+
=back
=head2 CONVERSION FUNCTIONS
@@ -364,11 +641,38 @@ respectively.
For cases 3 and 4 C<$options{value}> defaults to C and
C<$options{title}> defaults to C<$options{value}>.
+In addition to pure keys/method you can also provide coderefs as I
+and/or I. If present, these take precedence over keys or methods,
+and are called with the element as first argument. It must return the value or
+title.
+
+Lastly a joint coderef I may be provided, which in turn takes
+precedence over each individual sub. It will only be called once for each
+element and must return a list of value and title.
+
If the option C is set then an empty element (value
C) will be used as the first element. The title to display for
this element can be set with the option C and defaults to
an empty string.
+The option C can be either a scalar or an array reference
+containing the values of the options which should be set to be
+selected.
+
+=item C
+
+Creates a tab for C. The description will be used as displayed name.
+The target should be a block or template that can be processed. C supports
+a C parameter, which can override the process method to apply target.
+C 'raw'> will just include the given text as is. I was too lazy to
+implement C properly.
+
+Also an C attribute is supported, so that tabs can be suppressed based on
+some occasion. In this case the supplied block won't even get processed, and
+the resulting tab will get ignored by C:
+
+ L.tab('Awesome tab wih much info', '_much_info.html', if => SELF.wants_all)
+
=back
=head1 MODULE AUTHORS