<%args> $name => undef $rusname => undef $check => undef <%init> my $fields; eval { $fields = eval('use vars qw($VAR1); '.$check) }; $fields = [] unless $fields; $m->out('
Список полей:
'); $m->out('
'); my $i = 1; foreach my $field (@$fields) { my $rusname = "$rusname N$i"; $m->comp('.field', name => $name, fname => $field->{name}, url => $field->{url}, alias => $field->{alias}, image => $field->{image}, amage => $field->{amage}, delete => 1, number => $i); $i++; } $rusname = "$rusname N$i"; $m->comp('.field', name => $name, fname => '', url => '', alias => '', delete => 0, number => $i); $m->out('
'); <%def .field> <%args> $name => undef $fname => undef $url => undef $alias => undef $image => undef $amage => undef $delete => 0 $number => undef <%init> % if ( $delete ) { % }
#<% $number %>
Название:
Ссылка:
Алиас:
Картинка:(норм)
Картинка:(актив)
Удалить