53333c56a264b157781be8ed58db1840f6860780
[kivitendo-erp.git] / SL / Clipboard / RequirementSpecTextBlock.pm
1 package SL::Clipboard::RequirementSpecTextBlock;
2
3 use strict;
4
5 use parent qw(SL::Clipboard::Base);
6
7 use SL::Common;
8 use SL::Locale::String;
9
10 sub describe {
11   my ($self) = @_;
12
13   return t8('Requirement spec text block "#1"; content: "#2"', $self->content->{title}, Common::truncate($self->content->{text}, strip => 'full'));
14 }
15
16 sub _fix_object {
17   my ($self, $object) = @_;
18
19   $object->$_(undef) for qw(output_position position requirement_spec_id);
20
21   return $object;
22 }
23
24 1;
25 __END__
26
27 =pod
28
29 =encoding utf8
30
31 =head1 NAME
32
33 SL::Clipboard::RequirementSpecTextBlock - Clipboard specialization for
34 SL::DB::RequirementSpecTextBlock
35
36 =head1 FUNCTIONS
37
38 =over 4
39
40 =item C<describe>
41
42 Returns a human-readable description including the title and an
43 excerpt of its content.
44
45 =item C<_fix_object $object>
46
47 Fixes C<$object> by clearing certain columns like the position.
48
49 =back
50
51 =head1 BUGS
52
53 Nothing here yet.
54
55 =head1 AUTHOR
56
57 Moritz Bunkus E<lt>m.bunkus@linet-services.deE<gt>
58
59 =cut