Merge branch 'rb-wiederkehrende-rechnungen' into 263
[kivitendo-erp.git] / SL / DB / Shipto.pm
1 package SL::DB::Shipto;
2
3 use strict;
4 use Readonly;
5
6 use SL::DB::MetaSetup::Shipto;
7
8 Readonly our @SHIPTO_VARIABLES => qw(shiptoname shiptostreet shiptozipcode shiptocity shiptocountry shiptocontact
9                                      shiptophone shiptofax shiptoemail shiptodepartment_1 shiptodepartment_2);
10
11 __PACKAGE__->meta->make_manager_class;
12
13 sub displayable_id {
14   my $self = shift;
15   my $text = join('; ', grep { $_ } (map({ $self->$_ } qw(shiptoname shiptostreet)),
16                                      join(' ', grep { $_ }
17                                                map  { $self->$_ }
18                                                qw(shiptozipcode shiptocity))));
19
20   return $text;
21 }
22
23 1;