my $bank_accounts = SL::DB::Manager::BankAccount->get_all_sorted( query => [ obsolete => 0 ] );
+ $self->setup_search_action_bar;
$self->render('bank_transactions/search',
BANK_ACCOUNTS => $bank_accounts);
}
$self->make_filter_summary;
$self->prepare_report;
+ $self->setup_list_all_action_bar;
$self->report_generator_list_objects(report => $self->{report}, objects => $self->models->get);
}
);
}
+sub setup_search_action_bar {
+ my ($self, %params) = @_;
+
+ for my $bar ($::request->layout->get('actionbar')) {
+ $bar->add(
+ action => [
+ t8('Filter'),
+ submit => [ '#search_form', { action => 'BankTransaction/list' } ],
+ accesskey => 'enter',
+ ],
+ );
+ }
+}
+
+sub setup_list_all_action_bar {
+ my ($self, %params) = @_;
+
+ for my $bar ($::request->layout->get('actionbar')) {
+ $bar->add(
+ action => [
+ t8('Filter'),
+ submit => [ '#filter_form', { action => 'BankTransaction/list_all' } ],
+ accesskey => 'enter',
+ ],
+ );
+ }
+}
+
1;
__END__
</tr>
</table>
-[% L.hidden_tag('action', 'BankTransaction/dispatch') %]
[% L.hidden_tag('sort_by', FORM.sort_by) %]
[% L.hidden_tag('sort_dir', FORM.sort_dir) %]
[% L.hidden_tag('page', FORM.page) %]
-[% L.input_tag('action_list_all', LxERP.t8('Continue'), type = 'submit', class='submit')%]
-
[% L.button_tag('$("#filter_form").resetForm()', LxERP.t8('Reset')) %]
</div>
[%- INCLUDE 'common/flash.html' %]
- <form method="post" action="controller.pl">
+ <form method="post" action="controller.pl" id="search_form">
<div class="listtop">[% 'Search bank transactions' | $T8 %]</div>
</tr>
</table>
</p>
-
- <hr size="3" noshade>
-
- [% L.hidden_tag('action', 'BankTransaction/list') %]
-
- <p>[% L.submit_tag('dummy', LxERP.t8('Continue')) %]</p>
</form>