X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FDB%2FCustomer.pm;h=2e3fa68562bbb50ad5d95798aa0fef1ebb4310c2;hb=f4608acc141bdbea824fd3ccadeacf130bf78276;hp=0adffbddd8d485a7fa3914e7290b439b4e79cf3e;hpb=70ff48b402fcd79c156c7594c43acf12d78a4480;p=kivitendo-erp.git diff --git a/SL/DB/Customer.pm b/SL/DB/Customer.pm index 0adffbddd..2e3fa6856 100644 --- a/SL/DB/Customer.pm +++ b/SL/DB/Customer.pm @@ -26,11 +26,6 @@ __PACKAGE__->meta->add_relationship( column_map => { id => 'cp_cv_id' }, manager_args => { sort_by => 'lower(contacts.cp_name)' }, }, - business => { - type => 'one to one', - class => 'SL::DB::Business', - column_map => { business_id => 'id' }, - }, ); __PACKAGE__->meta->initialize; @@ -50,4 +45,10 @@ sub short_address { return join ', ', grep { $_ } $self->street, $self->zipcode, $self->city; } +sub displayable_name { + my $self = shift; + + return join ' ', grep $_, $self->customernumber, $self->name; +} + 1;