Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision c1569bc1

Von Moritz Bunkus vor mehr als 10 Jahren hinzugefügt

  • ID c1569bc195865fa5c25c6945bbad78c872fa2046
  • Vorgänger 54daa586
  • Nachfolger ca7c2f91

Pflichtenhefte bearbeiten

Unterschiede anzeigen:

SL/Presenter/RequirementSpec.pm
5 5
use parent qw(Exporter);
6 6

  
7 7
use Exporter qw(import);
8
our @EXPORT = qw(requirement_spec_text_block_jstree_data
9
                 requirement_spec_item_jstree_data);
8
our @EXPORT = qw(requirement_spec_text_block_jstree_data);
10 9

  
11 10
use Carp;
12 11

  
......
22 21
  };
23 22
}
24 23

  
25
sub requirement_spec_item_jstree_data {
26
  my ($self, $item, %params) = @_;
27

  
28
  my @children = map { $self->requirement_spec_item_jstree_data($_, %params) } @{ $item->sorted_children };
29
  my $type     = !$item->parent_id ? 'section' : 'functionblock';
30

  
31
  return {
32
    data     => join(' ', map { $_ || '' } ($item->fb_number, $item->title)),
33
    metadata => { id =>         $item->id, type => $type },
34
    attr     => { id => "fb-" . $item->id, href => $params{href} || '#' },
35
    children => \@children,
36
  };
37
}
38

  
39 24
1;

Auch abrufbar als: Unified diff