projects
/
kivitendo-erp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Part Controller: Aktion save_as_new wird nicht verwendet, sondern use_as_new
[kivitendo-erp.git]
/
SL
/
DB
/
ContactDepartment.pm
diff --git
a/SL/DB/ContactDepartment.pm
b/SL/DB/ContactDepartment.pm
index
a7645b1
..
8a6d2bd
100644
(file)
--- a/
SL/DB/ContactDepartment.pm
+++ b/
SL/DB/ContactDepartment.pm
@@
-5,9
+5,18
@@
package SL::DB::ContactDepartment;
use strict;
use strict;
+use SL::Util qw(trim);
+
use SL::DB::MetaSetup::ContactDepartment;
use SL::DB::Manager::ContactDepartment;
__PACKAGE__->meta->initialize;
use SL::DB::MetaSetup::ContactDepartment;
use SL::DB::Manager::ContactDepartment;
__PACKAGE__->meta->initialize;
+__PACKAGE__->before_save('_before_save_trim_content');
+
+sub _before_save_trim_content {
+ $_[0]->description(trim($_[0]->description));
+ return 1;
+}
+
1;
1;