diff --git a/ext/custom-addons/cam_reports/report/mrp.production.rml b/ext/custom-addons/cam_reports/report/mrp.production.rml new file mode 100644 index 00000000..40ced1b9 --- /dev/null +++ b/ext/custom-addons/cam_reports/report/mrp.production.rml @@ -0,0 +1,123 @@ + + + + + + + + + + + + + + + [[ repeatIn(objects,'o') ]] [[ o.partner_id and setLang(o.partner_id.lang) ]] + + + + + AUFTRAGSNUMMER: [[ o.origin or '' ]] + + + + + + + + + + + + + + + + + + + + + + + + + + + FERTIGUNG: [[ o.name ]] + + + + DATUM: [[ formatLang(o.date_planned,date=True) or formatLang(time.strftime('%Y-%m-%d'),date=True) ]] + + + + + + + + + + + + + + Fertigungsartikel: [[ (o.product_id.default_code and '['+o.product_id.default_code+']') or '']] [[ o.product_id.name ]] + + + Zu fertigende Menge: [[ o.product_qty ]] + + + + + + + + + + Bestandteile: + + + + Artikel + + + Menge + + + [[repeatIn(o.move_lines,'line')]] + + + + + [[ (line.product_id.default_code and '['+line.product_id.default_code+']') or '']] [[ line.product_id.name]] + + + [[ line.product_qty ]] + + + + + + diff --git a/ext/custom-addons/cam_reports/reports_data.xml b/ext/custom-addons/cam_reports/reports_data.xml index eecd06db..3df717e2 100644 --- a/ext/custom-addons/cam_reports/reports_data.xml +++ b/ext/custom-addons/cam_reports/reports_data.xml @@ -25,5 +25,10 @@ cam_reports/report/purchase.order.rml pdf + + + cam_reports/report/mrp.production.rml + pdf + \ No newline at end of file diff --git a/setup/lib/config_at.py b/setup/lib/config_at.py index a0a2b57f..8e0e6b81 100644 --- a/setup/lib/config_at.py +++ b/setup/lib/config_at.py @@ -4,6 +4,7 @@ class Config(): def __init__(self): + self.lang = 'de_DE' # de_DE, en_US self.chart_of_accounts = 'l10n_at' self.sales_tax = '20% MwSt' self.purchase_tax = '20% VSt' @@ -43,7 +44,7 @@ class Config(): # Nur für Lager # Wenn nicht gesetzt, dann wird der Firmenname genommen - self.warehouse_name = False + self.warehouse_name = 'Bademeisterei' self.valid_taxes = [ '20% MwSt', @@ -104,6 +105,7 @@ class Config(): self.stock_config = { 'group_stock_multiple_locations': True, # Verwalten Sie mehrere Lager und Lagerorte 'group_stock_tracking_lot': False, # Benutze Verpackungen: Paletten, Boxen, ... + 'group_stock_production_lot': True, # Verfolgen Sie Los- und Seriennummern. 'group_stock_packaging': False, # Ermöglicht die Auswahl einer Verpackung } @@ -157,6 +159,7 @@ class Config(): #'product.product_uom_meter': 'lfm', #'product.product_uom_litre': 'l', #'product.product_uom_hour': 'h', + #'product.product_uom_kgm': 'kg', } #Lieferbedingungen @@ -185,7 +188,7 @@ class Config(): 'sale', #'cam_hr_overtime', #'cam_hr', - #'sale_order_optiona', + #'sale_order_optional', #'sale_order_reminder', ] diff --git a/setup/lib/environments.py b/setup/lib/environments.py index 910e10b5..a5662b82 100644 --- a/setup/lib/environments.py +++ b/setup/lib/environments.py @@ -9,7 +9,6 @@ class Environment(): self.pwd = pwd self.port = port self.host = host - self.lang = 'de_DE' self.basic_auth = basic_auth or ('user', 'pass') # HTTP authentification def __str__(self): diff --git a/setup/lib/functions.py b/setup/lib/functions.py index 9fec899a..d16946ad 100755 --- a/setup/lib/functions.py +++ b/setup/lib/functions.py @@ -22,7 +22,7 @@ class CamadeusFunctions(): payload = {'fields': [ {'name': 'super_admin_pwd', 'value': self.env.admin_pw}, {'name': 'db_name', 'value': self.env.dbname}, {'name': 'demo_data', 'value': False}, - {'name': 'db_lang', 'value': self.env.lang}, + {'name': 'db_lang', 'value': self.config.lang}, {'name': 'create_admin_pwd', 'value': self.env.pwd}, ] } @@ -87,7 +87,7 @@ class CamadeusFunctions(): def set_date_format(self): """Setzen des Datumsformats """ - lang_ids = self._execute('res.lang', 'search', [('code','=','de_DE')]) + lang_ids = self._execute('res.lang', 'search', [('code','=',self.config.lang)]) if lang_ids: vals = { 'date_format': '%d.%m.%Y', @@ -377,7 +377,7 @@ class CamadeusFunctions(): def set_uom(self): """Mengeneinheiten setzen""" - context = {'lang': 'de_DE'} + context = {'lang': self.config.lang} c = self.config active_uoms = c.active_uoms.keys() @@ -585,19 +585,19 @@ class CamadeusFunctions(): def set_translations(self): """Übersetzungen aktualisieren """ - if hasattr(self.config, 'translation_files'): + if hasattr(self.config, 'translation_files') and self.config.lang != 'en_US': for file in self.config.translation_files: data = self._readAndReturnFile(file,encode='base64') vals = { 'name': 'test', - 'code': 'de_DE', + 'code': self.config.lang, 'data': data, 'overwrite': True, } wizard_id = self._execute('base.language.import', 'create', vals) self._execute('base.language.import', 'import_lang', [wizard_id]) return True - return False + return True def default_set_order_policy(self): """Setze Rechnung von Lieferschein""" @@ -620,7 +620,7 @@ class CamadeusFunctions(): return False return self._execute('stock.location', 'write', stock_id,{'removal_strategy_id':strategy_ids[0]}) - return False + return True def set_default_values(self): """Defaultwerte für Dokumente setzen"""