- ${$line_ref} ![Переместить секцию на шаг вниз](/contenido/i/ico-down-9x10.gif) |
-
-
- |
- $spacer |
- $html_sect |
-
-
- |
-EOT
+ $m->out( $m->scomp( '.table_row.msn',
+ sect => $sect,
+ root => $root,
+ style => $style,
+ spacer => $spacer,
+ viewmode => $viewmode,
+ html_sect => $html_sect,
+ line_ref => $line_ref,
+ section_access => $section_access,
+ )
+ );
- if ($viewmode) {
- my $fhref = '/contenido/?set_context=filter-'.$sect->id();
- my $new_doc_class = $sect->default_document_class;
- $m->out(qq^\n^);
- $m->out(qq^ ^);
- $m->out(qq^фильтр^);
- $m->out(qq^ доб.докум^) if $section_access == 2 and $new_doc_class;
- $m->out(" | ");
- } else {
- $m->out(qq^\n^);
- $m->out(qq^ ^);
- $m->out(" | ");
- }
-
- $m->out('');
}
my $childs = $sect->{children} || [];
@@ -109,3 +94,49 @@
my $line = 0;
%init>
+
+<%def .table_row.msn>
+<%args>
+
+ $sect => undef
+ $root => undef
+ $style => ''
+ $spacer => ''
+ $viewmode => undef
+ $html_sect => ''
+ $line_ref => undef
+ $section_access => undef
+
+%args>
+<%init>
+
+ my ($fhref, $new_doc_class);
+ if ( $viewmode ) {
+ $fhref = '/contenido/?set_context=filter-'.$sect->id;
+ $new_doc_class = $sect->default_document_class;
+ }
+
+%init>
+
+ <% $$line_ref %> ![Переместить секцию на шаг вниз](/contenido/i/ico-down-9x10.gif) |
+
+
+ |
+ <% $spacer %> |
+ ><% $html_sect %> |
+
+
+ |
+% if ( $viewmode ) {
+
+ фильтр\
+% if ( $section_access == 2 and $new_doc_class ) {
+ доб.докум\
+% }
+ |
+% } else {
+![](/contenido/i/actions/edit.gif) |
+% }
+
+%def>
\ No newline at end of file