|
Lines 66-74
files telling Koha what fields to insert data into.
Link Here
|
| 66 |
|
66 |
|
| 67 |
=head2 GetModificationTemplates |
67 |
=head2 GetModificationTemplates |
| 68 |
|
68 |
|
| 69 |
my @templates = GetModificationTemplates( [ $template_id ] ); |
69 |
my @templates = GetModificationTemplates( $template_id ); |
|
|
70 |
|
| 71 |
Passing optional $template_id marks it as the selected template. |
| 70 |
|
72 |
|
| 71 |
Passing a $template_id will mark the given id as the selected template. |
|
|
| 72 |
=cut |
73 |
=cut |
| 73 |
|
74 |
|
| 74 |
sub GetModificationTemplates { |
75 |
sub GetModificationTemplates { |
|
Lines 81-87
sub GetModificationTemplates {
Link Here
|
| 81 |
|
82 |
|
| 82 |
my @templates; |
83 |
my @templates; |
| 83 |
while ( my $template = $sth->fetchrow_hashref() ) { |
84 |
while ( my $template = $sth->fetchrow_hashref() ) { |
| 84 |
$template->{'selected'} = 1 if ( $template->{'template_id'} eq $template_id ); |
85 |
$template->{'selected'} = 1 |
|
|
86 |
if $template_id && $template->{'template_id'} eq $template_id; |
| 85 |
push( @templates, $template ); |
87 |
push( @templates, $template ); |
| 86 |
} |
88 |
} |
| 87 |
|
89 |
|
| 88 |
- |
|
|