Revision 9209583a
Von Sven Schöling vor fast 13 Jahren hinzugefügt
SL/DB/Contact.pm | ||
---|---|---|
14 | 14 |
# Creates get_all, get_all_count, get_all_iterator, delete_all and update_all. |
15 | 15 |
__PACKAGE__->meta->make_manager_class; |
16 | 16 |
|
17 |
sub full_name { |
|
18 |
my ($self) = @_; |
|
19 |
die 'not an accessor' if @_ > 1; |
|
20 |
join ', ', grep $_, $self->cp_name, $self->cp_givenname; |
|
21 |
} |
|
22 |
|
|
23 |
sub full_name_dep { |
|
24 |
my ($self) = @_; |
|
25 |
die 'not an accessor' if @_ > 1; |
|
26 |
$self->full_name |
|
27 |
. join '', map { " ($_)" } grep $_, $self->cp_abteilung; |
|
28 |
} |
|
29 |
|
|
17 | 30 |
1; |
Auch abrufbar als: Unified diff
full_name und full_name_dep methoden für Contact