Revision 1cc72c5b
Von Bernd Bleßmann vor etwa 11 Jahren hinzugefügt
SL/Controller/CsvImport.pm | ||
---|---|---|
127 | 127 |
my $csv = Text::CSV_XS->new({ binary => 1, map { ( $_ => $self->profile->get($_) ) } qw(sep_char escape_char quote_char),}); |
128 | 128 |
|
129 | 129 |
if ($self->worker->is_multiplexed) { |
130 |
foreach my $ri (keys %{ $self->displayable_columns }) {
|
|
131 |
$csv->print($file->fh, [ map { $_->{name} } @{ $self->displayable_columns->{$ri} } ]);
|
|
130 |
foreach my $p (@{ $self->worker->profile }) {
|
|
131 |
$csv->print($file->fh, [ map { $_->{name} } @{ $self->displayable_columns->{$p->{row_ident}} } ]);
|
|
132 | 132 |
$file->fh->print("\r\n"); |
133 | 133 |
} |
134 |
foreach my $ri (keys %{ $self->displayable_columns }) {
|
|
135 |
$csv->print($file->fh, [ map { $_->{description} } @{ $self->displayable_columns->{$ri} } ]);
|
|
134 |
foreach my $p (@{ $self->worker->profile }) {
|
|
135 |
$csv->print($file->fh, [ map { $_->{description} } @{ $self->displayable_columns->{$p->{row_ident}} } ]);
|
|
136 | 136 |
$file->fh->print("\r\n"); |
137 | 137 |
} |
138 | 138 |
} else { |
templates/webpages/csv_import/form.html | ||
---|---|---|
60 | 60 |
[%- IF SELF.worker.is_multiplexed %] |
61 | 61 |
<table> |
62 | 62 |
<tr class="listheading"> |
63 |
[%- FOREACH ri = SELF.displayable_columns.keys %]
|
|
64 |
<th>[%- ri %]</th>
|
|
63 |
[%- FOREACH p = SELF.worker.profile %]
|
|
64 |
<th>[%- p.row_ident %]</th>
|
|
65 | 65 |
[%- END %] |
66 | 66 |
</tr> |
67 | 67 |
<tr class="listrow[% loop.count % 2 %]"> |
68 |
[%- FOREACH ri = SELF.displayable_columns.keys %] |
|
68 |
[%- FOREACH p = SELF.worker.profile %] |
|
69 |
[% SET ri = p.row_ident %] |
|
69 | 70 |
<td> |
70 | 71 |
<table> |
71 | 72 |
<tr class="listheading"> |
Auch abrufbar als: Unified diff
Datentypen in der Hilfe und Beispieldatei in der richtigen Reihenfolge anzeigen.