From: Bernd Bleßmann Date: Tue, 27 Oct 2015 14:00:52 +0000 (+0100) Subject: SL::DB::Project: displayable_name-Methode X-Git-Tag: release-3.4.1~619 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=2c14706b3db5025126c88a2d0340e8e663ac31e8;p=kivitendo-erp.git SL::DB::Project: displayable_name-Methode --- diff --git a/SL/DB/Project.pm b/SL/DB/Project.pm index 40d1a844b..df5fe09ec 100644 --- a/SL/DB/Project.pm +++ b/SL/DB/Project.pm @@ -48,6 +48,12 @@ sub is_projectnumber_unique { return !SL::DB::Manager::Project->get_first(where => \@filter); } +sub displayable_name { + my ($self) = @_; + + return join ' ', grep $_, $self->projectnumber, $self->description; +} + sub full_description { my ($self, %params) = @_; @@ -113,6 +119,11 @@ Returns trueish if the project number is not used for any other project in the database. Also returns trueish if no project number has been set yet. +=item C + +Returns a human-readable description of the project, consisting of projectnumber +and description. + =item C Returns a full description for the project which can consist of the