Revision ee51b82f
Von Tamino Steinert vor etwa 2 Jahren hinzugefügt
SL/Presenter/SepaExport.pm | ||
---|---|---|
3 | 3 |
use strict; |
4 | 4 |
|
5 | 5 |
use SL::Presenter::EscapedText qw(escape is_escaped); |
6 |
use SL::Presenter::Tag qw(link_tag); |
|
6 | 7 |
|
7 | 8 |
use Exporter qw(import); |
8 | 9 |
our @EXPORT_OK = qw(sepa_export); |
... | ... | |
16 | 17 |
|
17 | 18 |
croak "Unknown display type '$params{display}'" unless $params{display} =~ m/^(?:inline|table-cell)$/; |
18 | 19 |
|
19 |
my $text = join '', ( |
|
20 |
$params{no_link} ? '' : '<a href="sepa.pl?action=bank_transfer_edit&vc=' . escape($sepa_export->vc) . '&id=' . escape($sepa_export->id) . '">', |
|
21 |
escape($sepa_export->id), |
|
22 |
$params{no_link} ? '' : '</a>', |
|
23 |
); |
|
20 |
my $text = escape($sepa_export->id); |
|
21 |
if (! delete $params{no_link}) { |
|
22 |
my $href = 'sepa.pl?action=bank_transfer_edit' |
|
23 |
. '&vc=' . escape($sepa_export->vc) |
|
24 |
. '&id=' . escape($sepa_export->id); |
|
25 |
$text = link_tag($href, $text, %params); |
|
26 |
} |
|
27 |
|
|
24 | 28 |
is_escaped($text); |
25 | 29 |
} |
26 | 30 |
|
Auch abrufbar als: Unified diff
Presenter: nutze link_tag anstelle von html im perl-code
(cherry picked aus Kundenprojekt)