diff --git a/connector_ecommerce/README.rst b/connector_ecommerce/README.rst new file mode 100644 index 00000000..11b64b15 --- /dev/null +++ b/connector_ecommerce/README.rst @@ -0,0 +1,117 @@ +======================== +Connector for E-Commerce +======================== + +.. + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! source digest: sha256:49ddd28c8d1b54bef16f9026aa5a6add6d88ab26a9bc72180e46849633302f56 + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png + :target: https://odoo-community.org/page/development-status + :alt: Beta +.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 +.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fconnector--ecommerce-lightgray.png?logo=github + :target: https://github.com/OCA/connector-ecommerce/tree/18.0/connector_ecommerce + :alt: OCA/connector-ecommerce +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/connector-ecommerce-18-0/connector-ecommerce-18-0-connector_ecommerce + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png + :target: https://runboat.odoo-community.org/builds?repo=OCA/connector-ecommerce&target_branch=18.0 + :alt: Try me on Runboat + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This modules aims to be a common layer for the connectors dealing with +e-commerce. + +It sits on top of the `connector `__ +framework and is used by the e-commerce connectors, like +`magentoerpconnect `__ or +`prestashoperpconnect `__. + +That's a technical module, which include amongst other things: + +Events + + On which the connectors can subscribe listeners. The events it adds + are: + + - ``on_invoice_paid(self, record)`` + - ``on_invoice_validated(self, record)`` + - ``on_invoice_validated(self, record)`` + - ``on_picking_out_done(self, record, method)`` where method is + 'partial' or 'complete' + - ``on_tracking_number_added(self, record)`` + - ``on_product_price_changed(self, record)`` + + Components + + A piece of code which allows to play all the ``onchanges`` required + when we create a sales order. + + Another one which allows to add special lines in imported sales + orders such as Shipping fees, Cash on Delivery or Discounts. + +Data Model + + Add structures shared for e-commerce connectors + +**Table of contents** + +.. contents:: + :local: + +Installation +============ + +This module is a dependency for more advanced connectors. It does +nothing on its own and there is no reason to install it alone. + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues `_. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us to smash it by providing a detailed and welcomed +`feedback `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +------- + +* Camptocamp +* Akretion + +Contributors +------------ + +See +`contributors `__. + +Maintainers +----------- + +This module is maintained by the OCA. + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +This module is part of the `OCA/connector-ecommerce `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/connector_ecommerce/__init__.py b/connector_ecommerce/__init__.py new file mode 100644 index 00000000..d2243add --- /dev/null +++ b/connector_ecommerce/__init__.py @@ -0,0 +1,3 @@ +from . import components +from . import models +from . import wizard diff --git a/connector_ecommerce/__manifest__.py b/connector_ecommerce/__manifest__.py new file mode 100644 index 00000000..0c831c33 --- /dev/null +++ b/connector_ecommerce/__manifest__.py @@ -0,0 +1,34 @@ +# © 2013-2016 Camptocamp SA +# © 2013-2016 Akretion +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +{ + "name": "Connector for E-Commerce", + "version": "18.0.1.0.0", + "category": "Hidden", + "author": "Camptocamp,Akretion,Odoo Community Association (OCA)", + "website": "https://github.com/OCA/connector-ecommerce", + "license": "AGPL-3", + "depends": [ + # odoo + "stock_delivery", + # OCA/bank-payment-alternative + "account_payment_base_oca_sale", + # OCA/connector + "connector_base_product", + # OCA/sale-workflow + "sale_exception", + ], + "data": [ + "security/security.xml", + "security/ir.model.access.csv", + "wizard/sale_ignore_cancel_view.xml", + "data/ecommerce_data.xml", + "views/sale_order.xml", + "views/account_move.xml", + "views/stock_picking.xml", + "views/account_journal.xml", + "views/account_payment_method_line.xml", + ], + "installable": True, +} diff --git a/connector_ecommerce/components/__init__.py b/connector_ecommerce/components/__init__.py new file mode 100644 index 00000000..61eb7d78 --- /dev/null +++ b/connector_ecommerce/components/__init__.py @@ -0,0 +1,2 @@ +from . import line_builder +from . import sale_order_onchange diff --git a/connector_ecommerce/components/line_builder.py b/connector_ecommerce/components/line_builder.py new file mode 100644 index 00000000..aac8c602 --- /dev/null +++ b/connector_ecommerce/components/line_builder.py @@ -0,0 +1,110 @@ +# © 2013-2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import models + +from odoo.addons.component.core import Component + + +class SpecialOrderLineBuilder(Component): + """Base class to build a sales order line for a sales order + + Used when extra order lines have to be added in a sales order + but we only know some parameters (product, price, ...), for instance, + a line for the shipping costs or the gift coupons. + + It can be subclassed to customize the way the lines are created. + + Usage:: + + builder = self.components(usage='shipping.line.builder', + model_name='sale.order.line') + builder.price_unit = 100 + builder.get_line() + + """ + + _name = "ecommerce.order.line.builder" + _inherit = "base.connector" + _usage = "order.line.builder" + + def __init__(self, work_context): + super().__init__(work_context) + self.product = None # id or browse_record + # when no product_id, fallback to a product_ref + self.product_ref = None # tuple (module, xmlid) + self.price_unit = None + self.quantity = 1 + self.sign = 1 + self.sequence = 980 + + def get_line(self): + assert self.product_ref or self.product + assert self.price_unit is not None + + product = self.product + if product is None: + product = self.env.ref(".".join(self.product_ref)) + + if not isinstance(product, models.BaseModel): + product = self.env["product.product"].browse(product) + return { + "product_id": product.id, + "name": product.name, + "product_uom": product.uom_id.id, + "product_uom_qty": self.quantity, + "price_unit": self.price_unit * self.sign, + "sequence": self.sequence, + } + + +class ShippingLineBuilder(Component): + """Return values for a Shipping line""" + + _name = "ecommerce.order.line.builder.shipping" + _inherit = "ecommerce.order.line.builder" + _usage = "order.line.builder.shipping" + + def __init__(self, work_context): + super().__init__(work_context) + self.product_ref = ("connector_ecommerce", "product_product_shipping") + self.sequence = 999 + + def get_line(self): + values = super().get_line() + values["is_delivery"] = True + return values + + +class CashOnDeliveryLineBuilder(Component): + """Return values for a Cash on Delivery line""" + + _name = "ecommerce.order.line.builder.cod" + _inherit = "ecommerce.order.line.builder" + _usage = "order.line.builder.cod" + + def __init__(self, work_context): + super().__init__(work_context) + self.product_ref = ("connector_ecommerce", "product_product_cash_on_delivery") + self.sequence = 995 + + +class GiftOrderLineBuilder(Component): + """Return values for a Gift line""" + + _name = "ecommerce.order.line.builder.gift" + _inherit = "ecommerce.order.line.builder" + _usage = "order.line.builder.gift" + + def __init__(self, work_context): + super().__init__(work_context) + self.product_ref = ("connector_ecommerce", "product_product_gift") + self.sign = -1 + self.gift_code = None + self.sequence = 990 + + def get_line(self): + line = super().get_line() + if self.gift_code: + line["name"] = "{} [{}]".format(line["name"], self.gift_code) + return line diff --git a/connector_ecommerce/components/sale_order_onchange.py b/connector_ecommerce/components/sale_order_onchange.py new file mode 100644 index 00000000..24171031 --- /dev/null +++ b/connector_ecommerce/components/sale_order_onchange.py @@ -0,0 +1,111 @@ +# © 2013-TODAY Akretion (Sébastien Beau) +# © 2016 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo.addons.component.core import Component + + +class OnChangeManager(Component): + _name = "ecommerce.onchange.manager" + _inherit = "base.connector" + + def get_new_values(self, record, on_change_result, model=None): + vals = on_change_result.get("value", {}) + new_values = {} + for fieldname, value in vals.items(): + if fieldname not in record: + if model: + column = self.env[model]._fields[fieldname] + if column.type == "many2one": + value = value["id"] + new_values[fieldname] = value + return new_values + + def play_onchanges(self, model, values, onchange_fields): + model = self.env[model] + field_spec = model._get_fields_spec() + # we need all fields in the dict even the empty ones + # otherwise 'onchange()' will not apply changes to them + all_values = {k: v for k, v in values.items() if k in model._fields} + not_values = {k: v for k, v in values.items() if k not in model._fields} + for field in model._fields: + if field not in all_values: + all_values[field] = False + + # we work on a temporary record + new_record = model.new(all_values) + + new_values = {} + for field in onchange_fields: + onchange_values = new_record.onchange(all_values, [field], field_spec) + new_values.update( + self.get_new_values(values, onchange_values, model=model._name) + ) + all_values.update(new_values) + + for fld in not_values: + if fld not in all_values: + all_values[fld] = not_values[fld] + res = {f: v for f, v in all_values.items() if f in values or f in new_values} + return res + + +class SaleOrderOnChange(Component): + _name = "ecommerce.onchange.manager.sale.order" + _inherit = "ecommerce.onchange.manager" + _usage = "ecommerce.onchange.manager.sale.order" + + order_onchange_fields = ["partner_id"] + + line_onchange_fields = ["order_id", "product_id"] + + def play(self, order, order_lines): + """Play the onchange of the sales order and it's lines + + :param order: sales order values + :type: dict + :param order_lines: data of the sales order lines + :type: list of dict + + :return: the sales order updated by the onchanges + :rtype: dict + """ + # play onchange on sales order + order = self.play_onchanges("sale.order", order, self.order_onchange_fields) + + # play onchange on sales order line + processed_order_lines = [] + line_lists = [order_lines] + if "order_line" in order and order["order_line"] is not order_lines: + # we have both backend-dependent and oerp-native order lines. + # oerp-native lines can have been added to map + # shipping fees with an Odoo Product + line_lists.append(order["order_line"]) + + for line_list in line_lists: + for idx, command_line in enumerate(line_list): + # line_list format:[(0, 0, {...}), (0, 0, {...})] + if command_line[0] in (0, 1): # create or update values + # we work on a temporary record + order_model = self.env["sale.order"] + + all_values = { + k: v for k, v in order.items() if k in order_model._fields + } + for field in order_model._fields: + if field not in all_values: + all_values[field] = False + new_record = order_model.new(all_values) + # keeps command number and ID (or 0) + old_line_data = command_line[2] + # passing order_id also so order_id.company_id based onchange will + # also work + old_line_data["order_id"] = new_record + new_line_data = self.play_onchanges( + "sale.order.line", old_line_data, self.line_onchange_fields + ) + new_line = (command_line[0], command_line[1], new_line_data) + processed_order_lines.append(new_line) + # in place modification of the sales order line in the list + line_list[idx] = new_line + return order diff --git a/connector_ecommerce/data/ecommerce_data.xml b/connector_ecommerce/data/ecommerce_data.xml new file mode 100644 index 00000000..e3fdc9bf --- /dev/null +++ b/connector_ecommerce/data/ecommerce_data.xml @@ -0,0 +1,58 @@ + + + + Services + + + SHIP + 0.0 + 0.0 + service + Shipping Costs + + + + CASH ON DELIVERY + 0.0 + 0.0 + service + Cash on Delivery + + + + GIFT CERTIFICATE + 0.0 + 0.0 + service + Gift Certificate + + + + DISCOUNT + 0.0 + 0.0 + service + Discount Coupon + + + + Parent sales order canceled on the backend. + The parent sales order has been canceled on the backend. You will not be able to process this sales order until the parent's one is canceled. + 30 + sale.order + if self.parent_need_cancel: failed = True + + + + Sales order canceled on the backend. + The sales order has been canceled on the backend. + 20 + sale.order + if self.need_cancel: failed = True + + + diff --git a/connector_ecommerce/i18n/connector_ecommerce.pot b/connector_ecommerce/i18n/connector_ecommerce.pot new file mode 100644 index 00000000..d6c0a67c --- /dev/null +++ b/connector_ecommerce/i18n/connector_ecommerce.pot @@ -0,0 +1,355 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * connector_ecommerce +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 16.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"

Resolution:

  1. Cancel the linked invoices, delivery orders, automatic" +" payments.
  2. Cancel the sales order manually.

" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "" +"A parent sales order has been canceled on the backend and needs to be " +"canceled." +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_id +msgid "A parent sales order is a sales order replaced by this one." +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "A parent sales order needs cancel" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "" +"After 'n' days, if the 'Import Rule' is not fulfilled, the import of the " +"sales order will be canceled." +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Cancel" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__canceled_in_backend +msgid "Canceled In Backend" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Canceled in backend, to cancel" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__cancellation_resolved +msgid "Cancellation from the backend resolved" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_cash_on_delivery_product_template +msgid "Cash on Delivery" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Confirm" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_move_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_order_connector_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_stock_picking_out_connector_form +msgid "Connectors" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_uid +msgid "Created by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_date +msgid "Created on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "Days Before Cancel" +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"Despite the cancellation of the sales order on the backend, it should stay " +"open.

Reason: %s" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_discount_product_template +msgid "Discount Coupon" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__display_name +msgid "Display Name" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_gift_product_template +msgid "Gift Certificate" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__need_cancel +msgid "Has been canceled on the backend, need to be canceled." +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "" +"However, if for any reason you need to keep it open in Odoo,\n" +" write the reason here and it will stay open." +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__id +msgid "ID" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_ignore_cancel +msgid "Ignore Sales Order Cancel" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "Ignore backend's cancellation, Keep Open" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.actions.act_window,name:connector_ecommerce.action_sale_ignore_cancel +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Ignore the cancellation on the Backend" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__import_rule +msgid "Import Rule" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "Import Rules" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_move +msgid "Journal Entry" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel____last_update +msgid "Last Modified on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_date +msgid "Last Updated on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__need_cancel +msgid "Need to be canceled" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Only sales orders canceled in their backend" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_id +msgid "Parent Order" +msgstr "" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_parent_order_need_cancel +msgid "Parent sales order canceled on the backend." +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_payment_mode +msgid "Payment Modes" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_template +msgid "Product" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_product +msgid "Product Variant" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__reason +msgid "Reason" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_stock_picking__related_backorder_ids +msgid "Related backorders" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_order +msgid "Sales Order" +msgstr "" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_order_need_cancel +msgid "Sales order canceled on the backend." +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_shipping_product_template +msgid "Shipping Costs" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_move +msgid "Stock Move" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_tax +msgid "Tax" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_template__tax_group_id +msgid "Tax Group" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,help:connector_ecommerce.field_product_template__tax_group_id +msgid "Tax groups are used with some external system like Prestashop" +msgstr "" + +#. module: connector_ecommerce +#: model:exception.rule,description:connector_ecommerce.excep_parent_order_need_cancel +msgid "" +"The parent sales order has been canceled on the backend. You will not be " +"able to process this sales order until the parent's one is canceled." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"The sales order cannot be automatically canceled because it is already in " +"\"Done\" state." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "The sales order could not be automatically canceled." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "The sales order has been automatically canceled." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#: model:exception.rule,description:connector_ecommerce.excep_order_need_cancel +#, python-format +msgid "The sales order has been canceled on the backend." +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "" +"The sales orders using the payment\n" +" method will be imported\n" +" only when they receive a payment on the E-Commerce backend.\n" +"
" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will always be imported." +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will never be imported." +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "" +"This sales order has been canceled from the backend.\n" +" The usual action would be to cancel it in Odoo along\n" +" all the documents generated (delivery orders, invoices, ...)." +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_picking +msgid "Transfer" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "View Parent Sales Order" +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "Warning: the origin sales order %s has been canceled on the backend." +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "or" +msgstr "" diff --git a/connector_ecommerce/i18n/de.po b/connector_ecommerce/i18n/de.po new file mode 100644 index 00000000..b7aea66b --- /dev/null +++ b/connector_ecommerce/i18n/de.po @@ -0,0 +1,483 @@ +# German translation for odoo-connector-ecommerce +# Copyright (c) 2014 Rosetta Contributors and Canonical Ltd 2014 +# This file is distributed under the same license as the odoo-connector-ecommerce package. +# FIRST AUTHOR , 2014. +# +msgid "" +msgstr "" +"Project-Id-Version: odoo-connector-ecommerce\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2013-05-01 14:34+0000\n" +"PO-Revision-Date: 2014-01-24 09:54+0000\n" +"Last-Translator: Jan-Philipp Fischer \n" +"Language-Team: German \n" +"Language: de\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2014-05-27 06:09+0000\n" +"X-Generator: Launchpad (build 17017)\n" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"

Resolution:

  1. Cancel the linked invoices, delivery orders, automatic " +"payments.
  2. Cancel the sales order manually.

" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "" +"A parent sales order has been canceled on the backend and needs to be " +"canceled." +msgstr "" +"Ein übergeordneter VK-Auftrag wurde im Backend abgebrochen und muss " +"abgebrochen werden." + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_id +msgid "A parent sales order is a sales order replaced by this one." +msgstr "Ein übergeordneter VK-Auftrag wurde durch diesen ersetzt." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "A parent sales order needs cancel" +msgstr "Eine übergeordnete" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "" +"After 'n' days, if the 'Import Rule' is not fulfilled, the import of the " +"sales order will be canceled." +msgstr "" +"Nach 'n' Tagen, wenn die 'Import Regel' nicht erfüllt ist, wird der Import " +"abgebrochen." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Cancel" +msgstr "Abbrechen" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__canceled_in_backend +msgid "Canceled In Backend" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Canceled in backend, to cancel" +msgstr "Abbebrochen im Backend, abzubrechen" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__cancellation_resolved +msgid "Cancellation from the backend resolved" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_cash_on_delivery_product_template +#, fuzzy +msgid "Cash on Delivery" +msgstr "Nachname (Zahlung)" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Confirm" +msgstr "Bestätigen" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_move_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_order_connector_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_stock_picking_out_connector_form +msgid "Connectors" +msgstr "Connector" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_uid +msgid "Created by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_date +msgid "Created on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "Days Before Cancel" +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"Despite the cancellation of the sales order on the backend, it should stay " +"open.

Reason: %s" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_discount_product_template +msgid "Discount Coupon" +msgstr "Rabattcode" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__display_name +msgid "Display Name" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_gift_product_template +msgid "Gift Certificate" +msgstr "Geschenkzertifikat" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__need_cancel +msgid "Has been canceled on the backend, need to be canceled." +msgstr "Wurde im Backend abgebrochen, muss abgebrochen werden." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "" +"However, if for any reason you need to keep it open in Odoo,\n" +" write the reason here and it will stay open." +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__id +msgid "ID" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_ignore_cancel +msgid "Ignore Sales Order Cancel" +msgstr "Ignoriere VK-Auftrag-Abbruch" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "Ignore backend's cancellation, Keep Open" +msgstr "Ignoriere abbruch im Backend und lasse offen" + +#. module: connector_ecommerce +#: model:ir.actions.act_window,name:connector_ecommerce.action_sale_ignore_cancel +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Ignore the cancellation on the Backend" +msgstr "Ignoriere den Abbruch im Backend." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__import_rule +msgid "Import Rule" +msgstr "Importregeln" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "Import Rules" +msgstr "Importregeln" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_move +msgid "Journal Entry" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel____last_update +msgid "Last Modified on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_date +msgid "Last Updated on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__need_cancel +msgid "Need to be canceled" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Only sales orders canceled in their backend" +msgstr "Nur VK-Aufträge können im Backend abgebrochen werden" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_id +msgid "Parent Order" +msgstr "Übergeordneter VK-Auftrag" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_parent_order_need_cancel +#, fuzzy +msgid "Parent sales order canceled on the backend." +msgstr "VK-Auftrag im Backend abgebrochen." + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_payment_mode +#, fuzzy +msgid "Payment Modes" +msgstr "Zahlungsmethode" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_template +msgid "Product" +msgstr "Produkt" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_product +msgid "Product Variant" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__reason +msgid "Reason" +msgstr "Grund" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_stock_picking__related_backorder_ids +msgid "Related backorders" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_order +msgid "Sales Order" +msgstr "" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_order_need_cancel +msgid "Sales order canceled on the backend." +msgstr "VK-Auftrag im Backend abgebrochen." + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_shipping_product_template +#, fuzzy +msgid "Shipping Costs" +msgstr "Lieferkosten" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_move +msgid "Stock Move" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_tax +msgid "Tax" +msgstr "Steuern" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_template__tax_group_id +msgid "Tax Group" +msgstr "Steuergruppe" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,help:connector_ecommerce.field_product_template__tax_group_id +#, fuzzy +msgid "Tax groups are used with some external system like Prestashop" +msgstr "" +"Steuergruppen werden für einige externe Systeme wie Magento oder Prestashop " +"genutzt." + +#. module: connector_ecommerce +#: model:exception.rule,description:connector_ecommerce.excep_parent_order_need_cancel +#, fuzzy +msgid "" +"The parent sales order has been canceled on the backend. You will not be " +"able to process this sales order until the parent's one is canceled." +msgstr "" +"Der übergeordnete VK-Auftrag wurde im Backend abgebrochen.\n" +"Sie werden nicht in der Lage sein, diesen VK-Auftrag fortzusetzen, \n" +"solange der übergeordnete VK-Auftrag abgebrochen ist." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"The sales order cannot be automatically canceled because it is already in " +"\"Done\" state." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "The sales order could not be automatically canceled." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, fuzzy, python-format +msgid "The sales order has been automatically canceled." +msgstr "Der VK-Auftrag wurde im Backend abgebrochen" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#: model:exception.rule,description:connector_ecommerce.excep_order_need_cancel +#, python-format +msgid "The sales order has been canceled on the backend." +msgstr "Der VK-Auftrag wurde im Backend abgebrochen" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +#, fuzzy +msgid "" +"The sales orders using the payment\n" +" method will be imported\n" +" only when they receive a payment on the E-" +"Commerce backend.\n" +"
" +msgstr "" +"Die VK-Aufträge welche diese Zahlungsmethode benutzen werden nur " +"importiert,\n" +"wenn eine Zahlung auf dem E-Commerce Backend vorliegt." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will always be imported." +msgstr "" +"Die VK-Aufträge welche diese Zahlungsmethode verwenden,\r\n" +"werden immer importiert." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will never be imported." +msgstr "Dei VK-Aufträge mit dieser Zahlungsmethode werden nie importiert." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +#, fuzzy +msgid "" +"This sales order has been canceled from the backend.\n" +" The usual action would be to cancel it in Odoo " +"along\n" +" all the documents generated (delivery orders, " +"invoices, ...)." +msgstr "" +"Dieser VK-Auftrag wurde vom Backend abgebrochen.\n" +"Die übliche Aktion wäre das Abbrechen von allen Odoo\n" +"Belegen (Lieferaufträge, Rechnungen, ...)." + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_picking +msgid "Transfer" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "View Parent Sales Order" +msgstr "Zeige übergeordnete VK-Aufträge" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, fuzzy, python-format +msgid "Warning: the origin sales order %s has been canceled on the backend." +msgstr "Der VK-Auftrag wurde %s im Backend abgebrochen" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "or" +msgstr "oder" + +#, fuzzy +#~ msgid "" +#~ "A product has been imported from a backend and needs to be reviewed. Go " +#~ "to Connectors > Checkpoint and review the new products." +#~ msgstr "" +#~ "Ein Produkt wurde aus einem Backend importiert und benötigt eine " +#~ "überprüfung.\n" +#~ "Gehen Sie zu Connectors->Checkpunkte und überprüfen Sie das neue Produkt." + +#~ msgid "A product needs to be reviewed." +#~ msgstr "Ein Produkt muss überprüft werden" + +#~ msgid "Canceled in backend" +#~ msgstr "Im Backend abgebrochen" + +#~ msgid "Days before cancel" +#~ msgstr "Tage bevor Abbruch" + +#~ msgid "Has Checkpoint" +#~ msgstr "Hat Überprüfungspunkt" + +#~ msgid "Invoice" +#~ msgstr "Rechnung" + +#~ msgid "Product Template" +#~ msgstr "Produkt Vorlage" + +#, fuzzy +#~| msgid "Sales Order" +#~ msgid "Sale Order" +#~ msgstr "VK-Auftrag" + +#~ msgid "Services" +#~ msgstr "Dienstleistungen" + +#, fuzzy +#~ msgid "" +#~ "Parent sales order canceled on the\n" +#~ " backend." +#~ msgstr "Übergeordneter VK-Auftrag im Backend abgebrochen." + +#, fuzzy +#~ msgid "" +#~ "The sales order has been canceled on the\n" +#~ " backend." +#~ msgstr "Der VK-Auftrag wurde im Backend abgebrochen" + +#~ msgid "" +#~ "Choose the tax group. This is needed for example with magento or " +#~ "prestashop" +#~ msgstr "" +#~ "Wählen Sie die Steuergruppe. Dies wird z. B. für Magento oder Prestashop " +#~ "benötigt." + +#~ msgid "Picking List" +#~ msgstr "Entnahmeliste" + +#~ msgid "Tax Groups" +#~ msgstr "Steuergruppen" + +#~ msgid "Sales Shop" +#~ msgstr "Verkaufsshop" + +#~ msgid "Other Information" +#~ msgstr "Weitere Informationen" + +#~ msgid "Pricelist Items" +#~ msgstr "Preislistenartikel" + +#~ msgid "Taxes" +#~ msgstr "Steuern" + +#~ msgid "Payments" +#~ msgstr "Zahlungen" + +#~ msgid "Delivery Orders" +#~ msgstr "Auslieferungsaufträge" + +#~ msgid "This is the list of sales orders related to this invoice." +#~ msgstr "" +#~ "Dies ist die Liste der VK-Aufträge welche mit dieser Rechnung in " +#~ "beziehung stehen." + +#~ msgid "Name" +#~ msgstr "Name" + +#~ msgid "Sales Orders" +#~ msgstr "VK-Aufträge" + +#~ msgid "Additional Info" +#~ msgstr "Zusätzliche Information" + +#~ msgid "Price Type" +#~ msgstr "Preistyp" diff --git a/connector_ecommerce/i18n/es.po b/connector_ecommerce/i18n/es.po new file mode 100644 index 00000000..ef654eb9 --- /dev/null +++ b/connector_ecommerce/i18n/es.po @@ -0,0 +1,500 @@ +# Spanish translation for odoo-connector-ecommerce +# Copyright (c) 2014 Rosetta Contributors and Canonical Ltd 2014 +# This file is distributed under the same license as the odoo-connector-ecommerce package. +# Alberto Garcia , 2014. +# +msgid "" +msgstr "" +"Project-Id-Version: odoo-connector-ecommerce\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2013-05-01 14:34+0000\n" +"PO-Revision-Date: 2023-10-10 22:56+0000\n" +"Last-Translator: Ivorra78 \n" +"Language-Team: Spanish \n" +"Language: es\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 4.17\n" +"X-Launchpad-Export-Date: 2014-06-06 06:38+0000\n" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"

Resolution:

  1. Cancel the linked invoices, delivery orders, automatic " +"payments.
  2. Cancel the sales order manually.

" +msgstr "" +"

Resolución:

  1. Cancelar las facturas vinculadas, órdenes de entraga, " +"pagos automáticos.
  2. Cancelar las órdenes de venta manualmente.
  3. " + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "" +"A parent sales order has been canceled on the backend and needs to be " +"canceled." +msgstr "" +"Una orden de venta padre ha sido cancelada en el área de administración y " +"debe ser cancelada." + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_id +msgid "A parent sales order is a sales order replaced by this one." +msgstr "" +"Una orden de venta padre is una orden de venta reeplazada por esta otra." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "A parent sales order needs cancel" +msgstr "Una orden de venta padre debe cancelar" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "" +"After 'n' days, if the 'Import Rule' is not fulfilled, the import of the " +"sales order will be canceled." +msgstr "" +"Después de 'n' días, si la 'Regla de Importación' no está realizada, la " +"importación de la orden de venta será cancelada." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Cancel" +msgstr "Cancelar" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__canceled_in_backend +msgid "Canceled In Backend" +msgstr "Cancelado en el Servidor" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Canceled in backend, to cancel" +msgstr "Cancelado en el área de administración, a cancelar" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__cancellation_resolved +msgid "Cancellation from the backend resolved" +msgstr "Cancelelación resuelta desde el área de administración" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_cash_on_delivery_product_template +msgid "Cash on Delivery" +msgstr "Contra reembolso" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Confirm" +msgstr "Confirmar" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_move_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_order_connector_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_stock_picking_out_connector_form +msgid "Connectors" +msgstr "Conectores" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_uid +msgid "Created by" +msgstr "Creado por" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_date +msgid "Created on" +msgstr "Creado en" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "Days Before Cancel" +msgstr "Días Antes de Cancelar" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"Despite the cancellation of the sales order on the backend, it should stay " +"open.

    Reason: %s" +msgstr "" +"A pesar de la cancelación de la venta en el área de administración, debería " +"permanecer abierto.

    Razón: %s" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_discount_product_template +msgid "Discount Coupon" +msgstr "Cupón de Descuento" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__display_name +msgid "Display Name" +msgstr "Nombre mostrado" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_gift_product_template +msgid "Gift Certificate" +msgstr "Certificado de Regalo" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__need_cancel +msgid "Has been canceled on the backend, need to be canceled." +msgstr "Ha sido cancelado en el área de administración, debe ser cancelado." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "" +"However, if for any reason you need to keep it open in Odoo,\n" +" write the reason here and it will stay open." +msgstr "" +"Sin embargo, si por alguna razón necesita mantenerlo abierto en Odoo,\n" +"\t\t\t\t\tescriba la razón aquí y se mantendrá abierto." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__id +msgid "ID" +msgstr "ID" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_ignore_cancel +msgid "Ignore Sales Order Cancel" +msgstr "Ignorar Órdenes de Venta Canceladas" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "Ignore backend's cancellation, Keep Open" +msgstr "Ignorar cancelaciones del área de administración, Mantener Abierto" + +#. module: connector_ecommerce +#: model:ir.actions.act_window,name:connector_ecommerce.action_sale_ignore_cancel +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Ignore the cancellation on the Backend" +msgstr "Ignorar la cancelación en el Área de Administración" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__import_rule +msgid "Import Rule" +msgstr "Importar Regla" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "Import Rules" +msgstr "Importar Reglas" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_move +msgid "Journal Entry" +msgstr "Entrada Diaria" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel____last_update +msgid "Last Modified on" +msgstr "Última modificación en" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_uid +msgid "Last Updated by" +msgstr "Última actualización por" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_date +msgid "Last Updated on" +msgstr "Última actualización en" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__need_cancel +msgid "Need to be canceled" +msgstr "Debe ser cancelado" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Only sales orders canceled in their backend" +msgstr "Solo las órdenes de venta canceladas en sus áreas de administración" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_id +msgid "Parent Order" +msgstr "Orden Padre" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_parent_order_need_cancel +msgid "Parent sales order canceled on the backend." +msgstr "Pedido de venta cancelado en el área de administración." + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_payment_mode +msgid "Payment Modes" +msgstr "Método de Pago" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_template +msgid "Product" +msgstr "Producto" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_product +msgid "Product Variant" +msgstr "Variante de producto" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__reason +msgid "Reason" +msgstr "Razón" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_stock_picking__related_backorder_ids +msgid "Related backorders" +msgstr "Pedidos pendientes relacionados" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_order +msgid "Sales Order" +msgstr "Orden de Venta" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_order_need_cancel +msgid "Sales order canceled on the backend." +msgstr "Pedido de venta cancelado en el área de administración." + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_shipping_product_template +msgid "Shipping Costs" +msgstr "Gastos de envío" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_move +msgid "Stock Move" +msgstr "Movimiento de stock" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_tax +msgid "Tax" +msgstr "Impuesto" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_template__tax_group_id +msgid "Tax Group" +msgstr "Grupo de impuestos" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,help:connector_ecommerce.field_product_template__tax_group_id +msgid "Tax groups are used with some external system like Prestashop" +msgstr "" +"El grupo fiscal se usa en algún sistema externo, por ejemplo Prestashop" + +#. module: connector_ecommerce +#: model:exception.rule,description:connector_ecommerce.excep_parent_order_need_cancel +msgid "" +"The parent sales order has been canceled on the backend. You will not be " +"able to process this sales order until the parent's one is canceled." +msgstr "" +"El pedido de venta relacionado ha sido cancelado en el área de " +"administración. No podrá procesar este pedido de venta mientras el " +"relacionado esté cancelado." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"The sales order cannot be automatically canceled because it is already in " +"\"Done\" state." +msgstr "" +"El pedido de venta no puede ser cancelado automáticamente porque ya está " +"'hecho'." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "The sales order could not be automatically canceled." +msgstr "El pedido de vente podría no ser cancelado automáticamente." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "The sales order has been automatically canceled." +msgstr "El pedido de venta ha sido cancelado automáticamente." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#: model:exception.rule,description:connector_ecommerce.excep_order_need_cancel +#, python-format +msgid "The sales order has been canceled on the backend." +msgstr "El pedido de venta ha sido cancelado en el área de administración." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "" +"The sales orders using the payment\n" +" method will be imported\n" +" only when they receive a payment on the E-" +"Commerce backend.\n" +"
    " +msgstr "" +"Los pedidos de venta que usan este método de pago\n" +" serán " +"importados\n" +" sólo cuando " +"reciban un pago en el área de administración del comercio electrónico.\n" +"
    " + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will always be imported." +msgstr "" +"Los pedidos de venta que usan este modo de pago serán siempre importados." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will never be imported." +msgstr "" +"Los pedidos de venta que usan este modo de pago nunca serán importados." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "" +"This sales order has been canceled from the backend.\n" +" The usual action would be to cancel it in Odoo " +"along\n" +" all the documents generated (delivery orders, " +"invoices, ...)." +msgstr "" +"Este pedido de venta ha sido cancelado desde el área de administración.\n" +" La acción habitual sería cancelarlo en Odoo junto con\n" +" todos los documentos generados (ordenes de entrega, " +"facturas, ...)." + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_picking +msgid "Transfer" +msgstr "Transferencia" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "View Parent Sales Order" +msgstr "Ver Pedido de Venta Padre" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "Warning: the origin sales order %s has been canceled on the backend." +msgstr "" +"Aviso: el pedido de venta original %s ha sido cancelado en el área de " +"administración." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "or" +msgstr "o" + +#, fuzzy +#~ msgid "" +#~ "A product has been imported from a backend and needs to be reviewed. Go " +#~ "to Connectors > Checkpoint and review the new products." +#~ msgstr "" +#~ "Un producto ha sido importado de un área de administración y debe ser " +#~ "revisado.\n" +#~ "Vaya a Conectores > Punto de Control y revise los nuevos productos." + +#~ msgid "A product needs to be reviewed." +#~ msgstr "Un nuevo producto debe ser revisado." + +#~ msgid "Canceled in backend" +#~ msgstr "Cancelado en el área de administración" + +#~ msgid "Days before cancel" +#~ msgstr "Días antes de cancelar" + +#~ msgid "Has Checkpoint" +#~ msgstr "Tiene Punto de Control" + +#~ msgid "Invoice" +#~ msgstr "Factura" + +#~ msgid "Product Template" +#~ msgstr "Plantilla de producto" + +#, fuzzy +#~| msgid "Sales Order" +#~ msgid "Sale Order" +#~ msgstr "Pedidos de venta" + +#~ msgid "Services" +#~ msgstr "Servicios" + +#, fuzzy +#~ msgid "" +#~ "Parent sales order canceled on the\n" +#~ " backend." +#~ msgstr "Órdenes de venta padres canceladas en el área de administración." + +#, fuzzy +#~ msgid "" +#~ "The sales order has been canceled on the\n" +#~ " backend." +#~ msgstr "El pedido de venta ha sido cancelado en el área de administración." + +#~ msgid "" +#~ "Choose the tax group. This is needed for example with magento or " +#~ "prestashop" +#~ msgstr "" +#~ "Elija el grupo fiscal. Esto es necesario por ejemplo con Magento o " +#~ "Prestashop" + +#~ msgid "Picking List" +#~ msgstr "Albarán" + +#~ msgid "Tax Groups" +#~ msgstr "Gupo Fiscal" + +#~ msgid "Account Tax Group" +#~ msgstr "Grupo de Cuenta Fiscal" + +#~ msgid "Sales Shop" +#~ msgstr "Tienda ventas" + +#~ msgid "Other Information" +#~ msgstr "Otra información" + +#~ msgid "Pricelist Items" +#~ msgstr "Listado de Precios de Artículos" + +#~ msgid "Taxes" +#~ msgstr "Impuestos" + +#~ msgid "Payments" +#~ msgstr "Pagos" + +#~ msgid "Delivery Orders" +#~ msgstr "Albaranes de salida" + +#~ msgid "This is the list of sales orders related to this invoice." +#~ msgstr "Esta es la lista de pedidos de venta relacionados con esta factura." + +#~ msgid "account tax group" +#~ msgstr "cuenta de grupo fiscal" + +#~ msgid "Name" +#~ msgstr "Nombre" + +#~ msgid "Sales Orders" +#~ msgstr "Pedido de Venta" + +#~ msgid "Additional Info" +#~ msgstr "Info Adicional" + +#~ msgid "Price Type" +#~ msgstr "Tipo precio" + +#~ msgid "The sales order could not be automatically canceled for this status." +#~ msgstr "" +#~ "El pedido de venta podría no ser cancelado automáticamente por este " +#~ "estado." diff --git a/connector_ecommerce/i18n/fr.po b/connector_ecommerce/i18n/fr.po new file mode 100644 index 00000000..552c3abe --- /dev/null +++ b/connector_ecommerce/i18n/fr.po @@ -0,0 +1,489 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * connector_ecommerce +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 7.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2013-05-01 14:34+0000\n" +"PO-Revision-Date: 2014-01-14 09:42+0000\n" +"Last-Translator: Guewen Baconnier @ Camptocamp \n" +"Language-Team: \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2014-05-27 06:09+0000\n" +"X-Generator: Launchpad (build 17017)\n" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"

    Resolution:

    1. Cancel the linked invoices, delivery orders, automatic " +"payments.
    2. Cancel the sales order manually.

    " +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "" +"A parent sales order has been canceled on the backend and needs to be " +"canceled." +msgstr "" +"Une commande parente a été annulée sur le backend et doit être annulée." + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_id +msgid "A parent sales order is a sales order replaced by this one." +msgstr "Une commande parente est une commande remplacée par celle-ci." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "A parent sales order needs cancel" +msgstr "Une commande parente doit être annulée" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "" +"After 'n' days, if the 'Import Rule' is not fulfilled, the import of the " +"sales order will be canceled." +msgstr "" +"Après \"n\" jours, si la règle d'import n'est pas satisfaite, l'import de la " +"commande sera annulé." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Cancel" +msgstr "Annuler" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__canceled_in_backend +msgid "Canceled In Backend" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Canceled in backend, to cancel" +msgstr "Annulé dans le backend, à annuler" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__cancellation_resolved +msgid "Cancellation from the backend resolved" +msgstr "Annulation depuis le backend résolue" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_cash_on_delivery_product_template +#, fuzzy +msgid "Cash on Delivery" +msgstr "Livraison contre remboursement" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Confirm" +msgstr "Confirmer" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_move_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_order_connector_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_stock_picking_out_connector_form +msgid "Connectors" +msgstr "Connecteurs" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_uid +msgid "Created by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_date +msgid "Created on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "Days Before Cancel" +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"Despite the cancellation of the sales order on the backend, it should stay " +"open.

    Reason: %s" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_discount_product_template +msgid "Discount Coupon" +msgstr "Bon de réduction" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__display_name +msgid "Display Name" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_gift_product_template +msgid "Gift Certificate" +msgstr "Coupon Cadeau" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__need_cancel +msgid "Has been canceled on the backend, need to be canceled." +msgstr "A été annulée sur le backend, doit être annulée." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +#, fuzzy +msgid "" +"However, if for any reason you need to keep it open in Odoo,\n" +" write the reason here and it will stay open." +msgstr "" +"Cependant, si pour une raison donnée vous devez la laisser ouverte dans " +"Odoo,\n" +" écrivez la raison ici et confirmez.." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__id +msgid "ID" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_ignore_cancel +msgid "Ignore Sales Order Cancel" +msgstr "Ignorer les annulations de commandes" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "Ignore backend's cancellation, Keep Open" +msgstr "Ignorer l'annulation du backend, laisser ouvert." + +#. module: connector_ecommerce +#: model:ir.actions.act_window,name:connector_ecommerce.action_sale_ignore_cancel +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Ignore the cancellation on the Backend" +msgstr "Ignorer l'annulation du backend." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__import_rule +msgid "Import Rule" +msgstr "Règle d'import" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "Import Rules" +msgstr "Règles d'import" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_move +msgid "Journal Entry" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel____last_update +msgid "Last Modified on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_date +msgid "Last Updated on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__need_cancel +msgid "Need to be canceled" +msgstr "Doit être annulée" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Only sales orders canceled in their backend" +msgstr "Uniquement les commandes annulées dans leur backend" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_id +msgid "Parent Order" +msgstr "Commande parente" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_parent_order_need_cancel +#, fuzzy +msgid "Parent sales order canceled on the backend." +msgstr "Commandes annulées sur leur backend." + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_payment_mode +#, fuzzy +msgid "Payment Modes" +msgstr "Méthode de paiement" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_template +msgid "Product" +msgstr "Produit" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_product +msgid "Product Variant" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__reason +msgid "Reason" +msgstr "Raison" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_stock_picking__related_backorder_ids +msgid "Related backorders" +msgstr "Reliquat lié" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_order +msgid "Sales Order" +msgstr "" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_order_need_cancel +msgid "Sales order canceled on the backend." +msgstr "Commandes annulées sur leur backend." + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_shipping_product_template +#, fuzzy +msgid "Shipping Costs" +msgstr "Coûts de livraison" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_move +msgid "Stock Move" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_tax +msgid "Tax" +msgstr "Taxe" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_template__tax_group_id +msgid "Tax Group" +msgstr "Groupe de taxes" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,help:connector_ecommerce.field_product_template__tax_group_id +#, fuzzy +msgid "Tax groups are used with some external system like Prestashop" +msgstr "" +"Les groupes de taxes sont utilisés avec des systèmes externes comme Magento " +"ou Prestashop." + +#. module: connector_ecommerce +#: model:exception.rule,description:connector_ecommerce.excep_parent_order_need_cancel +#, fuzzy +msgid "" +"The parent sales order has been canceled on the backend. You will not be " +"able to process this sales order until the parent's one is canceled." +msgstr "" +"The commande parente a été annulée sur son backend.\n" +"Impossible de confirmer ce devis tant que la commande parente n'est pas " +"annulée." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"The sales order cannot be automatically canceled because it is already in " +"\"Done\" state." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "The sales order could not be automatically canceled." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, fuzzy, python-format +msgid "The sales order has been automatically canceled." +msgstr "Les commandes ont été annulées sur leur backend." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#: model:exception.rule,description:connector_ecommerce.excep_order_need_cancel +#, python-format +msgid "The sales order has been canceled on the backend." +msgstr "Les commandes ont été annulées sur leur backend." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +#, fuzzy +msgid "" +"The sales orders using the payment\n" +" method will be imported\n" +" only when they receive a payment on the E-" +"Commerce backend.\n" +"
    " +msgstr "" +"Les commandes utilisant cette méthode de paiement seront importées\n" +" uniquement quand elles recevront un paiement " +"sur leur backend e-commerce." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will always be imported." +msgstr "" +"Les commandes utilisant cette méthode de paiement seront toujours importées." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will never be imported." +msgstr "" +"Les commandes utilisant cette méthode de paiement ne seront jamais importées." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +#, fuzzy +msgid "" +"This sales order has been canceled from the backend.\n" +" The usual action would be to cancel it in Odoo " +"along\n" +" all the documents generated (delivery orders, " +"invoices, ...)." +msgstr "" +"Cette commande a été annulée sur son backend.\n" +" L'action standard est d'annuler la commande dans Odoo " +"ainsi\n" +" que tous les documents qu'elle a générés (bons de " +"livraison, factures, ...)." + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_picking +msgid "Transfer" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "View Parent Sales Order" +msgstr "Voir la commande parente" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, fuzzy, python-format +msgid "Warning: the origin sales order %s has been canceled on the backend." +msgstr "Les commandes %s ont été annulées sur leur backend." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "or" +msgstr "ou" + +#, fuzzy +#~ msgid "" +#~ "A product has been imported from a backend and needs to be reviewed. Go " +#~ "to Connectors > Checkpoint and review the new products." +#~ msgstr "" +#~ "Un article a été importé depuis un backend et nécessite un contrôle.\n" +#~ "Aller dans Connecteurs > Points de contrôle et vérifier les nouveaux " +#~ "articles." + +#~ msgid "A product needs to be reviewed." +#~ msgstr "Un article doit être contrôlé." + +#~ msgid "Canceled in backend" +#~ msgstr "Annulée dans le backend" + +#~ msgid "Days before cancel" +#~ msgstr "Jours avant annulation" + +#~ msgid "Has Checkpoint" +#~ msgstr "A un point de contrôle" + +#~ msgid "Invoice" +#~ msgstr "Facture" + +#~ msgid "Product Template" +#~ msgstr "Template d'article" + +#, fuzzy +#~| msgid "Sales Order" +#~ msgid "Sale Order" +#~ msgstr "Bon de commande" + +#~ msgid "Services" +#~ msgstr "Services" + +#, fuzzy +#~ msgid "" +#~ "Parent sales order canceled on the\n" +#~ " backend." +#~ msgstr "Commande parente annulée sur le backend." + +#, fuzzy +#~ msgid "" +#~ "The sales order has been canceled on the\n" +#~ " backend." +#~ msgstr "Les commandes ont été annulées sur leur backend." + +#~ msgid "" +#~ "Choose the tax group. This is needed for example with magento or " +#~ "prestashop" +#~ msgstr "Choisir le groupe de taxes. Utilisé pour Magento ou Prestashop." + +#~ msgid "Picking List" +#~ msgstr "Liste de colisage" + +#~ msgid "Tax Groups" +#~ msgstr "Groupes de taxes" + +#~ msgid "Account Tax Group" +#~ msgstr "Groupe de taxes" + +#~ msgid "Sales Shop" +#~ msgstr "Magasins" + +#~ msgid "Other Information" +#~ msgstr "Autres informations" + +#~ msgid "Pricelist Items" +#~ msgstr "Lignes de liste de prix" + +#~ msgid "Taxes" +#~ msgstr "Taxes" + +#~ msgid "Payments" +#~ msgstr "Paiements" + +#~ msgid "Delivery Orders" +#~ msgstr "Bons de livraison" + +#~ msgid "This is the list of sales orders related to this invoice." +#~ msgstr "Liste des commandes liées à cette facture." + +#~ msgid "account tax group" +#~ msgstr "Groupe de taxes" + +#~ msgid "Name" +#~ msgstr "Nom" + +#~ msgid "Sales Orders" +#~ msgstr "Bons de commande" + +#~ msgid "Additional Info" +#~ msgstr "Informations additionnelles" + +#~ msgid "Price Type" +#~ msgstr "Type de prix" diff --git a/connector_ecommerce/i18n/nl.po b/connector_ecommerce/i18n/nl.po new file mode 100644 index 00000000..0a8f5735 --- /dev/null +++ b/connector_ecommerce/i18n/nl.po @@ -0,0 +1,493 @@ +# Dutch translation for odoo-connector-ecommerce +# Copyright (c) 2014 Rosetta Contributors and Canonical Ltd 2014 +# This file is distributed under the same license as the odoo-connector-ecommerce package. +# FIRST AUTHOR , 2014. +# +msgid "" +msgstr "" +"Project-Id-Version: odoo-connector-ecommerce\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2013-05-01 14:34+0000\n" +"PO-Revision-Date: 2014-02-12 08:22+0000\n" +"Last-Translator: Erwin van der Ploeg (BAS Solutions) \n" +"Language-Team: Dutch \n" +"Language: nl\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2014-05-27 06:09+0000\n" +"X-Generator: Launchpad (build 17017)\n" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"

    Resolution:

    1. Cancel the linked invoices, delivery orders, automatic " +"payments.
    2. Cancel the sales order manually.

    " +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "" +"A parent sales order has been canceled on the backend and needs to be " +"canceled." +msgstr "" +"Een bovenliggende verkooporder is geannuleerd in de backend en dient te " +"worden geannuleerd." + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__parent_id +msgid "A parent sales order is a sales order replaced by this one." +msgstr "" +"Een bovenliggende verkooporder is een verkooporder welke is vervangen door " +"deze order." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_need_cancel +msgid "A parent sales order needs cancel" +msgstr "Een bovenliggende verkooporder dient te worden geannuleerd" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "" +"After 'n' days, if the 'Import Rule' is not fulfilled, the import of the " +"sales order will be canceled." +msgstr "" +"Als na 'n' dagen niet aan de 'import regel' is voldaan, wordt de import van " +"de verkooporder geannuleerd." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Cancel" +msgstr "Annuleren" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__canceled_in_backend +msgid "Canceled In Backend" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Canceled in backend, to cancel" +msgstr "Geannuleerd in backen, te annuleren" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__cancellation_resolved +msgid "Cancellation from the backend resolved" +msgstr "Annulering in de backend opgelost." + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_cash_on_delivery_product_template +#, fuzzy +msgid "Cash on Delivery" +msgstr "Contant bij afleveren" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Confirm" +msgstr "Bevestigen" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_move_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_order_connector_form +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_stock_picking_out_connector_form +msgid "Connectors" +msgstr "Connectors" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_uid +msgid "Created by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__create_date +msgid "Created on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__days_before_cancel +msgid "Days Before Cancel" +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"Despite the cancellation of the sales order on the backend, it should stay " +"open.

    Reason: %s" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_discount_product_template +msgid "Discount Coupon" +msgstr "Kortingsbon" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__display_name +msgid "Display Name" +msgstr "" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_gift_product_template +msgid "Gift Certificate" +msgstr "Waardebon" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_sale_order__need_cancel +msgid "Has been canceled on the backend, need to be canceled." +msgstr "Is geannuleerd in de backend en dient geannuleerd te worden." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +#, fuzzy +msgid "" +"However, if for any reason you need to keep it open in Odoo,\n" +" write the reason here and it will stay open." +msgstr "" +"Indien u, voor welke reden dan ook, deze open wilt houden in Odoo,\n" +" schrijf dan hier de reden en hij blijft open." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__id +msgid "ID" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_ignore_cancel +msgid "Ignore Sales Order Cancel" +msgstr "Negeer annuleren verkooporder" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "Ignore backend's cancellation, Keep Open" +msgstr "Negeer annulering van de backend. Open houden." + +#. module: connector_ecommerce +#: model:ir.actions.act_window,name:connector_ecommerce.action_sale_ignore_cancel +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "Ignore the cancellation on the Backend" +msgstr "Annuleren vanuit de backend negeren" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_account_payment_mode__import_rule +msgid "Import Rule" +msgstr "Import regel" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "Import Rules" +msgstr "Import regels" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_move +msgid "Journal Entry" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel____last_update +msgid "Last Modified on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__write_date +msgid "Last Updated on" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__need_cancel +msgid "Need to be canceled" +msgstr "Dient te worden geannuleerd" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sales_order_filter +msgid "Only sales orders canceled in their backend" +msgstr "Alleen verkooporders welke zijn geannuleerd in de backend." + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_order__parent_id +msgid "Parent Order" +msgstr "Bovenliggende order" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_parent_order_need_cancel +#, fuzzy +msgid "Parent sales order canceled on the backend." +msgstr "Verkooporder is geannuleerd in de backend" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_payment_mode +#, fuzzy +msgid "Payment Modes" +msgstr "Betaalwijze" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_template +msgid "Product" +msgstr "Product" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_product_product +msgid "Product Variant" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_sale_ignore_cancel__reason +msgid "Reason" +msgstr "Reden" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_stock_picking__related_backorder_ids +msgid "Related backorders" +msgstr "Relateerde backorders" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_sale_order +msgid "Sales Order" +msgstr "" + +#. module: connector_ecommerce +#: model:exception.rule,name:connector_ecommerce.excep_order_need_cancel +msgid "Sales order canceled on the backend." +msgstr "Verkooporder is geannuleerd in de backend" + +#. module: connector_ecommerce +#: model:product.template,name:connector_ecommerce.product_product_shipping_product_template +#, fuzzy +msgid "Shipping Costs" +msgstr "Afleverkosten" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_move +msgid "Stock Move" +msgstr "" + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_account_tax +msgid "Tax" +msgstr "BTW" + +#. module: connector_ecommerce +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,field_description:connector_ecommerce.field_product_template__tax_group_id +msgid "Tax Group" +msgstr "BTW Groep" + +#. module: connector_ecommerce +#: model:ir.model.fields,help:connector_ecommerce.field_product_product__tax_group_id +#: model:ir.model.fields,help:connector_ecommerce.field_product_template__tax_group_id +#, fuzzy +msgid "Tax groups are used with some external system like Prestashop" +msgstr "" +"BTW groepen worden gebruikt met sommige externe systemen, zoals Magento of " +"Prestashop." + +#. module: connector_ecommerce +#: model:exception.rule,description:connector_ecommerce.excep_parent_order_need_cancel +#, fuzzy +msgid "" +"The parent sales order has been canceled on the backend. You will not be " +"able to process this sales order until the parent's one is canceled." +msgstr "" +"De bovenliggende verkooporder is geannuleerd in de backend.\n" +"U kunt deze verkooporder niet verder verwerken totdat de bovenliggende is " +"geannuleerd." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "" +"The sales order cannot be automatically canceled because it is already in " +"\"Done\" state." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, python-format +msgid "The sales order could not be automatically canceled." +msgstr "" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, fuzzy, python-format +msgid "The sales order has been automatically canceled." +msgstr "De verkooporder is geannuleerd in de backend." + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#: model:exception.rule,description:connector_ecommerce.excep_order_need_cancel +#, python-format +msgid "The sales order has been canceled on the backend." +msgstr "De verkooporder is geannuleerd in de backend." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +#, fuzzy +msgid "" +"The sales orders using the payment\n" +" method will be imported\n" +" only when they receive a payment on the E-" +"Commerce backend.\n" +"
    " +msgstr "" +"De verkooporder met deze betaalwijze wordt geïmporteerd\n" +" alleen als een betaling is ontvangen in de e-" +"commerce backend." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will always be imported." +msgstr "De verkooporder met deze betaalwijze zal altijd worden geïmporteerd." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.account_payment_mode_form_inherit +msgid "The sales orders using the payment method will never be imported." +msgstr "De verkooporder met deze betaalwijze zal nooit worden geïmporteerd." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +#, fuzzy +msgid "" +"This sales order has been canceled from the backend.\n" +" The usual action would be to cancel it in Odoo " +"along\n" +" all the documents generated (delivery orders, " +"invoices, ...)." +msgstr "" +"Deze verkooporder is geannuleerd in de backend.\n" +" De normale actie is om deze order ook in Odoo te " +"annuleren,\n" +" tezamen met de overige documenten, zoals uitgaande " +"levering en factuur." + +#. module: connector_ecommerce +#: model:ir.model,name:connector_ecommerce.model_stock_picking +msgid "Transfer" +msgstr "" + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.sale_order_view_form +msgid "View Parent Sales Order" +msgstr "Bekijk bovenliggende verkooporder" + +#. module: connector_ecommerce +#. odoo-python +#: code:addons/connector_ecommerce/models/sale.py:0 +#, fuzzy, python-format +msgid "Warning: the origin sales order %s has been canceled on the backend." +msgstr "De verkooporder %s is geannuleerd in de backend." + +#. module: connector_ecommerce +#: model_terms:ir.ui.view,arch_db:connector_ecommerce.view_sale_ignore_cancel +msgid "or" +msgstr "of" + +#, fuzzy +#~ msgid "" +#~ "A product has been imported from a backend and needs to be reviewed. Go " +#~ "to Connectors > Checkpoint and review the new products." +#~ msgstr "" +#~ "Een product is geïmporteerd vanuit de backend en moet worden " +#~ "gecontroleerd.\n" +#~ "Ga naar Connectors > Controlepunt en controleer de nieuwe producten." + +#~ msgid "A product needs to be reviewed." +#~ msgstr "Een product dient te worden gecontroleerd" + +#~ msgid "Canceled in backend" +#~ msgstr "Geannuleerd in backend" + +#~ msgid "Days before cancel" +#~ msgstr "Dagen voor annuleren" + +#~ msgid "Has Checkpoint" +#~ msgstr "Heeft controlepunt" + +#~ msgid "Invoice" +#~ msgstr "Factuur" + +#~ msgid "Product Template" +#~ msgstr "Productsjabloon" + +#, fuzzy +#~| msgid "Sales Order" +#~ msgid "Sale Order" +#~ msgstr "Verkooporder" + +#~ msgid "Services" +#~ msgstr "Diensten" + +#, fuzzy +#~ msgid "" +#~ "Parent sales order canceled on the\n" +#~ " backend." +#~ msgstr "Bovenliggende verkooporder is geannuleerd in de backend." + +#, fuzzy +#~ msgid "" +#~ "The sales order has been canceled on the\n" +#~ " backend." +#~ msgstr "De verkooporder is geannuleerd in de backend." + +#~ msgid "" +#~ "Choose the tax group. This is needed for example with magento or " +#~ "prestashop" +#~ msgstr "" +#~ "Kies een BTW groep. Dit is nodig voor de koppeling met Magento of " +#~ "Prestashop" + +#~ msgid "Picking List" +#~ msgstr "Verzamellijst" + +#~ msgid "Tax Groups" +#~ msgstr "BTW Groepen" + +#~ msgid "Account Tax Group" +#~ msgstr "BTW groep" + +#~ msgid "Sales Shop" +#~ msgstr "Verkooppunt" + +#~ msgid "Other Information" +#~ msgstr "Overige informatie" + +#~ msgid "Pricelist Items" +#~ msgstr "Prijslijst items" + +#~ msgid "Taxes" +#~ msgstr "BTW" + +#~ msgid "Payments" +#~ msgstr "Betalingen" + +#~ msgid "Delivery Orders" +#~ msgstr "Uitgaande leveringen" + +#~ msgid "This is the list of sales orders related to this invoice." +#~ msgstr "" +#~ "Dit is een lijst met alle verkooporders gerelateerd aan deze factuur." + +#~ msgid "account tax group" +#~ msgstr "BTW groep" + +#~ msgid "Name" +#~ msgstr "Naam" + +#~ msgid "Sales Orders" +#~ msgstr "Verkooporders" + +#~ msgid "Additional Info" +#~ msgstr "Aanvullende informatie" + +#~ msgid "Price Type" +#~ msgstr "Soort prijs" diff --git a/connector_ecommerce/models/__init__.py b/connector_ecommerce/models/__init__.py new file mode 100644 index 00000000..45db4cbe --- /dev/null +++ b/connector_ecommerce/models/__init__.py @@ -0,0 +1,9 @@ +from . import account_tax +from . import account_move +from . import account_payment_method +from . import account_payment_method_line +from . import product_template +from . import product_product +from . import sale_order +from . import stock_picking +from . import stock_move diff --git a/connector_ecommerce/models/account_move.py b/connector_ecommerce/models/account_move.py new file mode 100644 index 00000000..bfd8d74f --- /dev/null +++ b/connector_ecommerce/models/account_move.py @@ -0,0 +1,24 @@ +# © 2013 Camptocamp SA +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import models + + +class AccountMove(models.Model): + _inherit = "account.move" + + def action_post(self): + res = super().action_post() + self.notify_invoice_validate() + return res + + def _invoice_paid_hook(self): + res = super()._invoice_paid_hook() + for record in self: + self._event("on_invoice_paid").notify(record) + return res + + def notify_invoice_validate(self): + for record in self: + if record.move_type == "out_invoice": + self._event("on_invoice_validated").notify(record) diff --git a/connector_ecommerce/models/account_payment_method.py b/connector_ecommerce/models/account_payment_method.py new file mode 100644 index 00000000..c82479f8 --- /dev/null +++ b/connector_ecommerce/models/account_payment_method.py @@ -0,0 +1,43 @@ +# © 2011-2013 Akretion (Sébastien Beau) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) +import re + +from odoo import api, models + + +class AccountPaymentMethod(models.Model): + _inherit = "account.payment.method" + + @api.model + def _get_payment_method_domain(self, code, with_currency=True, with_country=True): + """Return the domain for searching a payment method.""" + return [("name", "=ilike", code)] + + @api.model + def _sanitize_payment_method_code(self, payment_method): + """Convert payment method name into a suitable code format.""" + return re.sub(r"[^a-z0-9]+", "_", payment_method.lower()).strip("_") + + @api.model + def _prepare_payment_method_vals(self, payment_method): + """Prepare values for creating a new payment method.""" + return { + "name": payment_method, + "code": self._sanitize_payment_method_code(payment_method), + "payment_type": "inbound", + } + + @api.model + def get_or_create_payment_method(self, payment_method): + """Try to get a payment method or create if it doesn't exist + + :param payment_method: payment method like PayPal, etc. + :type payment_method: str + :return: required payment method + :rtype: recordset + """ + domain = self._get_payment_method_domain(payment_method) + method = self.search(domain, limit=1) + if not method: + method = self.create([self._prepare_payment_method_vals(payment_method)]) + return method diff --git a/connector_ecommerce/models/account_payment_method_line.py b/connector_ecommerce/models/account_payment_method_line.py new file mode 100644 index 00000000..da90822c --- /dev/null +++ b/connector_ecommerce/models/account_payment_method_line.py @@ -0,0 +1,36 @@ +# © 2011-2013 Akretion (Sébastien Beau) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import api, fields, models + + +class AccountPaymentMethodLine(models.Model): + _inherit = "account.payment.method.line" + + # the logic around the 2 following fields has to be implemented + # in the connectors (magentoerpconnect, prestashoperpconnect,...) + days_before_cancel = fields.Integer( + default=30, + help="After 'n' days, if the 'Import Rule' is not fulfilled, the " + "import of the sales order will be canceled.", + ) + import_rule = fields.Selection( + selection=lambda self: self._selection_import_rule(), + default="always", + required=True, + help=""" + - Never: the sales orders using the payment method will never be imported. + - Always: the sales orders using the payment method will always be imported. + - Paid: the sales orders using the payment method will be imported + only when they receive a payment on the E-Commerce backend. + """, + ) + + @api.model + def _selection_import_rule(self): + return [ + ("always", "Always"), + ("never", "Never"), + ("paid", "Paid"), + ("authorized", "Authorized"), + ] diff --git a/connector_ecommerce/models/account_tax.py b/connector_ecommerce/models/account_tax.py new file mode 100644 index 00000000..66d3e880 --- /dev/null +++ b/connector_ecommerce/models/account_tax.py @@ -0,0 +1,34 @@ +# © 2011-2013 Akretion (Sébastien Beau) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import models + + +class AccountTaxCode(models.Model): + _inherit = "account.tax" + + def get_tax_from_rate(self, rate, is_tax_included=False): + account_tax_model = self.env["account.tax"] + tax = account_tax_model.search( + [ + ("price_include", "=", is_tax_included), + ("type_tax_use", "in", ["sale", "all"]), + ("amount", ">=", rate - 0.001), + ("amount", "<=", rate + 0.001), + ], + limit=1, + ) + if tax: + return tax + + # try to find a tax with less precision + tax = account_tax_model.search( + [ + ("price_include", "=", is_tax_included), + ("type_tax_use", "in", ["sale", "all"]), + ("amount", ">=", rate - 0.01), + ("amount", "<=", rate + 0.01), + ], + limit=1, + ) + return tax diff --git a/connector_ecommerce/models/product_product.py b/connector_ecommerce/models/product_product.py new file mode 100644 index 00000000..0d749ce4 --- /dev/null +++ b/connector_ecommerce/models/product_product.py @@ -0,0 +1,44 @@ +# © 2011-2013 Akretion (Sébastien Beau) +# © 2018 FactorLibre +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import api, models + + +class ProductProduct(models.Model): + _inherit = "product.product" + + @api.model + def _price_changed_fields(self): + return { + "lst_price", + "price_extra", + } | self.product_tmpl_id._price_changed_fields() + + def _price_changed(self, vals): + """Fire the ``on_product_price_changed`` if the price + of the product could have changed. + + If one of the field used in a sale pricelist item has been + modified, we consider that the price could have changed. + + There is no guarantee that's the price actually changed, + because it depends on the pricelists. + """ + price_fields = self._price_changed_fields() + if any(field in vals for field in price_fields): + for product in self: + self._event("on_product_price_changed").notify(product) + + def write(self, vals): + self_context = self.with_context(from_product_ids=self.ids) + result = super(ProductProduct, self_context).write(vals) + self._price_changed(vals) + return result + + @api.model_create_multi + def create(self, vals_list): + records = super().create(vals_list) + for vals, record in zip(vals_list, records, strict=True): + record._price_changed(vals) + return records diff --git a/connector_ecommerce/models/product_template.py b/connector_ecommerce/models/product_template.py new file mode 100644 index 00000000..de27994a --- /dev/null +++ b/connector_ecommerce/models/product_template.py @@ -0,0 +1,56 @@ +# © 2011-2013 Akretion (Sébastien Beau) +# © 2018 FactorLibre +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import api, fields, models + + +class ProductTemplate(models.Model): + _inherit = "product.template" + + # TODO implement set function and also support multi tax + + @api.depends("taxes_id.tax_group_id") + def _compute_tax_group_id(self): + for record in self: + taxes = record.taxes_id + record.tax_group_id = taxes[-1:].tax_group_id.id + + tax_group_id = fields.Many2one( + comodel_name="account.tax.group", + compute="_compute_tax_group_id", + string="Tax Group", + help="Tax groups are used with some external system like Prestashop", + ) + + @api.model + def _price_changed_fields(self): + return {"list_price", "lst_price", "standard_price"} + + def _price_changed(self, vals): + """Fire the ``on_product_price_changed`` on all the variants of + the template if the price of the product could have changed. + + If one of the field used in a sale pricelist item has been + modified, we consider that the price could have changed. + + There is no guarantee that's the price actually changed, + because it depends on the pricelists. + """ + price_fields = self._price_changed_fields() + if any(field in vals for field in price_fields): + product_model = self.env["product.product"] + products = product_model.search([("product_tmpl_id", "in", self.ids)]) + # when the write is done on the product.product, avoid + # to fire the event 2 times + if self.env.context.get("from_product_ids"): + from_product_ids = self.env.context["from_product_ids"] + remove_products = product_model.browse(from_product_ids) + products -= remove_products + for product in products: + self._event("on_product_price_changed").notify(product) + + def write(self, vals): + result = super().write(vals) + self._price_changed(vals) + return result diff --git a/connector_ecommerce/models/sale_order.py b/connector_ecommerce/models/sale_order.py new file mode 100644 index 00000000..b028dd8c --- /dev/null +++ b/connector_ecommerce/models/sale_order.py @@ -0,0 +1,231 @@ +# © 2011-2013 Camptocamp +# © 2010-2013 Akretion (Sébastien Beau) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) +# -*- coding: utf-8 -*- + +import logging + +from odoo import api, exceptions, fields, models, osv + +_logger = logging.getLogger(__name__) + + +class SaleOrder(models.Model): + """Add a cancellation mecanism in the sales orders + + When a sales order is canceled in a backend, the connectors can flag + the 'canceled_in_backend' flag. It will: + + * try to automatically cancel the sales order + * block the confirmation of the sales orders using a 'sales exception' + + When a sales order is canceled or the user used the button to force + to 'keep it open', the flag 'cancellation_resolved' is set to True. + + The second axe which can be used by the connectors is the 'parent' + sales order. When a sales order has a parent sales order (logic to + link with the parent to be defined by each connector), it will be + blocked until the cancellation of the sales order is resolved. + + This is used by, for instance, the magento connector, when one + modifies a sales order, Magento cancels it and create a new one with + the first one as parent. + """ + + _inherit = "sale.order" + + canceled_in_backend = fields.Boolean(readonly=True, copy=False) + # set to True when the cancellation from the backend is + # resolved, either because the SO has been canceled or + # because the user manually chose to keep it open + cancellation_resolved = fields.Boolean( + string="Cancellation from the backend resolved", copy=False + ) + parent_id = fields.Many2one( + comodel_name="sale.order", + compute="_compute_parent_id", + search="_search_parent_id", + string="Parent Order", + help="A parent sales order is a sales order replaced by this one.", + ) + need_cancel = fields.Boolean( + compute="_compute_need_cancel", + string="Need to be canceled", + copy=False, + help="Has been canceled on the backend, need to be canceled.", + ) + parent_need_cancel = fields.Boolean( + compute="_compute_parent_need_cancel", + string="A parent sales order needs cancel", + recursive=True, + help="A parent sales order has been canceled on the backend" + " and needs to be canceled.", + ) + + @api.depends() + def _compute_parent_id(self): + """Need to be inherited in the connectors to implement the + parent logic. + + See an implementation example in ``connector_magento``. + """ + for record in self: + record.parent_id = False + + # This is to resolve ERROR odoo.osv.expression: Non-stored field + # sale.order.parent_id cannot be searched. + def _search_parent_id(self, operator, value): + """Need to be inherited in the connectors to implement the parent logic.""" + return [("id", "=", -1)] + + @api.depends("canceled_in_backend", "cancellation_resolved") + def _compute_need_cancel(self): + """Return True if the sales order need to be canceled + (has been canceled on the Backend) + """ + for record in self: + record.need_cancel = ( + record.canceled_in_backend and not record.cancellation_resolved + ) + + @api.depends( + "need_cancel", + "parent_id", + "parent_id.need_cancel", + "parent_id.parent_need_cancel", + ) + def _compute_parent_need_cancel(self): + """Return True if at least one parent sales order need to + be canceled (has been canceled on the backend). + Follows all the parent sales orders. + """ + for record in self: + record.parent_need_cancel = False + order = record.parent_id + while order: + if order.need_cancel: + record.parent_need_cancel = True + order = order.parent_id + + def _try_auto_cancel(self): + """Try to automatically cancel a sales order canceled + in a backend. + + If it can't cancel it, does nothing. + """ + resolution_msg = self.env._( + "

    Resolution:

      " + "
    1. Cancel the linked invoices, delivery " + "orders, automatic payments.
    2. " + "
    3. Cancel the sales order manually.
    4. " + "

    " + ) + for order in self: + state = order.state + if state == "cancel": + continue + elif state == "done": + message = self.env._( + "The sales order cannot be automatically " + 'canceled because it is already in "Done" state.' + ) + else: + try: + order.action_cancel() + except (osv.osv.except_osv, osv.orm.except_orm, exceptions.Warning): + # the 'cancellation_resolved' flag will stay to False + message = ( + self.env._( + "The sales order could not be automatically canceled." + ) + + resolution_msg + ) + else: + message = self.env._( + "The sales order has been automatically canceled." + ) + order.message_post(body=message) + + def _log_canceled_in_backend(self): + message = self.env._("The sales order has been canceled on the backend.") + self.message_post(body=message) + for order in self: + message = ( + self.env._( + "Warning: the origin sales order %s has been canceled " + "on the backend." + ) + % order.name + ) + for picking in order.picking_ids: + picking.message_post(body=message) + for invoice in order.invoice_ids: + invoice.message_post(body=message) + + @api.model_create_multi + def create(self, vals_list): + records = super().create(vals_list) + for vals, record in zip(vals_list, records, strict=True): + if vals.get("canceled_in_backend"): + record._log_canceled_in_backend() + record._try_auto_cancel() + return records + + def write(self, values): + result = super().write(values) + if values.get("canceled_in_backend"): + self._log_canceled_in_backend() + self._try_auto_cancel() + return result + + def action_cancel(self): + res = super().action_cancel() + for sale in self: + # the sales order is canceled => considered as resolved + if sale.canceled_in_backend and not sale.cancellation_resolved: + sale.write({"cancellation_resolved": True}) + return res + + def ignore_cancellation(self, reason): + """Manually set the cancellation from the backend as resolved. + + The user can choose to keep the sales order active for some reason, + it only requires to push a button to keep it alive. + """ + message = ( + self.env._( + "Despite the cancellation of the sales order on the " + "backend, it should stay open.

    Reason: %s" + ) + % reason + ) + self.message_post(body=message) + self.write({"cancellation_resolved": True}) + return True + + def action_view_parent(self): + """Return an action to display the parent sales order""" + self.ensure_one() + + parent = self.parent_id + if not parent: + return + + view_xmlid = "sale.view_order_form" + if parent.state in ("draft", "sent", "cancel"): + action_xmlid = "sale.action_quotations" + else: + action_xmlid = "sale.action_orders" + + action = self.env.ref(action_xmlid).read()[0] + + view = self.env.ref(view_xmlid) + action["views"] = [(view.id if view else False, "form")] + action["res_id"] = parent.id + return action + + def _create_delivery_line(self, carrier, price_unit): + if self.order_line.filtered(lambda r: r.is_delivery): + # skip if we have already a delivery line (created by import of order) + return + return super()._create_delivery_line(carrier, price_unit) diff --git a/connector_ecommerce/models/stock_move.py b/connector_ecommerce/models/stock_move.py new file mode 100644 index 00000000..6ae00fb2 --- /dev/null +++ b/connector_ecommerce/models/stock_move.py @@ -0,0 +1,27 @@ +# © 2013-2015 Camptocamp +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import models + + +class StockMove(models.Model): + _inherit = "stock.move" + + def _action_done(self, cancel_backorder=False): + fire_event = not self.env.context.get("__no_on_event_out_done") + if fire_event: + pickings = self.mapped("picking_id") + states = {p.id: p.state for p in pickings} + + result = super()._action_done(cancel_backorder=cancel_backorder) + + if fire_event: + for picking in pickings: + if states[picking.id] != "done" and picking.state == "done": + if picking.picking_type_id.code != "outgoing": + continue + # partial pickings are handled in + # StockPicking.do_transfer() + picking._event("on_picking_out_done").notify(picking, "complete") + + return result diff --git a/connector_ecommerce/models/stock_picking.py b/connector_ecommerce/models/stock_picking.py new file mode 100644 index 00000000..4bf71cc9 --- /dev/null +++ b/connector_ecommerce/models/stock_picking.py @@ -0,0 +1,38 @@ +# © 2013-2015 Camptocamp +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from odoo import fields, models + + +class StockPicking(models.Model): + _inherit = "stock.picking" + + related_backorder_ids = fields.One2many( + comodel_name="stock.picking", + inverse_name="backorder_id", + string="Related backorders", + ) + + def write(self, vals): + res = super().write(vals) + if vals.get("carrier_tracking_ref"): + for record in self: + self._event("on_tracking_number_added").notify(record) + return res + + def _action_done(self): + # The key in the context avoid the event to be fired in + # StockMove.action_done(). Allow to handle the partial pickings + self_context = self.with_context(__no_on_event_out_done=True) + result = super(StockPicking, self_context)._action_done() + for picking in self: + method = "partial" if picking.related_backorder_ids else "complete" + if picking.picking_type_id.code == "outgoing": + self._event("on_picking_out_done").notify(picking, method) + elif ( + picking.picking_type_id.code == "incoming" + and picking.location_dest_id.usage == "customer" + ): + self._event("on_picking_dropship_done").notify(picking, method) + + return result diff --git a/connector_ecommerce/pyproject.toml b/connector_ecommerce/pyproject.toml new file mode 100644 index 00000000..4231d0cc --- /dev/null +++ b/connector_ecommerce/pyproject.toml @@ -0,0 +1,3 @@ +[build-system] +requires = ["whool"] +build-backend = "whool.buildapi" diff --git a/connector_ecommerce/readme/CONTRIBUTORS.md b/connector_ecommerce/readme/CONTRIBUTORS.md new file mode 100644 index 00000000..27d1c3f3 --- /dev/null +++ b/connector_ecommerce/readme/CONTRIBUTORS.md @@ -0,0 +1,2 @@ +See +[contributors](https://github.com/OCA/connector-ecommerce/graphs/contributors). diff --git a/connector_ecommerce/readme/DESCRIPTION.md b/connector_ecommerce/readme/DESCRIPTION.md new file mode 100644 index 00000000..00e1ef75 --- /dev/null +++ b/connector_ecommerce/readme/DESCRIPTION.md @@ -0,0 +1,34 @@ +This modules aims to be a common layer for the connectors dealing with +e-commerce. + +It sits on top of the [connector](http://odoo-connector.com) framework +and is used by the e-commerce connectors, like +[magentoerpconnect](http://odoo-magento-connector.com) or +[prestashoperpconnect](https://github.com/OCA/connector-prestashop). + +That's a technical module, which include amongst other things: + +Events + +> On which the connectors can subscribe listeners. The events it adds +> are: +> +> > - `on_invoice_paid(self, record)` +> > - `on_invoice_validated(self, record)` +> > - `on_invoice_validated(self, record)` +> > - `on_picking_out_done(self, record, method)` where method is +> > 'partial' or 'complete' +> > - `on_tracking_number_added(self, record)` +> > - `on_product_price_changed(self, record)` +> +> Components +> +> A piece of code which allows to play all the `onchanges` required when +> we create a sales order. +> +> Another one which allows to add special lines in imported sales orders +> such as Shipping fees, Cash on Delivery or Discounts. + +Data Model + +> Add structures shared for e-commerce connectors diff --git a/connector_ecommerce/readme/INSTALL.md b/connector_ecommerce/readme/INSTALL.md new file mode 100644 index 00000000..fa921d2a --- /dev/null +++ b/connector_ecommerce/readme/INSTALL.md @@ -0,0 +1,2 @@ +This module is a dependency for more advanced connectors. It does +nothing on its own and there is no reason to install it alone. diff --git a/connector_ecommerce/security/ir.model.access.csv b/connector_ecommerce/security/ir.model.access.csv new file mode 100644 index 00000000..d9937195 --- /dev/null +++ b/connector_ecommerce/security/ir.model.access.csv @@ -0,0 +1,2 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_sale_ignore_cancel,access_sale_ignore_cancel,model_sale_ignore_cancel,base.group_user,1,1,1,1 diff --git a/connector_ecommerce/security/security.xml b/connector_ecommerce/security/security.xml new file mode 100644 index 00000000..bd707771 --- /dev/null +++ b/connector_ecommerce/security/security.xml @@ -0,0 +1,14 @@ + + + + + + + + + + + diff --git a/connector_ecommerce/static/description/icon.png b/connector_ecommerce/static/description/icon.png new file mode 100644 index 00000000..3a0328b5 Binary files /dev/null and b/connector_ecommerce/static/description/icon.png differ diff --git a/connector_ecommerce/static/description/index.html b/connector_ecommerce/static/description/index.html new file mode 100644 index 00000000..437b9618 --- /dev/null +++ b/connector_ecommerce/static/description/index.html @@ -0,0 +1,459 @@ + + + + + +Connector for E-Commerce + + + +
    +

    Connector for E-Commerce

    + + +

    Beta License: AGPL-3 OCA/connector-ecommerce Translate me on Weblate Try me on Runboat

    +

    This modules aims to be a common layer for the connectors dealing with +e-commerce.

    +

    It sits on top of the connector +framework and is used by the e-commerce connectors, like +magentoerpconnect or +prestashoperpconnect.

    +

    That’s a technical module, which include amongst other things:

    +

    Events

    +
    +

    On which the connectors can subscribe listeners. The events it adds +are:

    +
    +
      +
    • on_invoice_paid(self, record)
    • +
    • on_invoice_validated(self, record)
    • +
    • on_invoice_validated(self, record)
    • +
    • on_picking_out_done(self, record, method) where method is +‘partial’ or ‘complete’
    • +
    • on_tracking_number_added(self, record)
    • +
    • on_product_price_changed(self, record)
    • +
    +
    +

    Components

    +

    A piece of code which allows to play all the onchanges required +when we create a sales order.

    +

    Another one which allows to add special lines in imported sales +orders such as Shipping fees, Cash on Delivery or Discounts.

    +
    +

    Data Model

    +
    +Add structures shared for e-commerce connectors
    +

    Table of contents

    + +
    +

    Installation

    +

    This module is a dependency for more advanced connectors. It does +nothing on its own and there is no reason to install it alone.

    +
    +
    +

    Bug Tracker

    +

    Bugs are tracked on GitHub Issues. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us to smash it by providing a detailed and welcomed +feedback.

    +

    Do not contact contributors directly about support or help with technical issues.

    +
    +
    +

    Credits

    +
    +

    Authors

    +
      +
    • Camptocamp
    • +
    • Akretion
    • +
    +
    + +
    +

    Maintainers

    +

    This module is maintained by the OCA.

    + +Odoo Community Association + +

    OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use.

    +

    This module is part of the OCA/connector-ecommerce project on GitHub.

    +

    You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

    +
    +
    +
    + + diff --git a/connector_ecommerce/tests/__init__.py b/connector_ecommerce/tests/__init__.py new file mode 100644 index 00000000..d99a8876 --- /dev/null +++ b/connector_ecommerce/tests/__init__.py @@ -0,0 +1,3 @@ +from . import test_onchange +from . import test_invoice_event +from . import test_picking_event diff --git a/connector_ecommerce/tests/test_invoice_event.py b/connector_ecommerce/tests/test_invoice_event.py new file mode 100644 index 00000000..5590d0c3 --- /dev/null +++ b/connector_ecommerce/tests/test_invoice_event.py @@ -0,0 +1,75 @@ +# © 2013 Camptocamp SA +# © 2018 FactorLibre +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from unittest import mock + +from odoo.addons.base.tests.common import BaseCommon + + +class TestInvoiceEvent(BaseCommon): + """Test if the events on the invoice are fired correctly""" + + def setUp(self): + super().setUp() + self.invoice_model = self.env["account.move"] + partner_model = self.env["res.partner"] + partner = partner_model.create({"name": "Hodor"}) + product = self.env.ref("product.product_product_6") + invoice_vals = { + "partner_id": partner.id, + "company_id": self.env.ref("base.main_company").id, + "move_type": "out_invoice", + "invoice_line_ids": [ + ( + 0, + 0, + { + "name": "LCD Screen", + "product_id": product.id, + "quantity": 5, + "price_unit": 200, + }, + ) + ], + } + self.invoice = self.invoice_model.create(invoice_vals) + self.invoice._onchange_partner_id() + + # self.invoice = self.invoice_model.create( + # invoice._convert_to_write(invoice._cache) + # ) + self.journal = self.env["account.journal"].search( + [("type", "=", "bank"), ("company_id", "=", self.env.company.id)], + limit=1, + ) + + def test_event_validated(self): + """Test if the ``on_invoice_validated`` event is fired + when an invoice is validated""" + assert self.invoice, "The invoice has not been created" + + mock_method = "odoo.addons.component_event.models.base.Base._event" + with mock.patch(mock_method) as mock_event: + self.invoice.action_post() + self.assertEqual(self.invoice.state, "posted") + mock_event("on_invoice_validated").notify.assert_any_call(self.invoice) + + def test_event_paid(self): + """Test if the ``on_invoice_paid`` event is fired + when an invoice is paid""" + assert self.invoice, "The invoice has not been created" + + mock_method = "odoo.addons.component_event.models.base.Base._event" + with mock.patch(mock_method) as mock_event: + self.assertEqual(self.invoice.state, "draft") + self.invoice.action_post() + self.assertEqual(self.invoice.state, "posted") + register_payments = ( + self.env["account.payment.register"] + .with_context(active_model="account.move", active_ids=self.invoice.ids) + .create({"journal_id": self.journal.id}) + ) + register_payments._create_payments() + self.assertEqual(self.invoice.payment_state, "paid") + mock_event("on_invoice_paid").notify.assert_any_call(self.invoice) diff --git a/connector_ecommerce/tests/test_onchange.py b/connector_ecommerce/tests/test_onchange.py new file mode 100644 index 00000000..7f1e99bf --- /dev/null +++ b/connector_ecommerce/tests/test_onchange.py @@ -0,0 +1,119 @@ +# © 2013-TODAY Akretion (Sébastien Beau) +# © 2018 FactorLibre +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from contextlib import contextmanager + +import odoo.tests.common as common + +from odoo.addons.component.core import ComponentRegistry + +from ..components.sale_order_onchange import OnChangeManager, SaleOrderOnChange + +DB = common.DB +ADMIN_USER_ID = common.ADMIN_USER_ID + + +class TestOnchange(ComponentRegistry): + """Test if the onchanges are applied correctly on a sales order""" + + def setUp(self): + super().setUp() + self.collection = self.env["collection.base"] + OnChangeManager._build_component(self.comp_registry) + SaleOrderOnChange._build_component(self.comp_registry) + self.collection_record = self.collection.new() + + @contextmanager + def get_base(): + # Our WorkContext, it will be passed along in every + # components so we can share data transversally. + # We are working with sale.order in the following tests, + # unless we change it in the test. + with self.collection_record.work_on( + "sale.order", + # we use a custom registry only + # for the sake of the tests + components_registry=self.comp_registry, + ) as work: + # We get the 'base' component, handy to test the base + # methods component, many_components, ... + yield work.component_by_name("base") + + self.get_base = get_base + + def test_play_onchange(self): + """Play the onchange ConnectorUnit on a sales order""" + product_model = self.env["product.product"] + partner_model = self.env["res.partner"] + tax_model = self.env["account.tax"] + + partner = partner_model.create( + {"name": "seb", "zip": "69100", "city": "Villeurbanne"} + ) + partner_invoice = partner_model.create( + { + "name": "Guewen", + "zip": "1015", + "city": "Lausanne", + "type": "invoice", + "parent_id": partner.id, + } + ) + tax = tax_model.create({"name": "My Tax", "amount": 1.0}) + product = product_model.create( + { + "default_code": "MyCode", + "name": "My Product", + "weight": 15, + "taxes_id": [(6, 0, [tax.id])], + } + ) + + order_vals = { + "name": "mag_10000001", + "partner_id": partner.id, + "company_id": self.env.company.id, + "order_line": [ + ( + 0, + 0, + { + "product_id": product.id, + "price_unit": 20, + "name": "My Real Name", + "product_uom_qty": 1, + "sequence": 1, + }, + ), + ], + } + + extra_lines = [ + ( + 0, + 0, + { + "product_id": product.id, + "price_unit": 10, + "name": "Line 2", + "product_uom_qty": 2, + "sequence": 2, + }, + ), + ] + + with self.get_base() as base: + onchange = base.component(usage="ecommerce.onchange.manager.sale.order") + order = onchange.play(order_vals, extra_lines) + + self.assertEqual(order["partner_invoice_id"], partner_invoice.id) + self.assertEqual(len(order["order_line"]), 1) + line = order["order_line"][0][2] + self.assertEqual(line["name"], "My Real Name") + self.assertEqual(line["product_uom"], product.uom_id.id) + self.assertEqual(line["tax_id"], [(5,), (4, tax.id)]) + line = extra_lines[0][2] + self.assertEqual(line["name"], "Line 2") + self.assertEqual(line["product_uom"], product.uom_id.id) + self.assertEqual(line["tax_id"], [(5,), (4, tax.id)]) diff --git a/connector_ecommerce/tests/test_picking_event.py b/connector_ecommerce/tests/test_picking_event.py new file mode 100644 index 00000000..6a1e0cfd --- /dev/null +++ b/connector_ecommerce/tests/test_picking_event.py @@ -0,0 +1,103 @@ +# © 2015-2016 Camptocamp SA +# © 2018 FactorLibre +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) + +from unittest import mock + +from odoo.addons.base.tests.common import BaseCommon + + +class TestPickingEvent(BaseCommon): + """Test if the events on the pickings are fired correctly""" + + def _create_pack_operation(self, product, product_qty, picking_id, **values): + move_line_env = self.env["stock.move.line"] + vals = { + "picking_id": picking_id.id, + "product_id": product.id, + "product_uom_qty": product_qty, + "quantity": product_qty, + } + vals.update(**values) + pack_operation = move_line_env.new(vals) + pack_operation.onchange_product_id() + return move_line_env.create( + pack_operation._convert_to_write(pack_operation._cache) + ) + + def setUp(self): + super().setUp() + self.picking_model = self.env["stock.picking"] + self.sale_model = self.env["sale.order"] + self.sale_line_model = self.env["sale.order.line"] + + partner_model = self.env["res.partner"] + partner = partner_model.create({"name": "Benjy"}) + self.product_6 = self.env.ref("product.product_product_6") + self.product_7 = self.env.ref("product.product_product_7") + self.sale = self.sale_model.create({"partner_id": partner.id}) + self.sale_line_model.create( + { + "order_id": self.sale.id, + "product_id": self.product_6.id, + "name": "Large Cabinet", + "product_uom_qty": 42, + "product_uom": self.env.ref("uom.product_uom_unit").id, + "price_unit": 65, + } + ) + self.sale_line_model.create( + { + "order_id": self.sale.id, + "product_id": self.product_7.id, + "name": "Storage Box", + "product_uom_qty": 2, + "product_uom": self.env.ref("uom.product_uom_unit").id, + "price_unit": 405, + } + ) + self.sale.action_confirm() + self.picking = self.sale.picking_ids + self.location_id = self.picking.move_line_ids[0].location_id.id + self.location_dest_id = self.picking.move_line_ids[0].location_dest_id.id + + def test_event_on_picking_out_done(self): + """Test if the ``on_picking_out_done`` event is fired + when an outgoing picking is done""" + mock_method = "odoo.addons.component_event.models.base.Base._event" + with mock.patch(mock_method) as mock_event: + self.picking.action_confirm() + self.picking.action_assign() + for move in self.picking.move_ids: + move.move_line_ids.quantity = move.product_qty + move.move_line_ids.picked = True + self.picking._action_done() + self.assertEqual(self.picking.state, "done") + mock_event("on_picking_out_done").notify.assert_called_with( + self.picking, "complete" + ) + + def test_event_on_picking_out_done_partial(self): + """Test if the ``on_picking_out_done`` informs of the partial + pickings""" + mock_method = "odoo.addons.component_event.models.base.Base._event" + with mock.patch(mock_method) as mock_event: + self.picking.action_confirm() + self.picking.action_assign() + self.picking.move_line_ids.quantity = 1.0 + self.picking.move_line_ids.picked = True + self.picking._action_done() + self.assertEqual(self.picking.state, "done") + mock_event("on_picking_out_done").notify.assert_called_with( + self.picking, "partial" + ) + + def test_event_on_tracking_number_added(self): + """Test if the ``on_tracking_number_added`` event is fired + when a tracking number is added""" + mock_method = "odoo.addons.component_event.models.base.Base._event" + with mock.patch(mock_method) as mock_event: + self.picking.carrier_tracking_ref = "XYZ" + mock_event("on_tracking_number_added").notify.assert_called_with( + self.picking + ) diff --git a/connector_ecommerce/views/account_journal.xml b/connector_ecommerce/views/account_journal.xml new file mode 100644 index 00000000..4489cf89 --- /dev/null +++ b/connector_ecommerce/views/account_journal.xml @@ -0,0 +1,16 @@ + + + + account.journal + + + + + + + + + diff --git a/connector_ecommerce/views/account_move.xml b/connector_ecommerce/views/account_move.xml new file mode 100644 index 00000000..38c16818 --- /dev/null +++ b/connector_ecommerce/views/account_move.xml @@ -0,0 +1,19 @@ + + + + account.move + + + + + + + + + diff --git a/connector_ecommerce/views/account_payment_method_line.xml b/connector_ecommerce/views/account_payment_method_line.xml new file mode 100644 index 00000000..ff8adcb1 --- /dev/null +++ b/connector_ecommerce/views/account_payment_method_line.xml @@ -0,0 +1,13 @@ + + + + account.payment.method.line + + + + + + + + + diff --git a/connector_ecommerce/views/sale_order.xml b/connector_ecommerce/views/sale_order.xml new file mode 100644 index 00000000..e513cb54 --- /dev/null +++ b/connector_ecommerce/views/sale_order.xml @@ -0,0 +1,59 @@ + + + + sale.order + + + + +