X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/ee74ea829d19e553d14e0f7bbdf9ee189cff3c36..c89986ac6447c14ebf351047b9441bcbf5637e76:/SL/Presenter/Part.pm diff --git a/SL/Presenter/Part.pm b/SL/Presenter/Part.pm index 9533e1d6c..a10340727 100644 --- a/SL/Presenter/Part.pm +++ b/SL/Presenter/Part.pm @@ -40,6 +40,7 @@ sub part_picker { join('', map { $params{$_} ? $self->input_tag("", delete $params{$_}, id => "${id}_${_}", type => 'hidden') : '' } qw(column type unit convertible_unit)) . $self->input_tag("", (ref $value && $value->can('description')) ? $value->description : '', id => "${id}_name", %params); + $::request->layout->add_javascripts('autocomplete_part.js'); $::request->presenter->need_reinit_widgets($id); $self->html_tag('span', $ret, class => 'part_picker'); @@ -88,7 +89,7 @@ to the corresponding 'edit' action. =back -=back +=back =over 2 @@ -119,8 +120,11 @@ Obsolete parts will by default not displayed for selection. However they are accepted as default values and can persist during updates. As with other selectors though, they are not selectable once overridden. -Currently you must include C in your controller, the -presenter can not do this from the template. +C will register it's javascript for inclusion in the next header +rendering. If you write a standard controller that only call C once, it +will just work. In case the header is generated in a different render call +(multiple blocks, ajax, old C style controllers) you need to +include C yourself. =back