Mandantenkonfiguration für Auftragsnummern mit Projekten speichern
authorG. Richardson <information@kivitendo-premium.de>
Thu, 6 Aug 2015 16:52:48 +0000 (18:52 +0200)
committerJan Büren <jan@kivitendo-premium.de>
Tue, 24 Nov 2015 07:20:24 +0000 (08:20 +0100)
SL/Controller/ClientConfig.pm
templates/webpages/client_config/_features.html

index ded1a33..521242d 100644 (file)
@@ -21,6 +21,7 @@ __PACKAGE__->run_before('check_auth');
 
 use Rose::Object::MakeMethods::Generic (
   'scalar --get_set_init' => [ qw(defaults all_warehouses all_weightunits all_languages all_currencies all_templates all_price_sources h_unit_name
+                                  all_project_statuses all_project_types
                                   posting_options payment_options accounting_options inventory_options profit_options balance_startdate_method_options) ],
 );
 
@@ -143,6 +144,8 @@ sub init_defaults        { SL::DB::Default->get
 sub init_all_warehouses  { SL::DB::Manager::Warehouse->get_all_sorted                                                    }
 sub init_all_languages   { SL::DB::Manager::Language->get_all_sorted                                                     }
 sub init_all_currencies  { SL::DB::Manager::Currency->get_all_sorted                                                     }
+sub init_all_project_types    { SL::DB::Manager::ProjectType->get_all_sorted                                             }
+sub init_all_project_statuses { SL::DB::Manager::ProjectStatus->get_all_sorted                                           }
 sub init_all_weightunits { my $unit = SL::DB::Manager::Unit->find_by(name => 'kg'); $unit ? $unit->convertible_units : [] }
 sub init_all_templates   { +{ SL::Template->available_templates }                                                        }
 sub init_h_unit_name     { first { SL::DB::Manager::Unit->find_by(name => $_) } qw(Std h Stunde)                         };
index de9a954..fd1c377 100644 (file)
    </td>
  </tr>
 
+  <tr><td class="listheading" colspan="4">[% LxERP.t8("Projects") %]</td></tr>
+
+  <tr>
+   <td align="right">[% LxERP.t8('Always save orders with a projectnumber (create new projects)') %]</td>
+   <td>[% L.yes_no_tag('defaults.order_always_project', SELF.defaults.order_always_project) %]</td>
+  </tr>
+  <tr>
+   <td align="right">[% LxERP.t8('Project type') %]</td>
+   <td>[% L.select_tag('defaults.project_type_id', SELF.all_project_types, default=SELF.defaults.project_type_id, title_key='description', with_empty=1, style="width: 200px") %]</td>
+  </tr>
+   <td align="right">[% LxERP.t8('Project Status') %]</td>
+   <td>[% L.select_tag('defaults.project_status_id', SELF.all_project_statuses, default=SELF.defaults.project_status_id, title_key='description', with_empty=1, style="width: 200px") %]</td>
+  </tr>
+
  </table>
 </div>