← Back to team overview

savoirfairelinux-openerp team mailing list archive

[Merge] lp:~arthru/e-commerce-addons/payment-method-multicompany into lp:e-commerce-addons

 

arthru has proposed merging lp:~arthru/e-commerce-addons/payment-method-multicompany into lp:e-commerce-addons.

Requested reviews:
  extra-addons-commiter (extra-addons-commiter)

For more details, see:
https://code.launchpad.net/~arthru/e-commerce-addons/payment-method-multicompany/+merge/197862

This adds multicompany supports for payment methods.

Simply add a relation to a res.company from the payment.method, a field to configure it, and a security rule.

This merge proposal is the same as the proposed one on openerp-connecter/e-commerce-addons (see https://code.launchpad.net/~akretion-team/openerp-connector/e-commerce-addons-payment-method-multicompany/+merge/190119 )
-- 
https://code.launchpad.net/~arthru/e-commerce-addons/payment-method-multicompany/+merge/197862
Your team extra-addons-commiter is requested to review the proposed merge of lp:~arthru/e-commerce-addons/payment-method-multicompany into lp:e-commerce-addons.
=== modified file 'base_sale_export_partner/__openerp__.py'
--- base_sale_export_partner/__openerp__.py	2012-12-26 13:24:14 +0000
+++ base_sale_export_partner/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -30,7 +30,7 @@
     """,
     'author': 'Akretion',
     'website': 'http://www.akretion.com',
-    'depends': ['base_sale_multichannels'],
+    'depends': ['connector_ecommerce'],
     'init_xml': [],
     'update_xml': [
         'wizard/export_partner.xml',

=== modified file 'base_sale_export_partner/wizard/export_partner.py'
--- base_sale_export_partner/wizard/export_partner.py	2012-12-07 12:44:57 +0000
+++ base_sale_export_partner/wizard/export_partner.py	2013-12-05 13:14:00 +0000
@@ -25,7 +25,7 @@
 from openerp.osv import fields
 from openerp.osv.osv import except_osv
 from openerp.tools.translate import _
-from base_external_referentials.external_osv import ExternalSession
+from openerp.addons.connector.external_osv import ExternalSession
 
 class partner_export_wizard(TransientModel):
     _name = 'partner.export.wizard'

=== modified file 'base_sale_export_product/__openerp__.py'
--- base_sale_export_product/__openerp__.py	2012-12-26 13:24:14 +0000
+++ base_sale_export_product/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -30,7 +30,7 @@
     """,
     'author': 'Akretion',
     'website': 'http://www.akretion.com',
-    'depends': ['base_sale_multichannels'],
+    'depends': ['connector_ecommerce'],
     'init_xml': [],
     'update_xml': [
         'wizard/export_product.xml',

=== modified file 'base_sale_export_product/wizard/export_product.py'
--- base_sale_export_product/wizard/export_product.py	2012-12-07 12:44:57 +0000
+++ base_sale_export_product/wizard/export_product.py	2013-12-05 13:14:00 +0000
@@ -24,7 +24,7 @@
 from openerp.osv import fields
 from openerp.osv.osv import except_osv
 from openerp.tools.translate import _
-from base_external_referentials.external_osv import ExternalSession
+from openerp.addons.connector.external_osv import ExternalSession
 
 class product_export_wizard(TransientModel):
     _name = 'product.export.wizard'

=== removed file 'base_sale_multichannels/connector.py'
--- base_sale_multichannels/connector.py	2012-08-22 16:31:16 +0000
+++ base_sale_multichannels/connector.py	1970-01-01 00:00:00 +0000
@@ -1,37 +0,0 @@
-# -*- encoding: utf-8 -*-
-###############################################################################
-#                                                                             #
-#   product_custom_attributes for OpenERP                                     #
-#   Copyright (C) 2012 Camptocamp Alexandre Fayolle  <alexandre.fayolle@xxxxxxxxxxxxxx>  #
-#   Copyright (C) 2012 Akretion Sebastien Beau <sebastien.beau@xxxxxxxxxxxx>  #
-#                                                                             #
-#   This program is free software: you can redistribute it and/or modify      #
-#   it under the terms of the GNU Affero General Public License as            #
-#   published by the Free Software Foundation, either version 3 of the        #
-#   License, or (at your option) any later version.                           #
-#                                                                             #
-#   This program is distributed in the hope that it will be useful,           #
-#   but WITHOUT ANY WARRANTY; without even the implied warranty of            #
-#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             #
-#   GNU Affero General Public License for more details.                       #
-#                                                                             #
-#   You should have received a copy of the GNU Affero General Public License  #
-#   along with this program.  If not, see <http://www.gnu.org/licenses/>.     #
-#                                                                             #
-###############################################################################
-
-from base_external_referentials.connector import AbstractConnector
-
-class BaseConnector(AbstractConnector):
-    def _get_import_defaults_res_partner(self, cr, uid, context=None):
-        pass
-    def _get_import_defaults_res_partner(self, cr, uid, context=None):
-        pass
-    def _get_import_defaults_external_shop_group(self, cr, uid, context=None):
-        pass
-
-    def _get_import_defaults_sale_order(self, cr, uid, context=None):
-        pass
-
-    def _record_one_sale_order(self, cr, uid, res_obj, resource, defaults, context):
-        pass

=== removed file 'base_sale_multichannels/delivery.py'
--- base_sale_multichannels/delivery.py	2012-08-21 13:57:44 +0000
+++ base_sale_multichannels/delivery.py	1970-01-01 00:00:00 +0000
@@ -1,29 +0,0 @@
-# -*- encoding: utf-8 -*-
-##############################################################################
-#
-#    Author Guewen Baconnier. Copyright 2011 Camptocamp SA
-#
-#    This program is free software: you can redistribute it and/or modify
-#    it under the terms of the GNU General Public License as published by
-#    the Free Software Foundation, either version 3 of the License, or
-#    (at your option) any later version.
-#
-#    This program is distributed in the hope that it will be useful,
-#    but WITHOUT ANY WARRANTY; without even the implied warranty of
-#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#    GNU General Public License for more details.
-#
-#    You should have received a copy of the GNU General Public License
-#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
-#
-##############################################################################
-
-from openerp.osv.orm import Model
-from openerp.osv import fields
-
-class delivery_carrier(Model):
-    _inherit = "delivery.carrier"
-
-    _columns = {
-        'export_needs_tracking': fields.boolean('Export only shippings with a tracking number'),
-    }

=== removed file 'base_sale_multichannels/delivery_view.xml'
--- base_sale_multichannels/delivery_view.xml	2011-07-14 14:37:48 +0000
+++ base_sale_multichannels/delivery_view.xml	1970-01-01 00:00:00 +0000
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<openerp>
-    <data>
-
-        <record id="view_delivery_carrier_form_inherit" model="ir.ui.view">
-            <field name="name">delivery.carrier.form.inherit</field>
-            <field name="model">delivery.carrier</field>
-            <field name="inherit_id" ref="delivery.view_delivery_carrier_form" />
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                 <data>
-                    <field name="product_id" position="after">
-                        <field name="export_needs_tracking"/>
-                    </field>
-                </data>
-            </field>
-        </record>
-
-    </data>
-</openerp>

=== removed file 'base_sale_multichannels/external_referential.py'
--- base_sale_multichannels/external_referential.py	2012-10-23 10:21:28 +0000
+++ base_sale_multichannels/external_referential.py	1970-01-01 00:00:00 +0000
@@ -1,83 +0,0 @@
-# -*- encoding: utf-8 -*-
-###############################################################################
-#                                                                             #
-#   base_sale_multichannels for OpenERP                                       #
-#   Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>  #
-#                                                                             #
-#   This program is free software: you can redistribute it and/or modify      #
-#   it under the terms of the GNU Affero General Public License as            #
-#   published by the Free Software Foundation, either version 3 of the        #
-#   License, or (at your option) any later version.                           #
-#                                                                             #
-#   This program is distributed in the hope that it will be useful,           #
-#   but WITHOUT ANY WARRANTY; without even the implied warranty of            #
-#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             #
-#   GNU Affero General Public License for more details.                       #
-#                                                                             #
-#   You should have received a copy of the GNU Affero General Public License  #
-#   along with this program.  If not, see <http://www.gnu.org/licenses/>.     #
-#                                                                             #
-###############################################################################
-from openerp.osv.orm import Model
-from openerp.osv import fields
-
-
-class external_referential(Model):
-    _inherit = "external.referential"
-
-    _columns = {
-        'last_imported_product_id': fields.integer('Last Imported Product Id',
-                                                   help=("Product are imported one by one."
-                                                         "This is the magento id of the last product imported."
-                                                         "If you clear it all product will be imported")),
-        'last_imported_partner_id': fields.integer('Last Imported Partner Id',
-                                                   help=("Partners are imported one by one."
-                                                         "This is the magento id of the last partner imported."
-                                                         "If you clear it all partners will be imported")),
-        'import_all_attributs': fields.boolean('Import all attributs',
-                                               help=("If the option is uncheck only the attributs"
-                                                     "that doesn't exist in OpenERP will be imported")),
-        'import_image_with_product': fields.boolean('With image',
-                                                    help=("If the option is check the product's image and"
-                                                          "the product will be imported at the same time and"
-                                                          "so the step '7-import images' is not needed")),
-        'import_links_with_product': fields.boolean('With links',
-                                                    help=("If the option is check the product's links"
-                                                          "(Up-Sell, Cross-Sell, Related) and the product will be imported"
-                                                          "at the same time and so the step '8-import links' is not needed")),
-        }
-
-    def import_customer_groups(self, cr, uid, ids, context=None):
-        self.import_resources(cr, uid, ids, 'res.partner.category', context=context)
-        return True
-
-    def import_product_categories(self, cr, uid, ids, context=None):
-        self.import_resources(cr, uid, ids, 'product.category', context=context)
-        return True
-
-    def import_customers(self, cr, uid, ids, context=None):
-        self.import_resources(cr, uid, ids, 'res.partner', context=context)
-        return True
-
-#    def import_product_attributes_sets(self, cr, uid, ids, context=None):
-#        return self.import_resources(cr, uid, ids, 'TODO', context=context)
-#
-#    def import_product_attributes_groups(self, cr, uid, ids, context=None):
-#        return self.import_resources(cr, uid, ids, 'TODO', context=context)
-#
-#    def import_product_attributes(self, cr, uid, ids, context=None):
-#        return self.import_resources(cr, uid, ids, 'TODO', context=context)
-
-    def import_products(self, cr, uid, ids, context=None):
-        self.import_resources(cr, uid, ids, 'product.product', context=context)
-        return True
-
-    def import_product_links(self, cr, uid, ids, context=None):
-        self.import_resources(cr, uid, ids, 'product.link', context=context)
-        return True
-
-
-
-
-
-

=== removed file 'base_sale_multichannels/i18n/base_sale_multichannels.pot'
--- base_sale_multichannels/i18n/base_sale_multichannels.pot	2010-08-26 01:14:26 +0000
+++ base_sale_multichannels/i18n/base_sale_multichannels.pot	1970-01-01 00:00:00 +0000
@@ -1,306 +0,0 @@
-# Translation of OpenERP Server.
-# This file contains the translation of the following modules:
-#	* base_sale_multichannels
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: OpenERP Server 5.0.6\n"
-"Report-Msgid-Bugs-To: support@xxxxxxxxxxx\n"
-"POT-Creation-Date: 2009-12-20 17:22:08+0000\n"
-"PO-Revision-Date: 2009-12-20 17:22:08+0000\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: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Partial Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: constraint:ir.model:0
-msgid "The Object name must start with x_ and not contain any special character !"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,description:base_sale_multichannels.module_meta_information
-msgid "\n"
-"This module provide an abstract common minimal base to multi-channels sales.\n"
-"Say you want to expose your product catalog to\n"
-"* several instances of flashy-sluggish Magento web sites\n"
-"* a cutting edge Spree web shop\n"
-"* a Neteven online Marketplace\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* an external Point Of Sale system\n"
-"* ...\n"
-"Then this module allows you to:\n"
-"* use several external references ids on every OpenERP object matching those all those external referentials\n"
-"* per referential instance, use several sale sub platform entities (ex: several Magento websites per instance)\n"
-"* per sub platform, use several shops (ex: several Magento web shops per website)\n"
-"\n"
-"For each sale shop (matching OpenERP sale.shop object), this module abstract the interfaces to:\n"
-"* export the catalog, shop warehouse stock level wise, shop pricelist wise\n"
-"* import the catalog\n"
-"* import orders\n"
-"* export orders/picking status\n"
-"    "
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,order_policy:0
-msgid "Shipping Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "None"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Shipped Quantities"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,referential_id:0
-msgid "Referential"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Draft"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_quantity:0
-msgid "The sale order will automatically create the invoice proposition (draft invoice). Ordered and delivered quantities may not be the same. You have to choose if you invoice based on ordered or shipped quantities. If the product is a service, shipped quantities means hours spent on the associated tasks."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,shop_group_id:0
-msgid "Shop Group"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:product.category,recursive_childen_ids:0
-msgid "All Child Categories"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Update Orders Status"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_policy:0
-msgid "If you don't have enough stock available to deliver all at once, do you accept partial shipments or not?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:account.journal,external_payment_codes:0
-msgid "Enter the external payment codes, comma separated. They will be used to select the payment journal."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_policy:0
-msgid "Packing Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Complete Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_generation_policy:0
-msgid "Invoice Generation Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Ordered Quantities"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,is_tax_included:0
-msgid "Requires sale_tax_include module to be installed"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Catalog"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "External Shop Settings"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Catalog"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice from the Packing"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Order Generation"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:account.journal,external_payment_codes:0
-msgid "External Payment Codes"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice on Order After Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: constraint:ir.ui.view:0
-msgid "Invalid XML for View Architecture!"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,shop_ids:0
-msgid "Sale Shops"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,name:0
-msgid "Name"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_quantity:0
-msgid "Invoice on"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,order_policy:0
-msgid "The Shipping Policy is used to synchronise invoice and delivery operations.\n"
-"  - The 'Pay before delivery' choice will first generate the invoice and then generate the packing order after the payment of this invoice.\n"
-"  - The 'Shipping & Manual Invoice' will create the packing order directly and wait for the user to manually click on the 'Invoice' button to generate the draft invoice.\n"
-"  - The 'Invoice on Order After Delivery' choice will generate the draft invoice based on sale order after all packing lists have been finished.\n"
-"  - The 'Invoice from the packing' choice is used to create an invoice during the packing process."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_inventory_export_date:0
-msgid "Last Inventory Export Time"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.referential,shop_group_ids:0
-msgid "Sub Entities"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,referential_id:0
-msgid "External Referential"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Payment Before Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,shortdesc:base_sale_multichannels.module_meta_information
-msgid "Base Sale MultiChannels"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-#: field:sale.shop,exportable_product_ids:0
-msgid "Exportable Products"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Import Orders"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_generation_policy:0
-msgid "Picking Generation Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_generation_policy:0
-msgid "Should orders create an invoice after import?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_update_order_export_date:0
-msgid "Last Order Update  Time"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_generation_policy:0
-msgid "Should orders create a picking after import?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Validated"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.model,name:base_sale_multichannels.model_external_shop_group
-msgid "External Referential Shop Group"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Stock Levels Only"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Shipping & Manual Invoice"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Actions"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,exportable_root_category_ids:0
-msgid "Root Category"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,is_tax_included:0
-msgid "Prices Include Tax?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Shop"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Multi Channels"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Orders"
-msgstr ""
-

=== removed file 'base_sale_multichannels/i18n/ca.po'
--- base_sale_multichannels/i18n/ca.po	2012-02-27 18:49:05 +0000
+++ base_sale_multichannels/i18n/ca.po	1970-01-01 00:00:00 +0000
@@ -1,380 +0,0 @@
-# Translation of OpenERP Server.
-# This file contains the translation of the following modules:
-#	* base_sale_multichannels
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: OpenERP Server 5.0.6\n"
-"Report-Msgid-Bugs-To: support@xxxxxxxxxxx\n"
-"POT-Creation-Date: 2009-12-20 17:22+0000\n"
-"PO-Revision-Date: 2011-02-14 10:04+0000\n"
-"Last-Translator: Jordi Esteve (www.zikzakmedia.com) "
-"<jesteve@xxxxxxxxxxxxxxx>\n"
-"Language-Team: \n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2012-01-17 05:05+0000\n"
-"X-Generator: Launchpad (build 14676)\n"
-"X-Poedit-Language: Catalan\n"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Partial Delivery"
-msgstr "Enviament parcial"
-
-#. module: base_sale_multichannels
-#: constraint:ir.model:0
-msgid ""
-"The Object name must start with x_ and not contain any special character !"
-msgstr ""
-"El nom de l'objecte ha de començar amb x_ i no contenir cap caràcter "
-"especial!"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,description:base_sale_multichannels.module_meta_information
-msgid ""
-"\n"
-"This module provide an abstract common minimal base to multi-channels "
-"sales.\n"
-"Say you want to expose your product catalog to\n"
-"* several instances of flashy-sluggish Magento web sites\n"
-"* a cutting edge Spree web shop\n"
-"* a Neteven online Marketplace\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* an external Point Of Sale system\n"
-"* ...\n"
-"Then this module allows you to:\n"
-"* use several external references ids on every OpenERP object matching those "
-"all those external referentials\n"
-"* per referential instance, use several sale sub platform entities (ex: "
-"several Magento websites per instance)\n"
-"* per sub platform, use several shops (ex: several Magento web shops per "
-"website)\n"
-"\n"
-"For each sale shop (matching OpenERP sale.shop object), this module abstract "
-"the interfaces to:\n"
-"* export the catalog, shop warehouse stock level wise, shop pricelist wise\n"
-"* import the catalog\n"
-"* import orders\n"
-"* export orders/picking status\n"
-"    "
-msgstr ""
-"\n"
-"Aquest mòdul proporciona una mínima base d'abstracció comuna a diversos "
-"canals de vendes.\n"
-"Suposem que voleu exposar el vostre catàleg de productes a:\n"
-"* Diverses instàncies de botiga web de Magento\n"
-"* Una botiga web d'última generació Spree\n"
-"* Un mercat Neteven\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* Un sistema punt de venda extern\n"
-"* ...\n"
-"Llavors, aquest mòdul us permet:\n"
-"* L'ús de diverses referències externes a tots els identificadors d'objectes "
-"OpenERP que apunten a totes aquestes referències externes.\n"
-"* Referències per instància, l'ús de diverses sub entitats de vendes (per "
-"exemple diversos llocs web Magento per instància)\n"
-"* Referències per sub entitat, l'ús de diverses botigues (per exemple "
-"diverses botigues web Magento per lloc web)\n"
-"\n"
-"Per a cada botiga de venda (que es correspondrà a l'objecte sale.shop de "
-"OpenERP), aquest mòdul abstreu les interfícies de:\n"
-"* Exportar el catàleg, nivell d'estoc del magatzem de la botiga, tarifa de "
-"preus de la botiga\n"
-"* Importar el catàleg\n"
-"* Importar comandes\n"
-"* Exportar l'estat de les comandes/albarans\n"
-"    "
-
-#. module: base_sale_multichannels
-#: field:sale.shop,order_policy:0
-msgid "Shipping Policy"
-msgstr "Política de facturació"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "None"
-msgstr "Cap"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Shipped Quantities"
-msgstr "Quantitats enviades"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,referential_id:0
-msgid "Referential"
-msgstr "Referència"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Draft"
-msgstr "Esborrany"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_quantity:0
-msgid ""
-"The sale order will automatically create the invoice proposition (draft "
-"invoice). Ordered and delivered quantities may not be the same. You have to "
-"choose if you invoice based on ordered or shipped quantities. If the product "
-"is a service, shipped quantities means hours spent on the associated tasks."
-msgstr ""
-"La comanda de venda crearà automàticament la proposta de factura (factura "
-"esborrany). Les quantitats demanades i les quantitats enviades poden no ser "
-"les mateixes. Heu de decidir si factureu basat en quantitats demanades o "
-"enviades. Si el producte és un servei, quantitats enviades significa hores "
-"dedicades a les tasques associades."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,shop_group_id:0
-msgid "Shop Group"
-msgstr "Grup botigues"
-
-#. module: base_sale_multichannels
-#: field:product.category,recursive_childen_ids:0
-msgid "All Child Categories"
-msgstr "Totes categories filles"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Update Orders Status"
-msgstr "Actualitza estat comandes"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_policy:0
-msgid ""
-"If you don't have enough stock available to deliver all at once, do you "
-"accept partial shipments or not?"
-msgstr ""
-"Si no disposeu de suficient estoc disponible per a enviar-ho tot a la "
-"vegada, accepteu enviaments parcials?"
-
-#. module: base_sale_multichannels
-#: help:account.journal,external_payment_codes:0
-msgid ""
-"Enter the external payment codes, comma separated. They will be used to "
-"select the payment journal."
-msgstr ""
-"Indiqueu els codis de pagament externs, separats per coma. S'utilitzaran per "
-"a seleccionar el diari de pagament."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_policy:0
-msgid "Packing Policy"
-msgstr "Política d'enviament"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Complete Delivery"
-msgstr "Enviament complet"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_generation_policy:0
-msgid "Invoice Generation Policy"
-msgstr "Política generació de factures"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Ordered Quantities"
-msgstr "Quantitats ordenades"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,is_tax_included:0
-msgid "Requires sale_tax_include module to be installed"
-msgstr "Requereix que el mòdul sale_tax_include sigui instal·lat."
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Catalog"
-msgstr "Catàleg"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "External Shop Settings"
-msgstr "Configuració botiga externa"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Catalog"
-msgstr "Exporta catàleg"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice from the Packing"
-msgstr "Factura des d'albarà"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Order Generation"
-msgstr "Generació comanda"
-
-#. module: base_sale_multichannels
-#: field:account.journal,external_payment_codes:0
-msgid "External Payment Codes"
-msgstr "Codis de pagament externs"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice on Order After Delivery"
-msgstr "Factura comanda després de l'enviament"
-
-#. module: base_sale_multichannels
-#: constraint:ir.ui.view:0
-msgid "Invalid XML for View Architecture!"
-msgstr "XML invàlid per a la definició de la vista!"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,shop_ids:0
-msgid "Sale Shops"
-msgstr "Botigues venda"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,name:0
-msgid "Name"
-msgstr "Nom"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_quantity:0
-msgid "Invoice on"
-msgstr "Factura les"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,order_policy:0
-msgid ""
-"The Shipping Policy is used to synchronise invoice and delivery operations.\n"
-"  - The 'Pay before delivery' choice will first generate the invoice and "
-"then generate the packing order after the payment of this invoice.\n"
-"  - The 'Shipping & Manual Invoice' will create the packing order directly "
-"and wait for the user to manually click on the 'Invoice' button to generate "
-"the draft invoice.\n"
-"  - The 'Invoice on Order After Delivery' choice will generate the draft "
-"invoice based on sale order after all packing lists have been finished.\n"
-"  - The 'Invoice from the packing' choice is used to create an invoice "
-"during the packing process."
-msgstr ""
-"La política d'enviament s'utilitza per sincronitzar la factura i les "
-"operacions d'enviament.\n"
-"  - L'opció 'Pagament abans de l'enviament' primer genera la factura i "
-"després genera l'albarà al fer efectiu el pagament d'aquesta factura.\n"
-"  - L'opció 'Enviament' & Factura manual 'crearà l'albarà directament i "
-"esperarà que l'usuari faci clic manualment al botó' Factura 'per generar la "
-"factura esborrany.\n"
-"  - L'opció 'Factura segons comanda després enviament' generarà la factura "
-"esborrany basada en la comanda de venda després que tots els albarans es "
-"processin.\n"
-"  - L'opció 'Factura des d'albarà' s'utilitza per a crear una factura des "
-"dels albarans processats."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_inventory_export_date:0
-msgid "Last Inventory Export Time"
-msgstr "Data última exportació inventari"
-
-#. module: base_sale_multichannels
-#: field:external.referential,shop_group_ids:0
-msgid "Sub Entities"
-msgstr "Sub entitats"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,referential_id:0
-msgid "External Referential"
-msgstr "Referència externa"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Payment Before Delivery"
-msgstr "Pagament abans de l'enviament"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,shortdesc:base_sale_multichannels.module_meta_information
-msgid "Base Sale MultiChannels"
-msgstr "Base vendes multicanal"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-#: field:sale.shop,exportable_product_ids:0
-msgid "Exportable Products"
-msgstr "Productes exportables"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Import Orders"
-msgstr "Importa comandes"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_generation_policy:0
-msgid "Picking Generation Policy"
-msgstr "Política generació d'albarans"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_generation_policy:0
-msgid "Should orders create an invoice after import?"
-msgstr "Les comandes haurien de crear una factura després de la importació?"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_update_order_export_date:0
-msgid "Last Order Update  Time"
-msgstr "Data última actualització comandes"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_generation_policy:0
-msgid "Should orders create a picking after import?"
-msgstr "Les comandes haurien de crear un albarà després de la importació?"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Validated"
-msgstr "Validat"
-
-#. module: base_sale_multichannels
-#: model:ir.model,name:base_sale_multichannels.model_external_shop_group
-msgid "External Referential Shop Group"
-msgstr "Referència externa grup botigues"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Stock Levels Only"
-msgstr "Exporta només nivells d'estoc"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Shipping & Manual Invoice"
-msgstr "Envia & Factura manual"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Actions"
-msgstr "Accions"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,exportable_root_category_ids:0
-msgid "Root Category"
-msgstr "Categoria arrel"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,is_tax_included:0
-msgid "Prices Include Tax?"
-msgstr "Preus inclouen impostos?"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Shop"
-msgstr "Botiga venda"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Multi Channels"
-msgstr "Vendes Multi canal"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Orders"
-msgstr "Comandes"

=== removed file 'base_sale_multichannels/i18n/ca_ES.po'
--- base_sale_multichannels/i18n/ca_ES.po	2010-08-26 01:14:26 +0000
+++ base_sale_multichannels/i18n/ca_ES.po	1970-01-01 00:00:00 +0000
@@ -1,334 +0,0 @@
-# Translation of OpenERP Server.
-# This file contains the translation of the following modules:
-#	* base_sale_multichannels
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: OpenERP Server 5.0.6\n"
-"Report-Msgid-Bugs-To: support@xxxxxxxxxxx\n"
-"POT-Creation-Date: 2009-12-20 17:22:08+0000\n"
-"PO-Revision-Date: 2010-03-02 13:08+0100\n"
-"Last-Translator: Jordi Esteve (Zikzakmedia) <jesteve@xxxxxxxxxxxxxxx>\n"
-"Language-Team: \n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Poedit-Language: Catalan\n"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Partial Delivery"
-msgstr "Enviament parcial"
-
-#. module: base_sale_multichannels
-#: constraint:ir.model:0
-msgid "The Object name must start with x_ and not contain any special character !"
-msgstr "El nom de l'objecte ha de començar amb x_ i no contenir cap caràcter especial!"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,description:base_sale_multichannels.module_meta_information
-msgid ""
-"\n"
-"This module provide an abstract common minimal base to multi-channels sales.\n"
-"Say you want to expose your product catalog to\n"
-"* several instances of flashy-sluggish Magento web sites\n"
-"* a cutting edge Spree web shop\n"
-"* a Neteven online Marketplace\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* an external Point Of Sale system\n"
-"* ...\n"
-"Then this module allows you to:\n"
-"* use several external references ids on every OpenERP object matching those all those external referentials\n"
-"* per referential instance, use several sale sub platform entities (ex: several Magento websites per instance)\n"
-"* per sub platform, use several shops (ex: several Magento web shops per website)\n"
-"\n"
-"For each sale shop (matching OpenERP sale.shop object), this module abstract the interfaces to:\n"
-"* export the catalog, shop warehouse stock level wise, shop pricelist wise\n"
-"* import the catalog\n"
-"* import orders\n"
-"* export orders/picking status\n"
-"    "
-msgstr ""
-"\n"
-"Aquest mòdul proporciona una mínima base d'abstracció comuna a diversos canals de vendes.\n"
-"Suposem que voleu exposar el vostre catàleg de productes a:\n"
-"* Diverses instàncies de botiga web de Magento\n"
-"* Una botiga web d'última generació Spree\n"
-"* Un mercat Neteven\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* Un sistema punt de venda extern\n"
-"* ...\n"
-"Llavors, aquest mòdul us permet:\n"
-"* L'ús de diverses referències externes a tots els identificadors d'objectes OpenERP que apunten a totes aquestes referències externes.\n"
-"* Referències per instància, l'ús de diverses sub entitats de vendes (per exemple diversos llocs web Magento per instància)\n"
-"* Referències per sub entitat, l'ús de diverses botigues (per exemple diverses botigues web Magento per lloc web)\n"
-"\n"
-"Per a cada botiga de venda (que es correspondrà a l'objecte sale.shop de OpenERP), aquest mòdul abstreu les interfícies de:\n"
-"* Exportar el catàleg, nivell d'estoc del magatzem de la botiga, tarifa de preus de la botiga\n"
-"* Importar el catàleg\n"
-"* Importar comandes\n"
-"* Exportar l'estat de les comandes/albarans\n"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,order_policy:0
-msgid "Shipping Policy"
-msgstr "Política de facturació"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "None"
-msgstr "Cap"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Shipped Quantities"
-msgstr "Quantitats enviades"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,referential_id:0
-msgid "Referential"
-msgstr "Referència"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Draft"
-msgstr "Esborrany"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_quantity:0
-msgid "The sale order will automatically create the invoice proposition (draft invoice). Ordered and delivered quantities may not be the same. You have to choose if you invoice based on ordered or shipped quantities. If the product is a service, shipped quantities means hours spent on the associated tasks."
-msgstr "La comanda de venda crearà automàticament la proposta de factura (factura esborrany). Les quantitats demanades i les quantitats enviades poden no ser les mateixes. Heu de decidir si factureu basat en quantitats demanades o enviades. Si el producte és un servei, quantitats enviades significa hores dedicades a les tasques associades."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,shop_group_id:0
-msgid "Shop Group"
-msgstr "Grup botigues"
-
-#. module: base_sale_multichannels
-#: field:product.category,recursive_childen_ids:0
-msgid "All Child Categories"
-msgstr "Totes categories filles"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Update Orders Status"
-msgstr "Actualitza estat comandes"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_policy:0
-msgid "If you don't have enough stock available to deliver all at once, do you accept partial shipments or not?"
-msgstr "Si no disposeu de suficient estoc disponible per a enviar-ho tot a la vegada, accepteu enviaments parcials?"
-
-#. module: base_sale_multichannels
-#: help:account.journal,external_payment_codes:0
-msgid "Enter the external payment codes, comma separated. They will be used to select the payment journal."
-msgstr "Indiqueu els codis de pagament externs, separats per coma. S'utilitzaran per a seleccionar el diari de pagament."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_policy:0
-msgid "Packing Policy"
-msgstr "Política d'enviament"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Complete Delivery"
-msgstr "Enviament complet"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_generation_policy:0
-msgid "Invoice Generation Policy"
-msgstr "Política generació de factures"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Ordered Quantities"
-msgstr "Quantitats ordenades"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,is_tax_included:0
-msgid "Requires sale_tax_include module to be installed"
-msgstr "Requereix que el mòdul sale_tax_include sigui instal·lat."
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Catalog"
-msgstr "Catàleg"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "External Shop Settings"
-msgstr "Configuració botiga externa"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Catalog"
-msgstr "Exporta catàleg"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice from the Packing"
-msgstr "Factura des d'albarà"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Order Generation"
-msgstr "Generació comanda"
-
-#. module: base_sale_multichannels
-#: field:account.journal,external_payment_codes:0
-msgid "External Payment Codes"
-msgstr "Codis de pagament externs"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice on Order After Delivery"
-msgstr "Factura comanda després de l'enviament"
-
-#. module: base_sale_multichannels
-#: constraint:ir.ui.view:0
-msgid "Invalid XML for View Architecture!"
-msgstr "XML invàlid per a la definició de la vista!"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,shop_ids:0
-msgid "Sale Shops"
-msgstr "Botigues venda"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,name:0
-msgid "Name"
-msgstr "Nom"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_quantity:0
-msgid "Invoice on"
-msgstr "Factura les"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,order_policy:0
-msgid ""
-"The Shipping Policy is used to synchronise invoice and delivery operations.\n"
-"  - The 'Pay before delivery' choice will first generate the invoice and then generate the packing order after the payment of this invoice.\n"
-"  - The 'Shipping & Manual Invoice' will create the packing order directly and wait for the user to manually click on the 'Invoice' button to generate the draft invoice.\n"
-"  - The 'Invoice on Order After Delivery' choice will generate the draft invoice based on sale order after all packing lists have been finished.\n"
-"  - The 'Invoice from the packing' choice is used to create an invoice during the packing process."
-msgstr ""
-"La política d'enviament s'utilitza per sincronitzar la factura i les operacions d'enviament.\n"
-"  - L'opció 'Pagament abans de l'enviament' primer genera la factura i després genera l'albarà al fer efectiu el pagament d'aquesta factura.\n"
-"  - L'opció 'Enviament' & Factura manual 'crearà l'albarà directament i esperarà que l'usuari faci clic manualment al botó' Factura 'per generar la factura esborrany.\n"
-"  - L'opció 'Factura segons comanda després enviament' generarà la factura esborrany basada en la comanda de venda després que tots els albarans es processin.\n"
-"  - L'opció 'Factura des d'albarà' s'utilitza per a crear una factura des dels albarans processats."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_inventory_export_date:0
-msgid "Last Inventory Export Time"
-msgstr "Data última exportació inventari"
-
-#. module: base_sale_multichannels
-#: field:external.referential,shop_group_ids:0
-msgid "Sub Entities"
-msgstr "Sub entitats"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,referential_id:0
-msgid "External Referential"
-msgstr "Referència externa"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Payment Before Delivery"
-msgstr "Pagament abans de l'enviament"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,shortdesc:base_sale_multichannels.module_meta_information
-msgid "Base Sale MultiChannels"
-msgstr "Base vendes multicanal"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-#: field:sale.shop,exportable_product_ids:0
-msgid "Exportable Products"
-msgstr "Productes exportables"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Import Orders"
-msgstr "Importa comandes"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_generation_policy:0
-msgid "Picking Generation Policy"
-msgstr "Política generació d'albarans"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_generation_policy:0
-msgid "Should orders create an invoice after import?"
-msgstr "Les comandes haurien de crear una factura després de la importació?"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_update_order_export_date:0
-msgid "Last Order Update  Time"
-msgstr "Data última actualització comandes"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_generation_policy:0
-msgid "Should orders create a picking after import?"
-msgstr "Les comandes haurien de crear un albarà després de la importació?"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Validated"
-msgstr "Validat"
-
-#. module: base_sale_multichannels
-#: model:ir.model,name:base_sale_multichannels.model_external_shop_group
-msgid "External Referential Shop Group"
-msgstr "Referència externa grup botigues"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Stock Levels Only"
-msgstr "Exporta només nivells d'estoc"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Shipping & Manual Invoice"
-msgstr "Envia & Factura manual"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Actions"
-msgstr "Accions"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,exportable_root_category_ids:0
-msgid "Root Category"
-msgstr "Categoria arrel"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,is_tax_included:0
-msgid "Prices Include Tax?"
-msgstr "Preus inclouen impostos?"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Shop"
-msgstr "Botiga venda"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Multi Channels"
-msgstr "Vendes Multi canal"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Orders"
-msgstr "Comandes"
-

=== removed file 'base_sale_multichannels/i18n/es.po'
--- base_sale_multichannels/i18n/es.po	2012-02-27 18:49:05 +0000
+++ base_sale_multichannels/i18n/es.po	1970-01-01 00:00:00 +0000
@@ -1,379 +0,0 @@
-# Translation of OpenERP Server.
-# This file contains the translation of the following modules:
-#	* base_sale_multichannels
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: OpenERP Server 5.0.6\n"
-"Report-Msgid-Bugs-To: support@xxxxxxxxxxx\n"
-"POT-Creation-Date: 2009-12-20 17:22+0000\n"
-"PO-Revision-Date: 2011-02-14 10:04+0000\n"
-"Last-Translator: Jordi Esteve (www.zikzakmedia.com) "
-"<jesteve@xxxxxxxxxxxxxxx>\n"
-"Language-Team: \n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2012-01-17 05:05+0000\n"
-"X-Generator: Launchpad (build 14676)\n"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Partial Delivery"
-msgstr "Envío parcial"
-
-#. module: base_sale_multichannels
-#: constraint:ir.model:0
-msgid ""
-"The Object name must start with x_ and not contain any special character !"
-msgstr ""
-"¡El nombre del objeto debe empezar con x_ y no contener ningún carácter "
-"especial!"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,description:base_sale_multichannels.module_meta_information
-msgid ""
-"\n"
-"This module provide an abstract common minimal base to multi-channels "
-"sales.\n"
-"Say you want to expose your product catalog to\n"
-"* several instances of flashy-sluggish Magento web sites\n"
-"* a cutting edge Spree web shop\n"
-"* a Neteven online Marketplace\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* an external Point Of Sale system\n"
-"* ...\n"
-"Then this module allows you to:\n"
-"* use several external references ids on every OpenERP object matching those "
-"all those external referentials\n"
-"* per referential instance, use several sale sub platform entities (ex: "
-"several Magento websites per instance)\n"
-"* per sub platform, use several shops (ex: several Magento web shops per "
-"website)\n"
-"\n"
-"For each sale shop (matching OpenERP sale.shop object), this module abstract "
-"the interfaces to:\n"
-"* export the catalog, shop warehouse stock level wise, shop pricelist wise\n"
-"* import the catalog\n"
-"* import orders\n"
-"* export orders/picking status\n"
-"    "
-msgstr ""
-"\n"
-"Este módulo proporciona una mínima base de abstracción común a varios "
-"canales de ventas.\n"
-"Supongamos que quiere exponer su catálogo de productos en:\n"
-"* Varias instancias de tiendas web de Magento\n"
-"* Una tienda web de última generación Spree\n"
-"* Un mercado Neteven\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* Un sistema punto de venta externo\n"
-"* ...\n"
-"Entonces, este módulo le permite:\n"
-"* El uso de varias referencias externas en todos los identificadores de "
-"objetos OpenERP que mapean todas estas referencias externas.\n"
-"* Referencias por instancia, el uso de varias subentidades de ventas (por "
-"ejemplo varios sitios web Magento por instancia)\n"
-"* Referencias por subentidad, el uso de varias tiendas (por ejemplo varias "
-"tiendas web Magento por sitio web)\n"
-"\n"
-"Para cada tienda de venta (que se corresponda al objeto sale.shop de "
-"OpenERP), este módulo abstrae las interfaces de:\n"
-"* Exportar el catálogo, nivel de stock del almacén de la tienda, tarifa de "
-"precios de la tienda\n"
-"* Importar el catálogo\n"
-"* Importar pedidos\n"
-"* Exportar el estado de pedidos/albaranes\n"
-"    "
-
-#. module: base_sale_multichannels
-#: field:sale.shop,order_policy:0
-msgid "Shipping Policy"
-msgstr "Política de facturación"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "None"
-msgstr "Ninguno/a"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Shipped Quantities"
-msgstr "Cantidades enviadas"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,referential_id:0
-msgid "Referential"
-msgstr "Referencia"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Draft"
-msgstr "Borrador"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_quantity:0
-msgid ""
-"The sale order will automatically create the invoice proposition (draft "
-"invoice). Ordered and delivered quantities may not be the same. You have to "
-"choose if you invoice based on ordered or shipped quantities. If the product "
-"is a service, shipped quantities means hours spent on the associated tasks."
-msgstr ""
-"El pedido de venta creará automáticamente la propuesta de factura (factura "
-"borrador). Las cantidades pedidas y las cantidades enviadas pueden no ser "
-"las mismas. Tiene que decidir si factura basado en cantidades pedidas o "
-"enviadas. Si el producto es un servicio, cantidades enviadas significa horas "
-"dedicadas a las tareas asociadas."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,shop_group_id:0
-msgid "Shop Group"
-msgstr "Grupo tiendas"
-
-#. module: base_sale_multichannels
-#: field:product.category,recursive_childen_ids:0
-msgid "All Child Categories"
-msgstr "Todas categorías hijas"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Update Orders Status"
-msgstr "Actualizar estado pedidos"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_policy:0
-msgid ""
-"If you don't have enough stock available to deliver all at once, do you "
-"accept partial shipments or not?"
-msgstr ""
-"Si no dispone de suficiente stock disponible para enviarlo todo a la vez, "
-"¿acepta envíos parciales?"
-
-#. module: base_sale_multichannels
-#: help:account.journal,external_payment_codes:0
-msgid ""
-"Enter the external payment codes, comma separated. They will be used to "
-"select the payment journal."
-msgstr ""
-"Indique los códigos de pago externos, separados por coma. Serán utilizados "
-"para seleccionar el diario de pago."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_policy:0
-msgid "Packing Policy"
-msgstr "Política de envío"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Complete Delivery"
-msgstr "Envío completo"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_generation_policy:0
-msgid "Invoice Generation Policy"
-msgstr "Política generación de facturas"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Ordered Quantities"
-msgstr "Cantidades ordenadas"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,is_tax_included:0
-msgid "Requires sale_tax_include module to be installed"
-msgstr "Requiere que el módulo sale_tax_include sea instalado."
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Catalog"
-msgstr "Catálogo"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "External Shop Settings"
-msgstr "Configuración tienda externa"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Catalog"
-msgstr "Exportar catálogo"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice from the Packing"
-msgstr "Factura desde albarán"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Order Generation"
-msgstr "Generación pedido"
-
-#. module: base_sale_multichannels
-#: field:account.journal,external_payment_codes:0
-msgid "External Payment Codes"
-msgstr "Códigos de pago externos"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice on Order After Delivery"
-msgstr "Facturar pedido después del envío"
-
-#. module: base_sale_multichannels
-#: constraint:ir.ui.view:0
-msgid "Invalid XML for View Architecture!"
-msgstr "¡XML inválido para la definición de la vista!"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,shop_ids:0
-msgid "Sale Shops"
-msgstr "Tiendas venta"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,name:0
-msgid "Name"
-msgstr "Nombre"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_quantity:0
-msgid "Invoice on"
-msgstr "Facturar las"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,order_policy:0
-msgid ""
-"The Shipping Policy is used to synchronise invoice and delivery operations.\n"
-"  - The 'Pay before delivery' choice will first generate the invoice and "
-"then generate the packing order after the payment of this invoice.\n"
-"  - The 'Shipping & Manual Invoice' will create the packing order directly "
-"and wait for the user to manually click on the 'Invoice' button to generate "
-"the draft invoice.\n"
-"  - The 'Invoice on Order After Delivery' choice will generate the draft "
-"invoice based on sale order after all packing lists have been finished.\n"
-"  - The 'Invoice from the packing' choice is used to create an invoice "
-"during the packing process."
-msgstr ""
-"La política de envío se utiliza para sincronizar la factura y las "
-"operaciones de envío.\n"
-"  - La opción 'Pago antes del envío' primero genera la factura y luego "
-"genera el albarán después del pago de esta factura.\n"
-"  - La opción 'Envío '& Factura manual' creará el albarán directamente y "
-"esperará a que el usuario haga clic manualmente en el botón 'Factura' para "
-"generar la factura borrador.\n"
-"  - La opción 'Factura según pedido después envío' generará la factura "
-"borrador basada en el pedido de venta después de que todos los albaranes se "
-"hayan procesado.\n"
-"  - La opción 'Factura desde albarán' se utiliza para crear una factura "
-"durante el proceso de los albaranes."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_inventory_export_date:0
-msgid "Last Inventory Export Time"
-msgstr "Fecha última exportación inventario"
-
-#. module: base_sale_multichannels
-#: field:external.referential,shop_group_ids:0
-msgid "Sub Entities"
-msgstr "Sub entidades"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,referential_id:0
-msgid "External Referential"
-msgstr "Referencia externa"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Payment Before Delivery"
-msgstr "Pago antes del envío"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,shortdesc:base_sale_multichannels.module_meta_information
-msgid "Base Sale MultiChannels"
-msgstr "Base ventas multicanal"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-#: field:sale.shop,exportable_product_ids:0
-msgid "Exportable Products"
-msgstr "Productos exportables"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Import Orders"
-msgstr "Importar pedidos"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_generation_policy:0
-msgid "Picking Generation Policy"
-msgstr "Política generación de albaranes"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_generation_policy:0
-msgid "Should orders create an invoice after import?"
-msgstr "¿Los pedidos deberían crear una factura después de la importación?"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_update_order_export_date:0
-msgid "Last Order Update  Time"
-msgstr "Fecha última actualización pedidos"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_generation_policy:0
-msgid "Should orders create a picking after import?"
-msgstr "¿Los pedidos deberían crear un albarán después de la importación?"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Validated"
-msgstr "Validado"
-
-#. module: base_sale_multichannels
-#: model:ir.model,name:base_sale_multichannels.model_external_shop_group
-msgid "External Referential Shop Group"
-msgstr "Referencia externa grupo tiendas"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Stock Levels Only"
-msgstr "Exportar sólo niveles de stock"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Shipping & Manual Invoice"
-msgstr "Enviar & Factura manual"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Actions"
-msgstr "Accions"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,exportable_root_category_ids:0
-msgid "Root Category"
-msgstr "Categoría raíz"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,is_tax_included:0
-msgid "Prices Include Tax?"
-msgstr "¿Precios incluyen impuestos?"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Shop"
-msgstr "Tienda venta"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Multi Channels"
-msgstr "Ventas Multi canal"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Orders"
-msgstr "Pedidos"

=== removed file 'base_sale_multichannels/i18n/fr.po'
--- base_sale_multichannels/i18n/fr.po	2012-02-27 18:49:05 +0000
+++ base_sale_multichannels/i18n/fr.po	1970-01-01 00:00:00 +0000
@@ -1,356 +0,0 @@
-# Translation of OpenERP Server.
-# This file contains the translation of the following modules:
-#	* base_sale_multichannels
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: OpenERP Server 6.1beta\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-12-20 17:22+0000\n"
-"PO-Revision-Date: 2011-12-05 12:42+0000\n"
-"Last-Translator: OpenERP Administrators <Unknown>\n"
-"Language-Team: \n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2012-01-17 05:05+0000\n"
-"X-Generator: Launchpad (build 14676)\n"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Partial Delivery"
-msgstr "Livraison Partielle"
-
-#. module: base_sale_multichannels
-#: constraint:ir.model:0
-msgid ""
-"The Object name must start with x_ and not contain any special character !"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,description:base_sale_multichannels.module_meta_information
-msgid ""
-"\n"
-"This module provide an abstract common minimal base to multi-channels "
-"sales.\n"
-"Say you want to expose your product catalog to\n"
-"* several instances of flashy-sluggish Magento web sites\n"
-"* a cutting edge Spree web shop\n"
-"* a Neteven online Marketplace\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* an external Point Of Sale system\n"
-"* ...\n"
-"Then this module allows you to:\n"
-"* use several external references ids on every OpenERP object matching those "
-"all those external referentials\n"
-"* per referential instance, use several sale sub platform entities (ex: "
-"several Magento websites per instance)\n"
-"* per sub platform, use several shops (ex: several Magento web shops per "
-"website)\n"
-"\n"
-"For each sale shop (matching OpenERP sale.shop object), this module abstract "
-"the interfaces to:\n"
-"* export the catalog, shop warehouse stock level wise, shop pricelist wise\n"
-"* import the catalog\n"
-"* import orders\n"
-"* export orders/picking status\n"
-"    "
-msgstr ""
-"\n"
-"Ce module fourni une couche d'abstracion minimale pour les ventes en multi-"
-"canaux.\n"
-"Vous voulez exposer votre catalogue produits sur\n"
-"* plusieurs instances de sites web magento\n"
-"* une boutique en ligne Spree d'avant garde\n"
-"* un marché en ligne Neteven\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* un système de point de vente externe\n"
-"* ...\n"
-"Ce module vous permet donc:\n"
-"* d'utiliser plusieurs identifiants externes dans tout les objets OpenERP "
-"correspondant entre eux use several external references ids on every OpenERP "
-"object matching those all those external referentials\n"
-"* par instance référentielle, d'utiliser plusieurs entités de sous "
-"plateforme de vente (ex: plusieurs sites web Magento par instance)\n"
-"* par sous plateforme, d'utiliser plusieurs boutiques (ex: plusieurs "
-"boutiques en ligne Magento par site web)\n"
-"\n"
-"Pour chaque boutique de vente (correspondant aux objets OpenERP sale.shop), "
-"ce module extrait les interfaces pour:\n"
-"* exporter le catalogue, le niveau de stock du magasin, les listes de prix "
-"du magasin\n"
-"* importer le catalogue\n"
-"* importer les commandes\n"
-"* exporter les commandes/status picking\n"
-"    "
-
-#. module: base_sale_multichannels
-#: field:sale.shop,order_policy:0
-msgid "Shipping Policy"
-msgstr "Politique d'expédition"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "None"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Shipped Quantities"
-msgstr "Quantités Expédiées"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,referential_id:0
-msgid "Referential"
-msgstr "Référentiel"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Draft"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_quantity:0
-msgid ""
-"The sale order will automatically create the invoice proposition (draft "
-"invoice). Ordered and delivered quantities may not be the same. You have to "
-"choose if you invoice based on ordered or shipped quantities. If the product "
-"is a service, shipped quantities means hours spent on the associated tasks."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,shop_group_id:0
-msgid "Shop Group"
-msgstr "Groupe de Magasin"
-
-#. module: base_sale_multichannels
-#: field:product.category,recursive_childen_ids:0
-msgid "All Child Categories"
-msgstr "Toute les Catégories Enfant"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Update Orders Status"
-msgstr "Mettre à Jour les Status des Commmandes"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_policy:0
-msgid ""
-"If you don't have enough stock available to deliver all at once, do you "
-"accept partial shipments or not?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:account.journal,external_payment_codes:0
-msgid ""
-"Enter the external payment codes, comma separated. They will be used to "
-"select the payment journal."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_policy:0
-msgid "Packing Policy"
-msgstr "Politique d'Emballage"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Complete Delivery"
-msgstr "Livraison Complète"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_generation_policy:0
-msgid "Invoice Generation Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Ordered Quantities"
-msgstr "Quantités Commandées"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,is_tax_included:0
-msgid "Requires sale_tax_include module to be installed"
-msgstr "Requière le module sale_tax_include pour pouvoir être installé"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Catalog"
-msgstr "Catalogue"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "External Shop Settings"
-msgstr "Paramètres du Magasin Externe"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Catalog"
-msgstr "Exporter le Catalogue"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice from the Packing"
-msgstr "Facture de l'emballage"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Order Generation"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:account.journal,external_payment_codes:0
-msgid "External Payment Codes"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice on Order After Delivery"
-msgstr "Facture sur Commande Après Livraison"
-
-#. module: base_sale_multichannels
-#: constraint:ir.ui.view:0
-msgid "Invalid XML for View Architecture!"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,shop_ids:0
-msgid "Sale Shops"
-msgstr "Magasins de Vente"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,name:0
-msgid "Name"
-msgstr "Nom"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_quantity:0
-msgid "Invoice on"
-msgstr "Facture sur"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,order_policy:0
-msgid ""
-"The Shipping Policy is used to synchronise invoice and delivery operations.\n"
-"  - The 'Pay before delivery' choice will first generate the invoice and "
-"then generate the packing order after the payment of this invoice.\n"
-"  - The 'Shipping & Manual Invoice' will create the packing order directly "
-"and wait for the user to manually click on the 'Invoice' button to generate "
-"the draft invoice.\n"
-"  - The 'Invoice on Order After Delivery' choice will generate the draft "
-"invoice based on sale order after all packing lists have been finished.\n"
-"  - The 'Invoice from the packing' choice is used to create an invoice "
-"during the packing process."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_inventory_export_date:0
-msgid "Last Inventory Export Time"
-msgstr "Date du Dernier Export d'Inventaire"
-
-#. module: base_sale_multichannels
-#: field:external.referential,shop_group_ids:0
-msgid "Sub Entities"
-msgstr "Sous Entité"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,referential_id:0
-msgid "External Referential"
-msgstr "Référentiel Externe"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Payment Before Delivery"
-msgstr "Paiement Avant Livraison"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,shortdesc:base_sale_multichannels.module_meta_information
-msgid "Base Sale MultiChannels"
-msgstr "Ventes en Multi Canaux"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-#: field:sale.shop,exportable_product_ids:0
-msgid "Exportable Products"
-msgstr "Produits Exportables"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Import Orders"
-msgstr "Import des Commandes"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_generation_policy:0
-msgid "Picking Generation Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_generation_policy:0
-msgid "Should orders create an invoice after import?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_update_order_export_date:0
-msgid "Last Order Update  Time"
-msgstr "Date de la dernière mise à jour des commandes"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_generation_policy:0
-msgid "Should orders create a picking after import?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Validated"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.model,name:base_sale_multichannels.model_external_shop_group
-msgid "External Referential Shop Group"
-msgstr "Référence Externe du Groupe de Magasin"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Stock Levels Only"
-msgstr "Export des niveaux de Stock Seulement"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Shipping & Manual Invoice"
-msgstr "Expédition et Facture Manuelle"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Actions"
-msgstr "Actions"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,exportable_root_category_ids:0
-msgid "Root Category"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,is_tax_included:0
-msgid "Prices Include Tax?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Shop"
-msgstr "Magasin de Vente"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Multi Channels"
-msgstr "Vente Multi Canaux"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Orders"
-msgstr "Commandes"

=== removed file 'base_sale_multichannels/i18n/pt.po'
--- base_sale_multichannels/i18n/pt.po	2012-02-27 18:49:05 +0000
+++ base_sale_multichannels/i18n/pt.po	1970-01-01 00:00:00 +0000
@@ -1,379 +0,0 @@
-# Portuguese translation for openobject-addons
-# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011
-# This file is distributed under the same license as the openobject-addons package.
-# FIRST AUTHOR <EMAIL@ADDRESS>, 2011.
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: openobject-addons\n"
-"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
-"POT-Creation-Date: 2009-12-20 17:22+0000\n"
-"PO-Revision-Date: 2011-02-14 10:04+0000\n"
-"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
-"Language-Team: Portuguese <pt@xxxxxx>\n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2012-01-17 05:05+0000\n"
-"X-Generator: Launchpad (build 14676)\n"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Partial Delivery"
-msgstr "Entrega Parcial"
-
-#. module: base_sale_multichannels
-#: constraint:ir.model:0
-msgid ""
-"The Object name must start with x_ and not contain any special character !"
-msgstr ""
-"O nome do Objecto deve começar com x_ e não pode conter nenhum caracter "
-"especial !"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,description:base_sale_multichannels.module_meta_information
-msgid ""
-"\n"
-"This module provide an abstract common minimal base to multi-channels "
-"sales.\n"
-"Say you want to expose your product catalog to\n"
-"* several instances of flashy-sluggish Magento web sites\n"
-"* a cutting edge Spree web shop\n"
-"* a Neteven online Marketplace\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* an external Point Of Sale system\n"
-"* ...\n"
-"Then this module allows you to:\n"
-"* use several external references ids on every OpenERP object matching those "
-"all those external referentials\n"
-"* per referential instance, use several sale sub platform entities (ex: "
-"several Magento websites per instance)\n"
-"* per sub platform, use several shops (ex: several Magento web shops per "
-"website)\n"
-"\n"
-"For each sale shop (matching OpenERP sale.shop object), this module abstract "
-"the interfaces to:\n"
-"* export the catalog, shop warehouse stock level wise, shop pricelist wise\n"
-"* import the catalog\n"
-"* import orders\n"
-"* export orders/picking status\n"
-"    "
-msgstr ""
-"\n"
-"Este módulo fornece uma base comum mínima abstrata para vendas multi-"
-"canais.\n"
-"Digamos que queira expor o seu catálogo de produto para\n"
-"* várias instâncias de wev sites Magento flashy-sluggish\n"
-"* Uma loja online Spree de ponta\n"
-"* Uma Mercado Local online de Neteven\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* um sistema externo de Ponto de Venda\n"
-"* ...\n"
-"Então, este módulo permite-lhe fazer:\n"
-"* utilizar vários id externos de referência em cada objecto OpenERP "
-"correspondente a todas as referências externas\n"
-"* por referência de instância utilizar várias entradas de sub-plantaformas "
-"de vendas (ex: várias páginas web Magento por instância)\n"
-"* por sub-plantaforma, utilizar várias lojas (ec: várias lojas web Magento "
-"por página web)\n"
-"\n"
-"Para cada loja de venda (sale.shop.object correspondente OpenERP), este "
-"módulo abstrata as interfaces para:\n"
-"* exportar o catálogo,nível sensato de stock no armazém da loja, lista de "
-"preço justo da loja \n"
-"* importar o catálogo\n"
-"* importar ordens\n"
-"* exportar ordens/estado da recolha\n"
-"    "
-
-#. module: base_sale_multichannels
-#: field:sale.shop,order_policy:0
-msgid "Shipping Policy"
-msgstr "Política de Expedição"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "None"
-msgstr "Nenhum"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Shipped Quantities"
-msgstr "Quantidades Enviadas"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,referential_id:0
-msgid "Referential"
-msgstr "Referencial"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Draft"
-msgstr "Rascunho"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_quantity:0
-msgid ""
-"The sale order will automatically create the invoice proposition (draft "
-"invoice). Ordered and delivered quantities may not be the same. You have to "
-"choose if you invoice based on ordered or shipped quantities. If the product "
-"is a service, shipped quantities means hours spent on the associated tasks."
-msgstr ""
-"A ordem de venda vai automáticamente criar uma proposta de factura (factura "
-"de rascunho). Quantidades entregues e ordenadas podem não ser a mesma. Vai "
-"ter que escolher se a sua factura é baseada em ordenada ou quantidades "
-"enviadas. Se o produto é um serviço, quantidades enviadas significa horas "
-"gastas nas tarefas associadas."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,shop_group_id:0
-msgid "Shop Group"
-msgstr "Grupo de Loja"
-
-#. module: base_sale_multichannels
-#: field:product.category,recursive_childen_ids:0
-msgid "All Child Categories"
-msgstr "Todas as Categorias Descendentes"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Update Orders Status"
-msgstr "Estado das Ordens Actualizadas"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_policy:0
-msgid ""
-"If you don't have enough stock available to deliver all at once, do you "
-"accept partial shipments or not?"
-msgstr ""
-"Se não tiver stock sufeciente desponível para entregar de uma vez, aceita "
-"transferência parciais ou não?"
-
-#. module: base_sale_multichannels
-#: help:account.journal,external_payment_codes:0
-msgid ""
-"Enter the external payment codes, comma separated. They will be used to "
-"select the payment journal."
-msgstr ""
-"Entrar com os códigos de pagamento externo, vírgula separada. Eles serão "
-"utilizados para selecionar o diário de pagamento."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_policy:0
-msgid "Packing Policy"
-msgstr "Política de Embalagem"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Complete Delivery"
-msgstr "Entrega completa"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_generation_policy:0
-msgid "Invoice Generation Policy"
-msgstr "Politica de Geração de Factura"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Ordered Quantities"
-msgstr "Quantidades Ordenadas"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,is_tax_included:0
-msgid "Requires sale_tax_include module to be installed"
-msgstr "Requere que o módulo sale_tax_include seja instalado"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Catalog"
-msgstr "Catálogo"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "External Shop Settings"
-msgstr "Definições da Loja Externa"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Catalog"
-msgstr "Exportar Catálogo"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice from the Packing"
-msgstr "Factura de Embalagem"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Order Generation"
-msgstr "Ordem de Geração"
-
-#. module: base_sale_multichannels
-#: field:account.journal,external_payment_codes:0
-msgid "External Payment Codes"
-msgstr "Códigos de Pagamento Externo"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice on Order After Delivery"
-msgstr "Ordem Facturada Antes da Entrega"
-
-#. module: base_sale_multichannels
-#: constraint:ir.ui.view:0
-msgid "Invalid XML for View Architecture!"
-msgstr "XML Inválido para a Arquitectura de Vista!"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,shop_ids:0
-msgid "Sale Shops"
-msgstr "Lojas de Vendas"
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,name:0
-msgid "Name"
-msgstr "Nome"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_quantity:0
-msgid "Invoice on"
-msgstr "Facturado em"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,order_policy:0
-msgid ""
-"The Shipping Policy is used to synchronise invoice and delivery operations.\n"
-"  - The 'Pay before delivery' choice will first generate the invoice and "
-"then generate the packing order after the payment of this invoice.\n"
-"  - The 'Shipping & Manual Invoice' will create the packing order directly "
-"and wait for the user to manually click on the 'Invoice' button to generate "
-"the draft invoice.\n"
-"  - The 'Invoice on Order After Delivery' choice will generate the draft "
-"invoice based on sale order after all packing lists have been finished.\n"
-"  - The 'Invoice from the packing' choice is used to create an invoice "
-"during the packing process."
-msgstr ""
-"A Políca de Entrega é utilizada para sincronizar a factura e as operações de "
-"entrega.\n"
-"   - A escolha 'Pagar antes de entregar' vai gerar a factura e em seguida "
-"gerar uma ordem de embalagem depois do pagamento desta factura.\n"
-"   - O 'Envio & Factura Manual' vai criar directamente a ordem de embalagem "
-"e esperar para que o utilizador clique manualmente no botão 'factura' para "
-"gerar uma factura rascunho.\n"
-"   - A escolha 'Factura em Ordem Antes da Entrega' vai gerar uma factura "
-"rascunho baseada na ordem de venda depois de todas as listas de embalagem "
-"tenham terminado.\n"
-"   - A escolha 'Factura a partir da embalagem' é utilizada para criar uma "
-"factura durante o processo de embalagem."
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_inventory_export_date:0
-msgid "Last Inventory Export Time"
-msgstr "Último Inventário de Exportação de Tempo"
-
-#. module: base_sale_multichannels
-#: field:external.referential,shop_group_ids:0
-msgid "Sub Entities"
-msgstr "Sub Movimentos"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,referential_id:0
-msgid "External Referential"
-msgstr "Referencial Externa"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Payment Before Delivery"
-msgstr "Pagamento Antes da Entrega"
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,shortdesc:base_sale_multichannels.module_meta_information
-msgid "Base Sale MultiChannels"
-msgstr "Venda Base de Multi-Canais"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-#: field:sale.shop,exportable_product_ids:0
-msgid "Exportable Products"
-msgstr "Produtos Exportados"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Import Orders"
-msgstr "Importar Ordem"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_generation_policy:0
-msgid "Picking Generation Policy"
-msgstr "Política de Recolha de Geração"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_generation_policy:0
-msgid "Should orders create an invoice after import?"
-msgstr "As ordens devem criar uma factura depois da importação?"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_update_order_export_date:0
-msgid "Last Order Update  Time"
-msgstr "Última Actualização da Ordem Tempo"
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_generation_policy:0
-msgid "Should orders create a picking after import?"
-msgstr "As ordens devem criar uma recolha depois da importação?"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Validated"
-msgstr "Validado"
-
-#. module: base_sale_multichannels
-#: model:ir.model,name:base_sale_multichannels.model_external_shop_group
-msgid "External Referential Shop Group"
-msgstr "Referencia Externa Grupo de Loja"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Stock Levels Only"
-msgstr "Exportar Somente os Níveis de Stock"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Shipping & Manual Invoice"
-msgstr "Expedição e Factura Manual"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Actions"
-msgstr "Acção"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,exportable_root_category_ids:0
-msgid "Root Category"
-msgstr "Categoria Raíz"
-
-#. module: base_sale_multichannels
-#: field:sale.shop,is_tax_included:0
-msgid "Prices Include Tax?"
-msgstr "Preços Incluem Impostos?"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Shop"
-msgstr "Loja de Venda"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Multi Channels"
-msgstr "Venda Multi Canais"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Orders"
-msgstr "Ordem"

=== removed file 'base_sale_multichannels/i18n/sv.po'
--- base_sale_multichannels/i18n/sv.po	2012-02-27 18:49:05 +0000
+++ base_sale_multichannels/i18n/sv.po	1970-01-01 00:00:00 +0000
@@ -1,327 +0,0 @@
-# Translation of OpenERP Server.
-# This file contains the translation of the following modules:
-#	* base_sale_multichannels
-#
-msgid ""
-msgstr ""
-"Project-Id-Version: OpenERP Server 5.0.14\n"
-"Report-Msgid-Bugs-To: support@xxxxxxxxxxx\n"
-"POT-Creation-Date: 2009-12-20 17:22+0000\n"
-"PO-Revision-Date: 2011-02-14 11:51+0000\n"
-"Last-Translator: Olivier Dony (OpenERP) <Unknown>\n"
-"Language-Team: \n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2012-01-17 05:05+0000\n"
-"X-Generator: Launchpad (build 14676)\n"
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Partial Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: constraint:ir.model:0
-msgid ""
-"The Object name must start with x_ and not contain any special character !"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,description:base_sale_multichannels.module_meta_information
-msgid ""
-"\n"
-"This module provide an abstract common minimal base to multi-channels "
-"sales.\n"
-"Say you want to expose your product catalog to\n"
-"* several instances of flashy-sluggish Magento web sites\n"
-"* a cutting edge Spree web shop\n"
-"* a Neteven online Marketplace\n"
-"* EBay\n"
-"* Amazon\n"
-"* Google Base\n"
-"* an external Point Of Sale system\n"
-"* ...\n"
-"Then this module allows you to:\n"
-"* use several external references ids on every OpenERP object matching those "
-"all those external referentials\n"
-"* per referential instance, use several sale sub platform entities (ex: "
-"several Magento websites per instance)\n"
-"* per sub platform, use several shops (ex: several Magento web shops per "
-"website)\n"
-"\n"
-"For each sale shop (matching OpenERP sale.shop object), this module abstract "
-"the interfaces to:\n"
-"* export the catalog, shop warehouse stock level wise, shop pricelist wise\n"
-"* import the catalog\n"
-"* import orders\n"
-"* export orders/picking status\n"
-"    "
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,order_policy:0
-msgid "Shipping Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "None"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Shipped Quantities"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,referential_id:0
-msgid "Referential"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Draft"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_quantity:0
-msgid ""
-"The sale order will automatically create the invoice proposition (draft "
-"invoice). Ordered and delivered quantities may not be the same. You have to "
-"choose if you invoice based on ordered or shipped quantities. If the product "
-"is a service, shipped quantities means hours spent on the associated tasks."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,shop_group_id:0
-msgid "Shop Group"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:product.category,recursive_childen_ids:0
-msgid "All Child Categories"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Update Orders Status"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_policy:0
-msgid ""
-"If you don't have enough stock available to deliver all at once, do you "
-"accept partial shipments or not?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:account.journal,external_payment_codes:0
-msgid ""
-"Enter the external payment codes, comma separated. They will be used to "
-"select the payment journal."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_policy:0
-msgid "Packing Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,picking_policy:0
-msgid "Complete Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_generation_policy:0
-msgid "Invoice Generation Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_quantity:0
-msgid "Ordered Quantities"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,is_tax_included:0
-msgid "Requires sale_tax_include module to be installed"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Catalog"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "External Shop Settings"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Catalog"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice from the Packing"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Order Generation"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:account.journal,external_payment_codes:0
-msgid "External Payment Codes"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Invoice on Order After Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: constraint:ir.ui.view:0
-msgid "Invalid XML for View Architecture!"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,shop_ids:0
-msgid "Sale Shops"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.shop.group,name:0
-msgid "Name"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,invoice_quantity:0
-msgid "Invoice on"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,order_policy:0
-msgid ""
-"The Shipping Policy is used to synchronise invoice and delivery operations.\n"
-"  - The 'Pay before delivery' choice will first generate the invoice and "
-"then generate the packing order after the payment of this invoice.\n"
-"  - The 'Shipping & Manual Invoice' will create the packing order directly "
-"and wait for the user to manually click on the 'Invoice' button to generate "
-"the draft invoice.\n"
-"  - The 'Invoice on Order After Delivery' choice will generate the draft "
-"invoice based on sale order after all packing lists have been finished.\n"
-"  - The 'Invoice from the packing' choice is used to create an invoice "
-"during the packing process."
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_inventory_export_date:0
-msgid "Last Inventory Export Time"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:external.referential,shop_group_ids:0
-msgid "Sub Entities"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,referential_id:0
-msgid "External Referential"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Payment Before Delivery"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.module.module,shortdesc:base_sale_multichannels.module_meta_information
-msgid "Base Sale MultiChannels"
-msgstr "Base Sale MultiChannels"
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-#: field:sale.shop,exportable_product_ids:0
-msgid "Exportable Products"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Import Orders"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,picking_generation_policy:0
-msgid "Picking Generation Policy"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,invoice_generation_policy:0
-msgid "Should orders create an invoice after import?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,last_update_order_export_date:0
-msgid "Last Order Update  Time"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: help:sale.shop,picking_generation_policy:0
-msgid "Should orders create a picking after import?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,invoice_generation_policy:0
-#: selection:sale.shop,picking_generation_policy:0
-msgid "Validated"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: model:ir.model,name:base_sale_multichannels.model_external_shop_group
-msgid "External Referential Shop Group"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Export Stock Levels Only"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: selection:sale.shop,order_policy:0
-msgid "Shipping & Manual Invoice"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Actions"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,exportable_root_category_ids:0
-msgid "Root Category"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: field:sale.shop,is_tax_included:0
-msgid "Prices Include Tax?"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Shop"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Sale Multi Channels"
-msgstr ""
-
-#. module: base_sale_multichannels
-#: view:sale.shop:0
-msgid "Orders"
-msgstr ""

=== removed file 'base_sale_multichannels/partner.py'
--- base_sale_multichannels/partner.py	2012-12-26 13:34:03 +0000
+++ base_sale_multichannels/partner.py	1970-01-01 00:00:00 +0000
@@ -1,54 +0,0 @@
-# -*- encoding: utf-8 -*-
-#################################################################################
-#                                                                               #
-#    base_sale_multichannels for OpenERP                                        #
-#    Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>   #
-#                                                                               #
-#    This program is free software: you can redistribute it and/or modify       #
-#    it under the terms of the GNU Affero General Public License as             #
-#    published by the Free Software Foundation, either version 3 of the         #
-#    License, or (at your option) any later version.                            #
-#                                                                               #
-#    This program is distributed in the hope that it will be useful,            #
-#    but WITHOUT ANY WARRANTY; without even the implied warranty of             #
-#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              #
-#    GNU Affero General Public License for more details.                        #
-#                                                                               #
-#    You should have received a copy of the GNU Affero General Public License   #
-#    along with this program.  If not, see <http://www.gnu.org/licenses/>.      #
-#                                                                               #
-#################################################################################
-
-from openerp.osv.orm import Model
-from openerp.osv import fields
-
-
-class res_partner(Model):
-    _inherit='res.partner'
-
-    _columns = {
-        # defaults_shop_id is deprecated... we should not use it any more !
-        'defaults_shop_id': fields.many2one('sale.shop', 'Sale Shop', help="This is the default shop of the customer"),
-        'shop_ids': fields.many2many('sale.shop', 'sale_shop_res_partner_rel', 'shop_id', 'partner_id', 'Present in Shops', readonly=True, help="List of shops in which this customer exists."),
-    }
-
-    # xxx move to BaseConnector _get_import_defaults_res_partner
-    def _get_default_import_values(self, cr, uid, external_session, mapping_id=None, defaults=None, context=None):
-        if external_session.sync_from_object._name == 'sale.shop':
-            shop = external_session.sync_from_object
-            if not defaults: defaults = {}
-            defaults.update({
-                'lang': shop.default_customer_lang.code,
-                'property_account_position': shop.default_fiscal_position.id,
-                'property_account_receivable': shop.default_customer_account,
-                'shop_ids': [(4, shop.id)],
-            })
-        return defaults
-
-class res_partner_address(Model):
-    _inherit='res.partner.address'
-
-    def _transform_one_resource(self, *args, **kwargs):
-        if kwargs.get('parent_data') and kwargs['parent_data'].get('partner_id'):
-            kwargs['defaults']['partner_id'] = kwargs['parent_data']['parent_id']
-        return super(res_partner_address, self)._transform_one_resource(*args, **kwargs)

=== removed file 'base_sale_multichannels/partner_view.xml'
--- base_sale_multichannels/partner_view.xml	2012-09-26 10:22:02 +0000
+++ base_sale_multichannels/partner_view.xml	1970-01-01 00:00:00 +0000
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-
-<!--
-    Copyright (C) 2012 Akretion (http://www.akretion.com/)
-    @author Alexis de Lattre <alexis.delattre@xxxxxxxxxxxx>
-    The licence is in the file __openerp__.py
--->
-
-<openerp>
-<data>
-
-
-<record id="shop_ids_partner_form" model="ir.ui.view">
-    <field name="name">shop_ids.partner.form</field>
-    <field name="model">res.partner</field>
-    <field name="inherit_id" ref="base.view_partner_form" />
-    <field name="arch" type="xml">
-        <page string="History" position="after">
-            <page string="Shops">
-                <field name="shop_ids" nolabel="1" colspan="4" />
-            </page>
-        </page>
-    </field>
-</record>
-
-
-</data>
-</openerp>

=== removed file 'base_sale_multichannels/sale.py'
--- base_sale_multichannels/sale.py	2013-01-14 07:40:50 +0000
+++ base_sale_multichannels/sale.py	1970-01-01 00:00:00 +0000
@@ -1,971 +0,0 @@
-# -*- encoding: utf-8 -*-
-#########################################################################
-#                                                                       #
-# Copyright (C) 2009  Raphaël Valyi                                     #
-# Copyright (C) 2010-2011 Akretion Sébastien BEAU                       #
-#                                        <sebastien.beau@xxxxxxxxxxxx>  #
-# Copyright (C) 2011-2012 Camptocamp Guewen Baconnier                   #
-# Copyright (C) 2011 by Openlabs Technologies & Consulting (P) Limited  #
-#                                                                       #
-#This program is free software: you can redistribute it and/or modify   #
-#it under the terms of the GNU General Public License as published by   #
-#the Free Software Foundation, either version 3 of the License, or      #
-#(at your option) any later version.                                    #
-#                                                                       #
-#This program is distributed in the hope that it will be useful,        #
-#but WITHOUT ANY WARRANTY; without even the implied warranty of         #
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          #
-#GNU General Public License for more details.                           #
-#                                                                       #
-#You should have received a copy of the GNU General Public License      #
-#along with this program.  If not, see <http://www.gnu.org/licenses/>.  #
-#########################################################################
-
-from openerp.osv.orm import Model
-from openerp.osv import fields
-from openerp.osv.osv import except_osv
-import pooler
-from sets import Set as set
-import netsvc
-from tools.translate import _
-import time
-import decimal_precision as dp
-from datetime import datetime, timedelta
-from dateutil.relativedelta import relativedelta
-from tools import DEFAULT_SERVER_DATETIME_FORMAT, DEFAULT_SERVER_DATE_FORMAT
-from base_external_referentials.external_osv import ExternalSession
-from base_external_referentials.decorator import open_report
-from base_external_referentials.decorator import catch_error_in_report
-
-#TODO use external_session.logger when it's posible
-import logging
-_logger = logging.getLogger(__name__)
-
-
-class StockPicking(Model):
-    '''Add a flag for marking picking as exported'''
-    _inherit = 'stock.picking'
-
-    _columns = {
-        'exported_to_magento': fields.boolean('Exported to Magento',
-            readonly=True),
-    }
-
-
-class external_shop_group(Model):
-    _name = 'external.shop.group'
-    _description = 'External Referential Shop Group'
-
-    _columns = {
-        'name': fields.char('Name', size=64, required=True),
-        'referential_id': fields.many2one('external.referential', 'Referential', select=True,
-                                                                             ondelete='cascade'),
-        'shop_ids': fields.one2many('sale.shop', 'shop_group_id', 'Sale Shops'),
-    }
-
-    # xxx move to BaseConnector _get_import_defaults_external_shop_group
-    def _get_default_import_values(self, cr, uid, external_session, **kwargs):
-        return {'referential_id' : external_session.referential_id.id}
-
-
-class external_referential(Model):
-    _inherit = 'external.referential'
-
-    _columns = {
-        'shop_group_ids': fields.one2many('external.shop.group', 'referential_id', 'Sub Entities'),
-    }
-
-
-
-class ExternalShippingCreateError(Exception):
-     """
-      This error has to be raised when we tried to create a stock.picking on
-      the external referential and the external referential has failed
-      to create it. It must be raised only when we are SURE that the
-      external referential will never be able to create it!
-     """
-     pass
-
-
-class sale_shop(Model):
-    _inherit = "sale.shop"
-
-    def _get_exportable_category_ids(self, cr, uid, ids, name, args, context=None):
-        res = {}
-        for shop in self.browse(cr, uid, ids, context=context):
-            res[shop.id] = set()
-            for category in shop.exportable_root_category_ids:
-                res[shop.id] = res[shop.id].union(set(self.pool.get('product.category')._get_recursive_children_ids(cr, uid, [category.id], "", [], context)[category.id]))
-            res[shop.id] = list(res[shop.id])
-        return res
-
-    def _get_exportable_product_ids(self, cr, uid, ids, name, args, context=None):
-        res = {}
-        for shop in self.read(cr, uid, ids, ['exportable_category_ids'], context=context):
-            all_categories = shop['exportable_category_ids']
-
-            # If product_m2mcategories module is installed search in main category
-            # and extra categories. If not, only in main category
-            cr.execute('select * from ir_module_module where name=%s and state=%s',
-                                                            ('product_m2mcategories','installed'))
-            if cr.fetchone():
-                res[shop['id']] = self.pool.get("product.product").search(cr, uid, ['|',
-                        ('categ_id', 'in', all_categories),('categ_ids', 'in', all_categories)])
-            else:
-                res[shop['id']] = self.pool.get("product.product").search(cr, uid,
-                                                            [('categ_id', 'in', all_categories)])
-        return res
-
-    def _get_referential_id(self, cr, uid, ids, name, args, context=None):
-        res = {}
-        for shop in self.browse(cr, uid, ids, context=context):
-            if shop.shop_group_id:
-                res[shop.id] = shop.shop_group_id.referential_id.id
-            else:
-                res[shop.id] = shop.referential_integer_id
-        return res
-
-    def _get_shop_from_shop_group(self, cr, uid, ids, context=None):
-        return self.pool.get('sale.shop').search(cr, uid, [('shop_group_id', 'in', ids)], context=context)
-
-    def _set_referential_id(self, cr, uid, id, name, value, arg, context=None):
-        shop = self.browse(cr, uid, id, context=context)
-        if shop.shop_group_id:
-            raise except_osv(_("User Error"), _("You can not change the referential of this shop, please change the referential of the shop group!"))
-        else:
-            self.write(cr, uid, id, {'referential_integer_id': value}, context=context)
-        return True
-
-    def _get_shop_ids(self, cr, uid, ids, context=None):
-        shop_ids=[]
-        for group in self.pool.get('external.shop.group').browse(cr, uid, ids, context=context):
-            shop_ids += [shop.id for shop in group.shop_ids]
-        return shop_ids
-
-    def _get_stock_field_id(self, cr, uid, context=None):
-        if self.pool.get('ir.module.module').search(cr, uid, [
-                    ['name', '=', 'stock_available_immediately'],
-                    ['state', 'in', ['installed', 'to upgrade']],
-                                            ], context=context):
-            stock_field = 'immediately_usable_qty'
-        else:
-            stock_field = 'virtual_available'
-
-        field_ids = self.pool.get('ir.model.fields').search(
-            cr, uid,
-            [('model', '=', 'product.product'),
-             ('name', '=', stock_field)],
-            context=context)
-        return field_ids[0]
-
-    #Depending of the e-commerce solution use you can have one or more root category
-    #If you need only one the value will be stored in the exportable_root_category_ids fields
-    def _get_rootcategory(self, cr, uid, ids, name, value, context=None):
-        res = {}
-        for shop in self.browse(cr, uid, ids, context):
-            res[shop.id] = shop.exportable_root_category_ids and shop.exportable_root_category_ids[0].id or False
-        return res
-
-    def _set_rootcategory(self, cr, uid, id, name, value, fnct_inv_arg, context=None):
-        return self.write(cr, uid, id, {'exportable_root_category_ids': [(6,0,[value])]}, context=context)
-
-    def _get_referential_type_name(self, cr, uid, ids, field_name, arg, context=None):
-        result = {}
-        for shop in self.browse(cr, uid, ids):
-            if shop.referential_id:
-                result[shop.id] = shop.referential_id.type_id.name
-            else:
-                result[shop.id] = False
-        return result
-
-    _columns = {
-        'exportable_category_ids': fields.function(_get_exportable_category_ids, type='many2many', relation="product.category", string='Exportable Categories'),
-        'exportable_root_category_ids': fields.many2many('product.category', 'shop_category_rel', 'categ_id', 'shop_id', 'Exportable Root Categories'),
-        'exportable_root_category_id':fields.function(_get_rootcategory, fnct_inv = _set_rootcategory, type="many2one", relation="product.category", string="Root Category"),
-        'exportable_product_ids': fields.function(_get_exportable_product_ids, type='many2many', relation="product.product", string='Exportable Products'),
-        'shop_group_id': fields.many2one('external.shop.group', 'Shop Group', ondelete='cascade'),
-        'last_inventory_export_date': fields.datetime('Last Inventory Export Time'),
-        'last_images_export_date': fields.datetime('Last Images Export Time'),
-        'last_update_order_export_date' : fields.datetime('Last Order Update  Time'),
-        'last_products_export_date' : fields.datetime('Last Product Export Time'),
-        'last_special_products_export_date' : fields.datetime('Last Special Product Export Time'),
-        'last_category_export_date' : fields.datetime('Last Category Export Time'),
-        'referential_id': fields.function(_get_referential_id,
-            fnct_inv=_set_referential_id, type='many2one',
-            relation='external.referential', string='External Referential', store={
-                'sale.shop': (lambda self, cr, uid, ids, c={}: ids, ['referential_integer_id', 'shop_group_id'], 10),
-                'external.shop.group': (_get_shop_from_shop_group, ['referential_id'], 20),
-                }),
-        'referential_integer_id': fields.integer('Referential Integer ID'),
-        'is_tax_included': fields.boolean('Prices Include Tax', help="Does the external system work with Taxes Inclusive Prices ?"),
-        'sale_journal': fields.many2one('account.journal', 'Sale Journal'),
-        'order_prefix': fields.char('Order Prefix', size=64),
-        'default_payment_method_id': fields.many2one('payment.method', 'Payment Method'),
-        'default_language': fields.many2one('res.lang', 'Default Language'),
-        'default_fiscal_position': fields.many2one('account.fiscal.position', 'Default Fiscal Position'),
-        'default_customer_account': fields.many2one('account.account', 'Default Customer Account'),
-        'default_customer_lang': fields.many2one('res.lang', 'Default Customer Language'),
-        'auto_import': fields.boolean('Automatic Import'),
-        'address_id':fields.many2one('res.partner.address', 'Address'),
-        'website': fields.char('Website', size=64),
-        'image':fields.binary('Image', filters='*.png,*.jpg,*.gif'),
-        'use_external_tax': fields.boolean(
-            'Use External Taxes',
-            help="If activated, the external taxes will be applied.\n"
-                 "If not activated, OpenERP will compute them "
-                 "according to default values and fiscal positions."),
-        'import_orders_from_date': fields.datetime('Only created after'),
-        'check_total_amount': fields.boolean('Check Total Amount', help="The total amount computed by OpenERP should match with the external amount, if not the sale order can not be confirmed."),
-        'type_name': fields.function(_get_referential_type_name, type='char', string='Referential type',
-                store={
-                'sale.shop': (lambda self, cr, uid, ids, c={}: ids, ['referential_id', 'shop_group_id'],10)}),
-        'product_stock_field_id': fields.many2one(
-            'ir.model.fields',
-            string='Stock Field',
-            domain="[('model', 'in', ['product.product', 'product.template']),"
-                   " ('ttype', '=', 'float')]",
-            help="Choose the field of the product which will be used for "
-                 "stock inventory updates.\nIf empty, Quantity Available "
-                 "is used"),
-    }
-
-    _defaults = {
-        'payment_default_id': 1, #required field that would cause trouble if not set when importing
-        'auto_import': True,
-        'use_external_tax': True,
-        'product_stock_field_id': _get_stock_field_id,
-    }
-
-    def init_context_before_exporting_resource(self, cr, uid, external_session, object_id, resource_name, context=None):
-        context = super(sale_shop, self).init_context_before_exporting_resource(cr, uid, external_session, object_id, resource_name, context=context)
-        context['pricelist'] = external_session.sync_from_object.get_pricelist(context=context)
-        return context
-
-    def get_pricelist(self, cr, uid, id, context=None):
-        if isinstance(id, list):
-            id=id[0]
-        shop = self.browse(cr, uid, id, context=context)
-        if shop.pricelist_id:
-            return shop.pricelist_id.id
-        else:
-            return self.pool.get('product.pricelist').search(cr, uid, [('type', '=', 'sale'), ('active', '=', True)], context=context)[0]
-
-    def export_catalog(self, cr, uid, ids, context=None):
-        if context is None: context={}
-        self.export_resources(cr, uid, ids, 'product.category', context=context)
-        # In various e-commerce system product can depend of other products
-        # So the simple product (with no dependency) are exported in priority
-        # Then the special product (with dependency) are exported at the end
-        context['export_product'] = 'simple'
-        self.export_resources(cr, uid, ids, 'product.product', context=context)
-        context['export_product'] = 'special'
-        self.export_resources(cr, uid, ids, 'product.product', context=context)
-        #Export Images
-        self.export_resources(cr, uid, ids, 'product.images', context=context)
-
-        #TODO export link
-        #TODO update the last date
-        #I don't know where it's the best to update it here or in the export functions
-        #take care about concurent write with different cursor
-
-
-        return True
-
-    def export_inventory(self, cr, uid, ids, context=None):
-        if context is None:
-            context = {}
-        for shop in self.browse(cr, uid, ids):
-            external_session = ExternalSession(shop.referential_id, shop)
-            self._export_inventory(cr, uid, external_session, ids, context=context)
-        return True
-
-    def _get_product_ids_for_stock_to_export(self, cr, uid, shop, context=None):
-        return [product.id for product in shop.exportable_product_ids]
-
-    def _export_inventory(self, cr, uid, external_session, ids, context=None):
-        shop = external_session.sync_from_object
-        stock_move_obj = self.pool.get('stock.move')
-        for shop in self.browse(cr, uid, ids):
-            external_session = ExternalSession(shop.referential_id, shop)
-
-            product_ids = self._get_product_ids_for_stock_to_export(cr, uid, shop, context=context)
-
-            if shop.last_inventory_export_date:
-                # we do not exclude canceled moves because it means
-                # some stock levels could have increased since last export
-                recent_move_ids = stock_move_obj.search(
-                    cr, uid,
-                    [('write_date', '>', shop.last_inventory_export_date),
-                     ('product_id', 'in', product_ids),
-                     ('product_id.type', '!=', 'service'),
-                     ('state', '!=', 'draft')],
-                    context=context)
-            else:
-                recent_move_ids = stock_move_obj.search(
-                    cr, uid,
-                    [('product_id', 'in', product_ids)],
-                    context=context)
-
-            recent_moves = stock_move_obj.browse(
-                cr, uid, recent_move_ids, context=context)
-
-            product_ids = [move.product_id.id
-                           for move
-                           in recent_moves
-                           if move.product_id.state != 'obsolete']
-            product_ids = list(set(product_ids))
-            external_session.logger.info('Export Stock for %s products' %len(product_ids))
-            self.pool.get('product.product').export_inventory(
-                    cr, uid, external_session, product_ids, context=context)
-            shop.write({'last_inventory_export_date':
-                            time.strftime(DEFAULT_SERVER_DATETIME_FORMAT)})
-        return True
-
-    def import_catalog(self, cr, uid, ids, context):
-        #TODO import categories, then products
-        raise except_osv(_("Not Implemented"), _("Not Implemented in abstract base module!"))
-
-    def import_orders(self, cr, uid, ids, context=None):
-        self.import_resources(cr, uid, ids, 'sale.order', context=context)
-        return True
-
-    def check_need_to_update(self, cr, uid, ids, context=None):
-        """ This function will update the order status in OpenERP for
-        the order which are in the state 'need to update' """
-        for shop in self.browse(cr, uid, ids, context=context):
-            external_session = ExternalSession(shop.referential_id, shop)
-            so_obj = self.pool.get('sale.order')
-            orders_to_update = so_obj.search(cr, uid,
-                    [('need_to_update', '=', True),
-                     ('shop_id', '=', shop.id)],
-                    context=context)
-            so_obj._check_need_to_update(cr, uid, external_session, orders_to_update, context=context)
-        return False
-
-    def _update_order_query(self, cr, uid, shop, context=None):
-        req = """
-            SELECT ir_model_data.res_id, ir_model_data.name
-                FROM sale_order
-                INNER JOIN ir_model_data ON sale_order.id = ir_model_data.res_id
-                WHERE ir_model_data.model='sale.order' AND sale_order.shop_id=%s
-                    AND ir_model_data.referential_id NOTNULL
-        """
-        params = (shop.id,)
-        if shop.last_update_order_export_date:
-            req += "AND sale_order.update_state_date > %s"
-            params = (shop.id, shop.last_update_order_export_date)
-        return req, params
-
-    def update_orders(self, cr, uid, ids, context=None):
-        if context is None:
-            context = {}
-        for shop in self.browse(cr, uid, ids):
-            external_session = ExternalSession(shop.referential_id, shop)
-            #get all orders, which the state is not draft and the date of modification is superior to the last update, to exports
-            cr.execute(*self._update_order_query(cr, uid, shop, context=context))
-            results = cr.fetchall()
-            for result in results:
-                ids = self.pool.get('sale.order').search(cr, uid, [('id', '=', result[0])])
-                if ids:
-                    id = ids[0]
-                    order = self.pool.get('sale.order').browse(cr, uid, id, context)
-                    order_ext_id = result[1].split('sale_order/')[1]
-                    res = self.update_shop_orders(cr, uid, external_session, order, order_ext_id, context)
-                    if res:
-                        external_session.logger.info(_("Successfully updated order with OpenERP id %s and ext id %s in external sale system") % (id, order_ext_id))
-            self.pool.get('sale.shop').write(cr, uid, shop.id, {'last_update_order_export_date': time.strftime(DEFAULT_SERVER_DATETIME_FORMAT)})
-        return False
-
-    def export_shop_partners(self, cr, uid, ids, context=None):
-        if context is None: context={}
-        self.export_resources(cr, uid, ids, 'res.partner', context=context)
-        return True
-
-    def update_shop_orders(self, cr, uid, external_session, order, ext_id, context):
-        raise except_osv(_("Not Implemented"), _("Not Implemented in abstract base module!"))
-
-    def _export_shipping_query(self, cr, uid, shop, context=None):
-        query = """
-        SELECT stock_picking.id AS picking_id,
-               sale_order.id AS order_id,
-               count(pickings.id) AS picking_number
-        FROM stock_picking
-        LEFT JOIN sale_order
-                  ON sale_order.id = stock_picking.sale_id
-        LEFT JOIN stock_picking as pickings
-                  ON (sale_order.id = pickings.sale_id
-                      AND pickings.type='out'
-                      AND pickings.state!='cancel')
-        LEFT JOIN ir_model_data
-                  ON stock_picking.id = ir_model_data.res_id
-                  AND ir_model_data.model = 'stock.picking'
-        LEFT JOIN delivery_carrier
-                  ON delivery_carrier.id = stock_picking.carrier_id
-        WHERE sale_order.shop_id = %(shop_id)s
-              AND ir_model_data.res_id ISNULL
-              AND stock_picking.state = 'done'
-              AND stock_picking.type = 'out'
-              AND NOT stock_picking.do_not_export
-              AND (NOT delivery_carrier.export_needs_tracking
-                   OR stock_picking.carrier_tracking_ref IS NOT NULL)
-        GROUP BY stock_picking.id,
-                 sale_order.id,
-                 delivery_carrier.export_needs_tracking,
-                 stock_picking.carrier_tracking_ref,
-                 stock_picking.backorder_id
-        ORDER BY sale_order.id ASC,
-                 COALESCE(stock_picking.backorder_id, NULL, 0) ASC"""
-        params = {'shop_id': shop.id}
-        return query, params
-
-    def export_shipping(self, cr, uid, ids, context):
-        picking_obj = self.pool.get('stock.picking')
-        for shop in self.browse(cr, uid, ids):
-            cr.execute(*self._export_shipping_query(
-                            cr, uid, shop, context=context))
-            results = cr.dictfetchall()
-            if not results:
-                _logger.info("There is no shipping to export for the shop '%s' to the external referential", shop.name)
-                continue
-            context['conn_obj'] = shop.referential_id.external_connection()
-
-
-            picking_cr = pooler.get_db(cr.dbname).cursor()
-            try:
-                for result in results:
-                    picking_id = result['picking_id']
-
-                    if result["picking_number"] == 1:
-                        picking_type = 'complete'
-                    else:
-                        picking_type = 'partial'
-
-                    ext_shipping_id = False
-                    try:
-                        ext_shipping_id = picking_obj.create_ext_shipping(
-                            picking_cr, uid, picking_id, picking_type,
-                            shop.referential_id.id, context)
-                    except ExternalShippingCreateError, e:
-                        # when the creation has failed on the external
-                        # referential and we know that we can never
-                        # create it, we flag it as do_not_export
-                        # ExternalShippingCreateError raising has to be
-                        # correctly handled by create_ext_shipping()
-                        picking_obj.write(
-                            picking_cr, uid,
-                            picking_id,
-                            {'do_not_export': True},
-                            context=context)
-
-                    if ext_shipping_id:
-                        picking_obj.create_external_id_vals(
-                            picking_cr,
-                            uid,
-                            picking_id,
-                            ext_shipping_id,
-                            shop.referential_id.id,
-                            context=context)
-                        _logger.info("Successfully creating shipping with OpenERP id %s and ext id %s in external sale system", result["picking_id"], ext_shipping_id)
-                    picking_cr.commit()
-            finally:
-                picking_cr.close()
-        return True
-
-    def export_invoices(self, cr, uid, ids, context=None):
-        invoice_obj = self.pool.get('account.invoice')
-        for shop in self.browse(cr, uid, ids, context=None):
-            external_session = ExternalSession(shop.referential_id, shop)
-            invoice_ids = self.get_invoice_to_export(cr, uid, shop.id, context=context)
-            if not invoice_ids:
-                external_session.logger.info("There is no invoice to export for the shop '%s' to the external referential" % (shop.name,))
-            for invoice_id in invoice_ids:
-                self.pool.get('account.invoice')._export_one_resource(cr, uid, external_session, invoice_id, context=context)
-        return True
-
-    def get_invoice_to_export(self, cr, uid, shop_id, context=None):
-        shop = self.browse(cr, uid, shop_id, context=context)
-        cr.execute(*self._export_invoice_query(cr, uid, shop, context=context))
-        results = cr.dictfetchall()
-        return [res['invoice_id'] for res in results]
-
-    def _export_invoice_query(self, cr, uid, shop, context=None):
-        query = """
-        SELECT account_invoice.id AS invoice_id
-        FROM account_invoice
-        LEFT JOIN ir_model_data
-                  ON account_invoice.id = ir_model_data.res_id
-                  AND ir_model_data.model = 'account.invoice'
-                  AND referential_id = %(referential_id)s
-        WHERE shop_id = %(shop_id)s
-              AND ir_model_data.res_id ISNULL
-              AND account_invoice.state in ('paid', 'open')
-              AND NOT account_invoice.do_not_export
-        """
-        params = {'shop_id': shop.id, 'referential_id': shop.referential_id.id}
-        return query, params
-
-sale_shop()
-
-
-class sale_order(Model):
-    _inherit = "sale.order"
-
-    _columns = {
-        'need_to_update': fields.boolean('Need To Update'),
-        'ext_total_amount': fields.float(
-            'Origin External Amount',
-            digits_compute=dp.get_precision('Sale Price'),
-            readonly=True),
-        'ext_total_amount_tax': fields.float(
-            'Origin External Tax Amount',
-            digits_compute=dp.get_precision('Sale Price'),
-            readonly=True),
-        'referential_id': fields.related(
-                    'shop_id', 'referential_id',
-                    type='many2one', relation='external.referential',
-                    string='External Referential'),
-        'update_state_date': fields.datetime('Update State Date'),
-        'shipping_tax_amount': fields.dummy(string = 'Shipping Taxe Amount'),
-        'shipping_amount_tax_excluded': fields.dummy(string = 'Shipping Price Tax Exclude'),
-        'shipping_amount_tax_included': fields.dummy(string = 'Shipping Price Tax Include'),
-    }
-
-    _defaults = {
-        'need_to_update': False,
-    }
-
-    def write(self, cr, uid, ids, vals, context=None):
-        if 'state' in vals:
-            vals['update_state_date'] = datetime.now().strftime(DEFAULT_SERVER_DATETIME_FORMAT)
-        return super(sale_order, self).write(cr, uid, ids, vals, context=context)
-
-    # xxx move to BaseConnector _get_import_defaults_sale_order
-    def _get_default_import_values(self, cr, uid, external_session, mapping_id=None, defaults=None, context=None):
-        shop = False
-        if external_session.sync_from_object._name == 'sale.shop':
-            shop = external_session.sync_from_object
-        elif context.get('sale_shop_id'):
-            shop = self.pool.get('sale.shop').browse(cr, uid,  context['sale_shop_id'], context=context)
-        if shop:
-            if defaults is None: defaults = {}
-            defaults.update({
-                    'pricelist_id': shop.get_pricelist(context=context),
-                    'shop_id': shop.id,
-                    'fiscal_position': shop.default_fiscal_position.id,
-                    'payment_method_id': shop.default_payment_method_id.id,
-                    'company_id': shop.company_id.id,
-            })
-            #TODO we should avoid passing this parameter in the context
-            #for now we new it for importing order from wizard correctly
-            #refactor for V7
-            context.update({
-                    'use_external_tax': shop.use_external_tax,
-                    'is_tax_included': shop.is_tax_included,
-                })
-        return defaults
-
-    @open_report
-    def _import_resources(self, cr, uid, external_session, defaults=None, method="search_then_read", context=None):
-        if context is None: context={}
-        shop = external_session.sync_from_object
-        if shop:
-            context.update({
-                    'use_external_tax': shop.use_external_tax,
-                    'is_tax_included': shop.is_tax_included,
-                })
-        return super(sale_order, self)._import_resources(cr, uid, external_session, defaults=defaults, method=method, context=context)
-
-
-    def check_if_order_exist(self, cr, uid, external_session, resource, order_mapping=None, defaults=None, context=None):
-        mapping_name = False
-        for line in order_mapping['mapping_lines']:
-            if line['internal_field'] == 'name':
-                mapping_name = line
-        if mapping_name:
-            local_mapping = {1: {'mapping_lines': [mapping_name]}}
-            vals = self._transform_one_resource(cr, uid, external_session,
-                                        'from_external_to_openerp', resource,
-                                        mapping=local_mapping,
-                                        mapping_id=1,
-                                        defaults=defaults,
-                                        context=context)
-            if vals.get('name'):
-                exist_id = self.search(cr, uid, [['name', '=', vals['name']]], context=context)
-                if exist_id:
-                    external_session.logger.info("Sale Order %s already exist in OpenERP,"
-                                                    "no need to import it again"%vals['name'])
-                    return True
-
-        return False
-
-    # xxx a deplacer dans BaseConnector  sale_order
-    @catch_error_in_report
-    def _record_one_external_resource(self, cr, uid, external_session, resource, defaults=None,
-                                                        mapping=None, mapping_id=None, context=None):
-        mapping, mapping_id = self._init_mapping(cr, uid, external_session.referential_id.id,
-                                            mapping=mapping, mapping_id=mapping_id, context=context)
-        exist_id = self.check_if_order_exist(cr, uid, external_session, resource,
-                                            order_mapping=mapping[mapping_id], defaults=defaults, context=context)
-        if exist_id:
-            return {}
-        else:
-            return super(sale_order, self)._record_one_external_resource(cr, uid, external_session, resource,
-                                defaults=defaults, mapping=mapping, mapping_id=mapping_id, context=context)
-
-    def _check_need_to_update(self, cr, uid, external_session, ids, context=None):
-        """
-        For each order, check in external system if it has been paid since last
-        check. If so, it will launch the defined flow based on the
-        payment type (validate order, invoice, ...)
-        """
-        for order in self.browse(cr, uid, ids, context=context):
-            self._check_need_to_update_single(cr, uid, external_session, order, context=context)
-        return True
-
-    def _check_need_to_update_single(self, cr, uid, external_session, order, context=None):
-        """Not implemented in this abstract module"""
-        return True
-
-    def _get_params_onchange_partner_id(self, cr, uid, vals, context=None):
-        args = [
-            'None',
-            vals.get('partner_id'),
-        ]
-        return args, {}
-
-    #I will probably extract this code in order to put it in a "glue" module
-    def _get_params_onchange_address_id(self, cr, uid, vals, context=None):
-        args = [
-            None,
-            vals.get('partner_invoice_id'),
-            vals.get('partner_shipping_id'),
-            vals.get('partner_id'),
-        ]
-        kwargs = {
-            'shop_id': vals.get('shop_id'),
-        }
-        return args, kwargs
-
-    def play_sale_order_onchange(self, cr, uid, vals, defaults=None, context=None):
-        ir_module_obj= self.pool.get('ir.module.module')
-        if ir_module_obj.search(cr, uid, [
-                            ['name', '=', 'account_fiscal_position_rule_sale'],
-                            ['state', 'in', ['installed', 'to upgrade']],
-                                                            ], context=context):
-            vals = self.call_onchange(cr, uid, 'onchange_partner_id', vals, defaults, context=context)
-            vals = self.call_onchange(cr, uid, 'onchange_address_id', vals, defaults, context=context)
-        else:
-            vals = self.call_onchange(cr, uid, 'onchange_partner_id', vals, defaults, context=context)
-
-
-        return vals
-
-    def _merge_with_default_values(self, cr, uid, external_session, ressource, vals, sub_mapping_list, defaults=None, context=None):
-        if vals.get('name'):
-            shop = external_session.sync_from_object
-            if shop.order_prefix:
-                vals['name'] = '%s%s' %(shop.order_prefix, vals['name'])
-        if context is None: context ={}
-        if vals.get('payment_method_id'):
-            payment_method = self.pool.get('payment.method').browse(cr, uid, vals['payment_method_id'], context=context)
-            workflow_process = payment_method.workflow_process_id
-            if workflow_process:
-                vals['order_policy'] = workflow_process.order_policy
-                vals['picking_policy'] = workflow_process.picking_policy
-                vals['invoice_quantity'] = workflow_process.invoice_quantity
-        # update vals with order onchange in order to compute taxes
-        vals = self.play_sale_order_onchange(cr, uid, vals, defaults=defaults, context=context)
-        return super(sale_order, self)._merge_with_default_values(cr, uid, external_session, ressource, vals, sub_mapping_list, defaults=defaults, context=context)
-
-    def oe_create(self, cr, uid, external_session, vals, resource, defaults, context):
-        #depending of the external system the contact address can be optionnal
-        vals = self._convert_special_fields(cr, uid, vals, external_session.referential_id.id, context=context)
-        if not vals.get('partner_order_id'):
-            vals['partner_order_id'] = vals['partner_invoice_id']
-        if not vals.get('partner_shipping_id'):
-            vals['partner_shipping_id'] = vals['partner_invoice_id']
-        order_id = super(sale_order, self).oe_create(cr, uid, external_session, vals, resource, defaults, context)
-        self.paid_and_update(cr, uid, external_session, order_id, resource, context=context)
-        return order_id
-
-    def paid_and_update(self, cr, uid, external_session, order_id, resource, context=None):
-        wf_service = netsvc.LocalService("workflow")
-        paid = self.create_external_payment(cr, uid, external_session, order_id, resource, context)
-        order = self.browse(cr, uid, order_id, context=context)
-        validate_order = order.workflow_process_id.validate_order
-        if validate_order == 'always' or validate_order == 'if_paid' and paid:
-            try:
-                wf_service.trg_validate(uid, 'sale.order', order.id, 'order_confirm', cr)
-            except:
-                raise
-                #What we should do?? creating the order but not validating it???
-                #Maybe setting a special flag can be a good solution? with a retry method?
-            return True
-
-        elif validate_order == 'if_paid' and order.payment_method_id.automatic_update:
-            days_before_order_cancel = order.workflow_process_id.days_before_order_cancel or 30
-            order_date = datetime.strptime(order.date_order, DEFAULT_SERVER_DATE_FORMAT)
-            order_cancel_date = order_date + relativedelta(days=days_before_order_cancel)
-            if order.state == 'draft' and order_cancel_date < datetime.now():
-                wf_service.trg_validate(uid, 'sale.order', order.id, 'cancel', cr)
-                self.write(cr, uid, order.id, {'need_to_update': False})
-                self.log(cr, uid, order.id, ("order %s canceled in OpenERP because older than % days"
-                                     "and still not confirmed") % (order.id, days_before_order_cancel))
-                #TODO eventually call a trigger to cancel the order in the external system too
-                external_session.logger.info(("order %s canceled in OpenERP because older than % days and "
-                                "still not confirmed") %(order.id, days_before_order_cancel))
-            else:
-                self.write(cr, uid, order_id, {'need_to_update': True}, context=context)
-        return False
-
-    def create_external_payment(self, cr, uid, external_session, order_id, resource, context):
-        """
-        Fonction that will create a payment from the external resource
-        """
-        vals = self._get_payment_information(cr, uid, external_session, order_id, resource, context=context)
-        if vals.get('paid'):
-            if not vals.get('journal_id'):
-                external_session.logger.warning(_("Not journal found for payment method %s. Can not create payment")%vals['payment_method'])
-                vals['paid'] = False
-            else:
-                self.pay_sale_order(cr, uid, order_id, vals['journal_id'], vals['amount'], vals['date'], context=context)
-        return vals.get('paid')
-
-    def _get_payment_information(self, cr, uid, external_session, order_id, resource, context=None):
-        """
-        Function that will return the information in order to create the payment
-        """
-        vals = {}
-        sale = self.browse(cr, uid, order_id, context=context)
-        vals['payment_method'] = sale.payment_method_id.name
-        vals['journal_id'] = sale.payment_method_id.journal_id and sale.payment_method_id.journal_id.id
-        vals['date'] = sale.date_order
-        return vals
-
-    def _prepare_invoice(self, cr, uid, order, lines, context=None):
-        """Prepare the dict of values to create the new invoice for a
-           sale order. This method may be overridden to implement custom
-           invoice generation (making sure to call super() to establish
-           a clean extension chain).
-
-           :param browse_record order: sale.order record to invoice
-           :param list(int) lines: list of invoice line IDs that must be
-                                  attached to the invoice
-           :return: dict of value to create() the invoice
-        """
-        vals = super(sale_order, self)._prepare_invoice(cr, uid, order, lines, context=context)
-        if order.shop_id.sale_journal:
-            vals['journal_id'] = order.shop_id.sale_journal.id
-        vals['shop_id'] = order.shop_id.id
-        return vals
-
-    def _prepare_order_picking(self, cr, uid, order, context=None):
-        vals = super(sale_order, self)._prepare_order_picking(cr, uid, order, context=context)
-        vals['shop_id'] = order.shop_id.id
-        return vals
-
-    def oe_update(self, cr, uid, external_session, existing_rec_id, vals, resource, defaults, context=None):
-        '''Not implemented in this abstract module, if it's not implemented in your module it will raise an error'''
-        # Explication :
-        # sometime customer can do ugly thing like renamming a sale_order and try to reimported it,
-        # sometime openerp run two scheduler at the same time, or the customer launch two openerp at the same time
-        # or the external system give us again an already imported order
-        # As the update of an existing order (this is not the update of the status but the update of the line, the address...)
-        # is not supported by base_sale_multichannels and also not in magentoerpconnect.
-        # It's better to don't allow this feature to avoid hidding a problem.
-        # It's better to have the order not imported and to know it than having order with duplicated line.
-        if not (context and context.get('oe_update_supported', False)):
-            #TODO found a clean solution to raise the except_osv error in the try except of the function import_with_try
-            raise except_osv(_("Not Implemented"), _(("The order with the id %s try to be updated from the external system."
-                                " This feature is not supported. Maybe the import try to reimport an existing sale order"%(existing_rec_id,))))
-        return super(sale_order, self).oe_update(cr, uid, external_session, existing_rec_id, vals, resource, defaults, context=context)
-
-    def _convert_special_fields(self, cr, uid, vals, referential_id, context=None):
-        """
-        Convert the special 'fake' field into an order line
-        special field are :
-        - shipping amount and shipping_tax_rate
-        - cash_on_delivery and cash_on_delivery_taxe_rate
-        - gift_certificates
-
-        :param dict vals : values of the sale order to create
-        :param int referential_id : external referential id
-        :return: the value for the sale order with the special field converted
-        :rtype: dict
-        """
-        def check_key(keys):
-            return len(set([
-                        'shipping_amount_tax_excluded',
-                        'shipping_amount_tax_included',
-                        'shipping_tax_amount'])
-                    & set(keys)) >= 2
-
-        for line in vals['order_line']:
-            for field in ['shipping_amount_tax_excluded','shipping_amount_tax_included', 'shipping_tax_amount']:
-                if field in line[2]:
-                    vals[field] = vals.get(field, 0.0) + line[2][field]
-                    del line[2][field]
-
-        if not 'shipping_tax_rate' in vals and check_key(vals.keys()):
-            if not 'shipping_amount_tax_excluded' in vals:
-                vals['shipping_amount_tax_excluded'] = vals['shipping_amount_tax_included'] - vals['shipping_tax_amount']
-            elif not 'shipping_tax_amount' in vals:
-                vals['shipping_tax_amount'] = vals['shipping_amount_tax_included'] - vals['shipping_amount_tax_excluded']
-            vals['shipping_tax_rate'] = vals['shipping_amount_tax_excluded'] and \
-                            vals['shipping_tax_amount'] / vals['shipping_amount_tax_excluded'] or 0
-            del vals['shipping_tax_amount']
-        for option in self._get_special_fields(cr, uid, context=context):
-            vals = self._add_order_extra_line(cr, uid, vals, option, context=context)
-        return vals
-
-
-    def _get_special_fields(self, cr, uid, context=None):
-        return [
-            {
-            'price_unit_tax_excluded' : 'shipping_amount_tax_excluded',
-            'price_unit_tax_included' : 'shipping_amount_tax_included',
-            'tax_rate_field' : 'shipping_tax_rate',
-            'product_ref' : ('base_sale_multichannels', 'product_product_shipping'),
-            },
-            {
-            'tax_rate_field' : 'cash_on_delivery_taxe_rate',
-            'price_unit_tax_excluded' : 'cash_on_delivery_amount_tax_excluded',
-            'price_unit_tax_included' : 'cash_on_delivery_amount_tax_included',
-            'product_ref' : ('base_sale_multichannels', 'product_product_cash_on_delivery'),
-            },
-            {
-            'price_unit_tax_excluded' : 'gift_certificates_amount', #gift certificate doesn't have any tax
-            'price_unit_tax_included' : 'gift_certificates_amount',
-            'product_ref' : ('base_sale_multichannels', 'product_product_gift'),
-            'code_field': 'gift_certificates_code',
-            'sign': -1,
-            },
-        ]
-
-    def _add_order_extra_line(self, cr, uid, vals, option, context):
-        """ Add or substract amount on order as a separate line item with single quantity for each type of amounts like :
-        shipping, cash on delivery, discount, gift certificates...
-
-        :param dict vals: values of the sale order to create
-        :param option: dictionnary of option for the special field to process
-        """
-        if context is None: context={}
-        sign = option.get('sign', 1)
-        if context.get('is_tax_included') and vals.get(option['price_unit_tax_included']):
-            price_unit = vals.pop(option['price_unit_tax_included']) * sign
-        elif vals.get(option['price_unit_tax_excluded']):
-            price_unit = vals.pop(option['price_unit_tax_excluded']) * sign
-        else:
-            for key in ['price_unit_tax_excluded', 'price_unit_tax_included', 'tax_rate_field']:
-                if option.get(key) and option[key] in vals:
-                    del vals[option[key]]
-            return vals #if there is not price, we have nothing to import
-
-        model_data_obj = self.pool.get('ir.model.data')
-        model, product_id = model_data_obj.get_object_reference(cr, uid, *option['product_ref'])
-        product = self.pool.get('product.product').browse(cr, uid, product_id, context)
-
-        extra_line = {
-                        'product_id': product.id,
-                        'name': product.name,
-                        'product_uom': product.uom_id.id,
-                        'product_uom_qty': 1,
-                        'price_unit': price_unit,
-                    }
-
-        extra_line = self.pool.get('sale.order.line').play_sale_order_line_onchange(cr, uid, extra_line, vals, vals['order_line'], context=context)
-        if context.get('use_external_tax') and option.get('tax_rate_field'):
-            tax_rate = vals.pop(option['tax_rate_field'])
-            if tax_rate:
-                line_tax_id = self.pool.get('account.tax').get_tax_from_rate(cr, uid, tax_rate, context.get('is_tax_included'), context=context)
-                if not line_tax_id:
-                    raise except_osv(_('Error'), _('No tax id found for the rate %s with the tax include = %s')%(tax_rate, context.get('is_tax_included')))
-                extra_line['tax_id'] = [(6, 0, [line_tax_id])]
-            else:
-                extra_line['tax_id'] = False
-        if not option.get('tax_rate_field'):
-            del extra_line['tax_id']
-        ext_code_field = option.get('code_field')
-        if ext_code_field and vals.get(ext_code_field):
-            extra_line['name'] = "%s [%s]" % (extra_line['name'], vals[ext_code_field])
-        vals['order_line'].append((0, 0, extra_line))
-        return vals
-
-class sale_order_line(Model):
-    _inherit='sale.order.line'
-
-    _columns = {
-        'ext_product_ref': fields.char('Product Ext Ref',
-                            help="This is the original external product reference", size=256),
-        'shipping_tax_amount': fields.dummy(string = 'Shipping Taxe Amount'),
-        'shipping_amount_tax_excluded': fields.dummy(string = 'Shipping Price Tax Exclude'),
-        'shipping_amount_tax_included': fields.dummy(string = 'Shipping Price Tax Include'),
-        'ext_ref_line': fields.char('Ext. Ref Line', size=64,
-                help='Unique order line id delivered by external application'),
-    }
-
-    def _get_params_product_id_change(self, cr, uid, line, parent_data, previous_lines, context=None):
-        args = [
-            None,
-            parent_data.get('pricelist_id'),
-            line.get('product_id')
-        ]
-        kwargs ={
-            'qty': float(line.get('product_uom_qty')),
-            'uom': line.get('product_uom'),
-            'qty_uos': float(line.get('product_uos_qty') or line.get('product_uom_qty')),
-            'uos': line.get('product_uos'),
-            'name': line.get('name'),
-            'partner_id': parent_data.get('partner_id'),
-            'lang': False,
-            'update_tax': True,
-            'date_order': parent_data.get('date_order'),
-            'packaging': line.get('product_packaging'),
-            'fiscal_position': parent_data.get('fiscal_position'),
-            'flag': False,
-            'context': context,
-        }
-        return args, kwargs
-
-    def play_sale_order_line_onchange(self, cr, uid, line, parent_data, previous_lines, defaults=None, context=None):
-        original_line = line.copy()
-        if not context.get('use_external_tax') and 'tax_id' in line:
-            del line['tax_id']
-        line = self.call_onchange(cr, uid, 'product_id_change', line, defaults=defaults, parent_data=parent_data, previous_lines=previous_lines, context=context)
-        #TODO all m2m should be mapped correctly
-        if context.get('use_external_tax'):
-            #if we use the external tax and the onchange have added a taxe, 
-            #them we remove it.
-            #Indeed we have to make the difference between a real tax_id
-            #imported and a default value set by the onchange
-            if not 'tax_id' in original_line and 'tax_id' in line:
-                del line['tax_id']
-        elif line.get('tax_id'):
-            line['tax_id'] = [(6, 0, line['tax_id'])]
-        return line
-
-    def _transform_one_resource(self, cr, uid, external_session, convertion_type, resource, mapping, mapping_id,
-                     mapping_line_filter_ids=None, parent_data=None, previous_result=None, defaults=None, context=None):
-        if context is None: context={}
-        line = super(sale_order_line, self)._transform_one_resource(cr, uid, external_session, convertion_type, resource,
-                            mapping, mapping_id, mapping_line_filter_ids=mapping_line_filter_ids, parent_data=parent_data,
-                            previous_result=previous_result, defaults=defaults, context=context)
-
-        if context.get('is_tax_included') and 'price_unit_tax_included' in line:
-            line['price_unit'] = line['price_unit_tax_included']
-        elif 'price_unit_tax_excluded' in line:
-            line['price_unit']  = line['price_unit_tax_excluded']
-
-        line = self.play_sale_order_line_onchange(cr, uid, line, parent_data, previous_result,
-                                                                        defaults, context=context)
-        if context.get('use_external_tax'):
-            if not 'tax_id' in line and line.get('tax_rate'):
-                line_tax_id = self.pool.get('account.tax').get_tax_from_rate(cr, uid, line['tax_rate'], context.get('is_tax_included', False), context=context)
-                if not line_tax_id:
-                    raise except_osv(_('Error'), _('No tax id found for the rate %s with the tax include = %s')%(line['tax_rate'], context.get('is_tax_included')))
-                line['tax_id'] = [(6, 0, [line_tax_id])]
-            else:
-                line['tax_id'] = False
-        return line
-
-# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

=== removed directory 'base_sale_multichannels/settings'
=== removed file 'base_sale_multichannels/settings/external.referential.category.csv'
--- base_sale_multichannels/settings/external.referential.category.csv	2012-06-21 17:44:12 +0000
+++ base_sale_multichannels/settings/external.referential.category.csv	1970-01-01 00:00:00 +0000
@@ -1,2 +0,0 @@
-"id","name"
-"multichannels","Multichannel Sale"

=== removed file 'base_sale_multichannels/settings/sale.exception.csv'
--- base_sale_multichannels/settings/sale.exception.csv	2013-02-04 14:47:25 +0000
+++ base_sale_multichannels/settings/sale.exception.csv	1970-01-01 00:00:00 +0000
@@ -1,12 +0,0 @@
-id,name,description,sequence,model,code
-excep_wrong_total_amount,Total Amount differs from external system,"The amount computed doesn't match with the external amount because the taxes have not been configured properly (maybe some fiscal positions have changed the final price).
-Please fix it manually and check your taxes rules.
-
-NB : This check have being applied because you have checked the option \check total amount\"" on the shop of this sale order""",30,sale.order,"if order.shop_id.check_total_amount and abs(order.amount_total - order.ext_total_amount) >= 0.01:
-    failed = True"
-excep_wrong_total_amount_tax,Total Tax Amount differs from external system,"The tax amount computed doesn't match with the external tax amount because the taxes have not been configured properly (maybe some fiscal positions have changed the final price).
-Please fix it manually and check your taxes rules.
-
-NB : This check have being applied because you have checked the option \check total amount\"" on the shop of this sale order""",30,sale.order,"#By default we allow a cent of difference for the taxe, feel free to customise it in your own module
-if order.shop_id.check_total_amount and abs(order.amount_tax - order.ext_total_amount_tax) > 0.01:
-    failed = True"

=== removed directory 'base_sale_multichannels/wizard'
=== removed file 'base_sale_multichannels/wizard/__init__.py'
--- base_sale_multichannels/wizard/__init__.py	2012-09-20 17:52:17 +0000
+++ base_sale_multichannels/wizard/__init__.py	1970-01-01 00:00:00 +0000
@@ -1,23 +0,0 @@
-# -*- coding: utf-8 -*-
-##############################################################################
-#
-#    Base_sale_multichannels module for OpenERP
-#    Copyright (C) 2010 Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
-#
-#    This program is free software: you can redistribute it and/or modify
-#    it under the terms of the GNU Affero General Public License as
-#    published by the Free Software Foundation, either version 3 of the
-#    License, or (at your option) any later version.
-#
-#    This program is distributed in the hope that it will be useful,
-#    but WITHOUT ANY WARRANTY; without even the implied warranty of
-#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#    GNU Affero General Public License for more details.
-#
-#    You should have received a copy of the GNU Affero General Public License
-#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
-#
-##############################################################################
-
-import import_order
-

=== removed file 'base_sale_multichannels/wizard/import_order.py'
--- base_sale_multichannels/wizard/import_order.py	2012-08-21 07:38:58 +0000
+++ base_sale_multichannels/wizard/import_order.py	1970-01-01 00:00:00 +0000
@@ -1,42 +0,0 @@
-# -*- coding: utf-8 -*-
-##############################################################################
-#
-#    Base_sale_multichannels module for OpenERP
-#    Copyright (C) 2010 Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
-#
-#    This program is free software: you can redistribute it and/or modify
-#    it under the terms of the GNU Affero General Public License as
-#    published by the Free Software Foundation, either version 3 of the
-#    License, or (at your option) any later version.
-#
-#    This program is distributed in the hope that it will be useful,
-#    but WITHOUT ANY WARRANTY; without even the implied warranty of
-#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#    GNU Affero General Public License for more details.
-#
-#    You should have received a copy of the GNU Affero General Public License
-#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
-#
-##############################################################################
-
-
-from osv import fields,osv
-from tools.translate import _
-from base_external_referentials.external_osv import ExternalSession
-
-class sale_order_import_wizard(osv.osv_memory):
-    _name = 'sale.order.import.wizard'
-    _description = 'sale order import wizard'
-
-    _columns = {
-        'order_number': fields.char('Order Number', size=64),
-        }
-
-    def import_order(self, cr, uid, ids, context=None):
-        if context is None:
-            context={}
-        shop = self.pool.get('sale.shop').browse(cr, uid, context['active_id'], context=context)
-        external_session = ExternalSession(shop.referential_id, shop)
-        wizard = self.browse(cr, uid, ids[0], context=context)
-        self.pool.get('sale.order')._import_one_resource(cr, uid, external_session, wizard.order_number, context=context)
-        return {'type': 'ir.actions.act_window_close'}

=== removed file 'base_sale_multichannels/wizard/import_order.xml'
--- base_sale_multichannels/wizard/import_order.xml	2012-06-11 07:33:40 +0000
+++ base_sale_multichannels/wizard/import_order.xml	1970-01-01 00:00:00 +0000
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<openerp>
-    <data>
-        <record model="ir.ui.view" id="sale_order_import_wizard_view">
-            <field name="name">sale.order.import.wizard.view</field>
-            <field name="model">sale.order.import.wizard</field>
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                <form string="Import a specifique order from an external system">
-                    <field name="order_number" nolabel="1" colspan='4'/>
-                    <button icon="gtk-cancel" special="cancel" string="Cancel"/>
-                    <button icon="gtk-ok" name="import_order" string="Import Order" type="object"/>
-                </form>
-            </field>
-        </record>
-
-        <record id="action_import_order_wizard" model="ir.actions.act_window">
-            <field name="name">Import Order</field>
-            <field name="type">ir.actions.act_window</field>
-            <field name="res_model">sale.order.import.wizard</field>
-            <field name="view_type">form</field>
-            <field name="view_mode">form</field>
-            <field name="target">new</field>
-            <field name="context">{}</field>
-        </record>
-
-        <record id="ir_action_import_order_wizard" model="ir.values">
-            <field name="key2">client_action_multi</field>
-            <field name="model">sale.shop</field>
-            <field name="name">Import Order</field>
-            <field eval="'ir.actions.act_window,%d'%action_import_order_wizard" name="value"/>
-            <field eval="True" name="object"/>
-        </record>
-    </data>
-</openerp>

=== modified file 'base_sale_report_synchronizer/__openerp__.py'
--- base_sale_report_synchronizer/__openerp__.py	2012-12-26 13:24:14 +0000
+++ base_sale_report_synchronizer/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -33,7 +33,7 @@
     'author': 'Akretion',
     'website': 'http://www.akretion.com/',
     'depends': [
-        'base_sale_multichannels',
+        'connector_ecommerce',
         'report_synchronizer',
         ], 
     'init_xml': [],

=== modified file 'base_sale_report_synchronizer/sale_view.xml'
--- base_sale_report_synchronizer/sale_view.xml	2012-10-09 12:40:16 +0000
+++ base_sale_report_synchronizer/sale_view.xml	2013-12-05 13:14:00 +0000
@@ -3,7 +3,7 @@
     <data>
 
         <record model="ir.ui.view" id="view_shop_form">
-            <field name="name">base_sale_multichannels_view_shop_form</field>
+            <field name="name">connector_ecommerce_view_shop_form</field>
             <field name="model">sale.shop</field>
             <field name="inherit_id" ref="sale.view_shop_form" />
             <field name="type">form</field>

=== renamed directory 'base_sale_multichannels' => 'connector_ecommerce'
=== modified file 'connector_ecommerce/__init__.py'
--- base_sale_multichannels/__init__.py	2012-08-21 13:57:44 +0000
+++ connector_ecommerce/__init__.py	2013-12-05 13:14:00 +0000
@@ -1,34 +1,30 @@
-# -*- encoding: utf-8 -*-
+# -*- coding: utf-8 -*-
 ##############################################################################
 #
-#    OpenERP, Open Source Management Solution    
-#    Copyright (C) 2009 Akretion (<http://www.akretion.com>). All Rights Reserved
-#    authors: Raphaël Valyi, Sharoon Thomas
+#    Copyright 2013 Camptocamp SA
+#    Copyright 2013 Akretion
 #
 #    This program is free software: you can redistribute it and/or modify
-#    it under the terms of the GNU General Public License as published by
-#    the Free Software Foundation, either version 3 of the License, or
-#    (at your option) any later version.
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
 #
 #    This program is distributed in the hope that it will be useful,
 #    but WITHOUT ANY WARRANTY; without even the implied warranty of
 #    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#    GNU General Public License for more details.
+#    GNU Affero General Public License for more details.
 #
-#    You should have received a copy of the GNU General Public License
+#    You should have received a copy of the GNU Affero General Public License
 #    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
-import sale
 import stock
-import wizard
-import delivery
-import partner
 import account
-import external_referential
 import product
 import invoice
 import payment_method
-
-# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
+import event
+import unit
+import sale
+import wizard

=== modified file 'connector_ecommerce/__openerp__.py'
--- base_sale_multichannels/__openerp__.py	2012-12-26 13:24:14 +0000
+++ connector_ecommerce/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -1,78 +1,80 @@
-# -*- encoding: utf-8 -*-
+# -*- coding: utf-8 -*-
 ##############################################################################
 #
-#    OpenERP, Open Source Management Solution
-#    Copyright (C) 2009 Akretion (<http://www.akretion.com>). All Rights Reserved
-#    authors: Raphaël Valyi, Sharoon Thomas
-#    Copyright (C) 2010-2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
+#    Copyright 2013 Camptocamp SA
+#    Copyright 2013 Akretion
+#
 #    This program is free software: you can redistribute it and/or modify
-#    it under the terms of the GNU General Public License as published by
-#    the Free Software Foundation, either version 3 of the License, or
-#    (at your option) any later version.
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
 #
 #    This program is distributed in the hope that it will be useful,
 #    but WITHOUT ANY WARRANTY; without even the implied warranty of
 #    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#    GNU General Public License for more details.
+#    GNU Affero General Public License for more details.
 #
-#    You should have received a copy of the GNU General Public License
+#    You should have received a copy of the GNU Affero General Public License
 #    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
-
-{
-    'name': 'Base Sale MultiChannels',
-    'version': '6.1.2',
-    'category': 'Generic Modules/Sale',
-    'description': """
-This module provide an abstract common minimal base to multi-channels sales.
-Say you want to expose your product catalog to
-* several instances of flashy-sluggish Magento web sites
-* a cutting edge Spree web shop
-* a Neteven online Marketplace
-* EBay
-* Amazon
-* Google Base
-* an external Point Of Sale system
-* ...
-Then this module allows you to:
-* use several external references ids on every OpenERP object matching those all those external referentials
-* per referential instance, use several sale sub platform entities (ex: several Magento websites per instance)
-* per sub platform, use several shops (ex: several Magento web shops per website)
-
-For each sale shop (matching OpenERP sale.shop object), this module abstract the interfaces to:
-* export the catalog, shop warehouse stock level wise, shop pricelist wise
-* import the catalog
-* import orders
-* export orders/picking status
-    """,
-    'author': 'Akretion, Sharoon Thomas (Openlabs.co.in)',
-    'website': 'http://www.akretion.com',
-    'depends': [
-        'sale_automatic_workflow',
-        'sale_exceptions',
-        'base_external_referentials',
-        'delivery',
-        'base_onchange_player',
-    ],
-    'init_xml': [],
-    'update_xml': [
-        'security/ir.model.access.csv',
-        'sale_view.xml',
-        'partner_view.xml',
-        'invoice_view.xml',
-        'wizard/import_order.xml',
-        'delivery_view.xml',
-        'base_sale_data.xml',
-        'settings/sale.exception.csv',
-        'settings/external.referential.category.csv',
-        'stock_view.xml',
-        'payment_method_view.xml',
-        'account_view.xml',
-    ],
-    'demo_xml': [],
-    'installable': False,
-    'certificate': '',
+{'name': 'Connector for E-Commerce',
+ 'version': '2.0.0',
+ 'category': 'Connector',
+ 'author': 'MagentoERPConnect Core Editors',
+ 'website': 'http://www.magentoerpconnect.com',
+ 'license': 'AGPL-3',
+ 'description': """
+Connector for E-Commerce
+========================
+
+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 consumers
+    (tracking number added, invoice paid, picking sent, ...)
+
+
+ConnectorUnit
+
+    A piece of code which allows to play all the ``onchanges`` required
+    when we create a sale order.
+
+Data Model
+
+    Add structures shared for e-commerce connectors
+
+
+.. _`connector`: https://code.launchpad.net/openerp-connector
+.. _`magentoerpconnect`: https://launchpad.net/magentoerpconnect
+.. _`prestashoperpconnect`: https://launchpad.net/prestashoperpconnect
+""",
+ 'depends': [
+     'connector',
+     'sale_automatic_workflow',
+     'sale_exceptions',
+     'delivery',
+ ],
+ 'data': [
+     'security/security.xml',
+     'security/ir.model.access.csv',
+     'wizard/sale_ignore_cancel_view.xml',
+     'sale_view.xml',
+     'product_view.xml',
+     'invoice_view.xml',
+     'ecommerce_data.xml',
+     'stock_view.xml',
+     'payment_method_view.xml',
+     'account_view.xml',
+ ],
+ 'installable': True,
 }
-# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

=== modified file 'connector_ecommerce/account.py'
--- base_sale_multichannels/account.py	2012-12-07 12:16:25 +0000
+++ connector_ecommerce/account.py	2013-12-05 13:14:00 +0000
@@ -1,23 +1,23 @@
-# -*- encoding: utf-8 -*-
-#################################################################################
-#                                                                               #
-#    base_sale_multichannels for OpenERP                                        #
-#    Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>   #
-#                                                                               #
-#    This program is free software: you can redistribute it and/or modify       #
-#    it under the terms of the GNU Affero General Public License as             #
-#    published by the Free Software Foundation, either version 3 of the         #
-#    License, or (at your option) any later version.                            #
-#                                                                               #
-#    This program is distributed in the hope that it will be useful,            #
-#    but WITHOUT ANY WARRANTY; without even the implied warranty of             #
-#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              #
-#    GNU Affero General Public License for more details.                        #
-#                                                                               #
-#    You should have received a copy of the GNU Affero General Public License   #
-#    along with this program.  If not, see <http://www.gnu.org/licenses/>.      #
-#                                                                               #
-#################################################################################
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Copyright 2011-2013 Akretion
+#    @author Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
 
 from openerp.osv.orm import Model
 from openerp.osv import fields

=== modified file 'connector_ecommerce/account_view.xml' (properties changed: +x to -x)
--- base_sale_multichannels/account_view.xml	2012-10-25 17:28:02 +0000
+++ connector_ecommerce/account_view.xml	2013-12-05 13:14:00 +0000
@@ -3,10 +3,9 @@
     <data>
 
         <record id="view_tax_form" model="ir.ui.view">
-            <field name="name">base_sale_multichannels.view_tax_form</field>
+            <field name="name">connector_ecommerce.view_tax_form</field>
             <field name="model">account.tax</field>
             <field name="inherit_id" ref="account.view_tax_form" />
-            <field name="type">form</field>
             <field name="arch" type="xml">
                 <field name="active" position="after">
                     <field name="group_id"/>
@@ -18,7 +17,6 @@
         <record id="view_tax_group_tree" model="ir.ui.view">
             <field name="name">account.tax.group</field>
             <field name="model">account.tax.group</field>
-            <field name="type">tree</field>
             <field name="arch" type="xml">
                 <tree string="Account Tax Group">
                     <field name="name"/>
@@ -30,7 +28,6 @@
         <record id="view_tax_group_form" model="ir.ui.view">
             <field name="name">account.tax.group</field>
             <field name="model">account.tax.group</field>
-            <field name="type">form</field>
             <field name="arch" type="xml">
                 <form string="Account Tax Group">
                     <field name="name" colspan="4"/>

=== renamed file 'base_sale_multichannels/base_sale_data.xml' => 'connector_ecommerce/ecommerce_data.xml'
--- base_sale_multichannels/base_sale_data.xml	2012-09-06 12:34:40 +0000
+++ connector_ecommerce/ecommerce_data.xml	2013-12-05 13:14:00 +0000
@@ -42,5 +42,37 @@
             <field name="categ_id" ref="product_categ_services"/>
         </record>
 
+        <record id="excep_parent_order_need_cancel" model="sale.exception">
+            <field name="name">Parent sales order canceled on the backend.</field>
+            <field name="description">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.</field>
+            <field name="sequence">30</field>
+            <field name="model">sale.order</field>
+            <field name="code">if order.parent_need_cancel:
+    failed = True</field>
+            <field name="active" eval="True"/>
+        </record>
+
+        <record id="excep_order_need_cancel" model="sale.exception">
+            <field name="name">Sales order canceled on the backend.</field>
+            <field name="description">The sales order has been canceled on the backend.</field>
+            <field name="sequence">20</field>
+            <field name="model">sale.order</field>
+            <field name="code">if order.need_cancel:
+    failed = True</field>
+            <field name="active" eval="True"/>
+        </record>
+
+        <record id="excep_product_has_checkpoint" model="sale.exception">
+            <field name="name">A product needs to be reviewed.</field>
+            <field name="description">A product has been imported from a backend and needs to be reviewed.
+Go to Connectors > Checkpoint and review the new products.</field>
+            <field name="sequence">20</field>
+            <field name="model">sale.order.line</field>
+            <field name="code">if object.product_id and object.product_id.has_checkpoint:
+    failed = True</field>
+            <field name="active" eval="True"/>
+        </record>
+
     </data>
 </openerp>

=== added file 'connector_ecommerce/event.py'
--- connector_ecommerce/event.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/event.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,87 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Joel Grand-Guillaume
+#    Copyright 2013 Camptocamp SA
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.addons.connector.event import Event
+
+
+on_picking_out_done = Event()
+"""
+``on_picking_out_done`` is fired when an outgoing picking has been
+marked as done.
+
+Listeners should take the following arguments:
+
+ * session: `connector.session.ConnectorSession` object
+ * model_name: name of the model
+ * record_id: id of the record
+ * type: 'partial' or 'complete' depending on the picking done
+"""
+
+
+on_tracking_number_added = Event()
+"""
+``on_tracking_number_added`` is fired when a picking has been marked as
+ done and a tracking number has been added to it (write).
+
+Listeners should take the following arguments:
+
+ * session: `connector.session.ConnectorSession` object
+ * model_name: name of the model
+ * record_id: id of the record
+"""
+
+
+on_invoice_paid = Event()
+"""
+``on_invoice_paid`` is fired when an invoice has been paid.
+
+Listeners should take the following arguments:
+
+ * session: `connector.session.ConnectorSession` object
+ * model_name: name of the model
+ * record_id: id of the record
+"""
+
+on_invoice_validated = Event()
+"""
+``on_invoice_validated`` is fired when an invoice has been validated.
+
+Listeners should take the following arguments:
+
+ * session: `connector.session.ConnectorSession` object
+ * model_name: name of the model
+ * record_id: id of the record
+"""
+
+on_product_price_changed = Event()
+"""
+``on_product_price_changed`` is fired when the price of a product is
+changed. Specifically, it is fired when one of the products' fields used
+in the sale pricelists are modified.
+
+There is no guarantee that's the price actually changed,
+because it depends on the pricelists.
+
+ * session: `connector.session.ConnectorSession` object
+ * model_name: name of the model
+ * record_id: id of the record
+
+"""

=== added file 'connector_ecommerce/i18n/connector_ecommerce.pot'
--- connector_ecommerce/i18n/connector_ecommerce.pot	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/i18n/connector_ecommerce.pot	2013-12-05 13:14:00 +0000
@@ -0,0 +1,354 @@
+# Translation of OpenERP Server.
+# This file contains the translation of the following modules:
+#	* connector_ecommerce
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: OpenERP Server 7.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2013-05-01 14:34+0000\n"
+"PO-Revision-Date: 2013-05-01 14:34+0000\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
+#: field:sale.order,cancellation_resolved:0
+msgid "Cancellation from the backend resolved"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:sale.exception,description:connector_ecommerce.excep_product_has_checkpoint
+msgid "A product has been imported from a backend and needs to be reviewed.\n"
+"Go to Connectors > Checkpoint and review the new products."
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_account_invoice
+msgid "Invoice"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "Confirm"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Ignore backend's cancellation, Keep Open"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Canceled in backend, to cancel"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Only sales orders canceled in their backend"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:sale.exception,description:connector_ecommerce.excep_parent_order_need_cancel
+msgid "The parent sales order has been canceled on the backend.\n"
+"You will not be able to process this sales order until the parent's one is canceled."
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:payment.method:0
+msgid "The sales orders using the payment method will always be imported."
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "This sales order has been canceled from the backend.\n"
+"                    The usual action would be to cancel it in OpenERP along\n"
+"                    all the documents generated (delivery orders, invoices, ...)."
+msgstr ""
+
+#. module: connector_ecommerce
+#: help:account.tax,group_id:0
+msgid "Choose the tax group. This is needed for example with magento or prestashop"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_stock_picking
+msgid "Picking List"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.actions.act_window,name:connector_ecommerce.action_sale_ignore_cancel
+#: view:sale.ignore.cancel:0
+msgid "Ignore the cancellation on the Backend"
+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,name:connector_ecommerce.model_sale_ignore_cancel
+msgid "Ignore Sales Order Cancel"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_product_product
+msgid "Product"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_payment_method
+msgid "Payment Method"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.actions.act_window,name:connector_ecommerce.action_tax_group_form
+#: model:ir.ui.menu,name:connector_ecommerce.menu_action_tax_group_form
+msgid "Tax Groups"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "View Parent Sales Order"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:stock.picking,related_backorder_ids:0
+msgid "Related backorders"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:account.tax.group:0
+msgid "Account Tax Group"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:payment.method,days_before_cancel:0
+msgid "Days before cancel"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:payment.method:0
+msgid "The sales orders using the payment method will never be imported."
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:sale.ignore.cancel,reason:0
+msgid "Reason"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:sale.exception,name:connector_ecommerce.excep_order_need_cancel
+msgid "Sales order canceled on the backend."
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_sale_shop
+msgid "Sales Shop"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:product.category,name:connector_ecommerce.product_categ_services
+msgid "Services"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Other Information"
+msgstr ""
+
+#. module: connector_ecommerce
+#: help:product.template,tax_group_id:0
+msgid "Tax group are used with some external system like magento or prestashop"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:product.price.type,pricelist_item_ids:0
+msgid "Pricelist Items"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:sale.order,parent_need_cancel:0
+msgid "A parent sales orders needs cancel"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:payment.method:0
+msgid "Import Rules"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:payment.method,import_rule:0
+msgid "Import Rule"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "However, if for any reason you need to keep it open in OpenERP,\n"
+"                    write the reason here and it will stay open."
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:payment.method:0
+msgid "The sales orders using the payment method will be imported\n"
+"                                only when they receive a payment on the E-Commerce backend."
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:account.tax.group,tax_ids:0
+msgid "Taxes"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:sale.exception,description:connector_ecommerce.excep_order_need_cancel
+msgid "The sales order has been canceled on the backend."
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:sale.order,need_cancel:0
+msgid "Need to be canceled"
+msgstr ""
+
+#. module: connector_ecommerce
+#: help:sale.order,parent_need_cancel:0
+msgid "A parent sales orders has been canceled on the backend and needs to be canceled."
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:account.tax,group_id:0
+#: field:product.template,tax_group_id:0
+msgid "Tax Group"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:account.invoice:0
+msgid "Payments"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:sale.exception,name:connector_ecommerce.excep_parent_order_need_cancel
+msgid "Parent sales order canceled on the backend."
+msgstr ""
+
+#. module: connector_ecommerce
+#: help:sale.order,need_cancel:0
+msgid "Has been canceled on the backend, need to be canceled."
+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,name:connector_ecommerce.model_sale_order
+msgid "Sales Order"
+msgstr ""
+
+#. module: connector_ecommerce
+#: help:payment.method,days_before_cancel:0
+msgid "After 'n' days, if the 'Import Rule' is not fulfilled, the import of the sale order will be canceled."
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_product_template
+msgid "Product Template"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_stock_picking_out
+msgid "Delivery Orders"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:product.template,name:connector_ecommerce.product_product_shipping_product_template
+msgid "Shipping costs"
+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
+#: field:sale.order,canceled_in_backend:0
+msgid "Canceled in backend"
+msgstr ""
+
+#. module: connector_ecommerce
+#: help:account.invoice,sale_order_ids:0
+msgid "This is the list of sale orders related to this invoice."
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_account_tax_group
+msgid "account tax group"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_account_tax
+msgid "Tax"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:account.invoice:0
+#: view:product.product:0
+#: view:sale.order:0
+#: view:stock.picking.out:0
+msgid "Connectors"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:sale.exception,name:connector_ecommerce.excep_product_has_checkpoint
+msgid "A product needs to be reviewed."
+msgstr ""
+
+#. module: connector_ecommerce
+#: help:sale.order,parent_id:0
+msgid "A parent sales order is a sales order replaced by this one."
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "Cancel"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:sale.order,parent_id:0
+msgid "Parent Order"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:account.tax.group,name:0
+msgid "Name"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:account.invoice,sale_order_ids:0
+msgid "Sale Orders"
+msgstr ""
+
+#. module: connector_ecommerce
+#: field:product.product,has_checkpoint:0
+msgid "Has Checkpoint"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "or"
+msgstr ""
+
+#. module: connector_ecommerce
+#: view:stock.picking.out:0
+msgid "Additional Info"
+msgstr ""
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_product_price_type
+msgid "Price Type"
+msgstr ""
+

=== added file 'connector_ecommerce/i18n/fr.po'
--- connector_ecommerce/i18n/fr.po	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/i18n/fr.po	2013-12-05 13:14:00 +0000
@@ -0,0 +1,360 @@
+# Translation of OpenERP Server.
+# This file contains the translation of the following modules:
+#	* connector_ecommerce
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: OpenERP Server 7.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2013-05-01 14:17+0000\n"
+"PO-Revision-Date: 2013-05-01 14:17+0000\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
+#: field:sale.order,cancellation_resolved:0
+msgid "Cancellation from the backend resolved"
+msgstr "Annulation depuis le backend résolue"
+
+#. module: connector_ecommerce
+#: model:sale.exception,description:connector_ecommerce.excep_product_has_checkpoint
+msgid "A product has been imported from a backend and needs to be reviewed.\n"
+"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."
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_account_invoice
+msgid "Invoice"
+msgstr "Facture"
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "Confirm"
+msgstr "Confirmer"
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Ignore backend's cancellation, Keep Open"
+msgstr "Ignorer l'annulation du backend, laisser ouvert."
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Canceled in backend, to cancel"
+msgstr "Annulé dans le backend, à annuler"
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Only sales orders canceled in their backend"
+msgstr "Uniquement les commandes annulées dans leur backend"
+
+#. module: connector_ecommerce
+#: model:sale.exception,description:connector_ecommerce.excep_parent_order_need_cancel
+msgid "The parent sales order has been canceled on the backend.\n"
+"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
+#: view:payment.method:0
+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
+#: view:sale.ignore.cancel:0
+msgid "This sales order has been canceled from the backend.\n"
+"                    The usual action would be to cancel it in OpenERP 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 OpenERP ainsi\n"
+"                    que tous les documents qu'elle a générés (bons de livraison, factures, ...)."
+
+#. module: connector_ecommerce
+#: help:account.tax,group_id:0
+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."
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_stock_picking
+msgid "Picking List"
+msgstr "Liste de colisage"
+
+#. module: connector_ecommerce
+#: model:ir.actions.act_window,name:connector_ecommerce.action_sale_ignore_cancel
+#: view:sale.ignore.cancel:0
+msgid "Ignore the cancellation on the Backend"
+msgstr "Ignorer l'annulation du backend."
+
+#. 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,name:connector_ecommerce.model_sale_ignore_cancel
+msgid "Ignore Sales Order Cancel"
+msgstr "Ignorer les annulations de commandes"
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_product_product
+msgid "Product"
+msgstr "Produit"
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_payment_method
+msgid "Payment Method"
+msgstr "Méthode de paiement"
+
+#. module: connector_ecommerce
+#: model:ir.actions.act_window,name:connector_ecommerce.action_tax_group_form
+#: model:ir.ui.menu,name:connector_ecommerce.menu_action_tax_group_form
+msgid "Tax Groups"
+msgstr "Groupes de taxes"
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "View Parent Sales Order"
+msgstr "Voir la commande parente"
+
+#. module: connector_ecommerce
+#: field:stock.picking,related_backorder_ids:0
+msgid "Related backorders"
+msgstr "Reliquat lié"
+
+#. module: connector_ecommerce
+#: view:account.tax.group:0
+msgid "Account Tax Group"
+msgstr "Groupe de taxes"
+
+#. module: connector_ecommerce
+#: field:payment.method,days_before_cancel:0
+msgid "Days before cancel"
+msgstr "Jours avant annulation"
+
+#. module: connector_ecommerce
+#: view:payment.method:0
+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
+#: field:sale.ignore.cancel,reason:0
+msgid "Reason"
+msgstr "Raison"
+
+#. module: connector_ecommerce
+#: model:sale.exception,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:ir.model,name:connector_ecommerce.model_sale_shop
+msgid "Sales Shop"
+msgstr "Magasins"
+
+#. module: connector_ecommerce
+#: model:product.category,name:connector_ecommerce.product_categ_services
+msgid "Services"
+msgstr "Services"
+
+#. module: connector_ecommerce
+#: view:sale.order:0
+msgid "Other Information"
+msgstr "Autres informations"
+
+#. module: connector_ecommerce
+#: help:product.template,tax_group_id:0
+msgid "Tax group are used with some external system like magento or prestashop"
+msgstr "Les groupes de taxes sont utilisés avec des systèmes externes comme Magento ou Prestashop."
+
+#. module: connector_ecommerce
+#: field:product.price.type,pricelist_item_ids:0
+msgid "Pricelist Items"
+msgstr "Lignes de liste de prix"
+
+#. module: connector_ecommerce
+#: field:sale.order,parent_need_cancel:0
+msgid "A parent sales orders needs cancel"
+msgstr "Une commande parente doit être annulée"
+
+#. module: connector_ecommerce
+#: view:payment.method:0
+msgid "Import Rules"
+msgstr "Règles d'import"
+
+#. module: connector_ecommerce
+#: field:payment.method,import_rule:0
+msgid "Import Rule"
+msgstr "Règle d'import"
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "However, if for any reason you need to keep it open in OpenERP,\n"
+"                    write the reason here and it will stay open."
+msgstr "Cependant, si pour une raison donnée vous devez la laisser ouverte dans OpenERP,\n"
+"                    écrivez la raison ici et confirmez.."
+
+#. module: connector_ecommerce
+#: view:payment.method:0
+msgid "The sales orders using the payment method will be imported\n"
+"                                only when they receive a payment on the E-Commerce backend."
+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
+#: field:account.tax.group,tax_ids:0
+msgid "Taxes"
+msgstr "Taxes"
+
+#. module: connector_ecommerce
+#: model:sale.exception,description:connector_ecommerce.excep_order_need_cancel
+msgid "The sales order has been canceled on the backend."
+msgstr "Les commandes ont été annulées sur leur backend."
+
+#. module: connector_ecommerce
+#: field:sale.order,need_cancel:0
+msgid "Need to be canceled"
+msgstr "Doit être annulée"
+
+#. module: connector_ecommerce
+#: help:sale.order,parent_need_cancel:0
+msgid "A parent sales orders 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
+#: field:account.tax,group_id:0
+#: field:product.template,tax_group_id:0
+msgid "Tax Group"
+msgstr "Groupe de taxes"
+
+#. module: connector_ecommerce
+#: view:account.invoice:0
+msgid "Payments"
+msgstr "Paiements"
+
+#. module: connector_ecommerce
+#: model:sale.exception,name:connector_ecommerce.excep_parent_order_need_cancel
+msgid "Parent sales order canceled on the backend."
+msgstr "Commande parente annulée sur le backend."
+
+#. module: connector_ecommerce
+#: help:sale.order,need_cancel:0
+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:product.template,name:connector_ecommerce.product_product_discount_product_template
+msgid "Discount Coupon"
+msgstr "Bon de réduction"
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_sale_order
+msgid "Sales Order"
+msgstr "Bon de commande"
+
+#. module: connector_ecommerce
+#: help:payment.method,days_before_cancel:0
+msgid "After 'n' days, if the 'Import Rule' is not fulfilled, the import of the sale 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:ir.model,name:connector_ecommerce.model_product_template
+msgid "Product Template"
+msgstr "Template d'article"
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_stock_picking_out
+msgid "Delivery Orders"
+msgstr "Bons de livraison"
+
+#. module: connector_ecommerce
+#: model:product.template,name:connector_ecommerce.product_product_shipping_product_template
+msgid "Shipping costs"
+msgstr "Coûts de livraison"
+
+#. module: connector_ecommerce
+#: model:product.template,name:connector_ecommerce.product_product_cash_on_delivery_product_template
+msgid "Cash on delivery"
+msgstr "Livraison contre remboursement"
+
+#. module: connector_ecommerce
+#: field:sale.order,canceled_in_backend:0
+msgid "Canceled in backend"
+msgstr "Annulée dans le backend"
+
+#. module: connector_ecommerce
+#: help:account.invoice,sale_order_ids:0
+msgid "This is the list of sale orders related to this invoice."
+msgstr "Liste des commandes liées à cette facture."
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_account_tax_group
+msgid "account tax group"
+msgstr "Groupe de taxes"
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_account_tax
+msgid "Tax"
+msgstr "Taxe"
+
+#. module: connector_ecommerce
+#: view:account.invoice:0
+#: view:product.product:0
+#: view:sale.order:0
+#: view:stock.picking.out:0
+msgid "Connectors"
+msgstr "Connecteurs"
+
+#. module: connector_ecommerce
+#: model:sale.exception,name:connector_ecommerce.excep_product_has_checkpoint
+msgid "A product needs to be reviewed."
+msgstr "Un article doit être contrôlé."
+
+#. module: connector_ecommerce
+#: help:sale.order,parent_id:0
+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
+#: view:sale.ignore.cancel:0
+msgid "Cancel"
+msgstr "Annuler"
+
+#. module: connector_ecommerce
+#: field:sale.order,parent_id:0
+msgid "Parent Order"
+msgstr "Commande parente"
+
+#. module: connector_ecommerce
+#: field:account.tax.group,name:0
+msgid "Name"
+msgstr "Nom"
+
+#. module: connector_ecommerce
+#: field:account.invoice,sale_order_ids:0
+msgid "Sale Orders"
+msgstr "Bons de commande"
+
+#. module: connector_ecommerce
+#: field:product.product,has_checkpoint:0
+msgid "Has Checkpoint"
+msgstr "A un point de contrôle"
+
+#. module: connector_ecommerce
+#: view:sale.ignore.cancel:0
+msgid "or"
+msgstr "ou"
+
+#. module: connector_ecommerce
+#: view:stock.picking.out:0
+msgid "Additional Info"
+msgstr "Informations additionnelles"
+
+#. module: connector_ecommerce
+#: model:ir.model,name:connector_ecommerce.model_product_price_type
+msgid "Price Type"
+msgstr "Type de prix"
+

=== modified file 'connector_ecommerce/invoice.py'
--- base_sale_multichannels/invoice.py	2012-08-21 13:57:44 +0000
+++ connector_ecommerce/invoice.py	2013-12-05 13:14:00 +0000
@@ -1,41 +1,55 @@
-# -*- encoding: utf-8 -*-
-###############################################################################
-#                                                                             #
-#   base_sale_multichannels for OpenERP                                       #
-#   Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>  #
-#                                                                             #
-#   This program is free software: you can redistribute it and/or modify      #
-#   it under the terms of the GNU Affero General Public License as            #
-#   published by the Free Software Foundation, either version 3 of the        #
-#   License, or (at your option) any later version.                           #
-#                                                                             #
-#   This program is distributed in the hope that it will be useful,           #
-#   but WITHOUT ANY WARRANTY; without even the implied warranty of            #
-#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             #
-#   GNU Affero General Public License for more details.                       #
-#                                                                             #
-#   You should have received a copy of the GNU Affero General Public License  #
-#   along with this program.  If not, see <http://www.gnu.org/licenses/>.     #
-#                                                                             #
-###############################################################################
-from openerp.osv.orm import Model
-from openerp.osv import fields
-
-class account_invoice(Model):
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Joel Grand-Guillaume
+#    Copyright 2013 Camptocamp SA
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.osv import fields, orm, osv
+from openerp.tools.translate import _
+from openerp.addons.connector.session import ConnectorSession
+from .event import on_invoice_paid, on_invoice_validated
+
+
+class account_invoice(orm.Model):
     _inherit='account.invoice'
-    
-    _columns={
-        'shop_id': fields.many2one('sale.shop', 'Shop', readonly=True, states={'draft': [('readonly', False)]}),
-        'do_not_export': fields.boolean('Do not export',
-                 help="This delivery order will not be exported to the external referential."),
+
+    _columns = {
+        'sale_order_ids': fields.many2many(  # TODO duplicate with 'sale_ids', replace
+            'sale.order',
+            'sale_order_invoice_rel',
+            'invoice_id',
+            'order_id',
+            string='Sale Orders', readonly=True,
+            help="This is the list of sale orders related to this invoice."),
     }
 
-    def _prepare_invoice_refund(self, cr, uid, ids, invoice_vals, date=None, period_id=None, description=None, journal_id=None, context=None):
-        invoice = self.browse(cr, uid, invoice_vals['id'], context=context)
-        invoice_vals = super(account_invoice, self)._prepare_invoice_refund(cr, uid, ids, invoice_vals, date=date, period_id=period_id, 
-                                                    description=description, journal_id=journal_id, context=context)
-        invoice_vals.update({
-                'sale_ids': [(6,0, [sale.id for sale in invoice.sale_ids])],
-                'shop_id': invoice.shop_id.id,
-            })
-        return invoice_vals
+    def confirm_paid(self, cr, uid, ids, context=None):
+        res = super(account_invoice, self).confirm_paid(
+                cr, uid, ids, context=context)
+        session = ConnectorSession(cr, uid, context=context)
+        for record_id in ids:
+            on_invoice_paid.fire(session, self._name, record_id)
+        return res
+
+    def invoice_validate(self, cr, uid, ids, context=None):
+        res = super(account_invoice, self).invoice_validate(
+                cr, uid, ids, context=context)
+        session = ConnectorSession(cr, uid, context=context)
+        for record_id in ids:
+            on_invoice_validated.fire(session, self._name, record_id)
+        return res

=== modified file 'connector_ecommerce/invoice_view.xml'
--- base_sale_multichannels/invoice_view.xml	2012-04-30 23:38:34 +0000
+++ connector_ecommerce/invoice_view.xml	2013-12-05 13:14:00 +0000
@@ -2,18 +2,19 @@
 <openerp>
     <data>
 
-        <record id="invoice_form" model="ir.ui.view">
-            <field name="name">base_sale_multichannel_invoice_form</field>
+        <record id="view_invoice_connector_form" model="ir.ui.view">
+            <field name="name">account.invoice.connector.form</field>
             <field name="model">account.invoice</field>
-            <field name="inherit_id" ref="account.invoice_form" />
-            <field name="type">form</field>
+            <field name="inherit_id" ref="account.invoice_form"/>
             <field name="arch" type="xml">
-                <field name="move_id" position="after">
-                    <field name="shop_id" select="1" />
-                </field>
+                <page string="Payments" position="after">
+                    <!-- change the invisible attribute to 0 when used
+                         in submodules -->
+                    <page name="connector" string="Connectors" invisible="1">
+                    </page>
+                </page>
             </field>
         </record>
 
-
     </data>
 </openerp>

=== modified file 'connector_ecommerce/payment_method.py'
--- base_sale_multichannels/payment_method.py	2012-08-21 13:57:44 +0000
+++ connector_ecommerce/payment_method.py	2013-12-05 13:14:00 +0000
@@ -1,37 +1,52 @@
-# -*- encoding: utf-8 -*-
-#################################################################################
-#                                                                               #
-#    base_sale_multichannels for OpenERP                                        #
-#    Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>   #
-#                                                                               #
-#    This program is free software: you can redistribute it and/or modify       #
-#    it under the terms of the GNU Affero General Public License as             #
-#    published by the Free Software Foundation, either version 3 of the         #
-#    License, or (at your option) any later version.                            #
-#                                                                               #
-#    This program is distributed in the hope that it will be useful,            #
-#    but WITHOUT ANY WARRANTY; without even the implied warranty of             #
-#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              #
-#    GNU Affero General Public License for more details.                        #
-#                                                                               #
-#    You should have received a copy of the GNU Affero General Public License   #
-#    along with this program.  If not, see <http://www.gnu.org/licenses/>.      #
-#                                                                               #
-#################################################################################
-
-
-from openerp.osv.orm import Model
-from openerp.osv import fields
-
-
-
-class payment_method(Model):
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Copyright 2011-2013 Akretion
+#    @author Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.osv import orm, fields
+
+
+class payment_method(orm.Model):
     _inherit = "payment.method"
 
+    def _get_import_rules(self, cr, uid, context=None):
+        return [('always', 'Always'),
+                ('never', 'Never'),
+                ('paid', 'Paid'),
+                ('authorized', 'Authorized'),
+                ]
+
     _columns = {
-        'automatic_update': fields.boolean('Automatic Update',
-                help=("If the order is not paid, OpenERP  will call the external system",
-                     "before each order import in order to know if this order is paid")),
+        # the logic around the 2 following fields has to be implemented
+        # in the connectors (magentoerpconnect, prestashoperpconnect,...)
+        'days_before_cancel': fields.integer(
+            'Days before cancel',
+            help="After 'n' days, if the 'Import Rule' is not fulfilled, the "
+                 "import of the sale order will be canceled."),
+        'import_rule': fields.selection(_get_import_rules,
+                                        string="Import Rule",
+                                        required=True)
+    }
+
+    _defaults = {
+        'import_rule': 'always',
+        'days_before_cancel': 30,
     }
 
     def get_or_create_payment_method(self, cr, uid, payment_method, context=None):
@@ -41,13 +56,14 @@
         :rtype: int
         :return: id of required payment method
         """
-
         pay_method_obj = self.pool.get('payment.method')
-        method_ids = pay_method_obj.search(cr, uid, [['name', '=ilike', payment_method]],
-                                                                                context=context)
+        method_ids = pay_method_obj.search(cr, uid,
+                                           [('name', '=ilike', payment_method)],
+                                           context=context)
         if method_ids:
             method_id = method_ids[0]
         else:
-            method_id = pay_method_obj.create(cr, uid, {'name' : payment_method}, context=context)
-
+            method_id = pay_method_obj.create(cr, uid,
+                                              {'name': payment_method},
+                                              context=context)
         return method_id

=== modified file 'connector_ecommerce/payment_method_view.xml'
--- base_sale_multichannels/payment_method_view.xml	2012-05-06 17:51:58 +0000
+++ connector_ecommerce/payment_method_view.xml	2013-12-05 13:14:00 +0000
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <!--
-  sale_quick_payment for OpenERP
+  sale_automatic_workflow for OpenERP
   Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
   The licence is in the file __openerp__.py
 -->
@@ -10,27 +10,40 @@
 
         <!-- VIEW FOR THE OBJECT : payment_method -->
         <record id="payment_method_view_form" model="ir.ui.view">
-            <field name="name">sale_automatic_workflow.payment_method.view_form</field>
+            <field name="name">payment.method.connector_ecommerce.form</field>
             <field name="model">payment.method</field>
-            <field name="inherit_id" ref="sale_quick_payment.payment_method_view_form" />
-            <field eval="16" name="priority"/>
-            <field name="type">form</field>
+            <field name="inherit_id" ref="sale_automatic_workflow.payment_method_view_form" />
             <field name="arch" type="xml">
-                <field name="payment_term_id" position="after">
-                    <field name="automatic_update" />
-                </field>
+                <group name="general" position="after">
+                    <group name="import_rule" string="Import Rules">
+                        <group>
+                            <field name="import_rule" />
+                            <field name="days_before_cancel" />
+                        </group>
+                        <group name="import_rule_help" class="oe_grey" col="1">
+                            <p attrs="{'invisible': [('import_rule', '!=', 'never')]}">
+                                The sales orders using the payment method will never be imported.
+                            </p>
+                            <p attrs="{'invisible': [('import_rule', '!=', 'always')]}">
+                                The sales orders using the payment method will always be imported.
+                            </p>
+                            <p attrs="{'invisible': [('import_rule', '!=', 'paid')]}">
+                                The sales orders using the payment method will be imported
+                                only when they receive a payment on the E-Commerce backend.<br/>
+                            </p>
+                        </group>
+                    </group>
+                </group>
             </field>
         </record>
 
         <record id="payment_method_view_tree" model="ir.ui.view">
-            <field name="name">sale_automatic_workflow.payment_method.view_tree</field>
+            <field name="name">payment.method.connector_ecommerce.tree</field>
             <field name="model">payment.method</field>
-            <field name="inherit_id" ref="sale_quick_payment.payment_method_view_tree" />
-            <field eval="16" name="priority"/>
-            <field name="type">tree</field>
+            <field name="inherit_id" ref="sale_automatic_workflow.payment_method_view_tree" />
             <field name="arch" type="xml">
-                <field name="payment_term_id" position="after">
-                    <field name="automatic_update" />
+                <field name="workflow_process_id" position="after">
+                    <field name="import_rule" />
                 </field>
             </field>
         </record>

=== modified file 'connector_ecommerce/product.py'
--- base_sale_multichannels/product.py	2013-01-04 10:15:39 +0000
+++ connector_ecommerce/product.py	2013-12-05 13:14:00 +0000
@@ -1,152 +1,175 @@
-    # -*- encoding: utf-8 -*-
-###############################################################################
-#                                                                             #
-#   base_sale_multichannels for OpenERP                                       #
-#   Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>  #
-#                                                                             #
-#   This program is free software: you can redistribute it and/or modify      #
-#   it under the terms of the GNU Affero General Public License as            #
-#   published by the Free Software Foundation, either version 3 of the        #
-#   License, or (at your option) any later version.                           #
-#                                                                             #
-#   This program is distributed in the hope that it will be useful,           #
-#   but WITHOUT ANY WARRANTY; without even the implied warranty of            #
-#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             #
-#   GNU Affero General Public License for more details.                       #
-#                                                                             #
-#   You should have received a copy of the GNU Affero General Public License  #
-#   along with this program.  If not, see <http://www.gnu.org/licenses/>.     #
-#                                                                             #
-###############################################################################
-
-
-from openerp.osv.orm import Model
-from openerp.osv import fields
-from base_external_referentials.decorator import only_for_referential
-from base_external_referentials.decorator import commit_now
-
-class product_product(Model):
-    _inherit='product.product'
-
-    def _check_if_export(self, cr, uid, external_session, product, context=None):
-        if context.get('export_product') == 'simple':
-            return True
-        return False
-
-    @only_for_referential(ref_categ ='Multichannel Sale')
-    def _get_last_exported_date(self, cr, uid, external_session, context=None):
-        shop = external_session.sync_from_object
-        if context.get('export_product') == 'simple':
-            return shop.last_products_export_date
-        elif context.get('export_product') == 'special':
-            return shop.last_special_products_export_date
-        return False
-
-    @only_for_referential(ref_categ ='Multichannel Sale')
-    @commit_now
-    def _set_last_exported_date(self, cr, uid, external_session, date, context=None):
-        shop = external_session.sync_from_object
-        if context.get('export_product') == 'simple':
-            return self.pool.get('sale.shop').write(cr, uid, shop.id, {'last_products_export_date': date}, context=context)
-        elif context.get('export_product') == 'special':
-            return self.pool.get('sale.shop').write(cr, uid, shop.id, {'last_special_products_export_date': date}, context=context)
-
-    @only_for_referential(ref_categ ='Multichannel Sale')
-    def get_ids_and_update_date(self, cr, uid, external_session, ids=None, last_exported_date=None, context=None):
-        res = (), {} # list of ids, dict of ids to date_changed
-        shop = external_session.sync_from_object
-        if shop.exportable_product_ids:
-            product_ids = [product.id for product in shop.exportable_product_ids if self._check_if_export(cr, uid, external_session, product, context=context)]
-            if ids:
-                product_ids = set(ids).intersection(set(product_ids))
-            if product_ids:
-                res = super(product_product, self).get_ids_and_update_date(cr, uid, external_session,
-                                                            ids=product_ids,
-                                                            last_exported_date=last_exported_date,
-                                                            context=context)
-        return res
-
-    def _get_categories_ids_for_shop(self, cr, uid, product_id, shop_id, context=None):
-        shop_obj = self.pool.get('sale.shop')
-        shop_values = shop_obj.read(cr, uid, shop_id,
-                                    ['exportable_category_ids'],
-                                    context=context)
-        shop_categ_ids = set(shop_values['exportable_category_ids'])
-        product = self.read(cr, uid, product_id, ['categ_ids', 'categ_id'], context=context)
-        product_categ_ids = set(product['categ_ids'])
-        product_categ_ids.add(product['categ_id'][0])
-        return list(product_categ_ids & shop_categ_ids)
-
-    def _get_or_create_ext_category_ids_for_shop(self, cr, uid, external_session, product_id, context=None):
-        res = []
-        categ_obj = self.pool.get('product.category')
-        for oe_categ_id in self._get_categories_ids_for_shop(cr, uid, product_id, external_session.sync_from_object.id, context=context):
-            res.append(categ_obj.get_or_create_extid(cr, uid, external_session, oe_categ_id, context=context))
-        return res
-
-class product_template(Model):
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Sébastien BEAU
+#    Copyright 2011-2013 Akretion
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.osv import orm, fields
+from openerp.addons.connector.session import ConnectorSession
+from .event import on_product_price_changed
+
+
+class product_template(orm.Model):
     _inherit = 'product.template'
 
     #TODO implement set function and also support multi tax
     def _get_tax_group_id(self, cr, uid, ids, field_name, args, context=None):
         result = {}
         for product in self.browse(cr, uid, ids, context=context):
-            result[product.id] = product.taxes_id and product.taxes_id[0].group_id.id
+            taxes = product.taxes_id
+            result[product.id] = taxes[0].group_id.id if taxes else False
         return result
 
     _columns = {
-        'tax_group_id': fields.function(_get_tax_group_id,
+        'tax_group_id': fields.function(
+                            _get_tax_group_id,
                             string='Tax Group',
                             type='many2one',
                             relation='account.tax.group',
                             store=False,
-                            help=('Tax group are use with some external',
-                                  ' system like magento or prestashop')),
-    }
-
-
-class product_category(Model):
-    _inherit = "product.category"
-
-    def collect_children(self, category, children=None):
-        if children is None:
-            children = []
-
-        for child in category.child_id:
-            children.append(child.id)
-            self.collect_children(child, children)
-
-        return children
-
-    def _get_recursive_children_ids(self, cr, uid, ids, name, args, context=None):
-        res = {}
-        for category in self.browse(cr, uid, ids):
-            res[category.id] = self.collect_children(category, [category.id])
-        return res
-
-    _columns = {
-        'recursive_children_ids': fields.function(_get_recursive_children_ids, method=True, type='one2many', relation="product.category", string='All Child Categories'),
-    }
-
-    @only_for_referential(ref_categ ='Multichannel Sale')
-    def _get_last_exported_date(self, cr, uid, external_session, context=None):
-        shop = external_session.sync_from_object
-        return shop.last_category_export_date
-
-    @only_for_referential(ref_categ ='Multichannel Sale')
-    @commit_now
-    def _set_last_exported_date(self, cr, uid, external_session, date, context=None):
-        shop = external_session.sync_from_object
-        return self.pool.get('sale.shop').write(cr, uid, shop.id, {'last_category_export_date': date}, context=context)
-
-    def get_ids_and_update_date(self, cr, uid, external_session, ids=None, last_exported_date=None, context=None):
-        shop = external_session.sync_from_object
-        if shop.exportable_category_ids:
-            res = super(product_category, self).get_ids_and_update_date(cr, uid, external_session,
-                                                            ids=[categ.id for categ in shop.exportable_category_ids],
-                                                            last_exported_date=last_exported_date,
-                                                            context=context)
-        else:
-            res = (), {} # list of ids, dict of ids to date_changed
-        return res
-
+                            help='Tax group are used with some external '
+                                 'system like magento or prestashop'),
+    }
+
+    def _price_changed(self, cr, uid, ids, vals, context=None):
+        """ Fire the ``on_product_price_changed`` on all the variants of
+        the template if the price if 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.
+        """
+        if context is None:
+            context = {}
+        type_obj = self.pool['product.price.type']
+        price_fields = type_obj.sale_price_fields(cr, uid, context=context)
+        # restrict the fields to the template ones only, so if
+        # the write has been done on product.product, we won't
+        # update all the variant if a price field of the
+        # variant has been changed
+        tmpl_fields = [field for field in vals if field in self._columns]
+        if any(field in price_fields for field in tmpl_fields):
+            product_obj = self.pool['product.product']
+            session = ConnectorSession(cr, uid, context=context)
+            product_ids = product_obj.search(cr, uid,
+                                             [('product_tmpl_id', 'in', ids)],
+                                             context=context)
+            # when the write is done on the product.product, avoid
+            # to fire the event 2 times
+            if context.get('from_product_ids'):
+                product_ids = list(set(product_ids) -
+                                   set(context['from_product_ids']))
+            for prod_id in product_ids:
+                on_product_price_changed.fire(session,
+                                              product_obj._name,
+                                              prod_id)
+
+    def write(self, cr, uid, ids, vals, context=None):
+        result = super(product_template, self).write(cr, uid, ids,
+                                                     vals, context=context)
+        self._price_changed(cr, uid, ids, vals, context=context)
+        return result
+
+
+class product_product(orm.Model):
+    _inherit = 'product.product'
+
+    def _get_checkpoint(self, cr, uid, ids, name, arg, context=None):
+        result = {}
+        checkpoint_obj = self.pool.get('connector.checkpoint')
+        model_obj = self.pool.get('ir.model')
+        model_id = model_obj.search(cr, uid,
+                                    [('model', '=', 'product.product')],
+                                    context=context)[0]
+        for product_id in ids:
+            point_ids = checkpoint_obj.search(cr, uid,
+                                              [('model_id', '=', model_id),
+                                               ('record_id', '=', product_id),
+                                               ('state', '=', 'need_review')],
+                                              context=context)
+            result[product_id] = bool(point_ids)
+        return result
+
+    _columns = {
+        'has_checkpoint': fields.function(_get_checkpoint,
+                                          type='boolean',
+                                          readonly=True,
+                                          string='Has Checkpoint'),
+    }
+
+    def _price_changed(self, cr, uid, ids, vals, context=None):
+        """ Fire the ``on_product_price_changed`` if the price
+        if 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.
+        """
+        type_obj = self.pool['product.price.type']
+        price_fields = type_obj.sale_price_fields(cr, uid, context=context)
+        if any(field in price_fields for field in vals):
+            session = ConnectorSession(cr, uid, context=context)
+            for prod_id in ids:
+                on_product_price_changed.fire(session, self._name, prod_id)
+
+    def write(self, cr, uid, ids, vals, context=None):
+        if context is None:
+            context = {}
+        context = context.copy()
+        context['from_product_ids'] = ids
+        result = super(product_product, self).write(
+            cr, uid, ids, vals, context=context)
+        self._price_changed(cr, uid, ids, vals, context=context)
+        return result
+
+    def create(self, cr, uid, vals, context=None):
+        product_ids = super(product_product, self).create(
+            cr, uid, vals, context=None)
+        self._price_changed(cr, uid, [product_ids], vals, context=context)
+        return product_ids
+
+
+class product_price_type(orm.Model):
+    _inherit = 'product.price.type'
+
+    _columns = {
+        'pricelist_item_ids': fields.one2many(
+            'product.pricelist.item', 'base',
+            string='Pricelist Items',
+            readonly=True)
+    }
+
+    def sale_price_fields(self, cr, uid, context=None):
+        """ Returns a list of fields used by sale pricelists.
+        Used to know if the sale price could have changed
+        when one of these fields has changed.
+        """
+        item_obj = self.pool['product.pricelist.item']
+        item_ids = item_obj.search(
+            cr, uid,
+            [('price_version_id.pricelist_id.type', '=', 'sale')],
+            context=context)
+        type_ids = self.search(cr, uid,
+                               [('pricelist_item_ids', 'in', item_ids)],
+                               context=context)
+        types = self.read(cr, uid, type_ids, ['field'], context=context)
+        return [t['field'] for t in types]

=== added file 'connector_ecommerce/product_view.xml'
--- connector_ecommerce/product_view.xml	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/product_view.xml	2013-12-05 13:14:00 +0000
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<!--
+    Copyright (C) 2013 Akretion (http://www.akretion.com/)
+    The licence is in the file __openerp__.py
+-->
+
+<openerp>
+<data>
+
+<!--This is a product inherited form that will be dynamically populated-->
+<record id="product_normal_form_view" model="ir.ui.view">
+   <field name="name">product.product.form</field>
+   <field name="model">product.product</field>
+   <field name="inherit_id" ref="product.product_normal_form_view" />
+   <field name="arch" type="xml">
+       <xpath expr="/form/sheet/notebook" position="inside">
+           <!-- change the invisible attribute to 0 when used
+                in submodules -->
+           <page string="Connectors" name="connector" invisible="1">
+           </page>
+       </xpath>
+   </field>
+</record>
+
+
+
+</data>
+</openerp>

=== added file 'connector_ecommerce/sale.py'
--- connector_ecommerce/sale.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/sale.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,408 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Guewen Baconnier
+#    Copyright 2011-2013 Camptocamp SA
+#    Author: Sébastien Beau
+#    Copyright 2010-2013 Akretion
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.osv import orm, fields, osv
+from openerp.tools.translate import _
+from openerp import netsvc
+
+
+class sale_shop(orm.Model):
+    _inherit = 'sale.shop'
+
+    def _get_payment_default(self, cr, uid, context=None):
+        """ Return a arbitrary account.payment.term record for the sale.shop
+
+        ``sale.shop`` records are created dynamically from the backends
+        and the field ``payment_default_id`` needs a default value.
+        """
+        data_obj = self.pool.get('ir.model.data')
+        __, payment_id = data_obj.get_object_reference(
+                cr, uid, 'account', 'account_payment_term_immediate')
+        return payment_id
+
+    _defaults = {
+        # see method docstring for explanation
+        'payment_default_id': _get_payment_default,
+    }
+
+
+class sale_order(orm.Model):
+    """ Add a cancellation mecanism in the sales orders
+
+    When a sale 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'
+    sale 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 sale 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'
+
+    def _get_parent_id(self, cr, uid, ids, name, arg, context=None):
+        return self.get_parent_id(cr, uid, ids, context=context)
+
+    def get_parent_id(self, cr, uid, ids, context=None):
+        """ Need to be inherited in the connectors to implement the
+        parent logic.
+
+        See an implementation example in ``magentoerpconnect``.
+        """
+        return dict.fromkeys(ids, False)
+
+    def _get_need_cancel(self, cr, uid, ids, name, arg, context=None):
+        result = {}
+        for order in self.browse(cr, uid, ids, context=context):
+            result[order.id] = self._need_cancel(cr, uid, order,
+                                                 context=context)
+        return result
+
+    def _get_parent_need_cancel(self, cr, uid, ids, name, arg, context=None):
+        result = {}
+        for order in self.browse(cr, uid, ids, context=context):
+            result[order.id] = self._parent_need_cancel(cr, uid, order,
+                                                        context=context)
+        return result
+
+    _columns = {
+        'canceled_in_backend': fields.boolean('Canceled in backend',
+                                               readonly=True),
+        # set to True when the cancellation from the backend is
+        # resolved, either because the SO has been canceled or
+        # because the user manually chosed to keep it open
+        'cancellation_resolved': fields.boolean('Cancellation from the '
+                                                'backend resolved'),
+        'parent_id': fields.function(_get_parent_id,
+                                     string='Parent Order',
+                                     type='many2one',
+                                     help='A parent sales order is a sales '
+                                          'order replaced by this one.',
+                                     relation='sale.order'),
+        'need_cancel': fields.function(_get_need_cancel,
+                                       string='Need to be canceled',
+                                       type='boolean',
+                                       help='Has been canceled on the backend'
+                                            ', need to be canceled.'),
+        'parent_need_cancel': fields.function(
+            _get_parent_need_cancel,
+            string='A parent sales orders needs cancel',
+            type='boolean',
+            help='A parent sales orders has been canceled on the backend'
+                 ' and needs to be canceled.'),
+    }
+
+    def _need_cancel(self, cr, uid, order, context=None):
+        """ Return True if the sales order need to be canceled
+        (has been canceled on the Backend) """
+        return order.canceled_in_backend and not order.cancellation_resolved
+
+    def _parent_need_cancel(self, cr, uid, order, context=None):
+        """ 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.
+        """
+        def need_cancel(order):
+            if self._need_cancel(cr, uid, order, context=context):
+                return True
+            if order.parent_id:
+                return need_cancel(order.parent_id)
+            else:
+                return False
+        if not order.parent_id:
+            return False
+        return need_cancel(order.parent_id)
+
+    def _try_auto_cancel(self, cr, uid, ids, context=None):
+        """ Try to automatically cancel a sales order canceled
+        in a backend.
+
+        If it can't cancel it, does nothing.
+        """
+        wkf_states = ('draft', 'sent')
+        action_states = ('manual', 'progress')
+        wf_service = netsvc.LocalService("workflow")
+        resolution_msg = _("<p>Resolution:<ol>"
+                           "<li>Cancel the linked invoices, delivery "
+                           "orders, automatic payments.</li>"
+                           "<li>Cancel the sales order manually.</li>"
+                           "</ol></p>")
+        for order_id in ids:
+            state = self.read(cr, uid, order_id,
+                              ['state'], context=context)['state']
+            if state == 'cancel':
+                continue
+            elif state == 'done':
+                message = _("The sales order cannot be automatically "
+                            "canceled because it is already done.")
+            elif state in wkf_states + action_states:
+                try:
+                    # respect the same cancellation methods than
+                    # the sales order view: quotations use the workflow
+                    # action, sales orders use the action_cancel method.
+                    if state in wkf_states:
+                        wf_service.trg_validate(uid, 'sale.order',
+                                                order_id, 'cancel', cr)
+                    elif state in action_states:
+                        self.action_cancel(cr, uid, order_id, context=context)
+                    else:
+                        raise ValueError('%s should not fall here.' % state)
+                except osv.except_osv:
+                    # the 'cancellation_resolved' flag will stay to False
+                    message = _("The sales order could not be automatically "
+                                "canceled.") + resolution_msg
+                else:
+                    message = _("The sales order has been automatically "
+                                "canceled.")
+            else:
+                # shipping_except, invoice_except, ...
+                # can not be canceled from the view, so assume that it
+                # should not be canceled here neiter, exception to
+                # resolve
+                message = _("The sales order could not be automatically "
+                            "canceled for this status.") + resolution_msg
+            self.message_post(cr, uid, [order_id], body=message,
+                              context=context)
+
+    def _log_canceled_in_backend(self, cr, uid, ids, context=None):
+        message = _("The sales order has been canceled on the backend.")
+        self.message_post(cr, uid, ids, body=message, context=context)
+        for order in self.browse(cr, uid, ids, context=context):
+            message = _("Warning: the origin sales order %s has been canceled "
+                        "on the backend.") % order.name
+            if order.picking_ids:
+                picking_obj = self.pool.get('stock.picking')
+                picking_obj.message_post(cr, uid, order.picking_ids,
+                                         body=message, context=context)
+            if order.invoice_ids:
+                picking_obj = self.pool.get('account.invoice')
+                picking_obj.message_post(cr, uid, order.invoice_ids,
+                                         body=message, context=context)
+
+    def create(self, cr, uid, values, context=None):
+        order_id = super(sale_order, self).create(cr, uid, values,
+                                                  context=context)
+        if values.get('canceled_in_backend'):
+            self._log_canceled_in_backend(cr, uid, [order_id], context=context)
+            self._try_auto_cancel(cr, uid, [order_id], context=context)
+        return order_id
+
+    def write(self, cr, uid, ids, values, context=None):
+        result = super(sale_order, self).write(cr, uid, ids, values,
+                                               context=context)
+        if values.get('canceled_in_backend'):
+            self._log_canceled_in_backend(cr, uid, ids, context=context)
+            self._try_auto_cancel(cr, uid, ids, context=context)
+        return result
+
+    def action_cancel(self, cr, uid, ids, context=None):
+        if not hasattr(ids, '__iter__'):
+            ids = [ids]
+        super(sale_order, self).action_cancel(cr, uid, ids, context=context)
+        sales = self.read(cr, uid, ids,
+                          ['canceled_in_backend',
+                           'cancellation_resolved'],
+                          context=context)
+        for sale in sales:
+            # the sale order is canceled => considered as resolved
+            if (sale['canceled_in_backend'] and
+                    not sale['cancellation_resolved']):
+                self.write(cr, uid, sale['id'],
+                           {'cancellation_resolved': True},
+                           context=context)
+        return True
+
+    def ignore_cancellation(self, cr, uid, ids, reason, context=None):
+        """ Manually set the cancellation from the backend as resolved.
+
+        The user can choose to keep the sale order active for some reason,
+        so it just push a button to keep it alive.
+        """
+        message = (_("Despite the cancellation of the sales order on the "
+                     "backend, it should stay open.<br/><br/>Reason: %s") %
+                   reason)
+        self.message_post(cr, uid, ids, body=message, context=context)
+        self.write(cr, uid, ids,
+                   {'cancellation_resolved': True},
+                   context=context)
+        return True
+
+    def action_view_parent(self, cr, uid, ids, context=None):
+        """ Return an action to display the parent sale order """
+        if isinstance(ids, (list, tuple)):
+            assert len(ids) == 1
+            ids = ids[0]
+
+        mod_obj = self.pool.get('ir.model.data')
+        act_obj = self.pool.get('ir.actions.act_window')
+
+        parent = self.browse(cr, uid, ids, context=context).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')
+
+        ref = mod_obj.get_object_reference(cr, uid, *action_xmlid)
+        action_id = False
+        if ref:
+            __, action_id = ref
+        action = act_obj.read(cr, uid, [action_id], context=context)[0]
+
+        ref = mod_obj.get_object_reference(cr, uid, *view_xmlid)
+        action['views'] = [(ref[1] if ref else False, 'form')]
+        action['res_id'] = parent.id
+        return action
+
+    # XXX the 3 next methods seems very specific to magento
+    def _convert_special_fields(self, cr, uid, vals, order_lines, context=None):
+        """ Convert the special 'fake' field into an order line.
+
+        Special fields are:
+        - shipping amount and shipping_tax_rate
+        - cash_on_delivery and cash_on_delivery_taxe_rate
+        - gift_certificates
+
+        :param vals: values of the sale order to create
+        :type vals: dict
+        :param order_lines: lines of the orders to import
+        :return: the value for the sale order with the special field converted
+        :rtype: dict
+        """
+        shipping_fields = ['shipping_amount_tax_excluded',
+                           'shipping_amount_tax_included',
+                           'shipping_tax_amount']
+
+        def check_key(keys):
+            return len(set(shipping_fields) & set(keys)) >= 2
+
+        vals.setdefault('order_line', [])
+        for line in order_lines:
+            for field in shipping_fields:
+                if field in line[2]:
+                    vals[field] = vals.get(field, 0.0) + line[2][field]
+                    del line[2][field]
+
+        if not 'shipping_tax_rate' in vals and check_key(vals.keys()):
+            if not 'shipping_amount_tax_excluded' in vals:
+                vals['shipping_amount_tax_excluded'] = vals['shipping_amount_tax_included'] - vals['shipping_tax_amount']
+            elif not 'shipping_tax_amount' in vals:
+                vals['shipping_tax_amount'] = vals['shipping_amount_tax_included'] - vals['shipping_amount_tax_excluded']
+            if vals['shipping_amount_tax_excluded']:
+                vals['shipping_tax_rate'] = vals['shipping_tax_amount'] / vals['shipping_amount_tax_excluded']
+            else:
+                vals['shipping_tax_rate'] = 0.
+            del vals['shipping_tax_amount']
+        for option in self._get_special_fields(cr, uid, context=context):
+            vals = self._add_order_extra_line(cr, uid, vals,
+                                              option, context=context)
+        return vals
+
+    def _get_special_fields(self, cr, uid, context=None):
+        return [
+            {
+            'price_unit_tax_excluded': 'shipping_amount_tax_excluded',
+            'price_unit_tax_included': 'shipping_amount_tax_included',
+            'tax_rate_field': 'shipping_tax_rate',
+            'product_ref': ('connector_ecommerce', 'product_product_shipping'),
+            },
+            {
+            'tax_rate_field': 'cash_on_delivery_taxe_rate',
+            'price_unit_tax_excluded': 'cash_on_delivery_amount_tax_excluded',
+            'price_unit_tax_included': 'cash_on_delivery_amount_tax_included',
+            'product_ref': ('connector_ecommerce', 'product_product_cash_on_delivery'),
+            },
+            {
+            #gift certificate doesn't have any tax
+            'price_unit_tax_excluded': 'gift_certificates_amount',
+            'price_unit_tax_included': 'gift_certificates_amount',
+            'product_ref': ('connector_ecommerce', 'product_product_gift'),
+            'code_field': 'gift_certificates_code',
+            'sign': -1,
+            },
+        ]
+
+    def _get_order_extra_line_vals(self, cr, uid, vals, option, product,
+                                   price_unit, context=None):
+        return {
+            'product_id': product.id,
+            'name': product.name,
+            'product_uom': product.uom_id.id,
+            'product_uom_qty': 1,
+            'price_unit': price_unit
+        }
+
+    def _add_order_extra_line(self, cr, uid, vals, option, context=None):
+        """ Add or substract amount on order as a separate line item
+        with single quantity for each type of amounts like: shipping,
+        cash on delivery, discount, gift certificates...
+
+        :param dict vals: values of the sale order to create
+        :param option: dictionary of options for the special field to process
+        """
+        if context is None:
+            context = {}
+        sign = option.get('sign', 1)
+        if (context.get('is_tax_included') and
+                vals.get(option['price_unit_tax_included'])):
+            price_unit = vals.pop(option['price_unit_tax_included']) * sign
+        elif vals.get(option['price_unit_tax_excluded']):
+            price_unit = vals.pop(option['price_unit_tax_excluded']) * sign
+        else:
+            return self._clean_special_fields(option, vals)
+        model_data_obj = self.pool.get('ir.model.data')
+        product_obj = self.pool.get('product.product')
+        __, product_id = model_data_obj.get_object_reference(
+            cr, uid, *option['product_ref'])
+        product = product_obj.browse(cr, uid, product_id, context=context)
+
+        extra_line = self._get_order_extra_line_vals(
+            cr, uid, vals, option, product, price_unit, context=context)
+
+        ext_code_field = option.get('code_field')
+        if ext_code_field and vals.get(ext_code_field):
+            extra_line['name'] = "%s [%s]" % (extra_line['name'],
+                                              vals[ext_code_field])
+        vals['order_line'].append((0, 0, extra_line))
+
+        return self._clean_special_fields(option, vals)
+
+    def _clean_special_fields(self, option, vals):
+        for key in ['price_unit_tax_excluded',
+                    'price_unit_tax_included',
+                    'tax_rate_field']:
+            if option.get(key) and option[key] in vals:
+                del vals[option[key]]
+        return vals  # if there is no price, we have nothing to import

=== modified file 'connector_ecommerce/sale_view.xml' (properties changed: +x to -x)
--- base_sale_multichannels/sale_view.xml	2012-12-20 15:09:51 +0000
+++ connector_ecommerce/sale_view.xml	2013-12-05 13:14:00 +0000
@@ -2,220 +2,62 @@
 <openerp>
     <data>
 
-        <record model="ir.ui.view" id="base_sale_multichannels_view_shop_form">
-            <field name="name">base_sale_multichannels_view_shop_form</field>
-            <field name="model">sale.shop</field>
-            <field name="inherit_id" ref="sale.view_shop_form" />
-            <field name="type">form</field>
+        <record id="view_order_connector_form" model="ir.ui.view">
+            <field name="name">sale.order.connector.form</field>
+            <field name="model">sale.order</field>
+            <field name="inherit_id" ref="sale.view_order_form"/>
             <field name="arch" type="xml">
-                <data>
-                    <field name="payment_default_id" position="after">
-                        <field name="sale_journal" domain="[('type','=','sale')]"/>
-                    </field>
-                    <form position="inside">
-                        <separator string="Sale Multi Channels" colspan="4" />
-                        <notebook colspan="4">
-                            <page string="External Shop Settings">
-                                <group col="4" colspan="4">
-                                    <field name="referential_id" />
-                                    <field name="shop_group_id" />
-                                    <field name="type_name" invisible="True"/>
-                                </group>
-                            </page>
-                            <page string="Extra Information">
-                                <separator string='Accounting' colspan="4"/>
-                                    <field name="auto_import"/>
-                                    <field name="is_tax_included"/>
-                                    <field name="use_external_tax"/>
-                                    <field name="check_total_amount"/>
-                                    <field name="order_prefix"/>
-                                    <field name="default_payment_method_id"/>
-                                    <field name="default_fiscal_position"/>
-                                    <field name="default_customer_account"/>
-                                    <field name="default_customer_lang"/>
-                                <separator string='Stock' colspan="4"/>
-                                    <field name="product_stock_field_id"/>
-                                <separator string='Other Information' colspan="4"/>
-                                    <field name="address_id" colspan="2" />
-                                    <field name="website" colspan="2" />
-                                    <field name="image" widget='image' colspan="2" />
-                            </page>
-                        </notebook>
-                    </form>
-                </data>
+                <page string="Other Information" position="after">
+                    <!-- change the invisible attribute to 0 when used
+                         in submodules -->
+                    <page name="connector" string="Connectors" invisible="1">
+                    </page>
+                </page>
             </field>
         </record>
 
-        <record model="ir.ui.view" id="base_sale_multichannel_view_order_tree">
-            <field name="name">base_sale_multichannel_view_order_tree</field>
+        <record id="sale_order_view_form" model="ir.ui.view">
+            <field name="name">sale_order.view_form</field>
             <field name="model">sale.order</field>
-            <field name="inherit_id" ref="sale.view_order_tree" />
-            <field name="type">form</field>
+            <field name="inherit_id" ref="sale_automatic_workflow.sale_order_view_form" />
             <field name="arch" type="xml">
-                <field name="state" position="after">
-                    <field name="need_to_update" />
-                </field>
-                <field name="amount_total" position="after">
-                    <field name="ext_total_amount" string="Ext. Total" />
-                </field>
+                <field name="workflow_process_id" position="after">
+                    <field name="canceled_in_backend"/>
+                    <field name="cancellation_resolved" invisible="1"/>
+                </field>
+                <button name="invoice_recreate" position="before">
+                    <field name="parent_id" invisible="1"/>
+                    <button name="action_view_parent"
+                        string="View Parent Sales Order"
+                        type="object" class="oe_highlight"
+                        attrs="{'invisible': [('parent_id', '=', False)]}"
+                        groups="base.group_user"/>
+                </button>
+                <button name="invoice_cancel" position="after">
+                    <button name="%(action_sale_ignore_cancel)d"
+                        type="action"
+                        attrs="{'invisible': ['|', '|', ('canceled_in_backend', '=', False), ('cancellation_resolved', '=', True), ('state', '==', 'cancel')]}"
+                        string="Ignore backend's cancellation, Keep Open"
+                        groups="base.group_sale_manager"/>
+                </button>
             </field>
         </record>
 
         <record id="view_sales_order_filter" model="ir.ui.view">
-            <field name="name">base_sale_multichannel.view_sales_order_filter</field>
+            <field name="name">sale.order.search</field>
             <field name="model">sale.order</field>
-            <field name="inherit_id" ref="sale.view_sales_order_filter" />
-            <field name="type">search</field>
-            <field eval="32" name="priority"/>
+            <field name="inherit_id" ref="sale.view_sales_order_filter"/>
             <field name="arch" type="xml">
-                <filter icon="terp-check" string="Sales" position="after">
-                    <separator orientation="vertical"/>
-                    <filter icon="gtk-refresh" name="to-update" string="TO UPDATE" domain="[('need_to_update','!=',False)]"/>
+                <filter name="my_sale_orders_filter" position="after">
+                    <filter string="Canceled in backend, to cancel"
+                        domain="[('canceled_in_backend', '=', True),
+                                 ('cancellation_resolved', '=', False),
+                                 ('state', '!=', 'cancel')]"
+                        help="Only sales orders canceled in their backend"
+                        name="canceled_in_backend_filter"/>
                 </filter>
             </field>
         </record>
 
-        <record model="ir.ui.view" id="base_sale_multichannel_view_order_form">
-            <field name="name">base_sale_multichannel_view_order_form</field>
-            <field name="model">sale.order</field>
-            <field name="inherit_id" ref="sale_automatic_workflow.sale_order_view_form" />
-            <field name="type">form</field>
-            <field eval="30" name="priority"/>
-            <field name="arch" type="xml">
-                <data>
-                    <group name="automatic_workflow" position="after">
-                        <field name="referential_id" invisible="True"/>
-                        <group name="external_payment" attrs="{'invisible': [('referential_id', '=', False)]}">
-                            <separator string="External Payment" colspan="4"/>
-                            <field name="ext_total_amount" />
-                            <field name="ext_total_amount_tax"/>
-                            <field name="need_to_update" />
-                        </group>
-                    </group>
-                    <xpath expr="/form/notebook/page/field/form/notebook/page[@string='Order Line']/group" position="after">
-                        <group name='External Information' colspan="4">
-                            <separator string="External Information" colspan="4" />
-                            <field name="ext_product_ref" />
-                            <field name="ext_ref_line" select="1" />
-                        </group>
-                    </xpath>
-                </data>
-            </field>
-        </record>
-
-        <record model="ir.ui.view" id="base_sale_multichannel_view_order_line_tree">
-            <field name="name">base_sale_multichannel_view_order_tree</field>
-            <field name="model">sale.order.line</field>
-            <field name="inherit_id" ref="sale.view_order_line_tree" />
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                <data>
-                    <field name="product_id" position="after">
-                        <field name="ext_product_ref" />
-                    </field>
-                </data>
-            </field>
-        </record>
-
-        <record model="ir.ui.view" id="base_sale_multichannel_view_order_line_form">
-            <field name="name">base_sale_multichannel_view_order_form</field>
-            <field name="model">sale.order.line</field>
-            <field name="inherit_id" ref="sale.view_order_line_form2" />
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                <data>
-                    <field name="notes" position="after">
-                        <group name='External Syncronization' colspan="4">
-                            <separator string="External syncronization" colspan="4" />
-                            <field name="ext_product_ref" select="1" />
-                            <field name="ext_ref_line" select="1" />
-                        </group>
-                    </field>
-                </data>
-            </field>
-        </record>
-
-        <record id="view_base_sale_external_shop_group_form" model="ir.ui.view">
-            <field name="name">base.sale.external.shop.group.form</field>
-            <field name="model">external.shop.group</field>
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                <form string="External shop group">
-                    <field name="name" select="1" />
-                    <field name="referential_id" widget="selection" select="1" />
-                    <newline />
-                    <field name="shop_ids" colspan="4" />
-                </form>
-            </field>
-        </record>
-
-        <record id="view_base_sale_external_shop_group_tree" model="ir.ui.view">
-            <field name="name">base.sale.external.shop.group.tree</field>
-            <field name="model">external.shop.group</field>
-            <field name="type">tree</field>
-            <field name="arch" type="xml">
-                <tree string="External shop groups">
-                    <field name="name" />
-                    <field name="referential_id" />
-                    <field name="shop_ids" />
-                </tree>
-            </field>
-        </record>
-
-        <record id="act_base_sale_external_shop_group" model="ir.actions.act_window">
-            <field name="name">External referential shop groups</field>
-            <field name="res_model">external.shop.group</field>
-            <field name="view_type">form</field>
-            <field name="view_mode">tree,form</field>
-        </record>
-
-        <act_window
-            id="base_external_referentials.ext_product_product"
-            name="External Product"
-            res_model="ir.model.data"
-            src_model="product.product"
-            domain="[('res_id', '=', active_id), ('model', '=', 'product.product')]"
-        />
-        
-        <act_window
-            id="base_external_referentials.ext_product_category"
-            name="External Category"
-            res_model="ir.model.data"
-            src_model="product.category"
-            domain="[('res_id', '=', active_id), ('model', '=', 'product.category')]"
-        />
-
-        <act_window
-            id="base_external_referentials.ext_sale_order"
-            name="External Order"
-            res_model="ir.model.data"
-            src_model="sale.order"
-            domain="[('res_id', '=', active_id), ('model', '=', 'sale.order')]"
-        />
-        
-        <act_window
-            id="base_external_referentials.ext_sale_shop"
-            name="External Shop"
-            res_model="ir.model.data"
-            src_model="sale.shop"
-            domain="[('res_id', '=', active_id), ('model', '=', 'sale.shop')]"
-        />
-        
-        <act_window
-            id="base_external_referentials.ext_res_partner"
-            name="External Partner"
-            res_model="ir.model.data"
-            src_model="res.partner"
-            domain="[('res_id', '=', active_id), ('model', '=', 'res.partner')]"
-        />
-        
-        <act_window
-            id="base_external_referentials.ext_res_partner_address"
-            name="External Address"
-            res_model="ir.model.data"
-            src_model="res.partner.address"
-            domain="[('res_id', '=', active_id), ('model', '=', 'res.partner.address')]"
-        />
-
     </data>
 </openerp>

=== modified file 'connector_ecommerce/security/ir.model.access.csv'
--- base_sale_multichannels/security/ir.model.access.csv	2012-10-17 12:58:27 +0000
+++ connector_ecommerce/security/ir.model.access.csv	2013-12-05 13:14:00 +0000
@@ -1,18 +1,3 @@
 "id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
-"access_base_sale_multichannels_external_shop_group_manager","base_sale_multichannels_external_shop_group","model_external_shop_group","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_referential","base_external_referentials_external_referential","base_external_referentials.model_external_referential","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_referential_type","base_external_referentials_external_referential_type","base_external_referentials.model_external_referential_type","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_referential_version","base_external_referentials_external_referential_version","base_external_referentials.model_external_referential_version","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_mapping_template","base_external_referentials_external_mapping_template","base_external_referentials.model_external_mapping_template","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_mappinglines_template","base_external_referentials_external_mappinglines_template","base_external_referentials.model_external_mappinglines_template","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_referential","base_external_referentials_external_referential","base_external_referentials.model_external_referential","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_mapping_line","base_external_referentials_external_mapping_line","base_external_referentials.model_external_mapping_line","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_mapping","base_external_referentials_external_mapping","base_external_referentials.model_external_mapping","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_report","base_external_referentials_external_report","base_external_referentials.model_external_report","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_report_history","base_external_referentials_external_report_history","base_external_referentials.model_external_report_history","base.group_sale_manager",1,1,1,1
-"access_base_external_referentials_external_report_line","base_external_referentials_external_report_line","base_external_referentials.model_external_report_line","base.group_sale_manager",1,1,1,1
-"access_sale_sale_shop","sale_sale_shop","sale.model_sale_shop","base.group_sale_manager",1,1,1,1
-"access_base_sale_multichannels_ir_model_data","base_sale_multichannels_ir_model_data","base.model_ir_model_data","base.group_sale_manager",1,1,1,1
-"access_base_sale_multichannels_external_shop_group","base_sale_multichannels_external_shop_group","model_external_shop_group","base.group_user",1,0,0,0
 "access_account_tax_group_user","Read-only access to account.tax.group","model_account_tax_group","base.group_user",1,0,0,0
 "access_account_tax_group_account_manager","RW access to account.tax.group","model_account_tax_group","account.group_account_manager",1,1,1,1

=== added file 'connector_ecommerce/security/security.xml'
--- connector_ecommerce/security/security.xml	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/security/security.xml	2013-12-05 13:14:00 +0000
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<openerp>
+    <data noupdate="1">
+
+    <!-- activate the following options in the global settings:
+         * Manage multiple shops
+         * Allow setting a discount on the sales order lines
+         * Allow a different address for delivery and invoicing
+    -->
+    <record model="res.groups" id="base.group_user">
+        <field name="implied_ids" eval="[(4, ref('stock.group_locations')), (4, ref('sale.group_discount_per_so_line')), (4, ref('sale.group_delivery_invoice_address'))]"/>
+    </record>
+
+    <!-- the connector managers always need theses rights to import or export products,
+         sales orders, ... -->
+    <record id="connector.group_connector_manager" model="res.groups">
+        <field name="implied_ids" eval="[(4, ref('base.group_sale_manager'))]"/>
+    </record>
+
+    </data>
+</openerp>
+

=== modified file 'connector_ecommerce/stock.py'
--- base_sale_multichannels/stock.py	2012-08-21 13:57:44 +0000
+++ connector_ecommerce/stock.py	2013-12-05 13:14:00 +0000
@@ -1,46 +1,68 @@
-# -*- encoding: utf-8 -*-
-#########################################################################
-#                                                                       #
-#########################################################################
-#                                                                       #
-# Copyright (C) 2010 BEAU Sébastien                                     #
-#                                                                       #
-#This program is free software: you can redistribute it and/or modify   #
-#it under the terms of the GNU General Public License as published by   #
-#the Free Software Foundation, either version 3 of the License, or      #
-#(at your option) any later version.                                    #
-#                                                                       #
-#This program is distributed in the hope that it will be useful,        #
-#but WITHOUT ANY WARRANTY; without even the implied warranty of         #
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          #
-#GNU General Public License for more details.                           #
-#                                                                       #
-#You should have received a copy of the GNU General Public License      #
-#along with this program.  If not, see <http://www.gnu.org/licenses/>.  #
-#########################################################################
-
-from openerp.osv.orm import Model
-from openerp.osv import fields
-from openerp.osv.osv import except_osv
-from tools.translate import _
-
-class stock_picking(Model):
-    _inherit = "stock.picking"
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Joel Grand-Guillaume
+#    Copyright 2013 Camptocamp SA
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.osv import orm, fields
+
+from openerp.addons.connector.session import ConnectorSession
+from .event import on_picking_out_done, on_tracking_number_added
+
+class stock_picking(orm.Model):
+    _inherit = 'stock.picking'
 
     _columns = {
-        'do_not_export': fields.boolean(
-            'Do not export',
-            help="This delivery order will not be exported to the "
-                 "external referential."
-        ),
-        'shop_id': fields.many2one('sale.shop', 'Shop', readonly=True, states={'draft': [('readonly', False)]}),
+        'related_backorder_ids': fields.one2many(
+            'stock.picking', 'backorder_id',
+            string="Related backorders"),
     }
 
-    def create_ext_shipping(self, cr, uid, id, picking_type, external_referential_id, context):
-        raise except_osv(_("Not Implemented"), _("Not Implemented in abstract base module!"))
-
-    def _prepare_invoice(self, cr, uid, picking, partner, inv_type, journal_id, context=None):
-        vals = super(stock_picking, self)._prepare_invoice(cr, uid, picking, partner, \
-                                                            inv_type, journal_id, context=context)
-        vals['shop_id'] = picking.shop_id.id
-        return vals
+    def action_done(self, cr, uid, ids, context=None):
+        res = super(stock_picking, self).action_done(cr, uid,
+                                                     ids, context=context)
+        session = ConnectorSession(cr, uid, context=context)
+        # Look if it exists a backorder, in that case call for partial
+        picking_records = self.read(cr, uid, ids,
+                                 ['id', 'related_backorder_ids', 'type'],
+                                 context=context)
+        for picking_vals in picking_records:
+            if picking_vals['type'] != 'out':
+                continue
+            if picking_vals['related_backorder_ids']:
+                picking_method = 'partial'
+            else:
+                picking_method = 'complete'
+            on_picking_out_done.fire(session, self._name,
+                                     picking_vals['id'], picking_method)
+        return res
+
+
+class stock_picking_out(orm.Model):
+    _inherit = 'stock.picking.out'
+
+    def write(self, cr, uid, ids, vals, context=None):
+        if not hasattr(ids, '__iter__'):
+            ids = [ids]
+        res = super(stock_picking_out, self).write(cr, uid, ids,
+                                                   vals, context=context)
+        if vals.get('carrier_tracking_ref'):
+            session = ConnectorSession(cr, uid, context=context)
+            for record_id in ids:
+                on_tracking_number_added.fire(session, self._name, record_id)
+        return res

=== modified file 'connector_ecommerce/stock_view.xml'
--- base_sale_multichannels/stock_view.xml	2012-03-29 09:59:52 +0000
+++ connector_ecommerce/stock_view.xml	2013-12-05 13:14:00 +0000
@@ -1,14 +1,16 @@
 <?xml version="1.0" encoding="utf-8"?>
 <openerp>
     <data>
-        <record id="view_picking_out_form_ext" model="ir.ui.view">
-            <field name="name">stock.picking.out.form.ext</field>
-            <field name="model">stock.picking</field>
+        <record id="view_stock_picking_out_connector_form" model="ir.ui.view">
+            <field name="name">stock.picking.out.connector.form</field>
+            <field name="model">stock.picking.out</field>
             <field name="inherit_id" ref="stock.view_picking_out_form"/>
-            <field name="type">form</field>
             <field name="arch" type="xml">
-                <page string="Additional info" position="inside">
-                    <field name="do_not_export"/>
+                <page string="Additional Info" position="after">
+                    <!-- change the invisible attribute to 0 when used
+                         in submodules -->
+                    <page name="connector" string="Connectors" invisible="1">
+                    </page>
                 </page>
             </field>
         </record>

=== added directory 'connector_ecommerce/tests'
=== added file 'connector_ecommerce/tests/__init__.py'
--- connector_ecommerce/tests/__init__.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/tests/__init__.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,32 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Guewen Baconnier
+#    Copyright 2012 Camptocamp SA
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+import test_onchange
+import test_invoice_event
+
+fast_suite = [
+]
+
+checks = [
+    test_onchange,
+    test_invoice_event,
+]
+

=== added file 'connector_ecommerce/tests/test_invoice_event.py'
--- connector_ecommerce/tests/test_invoice_event.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/tests/test_invoice_event.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,97 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Guewen Baconnier
+#    Copyright 2013 Camptocamp SA
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+import unittest2
+import mock
+from functools import partial
+
+import openerp.tests.common as common
+from openerp import netsvc
+
+
+class test_invoice_event(common.TransactionCase):
+    """ Test if the events on the invoice are fired correctly """
+
+    def setUp(self):
+        super(test_invoice_event, self).setUp()
+        cr, uid = self.cr, self.uid
+        self.invoice_model = self.registry('account.invoice')
+        partner_model = self.registry('res.partner')
+        partner_id = partner_model.create(cr, uid, {'name': 'Hodor'})
+        data_model = self.registry('ir.model.data')
+        self.get_ref = partial(data_model.get_object_reference, cr, uid)
+        product_id = self.get_ref('product', 'product_product_6')[1]
+        invoice_vals = {'partner_id': partner_id,
+                        'type': 'out_invoice',
+                        'invoice_line': [(0, 0, {'name': "LCD Screen",
+                                                 'product_id': product_id,
+                                                 'quantity': 5,
+                                                 'price_unit': 200})],
+                        }
+        onchange_res = self.invoice_model.onchange_partner_id(
+            cr, uid, [], 'out_invoice', partner_id)
+        invoice_vals.update(onchange_res['value'])
+        invoice_id = self.invoice_model.create(cr, uid, invoice_vals)
+        self.invoice = self.invoice_model.browse(cr, uid, invoice_id)
+
+    def test_event_validated(self):
+        """ Test if the ``on_invoice_validated`` event is fired
+        when an invoice is validated """
+        cr, uid = self.cr, self.uid
+        assert self.invoice, "The invoice has not been created"
+        wf_service = netsvc.LocalService('workflow')
+        event = 'openerp.addons.connector_ecommerce.invoice.on_invoice_validated'
+        with mock.patch(event) as event_mock:
+            wf_service.trg_validate(uid, 'account.invoice',
+                                    self.invoice.id, 'invoice_open', cr)
+            self.assertEqual(self.invoice.state, 'open')
+            event_mock.fire.assert_called_with(mock.ANY,
+                                               'account.invoice',
+                                               self.invoice.id)
+
+    def test_event_paid(self):
+        """ Test if the ``on_invoice_paid`` event is fired
+        when an invoice is paid """
+        cr, uid = self.cr, self.uid
+        assert self.invoice, "The invoice has not been created"
+        wf_service = netsvc.LocalService('workflow')
+        wf_service.trg_validate(uid, 'account.invoice',
+                                self.invoice.id, 'invoice_open', cr)
+        self.assertEqual(self.invoice.state, 'open')
+        journal_id = self.get_ref('account', 'bank_journal')[1]
+        pay_account_id = self.get_ref('account', 'cash')[1]
+        period_id = self.get_ref('account', 'period_10')[1]
+        event = 'openerp.addons.connector_ecommerce.invoice.on_invoice_paid'
+        with mock.patch(event) as event_mock:
+            self.invoice.pay_and_reconcile(
+                pay_amount=self.invoice.amount_total,
+                pay_account_id=pay_account_id,
+                period_id=period_id,
+                pay_journal_id=journal_id,
+                writeoff_acc_id=pay_account_id,
+                writeoff_period_id=period_id,
+                writeoff_journal_id=journal_id,
+                name="Payment for test of the event on_invoice_paid")
+            self.invoice.refresh()
+            self.assertEqual(self.invoice.state, 'paid')
+            event_mock.fire.assert_called_with(mock.ANY,
+                                               'account.invoice',
+                                               self.invoice.id)

=== added file 'connector_ecommerce/tests/test_onchange.py'
--- connector_ecommerce/tests/test_onchange.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/tests/test_onchange.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,94 @@
+# -*- coding: utf-8 -*-
+############################################################################### 
+#
+#   connector-ecommerce for OpenERP
+#   Copyright (C) 2013-TODAY Akretion <http://www.akretion.com>.
+#     @author Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
+#
+#   This program is free software: you can redistribute it and/or modify
+#   it under the terms of the GNU Affero General Public License as
+#   published by the Free Software Foundation, either version 3 of the
+#   License, or (at your option) any later version.
+#
+#   This program is distributed in the hope that it will be useful,
+#   but WITHOUT ANY WARRANTY; without even the implied warranty of
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#   GNU Affero General Public License for more details.
+#
+#   You should have received a copy of the GNU Affero General Public License
+#   along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+############################################################################### 
+
+import unittest2
+import mock
+
+from openerp.addons.connector_ecommerce.unit.sale_order_onchange import (
+    SaleOrderOnChange)
+from openerp.addons.connector.session import ConnectorSession
+from openerp.addons.connector.connector import Environment
+import openerp.tests.common as common
+
+DB = common.DB
+ADMIN_USER_ID = common.ADMIN_USER_ID
+
+
+class test_onchange(common.TransactionCase):
+    """ Test if the onchanges are applied correctly on a sale order"""
+
+    def setUp(self):
+        super(test_onchange, self).setUp()
+        self.session = ConnectorSession(self.cr, self.uid)
+
+    def test_play_onchange(self):
+        """ Play the onchange ConnectorUnit on a sale order """
+        product_model = self.registry('product.product')
+        partner_model = self.registry('res.partner')
+        shop_model = self.registry('sale.shop')
+        tax_model = self.registry('account.tax')
+        cr, uid = self.cr, self.uid
+
+        backend_record = mock.Mock()
+        env = Environment(backend_record, self.session, 'sale.order')
+
+        partner_id = partner_model.create(cr, uid,
+                                          {'name': 'seb',
+                                          'zip': '69100',
+                                          'city': 'Villeurbanne'})
+        partner_invoice_id = partner_model.create(cr, uid,
+                                                  {'name': 'Guewen',
+                                                   'zip': '1015',
+                                                   'city': 'Lausanne',
+                                                   'type': 'invoice',
+                                                   'parent_id': partner_id})
+        tax_id = tax_model.create(cr, uid, {'name': 'My Tax'})
+        product_id = product_model.create(cr, uid,
+                                          {'default_code': 'MyCode',
+                                           'name': 'My Product',
+                                           'weight': 15,
+                                           'taxes_id': [(6, 0, [tax_id])]})
+        shop_id = shop_model.create(cr, uid, {'name': 'My shop'})
+
+        order_input = {
+            'shop_id': shop_id,
+            'name': 'mag_10000001',
+            'partner_id': partner_id,
+            'order_line': [
+                (0, 0, {
+                    'product_id': product_id,
+                    'price_unit': 20,
+                    'name': 'My Real Name',
+                    'product_uom_qty': 1,
+                }),
+            ]
+        }
+
+        onchange = SaleOrderOnChange(env)
+        order = onchange.play(order_input,
+                              order_input['order_line'])
+
+        self.assertEqual(order['partner_invoice_id'], partner_invoice_id)
+        line = order['order_line'][0][2]
+        self.assertEqual(line['name'], 'My Real Name')
+        self.assertEqual(line['th_weight'], 15)
+        self.assertEqual(line['tax_id'][0][2][0], tax_id)

=== added directory 'connector_ecommerce/unit'
=== added file 'connector_ecommerce/unit/__init__.py'
--- connector_ecommerce/unit/__init__.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/unit/__init__.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,2 @@
+# -*- coding: utf-8 -*-
+import sale_order_onchange

=== added file 'connector_ecommerce/unit/sale_order_onchange.py'
--- connector_ecommerce/unit/sale_order_onchange.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/unit/sale_order_onchange.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,223 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#   connector-ecommerce for OpenERP
+#   Copyright (C) 2013-TODAY Akretion <http://www.akretion.com>.
+#     @author Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
+#
+#   This program is free software: you can redistribute it and/or modify
+#   it under the terms of the GNU Affero General Public License as
+#   published by the Free Software Foundation, either version 3 of the
+#   License, or (at your option) any later version.
+#
+#   This program is distributed in the hope that it will be useful,
+#   but WITHOUT ANY WARRANTY; without even the implied warranty of
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#   GNU Affero General Public License for more details.
+#
+#   You should have received a copy of the GNU Affero General Public License
+#   along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.addons.connector.connector import ConnectorUnit
+
+
+class OnChangeManager(ConnectorUnit):
+    def merge_values(self, record, on_change_result):
+        vals = on_change_result.get('value', {})
+        for key in vals:
+            if not key in record:
+                record[key] = vals[key]
+
+
+class SaleOrderOnChange(OnChangeManager):
+    _model_name = None
+
+    def _get_partner_id_onchange_param(self, order):
+        """ Prepare the arguments for calling the partner_id change
+        on sale order. You can overwrite this method in your own
+        module if they modify the onchange signature
+
+        :param order: a dictionary of the value of your sale order
+        :type: dict
+
+        :return: a tuple of args and kwargs for the onchange
+        :rtype: tuple
+        """
+        args = [
+            None, # sale order ids not needed
+            order['partner_id'],
+        ]
+        kwargs = {'context': self.session.context}
+        return args, kwargs
+
+    def _get_shop_id_onchange_param(self, order):
+        args = [None,
+                order['shop_id']]
+        kwargs = {'context': self.session.context}
+        return args, kwargs
+
+    def _get_payment_method_id_onchange_param(self, order):
+        args = [None,
+                order['payment_method_id']]
+        kwargs = {'context': self.session.context}
+        return args, kwargs
+
+    def _get_workflow_process_id_onchange_param(self, order):
+        args = [None,
+                order['workflow_process_id']]
+        kwargs = {'context': self.session.context}
+        return args, kwargs
+
+    def _play_order_onchange(self, order):
+        """ Play the onchange of the sale order
+
+        :param order: a dictionary of the value of your sale order
+        :type: dict
+
+        :return: the value of the sale order updated with the onchange result
+        :rtype: dict
+        """
+        sale_model = self.session.pool.get('sale.order')
+
+        #Play partner_id onchange
+        args, kwargs = self._get_shop_id_onchange_param(order)
+        res = sale_model.onchange_shop_id(self.session.cr,
+                                          self.session.uid,
+                                          *args,
+                                          **kwargs)
+        self.merge_values(order, res)
+
+        args, kwargs = self._get_partner_id_onchange_param(order)
+        res = sale_model.onchange_partner_id(self.session.cr,
+                                             self.session.uid,
+                                             *args,
+                                             **kwargs)
+        self.merge_values(order, res)
+
+        if order.get('payment_method_id'):
+            # apply payment method
+            args, kwargs = self._get_payment_method_id_onchange_param(order)
+            res = sale_model.onchange_payment_method_id(self.session.cr,
+                                                        self.session.uid,
+                                                        *args,
+                                                        **kwargs)
+        self.merge_values(order, res)
+
+        if order.get('workflow_process_id'):
+            # apply default values from the workflow
+            args, kwargs = self._get_workflow_process_id_onchange_param(order)
+            res = sale_model.onchange_workflow_process_id(self.session.cr,
+                                                        self.session.uid,
+                                                        *args,
+                                                        **kwargs)
+        self.merge_values(order, res)
+        return order
+
+    def _get_product_id_onchange_param(self, line, previous_lines, order):
+        """ Prepare the arguments for calling the product_id change
+        on sale order line. You can overwrite this method in your own
+        module if they modify the onchange signature
+
+        :param line: the sale order line to process
+        :type: dict
+        :param previous_lines: list of dict of the previous lines processed
+        :type: list
+        :param order: data of the sale order
+        :type: dict
+
+        :return: a tuple of args and kwargs for the onchange
+        :rtype: tuple
+        """
+        args = [
+            None, # sale order line ids not needed
+            order.get('pricelist_id'),
+            line.get('product_id')
+            ]
+        uos_qty = float(line.get('product_uos_qty', 0))
+        if not uos_qty:
+            uos_qty = float(line.get('product_uom_qty', 0))
+
+        kwargs ={
+            'qty': float(line.get('product_uom_qty', 0)),
+            'uom': line.get('product_uom'),
+            'qty_uos': uos_qty,
+            'uos': line.get('product_uos'),
+            'name': line.get('name'),
+            'partner_id': order.get('partner_id'),
+            'lang': False,
+            'update_tax': True,
+            'date_order': order.get('date_order'),
+            'packaging': line.get('product_packaging'),
+            'fiscal_position': order.get('fiscal_position'),
+            'flag': False,
+            'context': self.session.context,
+            }
+        return args, kwargs
+
+    def _play_line_onchange(self, line, previous_lines, order):
+        """ Play the onchange of the sale order line
+
+        :param line: the sale order line to process
+        :type: dict
+        :param previous_lines: list of dict of the previous line processed
+        :type: list
+        :param order: data of the sale order
+        :type: dict
+
+        :return: the value of the sale order updated with the onchange result
+        :rtype: dict
+        """
+        sale_line_model = self.session.pool.get('sale.order.line')
+
+        #Play product_id onchange
+        args, kwargs = self._get_product_id_onchange_param(line,
+                                                           previous_lines,
+                                                           order)
+        res = sale_line_model.product_id_change(self.session.cr,
+                                                self.session.uid,
+                                                *args,
+                                                **kwargs)
+        # TODO refactor this with merge_values
+        vals = res.get('value', {})
+        for key in vals:
+            if not key in line:
+                if sale_line_model._columns[key]._type == 'many2many':
+                    line[key] = [(6, 0, vals[key])]
+                else:
+                    line[key] = vals[key]
+        return line
+
+    def play(self, order, order_lines):
+        """ Play the onchange of the sale order and it's lines
+
+        :param order: data of the sale order
+        :type: dict
+
+        :return: the value of the sale order updated with the onchange result
+        :rtype: dict
+        """
+        #play onchange on sale order
+        order = self._play_order_onchange(order)
+        #play onchanfe on sale 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 OpenERP Product
+            line_lists.append(order['order_line'])
+        for line_list in line_lists:
+            for idx, line in enumerate(line_list):
+                # line_list format:[(0, 0, {...}), (0, 0, {...})]
+                old_line_data = line[2]
+                new_line_data = self._play_line_onchange(old_line_data,
+                                                         processed_order_lines,
+                                                         order)
+                new_line = (0, 0, new_line_data)
+                processed_order_lines.append(new_line)
+                # in place modification of the sale order line in the list
+                line_list[idx] = new_line
+        return order

=== added directory 'connector_ecommerce/wizard'
=== added file 'connector_ecommerce/wizard/__init__.py'
--- connector_ecommerce/wizard/__init__.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/wizard/__init__.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,3 @@
+# -*- coding: utf-8 -*-
+
+import sale_ignore_cancel

=== added file 'connector_ecommerce/wizard/sale_ignore_cancel.py'
--- connector_ecommerce/wizard/sale_ignore_cancel.py	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/wizard/sale_ignore_cancel.py	2013-12-05 13:14:00 +0000
@@ -0,0 +1,46 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Guewen Baconnier
+#    Copyright 2013 Camptocamp SA
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.osv import orm, fields
+
+
+class sale_ignore_cancel(orm.TransientModel):
+    _name = 'sale.ignore.cancel'
+    _description = 'Ignore Sales Order Cancel'
+
+    _columns = {
+        'reason': fields.html('Reason', required=True),
+    }
+
+    def confirm_ignore_cancel(self, cr, uid, ids, context=None):
+        if context is None:
+            context = {}
+        if isinstance(ids, (list, tuple)):
+            assert len(ids) == 1
+            ids = ids[0]
+        order_ids = context.get('active_ids')
+        if order_ids is None:
+            return
+        form = self.browse(cr, uid, ids, context=context)
+        self.pool.get('sale.order').ignore_cancellation(cr, uid, order_ids,
+                                                        form.reason,
+                                                        context=context)
+        return {'type': 'ir.actions.act_window_close'}

=== added file 'connector_ecommerce/wizard/sale_ignore_cancel_view.xml'
--- connector_ecommerce/wizard/sale_ignore_cancel_view.xml	1970-01-01 00:00:00 +0000
+++ connector_ecommerce/wizard/sale_ignore_cancel_view.xml	2013-12-05 13:14:00 +0000
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="utf-8"?>
+<openerp>
+    <data noupdate="0">
+        <record id="view_sale_ignore_cancel" model="ir.ui.view">
+            <field name="name">Sale Ignore Cancel</field>
+            <field name="model">sale.ignore.cancel</field>
+            <field name="arch" type="xml">
+             <form string="Ignore the cancellation on the Backend" version="7.0">
+                <p class="oe_grey">
+                    This sales order has been canceled from the backend.
+                    The usual action would be to cancel it in OpenERP along
+                    all the documents generated (delivery orders, invoices, ...).
+                </p>
+                <p class="oe_grey">
+                    However, if for any reason you need to keep it open in OpenERP,
+                    write the reason here and it will stay open.
+                </p>
+                <group>
+                    <label for="reason" colspan="2"/>
+                    <field name="reason" nolabel="1" colspan="2"/>
+                </group>
+                <footer>
+                    <button name="confirm_ignore_cancel"
+                        string="Confirm" type="object"
+                        class="oe_highlight"/>
+                    or
+                    <button string="Cancel" class="oe_link" special="cancel" />
+                </footer>
+            </form>
+            </field>
+        </record>
+
+        <record id="action_sale_ignore_cancel" model="ir.actions.act_window">
+            <field name="name">Ignore the cancellation on the Backend</field>
+            <field name="type">ir.actions.act_window</field>
+            <field name="res_model">sale.ignore.cancel</field>
+            <field name="view_type">form</field>
+            <field name="view_mode">form</field>
+            <field name="view_id" ref="view_sale_ignore_cancel"/>
+            <field name="target">new</field>
+        </record>
+    </data>
+</openerp>

=== modified file 'product_custom_attributes_shop/__openerp__.py'
--- product_custom_attributes_shop/__openerp__.py	2012-12-26 13:24:14 +0000
+++ product_custom_attributes_shop/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -36,7 +36,7 @@
     'author': 'Akretion',
     'website': 'http://www.akretion.com/',
     'depends': [
-        'base_sale_multichannels',
+        'connector_ecommerce',
         'product_custom_attributes',
         ],
     'init_xml': [],

=== modified file 'product_custom_attributes_shop/sale_view.xml'
--- product_custom_attributes_shop/sale_view.xml	2012-08-10 12:03:22 +0000
+++ product_custom_attributes_shop/sale_view.xml	2013-12-05 13:14:00 +0000
@@ -13,7 +13,7 @@
         <record id="attributes_sale_shop_view_form" model="ir.ui.view">
             <field name="name">product_custom_attributs_shop.sale_shop.view_form</field>
             <field name="model">sale.shop</field>
-            <field name="inherit_id" ref="base_sale_multichannels.base_sale_multichannels_view_shop_form" />
+            <field name="inherit_id" ref="connector_ecommerce.connector_ecommerce_view_shop_form" />
             <field eval="16" name="priority"/>
             <field name="type">form</field>
             <field name="arch" type="xml">

=== modified file 'product_images_sync/__openerp__.py'
--- product_images_sync/__openerp__.py	2012-12-26 13:24:14 +0000
+++ product_images_sync/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -35,8 +35,8 @@
     'website': 'http://www.akretion.com',
     'depends': [
         'product_images_olbs',
-        'base_external_referentials',
-        'base_sale_multichannels',
+        'connector',
+        'connector_ecommerce',
         ],
     'init_xml': [],
     'update_xml': [

=== modified file 'product_images_sync/product_images_sync.py'
--- product_images_sync/product_images_sync.py	2012-11-28 17:28:03 +0000
+++ product_images_sync/product_images_sync.py	2013-12-05 13:14:00 +0000
@@ -21,7 +21,7 @@
 ##############################################################################
 
 from osv import osv, fields
-from base_external_referentials.decorator import only_for_referential, commit_now
+from openerp.addons.connector.decorator import only_for_referential, commit_now
 
 # TODO : move field last_images_export_date in this module ? (-> will need to update dependancy ?)
 

=== modified file 'product_links_sync/product.py'
--- product_links_sync/product.py	2012-11-21 12:50:15 +0000
+++ product_links_sync/product.py	2013-12-05 13:14:00 +0000
@@ -25,8 +25,8 @@
 from openerp.osv.orm import TransientModel
 from openerp.osv import fields
 from openerp.tools import DEFAULT_SERVER_DATETIME_FORMAT
-from base_external_referentials.decorator import only_for_referential
-from base_external_referentials.decorator import commit_now
+from openerp.addons.connector.decorator import only_for_referential
+from openerp.addons.connector.decorator import commit_now
 
 
 class product_product(Model):

=== modified file 'sale_automatic_workflow/__openerp__.py'
--- sale_automatic_workflow/__openerp__.py	2013-11-04 09:23:03 +0000
+++ sale_automatic_workflow/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -25,6 +25,7 @@
     'version': '0.2',
     'category': 'Generic Modules/Others',
     'license': 'AGPL-3',
+<<<<<<< TREE
     'description': """
 Sale Automatic Workflow
 =======================
@@ -50,6 +51,33 @@
 It is well suited for other E-Commerce connectors as well.
 """,
     'author': 'Akretion,Camptocamp',
+=======
+    'description': """
+Sale Automatic Workflow
+=======================
+
+Create workflows with more or less automatization and apply it on sales
+orders.
+
+A workflow can:
+
+- Apply default values:
+  * Packing Policy (partial, complete)
+  * Shipping Policy (prepaid, manual, postpaid, picking)
+  * Invoice On (ordered quantities, shipped quantities)
+  * Set the invoice's date to the sale order's date
+
+- Apply automatic actions:
+  * Validate the order (only if paid, always, never)
+  * Create an invoice
+  * Validate the invoice
+  * Confirm the picking
+
+This module is used by Magentoerpconnect and Prestashoperpconnect.
+It is well suited for other E-Commerce connectors as well.
+""",
+    'author': 'Akretion',
+>>>>>>> MERGE-SOURCE
     'website': 'http://www.akretion.com/',
     'depends': ['sale_payment_method',
                 'stock',

=== modified file 'sale_automatic_workflow/automatic_workflow_data.xml'
--- sale_automatic_workflow/automatic_workflow_data.xml	2013-03-27 13:21:58 +0000
+++ sale_automatic_workflow/automatic_workflow_data.xml	2013-12-05 13:14:00 +0000
@@ -8,17 +8,26 @@
 <openerp>
     <data noupdate="1">
 
-        <!-- VIEW FOR THE OBJECT : payment_method -->
         <record id="automatic_validation" model="sale.workflow.process">
-            <field name="name">Automatic Validation</field>
+            <field name="name">Automatic</field>
             <field name="picking_policy">one</field>
+<<<<<<< TREE
             <field name="order_policy">picking</field>
+=======
+            <field name="order_policy">manual</field>
+>>>>>>> MERGE-SOURCE
             <field name="invoice_quantity">order</field>
+<<<<<<< TREE
             <field name="validate_order" eval="0"/>
             <field name="create_invoice" eval="1" />
+=======
+            <field name="validate_order" eval="1"/>
+            <field name="create_invoice_on">on_picking_done</field>
+>>>>>>> MERGE-SOURCE
             <field name="validate_invoice" eval="1" />
             <field name="invoice_date_is_order_date" eval="0" />
             <field name="validate_picking" eval="0" />
+<<<<<<< TREE
             <field name="validate_manufactoring_order" eval="0" />
         </record>
 
@@ -34,5 +43,33 @@
             <field eval="'run'" name="function"/>
             <field eval="'()'" name="args"/>
         </record>
+=======
+        </record>
+
+        <record id="manual_validation" model="sale.workflow.process">
+            <field name="name">Manual</field>
+            <field name="picking_policy">one</field>
+            <field name="order_policy">manual</field>
+            <field name="invoice_quantity">order</field>
+            <field name="validate_order" eval="0"/>
+            <field name="create_invoice_on">manual</field>
+            <field name="validate_invoice" eval="0" />
+            <field name="invoice_date_is_order_date" eval="0" />
+            <field name="validate_picking" eval="0" />
+        </record>
+
+        <record forcecreate="True" id="ir_cron_automatic_workflow_job" model="ir.cron">
+            <field name="name">Automatic Workflow Job</field>
+            <field eval="True" name="active"/>
+            <field name="user_id" ref="base.user_root"/>
+            <field name="interval_number">1</field>
+            <field name="interval_type">minutes</field>
+            <field name="numbercall">-1</field>
+            <field eval="False" name="doall"/>
+            <field eval="'automatic.workflow.job'" name="model"/>
+            <field eval="'run'" name="function"/>
+            <field eval="'()'" name="args"/>
+        </record>
+>>>>>>> MERGE-SOURCE
     </data>
 </openerp>

=== modified file 'sale_automatic_workflow/automatic_workflow_job.py'
--- sale_automatic_workflow/automatic_workflow_job.py	2013-10-30 09:05:57 +0000
+++ sale_automatic_workflow/automatic_workflow_job.py	2013-12-05 13:14:00 +0000
@@ -22,6 +22,7 @@
 
 
 import logging
+<<<<<<< TREE
 from contextlib import contextmanager
 from openerp.osv import orm
 from openerp import netsvc
@@ -73,8 +74,63 @@
 class automatic_workflow_job(orm.Model):
     """ Scheduler that will play automatically the validation of
     invoices, pickings...  """
+=======
+from contextlib import contextmanager
+from openerp.osv import orm
+from openerp import pooler
+from openerp import netsvc
+
+"""
+Some comments about the implementation
+
+In order to validate the invoice and the picking, we have to use
+scheduled actions, because if we directly jump the various steps in the
+workflow of the invoice and the picking, the sale order workflow will be
+broken.
+
+The explanation is 'simple'. Example with the invoice workflow: When we
+are in the sale order at the workflow router, a transition like a signal
+or condition will change the step of the workflow to the step 'invoice';
+this step will launch the creation of the invoice.  If the invoice is
+directly validated and reconciled with the payment, the subworkflow will
+end and send a signal to the sale order workflow.  The problem is that
+the sale order workflow has not yet finished to apply the step 'invoice',
+so the signal of the subworkflow will be lost because the step 'invoice'
+is still not finished. The step invoice should be finished before
+receiving the signal. This means that we can not directly validate every
+steps of the workflow in the same transaction.
+
+If my explanation is not clear, contact me by email and I will improve
+it: sebastien.beau@xxxxxxxxxxxx
+"""
+
+_logger = logging.getLogger(__name__)
+
+
+@contextmanager
+def commit(cr):
+    """
+    Commit the cursor after the ``yield``, or rollback it if an
+    exception occurs.
+
+    Warning: using this method, the exceptions are logged then discarded.
+    """
+    try:
+        yield
+    except Exception, e:
+        cr.rollback()
+        _logger.exception('Error during an automatic workflow action.')
+    else:
+        cr.commit()
+
+
+class automatic_workflow_job(orm.Model):
+    """ Scheduler that will play automatically the validation of
+    invoices, pickings...  """
+>>>>>>> MERGE-SOURCE
     _name = 'automatic.workflow.job'
 
+<<<<<<< TREE
     def _get_domain_for_sale_validation(self, cr, uid, context=None):
         return [('state', '=', 'draft'),
                 ('workflow_process_id.validate_order', '=', True)]
@@ -138,6 +194,70 @@
                                                  picking_ids,
                                                  context=context)
 
+=======
+    def _validate_sale_orders(self, cr, uid, context=None):
+        wf_service = netsvc.LocalService("workflow")
+        sale_obj = self.pool.get('sale.order')
+        sale_ids = sale_obj.search(
+            cr, uid,
+            [('state', '=', 'draft'),
+             ('workflow_process_id.validate_order', '=', True)],
+            context=context)
+        _logger.debug('Sale Orders to validate: %s', sale_ids)
+        for sale_id in sale_ids:
+            with commit(cr):
+                wf_service.trg_validate(uid, 'sale.order',
+                                        sale_id, 'order_confirm', cr)
+
+    def _reconcile_invoices(self, cr, uid, ids=None, context=None):
+        invoice_obj = self.pool.get('account.invoice')
+        if ids is None:
+            ids = invoice_obj.search(cr, uid,
+                                     [('state', 'in', ['open'])],
+                                     context=context)
+        for invoice_id in ids:
+            with commit(cr):
+                invoice_obj.reconcile_invoice(cr, uid,
+                                              [invoice_id],
+                                              context=context)
+
+    def _validate_invoices(self, cr, uid, context=None):
+        wf_service = netsvc.LocalService("workflow")
+        invoice_obj = self.pool.get('account.invoice')
+        invoice_ids = invoice_obj.search(
+            cr, uid,
+            [('state', 'in', ['draft']),
+             ('workflow_process_id.validate_invoice', '=', True)],
+            context=context)
+        _logger.debug('Invoices to validate: %s', invoice_ids)
+        for invoice_id in invoice_ids:
+            with commit(cr):
+                wf_service.trg_validate(uid, 'account.invoice',
+                                        invoice_id, 'invoice_open', cr)
+
+    def _validate_pickings(self, cr, uid, context=None):
+        picking_obj = self.pool.get('stock.picking')
+        picking_out_obj = self.pool.get('stock.picking.out')
+        # We search on stock.picking (using the type) rather than
+        # stock.picking.out because the ORM seems bugged and can't
+        # search on stock_picking_out.workflow_process_id.
+        # Later, we'll call `validate_picking` on stock.picking.out
+        # because anyway they have the same ID and the call will be at
+        # the correct object level.
+        picking_ids = picking_obj.search(
+            cr, uid,
+            [('state', 'in', ['draft', 'confirmed', 'assigned']),
+             ('workflow_process_id.validate_picking', '=', True),
+             ('type', '=', 'out')],
+            context=context)
+        _logger.debug('Pickings to validate: %s', picking_ids)
+        if picking_ids:
+            with commit(cr):
+                picking_out_obj.validate_picking(cr, uid,
+                                                 picking_ids,
+                                                 context=context)
+
+>>>>>>> MERGE-SOURCE
     def run(self, cr, uid, ids=None, context=None):
         """ Must be called from ir.cron """
 

=== modified file 'sale_automatic_workflow/invoice.py'
--- sale_automatic_workflow/invoice.py	2013-11-04 09:21:34 +0000
+++ sale_automatic_workflow/invoice.py	2013-12-05 13:14:00 +0000
@@ -42,15 +42,30 @@
         return []
 
     def _can_be_reconciled(self, cr, uid, invoice, context=None):
+<<<<<<< TREE
         payments = self._get_payment(cr, uid, invoice, context=context)
         if not (payments and invoice.move_id):
+=======
+        if not (invoice.sale_ids and
+                invoice.sale_ids[0].payment_ids and invoice.move_id):
+>>>>>>> MERGE-SOURCE
             return False
+<<<<<<< TREE
         # Check currency
         company_currency_id = invoice.company_id.currency_id.id
         for payment in payments:
             currency_id = payment.currency_id.id or company_currency_id
             if currency_id != invoice.currency_id.id:
                 return False
+=======
+        # Check currency
+        company_currency_id = invoice.company_id.currency_id.id
+        for payment in invoice.sale_ids[0].payment_ids:
+            for move in payment.line_id:
+                currency_id = move.currency_id.id or company_currency_id
+                if currency_id != invoice.currency_id.id:
+                    return False
+>>>>>>> MERGE-SOURCE
         return True
 
     def _get_sum_invoice_move_line(self, cr, uid, move_lines,\
@@ -143,10 +158,17 @@
                     move_line_obj.reconcile(cr, uid, line_ids, **kwargs)
 
     def reconcile_invoice(self, cr, uid, ids, context=None):
+<<<<<<< TREE
         """ Simple method to reconcile the invoice with the payment
         generated on the sale order """
         if not isinstance(ids, (list, tuple)):
             ids = [ids]
+=======
+        """ Simple method to reconcile the invoice with the payment
+        generated on the sale order """
+        if not hasattr(ids, '__iter__'):
+            ids = [ids]
+>>>>>>> MERGE-SOURCE
         for invoice in self.browse(cr, uid, ids, context=context):
             self._reconcile_invoice(cr, uid, invoice, context=context)
         return True

=== modified file 'sale_automatic_workflow/payment_method.py'
=== modified file 'sale_automatic_workflow/sale.py'
--- sale_automatic_workflow/sale.py	2013-03-27 14:12:59 +0000
+++ sale_automatic_workflow/sale.py	2013-12-05 13:14:00 +0000
@@ -45,30 +45,76 @@
         if order.workflow_process_id:
             picking_vals['workflow_process_id'] = order.workflow_process_id.id
         return picking_vals
-
-    def onchange_payment_method_id(self, cr, uid, ids, payment_method_id, context=None):
-        values = super(sale_order, self).onchange_payment_method_id(
-            cr, uid, ids, payment_method_id, context=context)
-        if not payment_method_id:
-            return values
-        method_obj = self.pool.get('payment.method')
-        method = method_obj.browse(cr, uid, payment_method_id, context=context)
-        workflow = method.workflow_process_id
-        if workflow:
-            values.setdefault('value', {})
-            values['value']['workflow_process_id'] = workflow.id
-        return values
-
-    def onchange_workflow_process_id(self, cr, uid, ids, workflow_process_id, context=None):
-        if not workflow_process_id:
-            return {}
-        result = {}
-        workflow_obj = self.pool.get('sale.workflow.process')
-        workflow = workflow_obj.browse(cr, uid, workflow_process_id, context=context)
-        if workflow.picking_policy:
-            result['picking_policy'] = workflow.picking_policy
-        if workflow.order_policy:
-            result['order_policy'] = workflow.order_policy
-        if workflow.invoice_quantity:
-            result['invoice_quantity'] = workflow.invoice_quantity
-        return {'value': result}
+<<<<<<< TREE
+
+    def onchange_payment_method_id(self, cr, uid, ids, payment_method_id, context=None):
+        values = super(sale_order, self).onchange_payment_method_id(
+            cr, uid, ids, payment_method_id, context=context)
+        if not payment_method_id:
+            return values
+        method_obj = self.pool.get('payment.method')
+        method = method_obj.browse(cr, uid, payment_method_id, context=context)
+        workflow = method.workflow_process_id
+        if workflow:
+            values.setdefault('value', {})
+            values['value']['workflow_process_id'] = workflow.id
+        return values
+
+    def onchange_workflow_process_id(self, cr, uid, ids, workflow_process_id, context=None):
+        if not workflow_process_id:
+            return {}
+        result = {}
+        workflow_obj = self.pool.get('sale.workflow.process')
+        workflow = workflow_obj.browse(cr, uid, workflow_process_id, context=context)
+        if workflow.picking_policy:
+            result['picking_policy'] = workflow.picking_policy
+        if workflow.order_policy:
+            result['order_policy'] = workflow.order_policy
+        if workflow.invoice_quantity:
+            result['invoice_quantity'] = workflow.invoice_quantity
+        return {'value': result}
+=======
+
+    def onchange_payment_method_id(self, cr, uid, ids, payment_method_id, context=None):
+        values = super(sale_order, self).onchange_payment_method_id(
+            cr, uid, ids, payment_method_id, context=context)
+        if not payment_method_id:
+            return values
+        method_obj = self.pool.get('payment.method')
+        method = method_obj.browse(cr, uid, payment_method_id, context=context)
+        workflow = method.workflow_process_id
+        if workflow:
+            values.setdefault('value', {})
+            values['value']['workflow_process_id'] = workflow.id
+        return values
+
+    def onchange_workflow_process_id(self, cr, uid, ids, workflow_process_id, context=None):
+        if not workflow_process_id:
+            return {}
+        result = {}
+        workflow_obj = self.pool.get('sale.workflow.process')
+        workflow = workflow_obj.browse(cr, uid, workflow_process_id, context=context)
+        if workflow.picking_policy:
+            result['picking_policy'] = workflow.picking_policy
+        if workflow.order_policy:
+            result['order_policy'] = workflow.order_policy
+        if workflow.invoice_quantity:
+            result['invoice_quantity'] = workflow.invoice_quantity
+        return {'value': result}
+
+    def test_create_invoice(self, cr, uid, ids):
+        """ Workflow condition: test if an invoice should be created,
+        based on the automatic workflow rules """
+        if isinstance(ids, (list, tuple)):
+            assert len(ids) == 1
+            ids = ids[0]
+        order = self.browse(cr, uid, ids)
+        if order.order_policy != 'manual' or not order.workflow_process_id:
+            return False
+        invoice_on = order.workflow_process_id.create_invoice_on
+        if invoice_on == 'on_order_confirm':
+            return True
+        elif invoice_on == 'on_picking_done' and order.shipped:
+            return True
+        return False
+>>>>>>> MERGE-SOURCE

=== modified file 'sale_automatic_workflow/sale_workflow.xml'
--- sale_automatic_workflow/sale_workflow.xml	2012-04-22 12:49:21 +0000
+++ sale_automatic_workflow/sale_workflow.xml	2013-12-05 13:14:00 +0000
@@ -5,7 +5,7 @@
         <record id="trans_wait_invoice_invoice" model="workflow.transition">
             <field name="act_from" ref="sale.act_wait_invoice"/>
             <field name="act_to" ref="sale.act_invoice"/>
-            <field name="condition">(order_policy=='manual' and workflow_process_id.create_invoice)</field>
+            <field name="condition">test_create_invoice()</field>
         </record>
 
     </data>

=== modified file 'sale_automatic_workflow/sale_workflow_process.py'
--- sale_automatic_workflow/sale_workflow_process.py	2013-09-25 08:38:41 +0000
+++ sale_automatic_workflow/sale_workflow_process.py	2013-12-05 13:14:00 +0000
@@ -19,6 +19,7 @@
 #                                                                               #
 #################################################################################
 
+<<<<<<< TREE
 from openerp.osv import orm, fields
 
 
@@ -33,11 +34,18 @@
     A workflow process may be linked with a Sales payment method, so
     each time a payment method is used, the workflow will be applied.
     """
+=======
+from openerp.osv import orm, fields
+
+
+class sale_workflow_process(orm.Model):
+>>>>>>> MERGE-SOURCE
     _name = "sale.workflow.process"
     _description = "Sale Workflow Process"
 
     _columns = {
         'name': fields.char('Name', size=64),
+<<<<<<< TREE
         'picking_policy': fields.selection([('direct', 'Deliver each product when available'),
                                             ('one', 'Deliver all products at once')],
                                            string='Shipping Policy'),
@@ -53,6 +61,27 @@
                                              string='Invoice on'),
         'validate_order': fields.boolean('Validate Order'),
         'create_invoice': fields.boolean('Create Invoice'),
+=======
+        'picking_policy': fields.selection(
+            [('direct', 'Deliver each product when available'),
+             ('one', 'Deliver all products at once')],
+            string='Shipping Policy'),
+        'order_policy': fields.selection([('prepaid', 'Before Delivery'),
+                                          ('manual', 'On Demand'),
+                                          ('picking', 'On Delivery Order')],
+                                         string='Invoice Policy'),
+        'invoice_quantity': fields.selection(
+            [('order', 'Ordered Quantities'),
+             ('procurement', 'Shipped Quantities')],
+            string='Invoice on'),
+        'validate_order': fields.boolean('Validate Order'),
+        'create_invoice_on': fields.selection(
+            [('manual', 'No automatic invoice'),
+             ('on_order_confirm', 'On confirmation of Sale Order'),
+             ('on_picking_done', 'After Delivery')],
+            required=True,
+            string='Create Invoice'),
+>>>>>>> MERGE-SOURCE
         'validate_invoice': fields.boolean('Validate Invoice'),
         'validate_picking': fields.boolean('Confirm and Close Picking'),
         # TODO not implemented actually
@@ -64,8 +93,16 @@
     }
 
     _defaults = {
-        'picking_policy': 'direct',
-        'order_policy': 'manual',
-        'invoice_quantity': 'order',
-        'validate_invoice': False,
+<<<<<<< TREE
+        'picking_policy': 'direct',
+        'order_policy': 'manual',
+        'invoice_quantity': 'order',
+        'validate_invoice': False,
+=======
+        'picking_policy': 'direct',
+        'order_policy': 'manual',
+        'create_invoice_on': 'manual',
+        'invoice_quantity': 'order',
+        'validate_invoice': False,
+>>>>>>> MERGE-SOURCE
     }

=== modified file 'sale_automatic_workflow/sale_workflow_process_view.xml'
--- sale_automatic_workflow/sale_workflow_process_view.xml	2013-04-11 09:15:22 +0000
+++ sale_automatic_workflow/sale_workflow_process_view.xml	2013-12-05 13:14:00 +0000
@@ -22,8 +22,13 @@
                     <separator string="Workflow Options" colspan="4" />
                     <field name="validate_order"/>
                     <field name="validate_picking"/>
+<<<<<<< TREE
                     <!-- <field name="validate_manufactoring_order"/> -->
                     <field name="create_invoice" />
+=======
+                    <!-- <field name="validate_manufactoring_order"/> -->
+                    <field name="create_invoice_on" attrs="{'readonly': [('order_policy', '!=', 'manual')]}" />
+>>>>>>> MERGE-SOURCE
                     <field name="validate_invoice"/>
                     <field name="invoice_date_is_order_date"/>
 
@@ -42,8 +47,13 @@
                     <field name="invoice_quantity"/>
                     <field name="validate_order"/>
                     <field name="validate_picking"/>
+<<<<<<< TREE
                     <!-- <field name="validate_manufactoring_order"/> -->
                     <field name="create_invoice" />
+=======
+                    <!-- <field name="validate_manufactoring_order"/> -->
+                    <field name="create_invoice_on" />
+>>>>>>> MERGE-SOURCE
                     <field name="validate_invoice"/>
                     <field name="invoice_date_is_order_date"/>
                 </tree>

=== added directory 'sale_exceptions'
=== added directory 'sale_exceptions/i18n'
=== added file 'sale_exceptions/i18n/fr.po'
--- sale_exceptions/i18n/fr.po	1970-01-01 00:00:00 +0000
+++ sale_exceptions/i18n/fr.po	2013-12-05 13:14:00 +0000
@@ -0,0 +1,177 @@
+# Translation of OpenERP Server.
+# This file contains the translation of the following modules:
+#	* sale_exceptions
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: OpenERP Server 7.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2013-05-02 06:57+0000\n"
+"PO-Revision-Date: 2013-05-02 06:57+0000\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: sale_exceptions
+#: model:ir.model,name:sale_exceptions.model_sale_exception_confirm
+msgid "sale.exception.confirm"
+msgstr ""
+
+#. module: sale_exceptions
+#: selection:sale.exception,model:0
+msgid "Sale Order Line"
+msgstr "Ligne de commande"
+
+#. module: sale_exceptions
+#: field:sale.exception,model:0
+msgid "Apply on"
+msgstr "Appliquer sur"
+
+#. module: sale_exceptions
+#: model:sale.exception,name:sale_exceptions.excep_no_stock
+msgid "Not Enough Virtual Stock"
+msgstr "Pas assez de quantité de stock prévue"
+
+#. module: sale_exceptions
+#: field:sale.exception,description:0
+msgid "Description"
+msgstr "Description"
+
+#. module: sale_exceptions
+#: help:sale.exception,sequence:0
+msgid "Gives the sequence order when applying the test"
+msgstr "Définit l'ordre d'application des contrôles"
+
+#. module: sale_exceptions
+#: view:sale.exception.confirm:0
+msgid "Sale Exceptions On Sale Order"
+msgstr "Restrictions sur la commande"
+
+#. module: sale_exceptions
+#: field:sale.exception.confirm,exception_ids:0
+msgid "Exceptions to resolve"
+msgstr "Restrictions à résoudre"
+
+#. module: sale_exceptions
+#: view:sale.exception.confirm:0
+msgid "_Ok"
+msgstr "_Ok"
+
+#. module: sale_exceptions
+#: view:sale.exception:0
+#: view:sale.exception.confirm:0
+msgid "Sale Exception"
+msgstr "Restriction de vente"
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "TO FIX"
+msgstr "A CORRIGER"
+
+#. module: sale_exceptions
+#: help:sale.exception,code:0
+msgid "Python code executed to check if the exception apply or not. The code must apply block = True to apply the exception."
+msgstr "Code Python exécuté pour déterminer si la restriction s'applique. The bloc de code doit retourner block = True pour appliquer la restriction."
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "Exception"
+msgstr "Restriction"
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "Error:"
+msgstr "Erreur :"
+
+#. module: sale_exceptions
+#: selection:sale.exception,model:0
+msgid "Sale Order"
+msgstr "Bon de commande"
+
+#. module: sale_exceptions
+#: field:sale.exception.confirm,sale_id:0
+msgid "Sale"
+msgstr "Commande"
+
+#. module: sale_exceptions
+#: field:sale.exception,active:0
+msgid "Active"
+msgstr "Actif"
+
+#. module: sale_exceptions
+#: field:sale.exception,name:0
+msgid "Exception Name"
+msgstr "Nom de la restriction"
+
+#. module: sale_exceptions
+#: field:sale.order,exceptions_ids:0
+msgid "Exceptions"
+msgstr "Restrictions"
+
+#. module: sale_exceptions
+#: model:ir.actions.act_window,name:sale_exceptions.action_sale_exception_confirm
+#: model:ir.model,name:sale_exceptions.model_sale_exception
+#: view:sale.exception.confirm:0
+msgid "Sale Exceptions"
+msgstr "Restrictions de vente"
+
+#. module: sale_exceptions
+#: model:ir.actions.act_window,name:sale_exceptions.action_sale_test_tree
+#: model:ir.ui.menu,name:sale_exceptions.menu_sale_test
+msgid "Exception Rules"
+msgstr "Règles de restriction"
+
+#. module: sale_exceptions
+#: model:ir.model,name:sale_exceptions.model_sale_order
+msgid "Sales Order"
+msgstr "Bon de commande"
+
+#. module: sale_exceptions
+#: field:sale.exception,sequence:0
+msgid "Sequence"
+msgstr "Séquence"
+
+#. module: sale_exceptions
+#: field:sale.exception,code:0
+msgid "Python Code"
+msgstr "Code Python"
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "Sales"
+msgstr "Bons de commande"
+
+#. module: sale_exceptions
+#: model:sale.exception,name:sale_exceptions.excep_no_zip
+msgid "No ZIP code on destination"
+msgstr "Code postal manquant sur la destination"
+
+#. module: sale_exceptions
+#: view:sale.exception:0
+msgid "Sale Exception Setup"
+msgstr "Configuration des restrictions de vente"
+
+#. module: sale_exceptions
+#: view:sale.exception:0
+msgid "Affected Sales Orders"
+msgstr "Bons de commande affectés"
+
+#. module: sale_exceptions
+#: field:sale.exception,sale_order_ids:0
+msgid "Sale Orders"
+msgstr "Bons de commande"
+
+#. module: sale_exceptions
+#: field:sale.exception.confirm,ignore:0
+#: field:sale.order,ignore_exceptions:0
+msgid "Ignore Exceptions"
+msgstr "Ignorer la restriction"
+
+#. module: sale_exceptions
+#: field:sale.order,main_exception_id:0
+msgid "Main Exception"
+msgstr "Restriction principale"
+

=== added file 'sale_exceptions/i18n/sale_exceptions.pot'
--- sale_exceptions/i18n/sale_exceptions.pot	1970-01-01 00:00:00 +0000
+++ sale_exceptions/i18n/sale_exceptions.pot	2013-12-05 13:14:00 +0000
@@ -0,0 +1,177 @@
+# Translation of OpenERP Server.
+# This file contains the translation of the following modules:
+#	* sale_exceptions
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: OpenERP Server 7.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2013-05-02 06:57+0000\n"
+"PO-Revision-Date: 2013-05-02 06:57+0000\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: sale_exceptions
+#: model:ir.model,name:sale_exceptions.model_sale_exception_confirm
+msgid "sale.exception.confirm"
+msgstr ""
+
+#. module: sale_exceptions
+#: selection:sale.exception,model:0
+msgid "Sale Order Line"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception,model:0
+msgid "Apply on"
+msgstr ""
+
+#. module: sale_exceptions
+#: model:sale.exception,name:sale_exceptions.excep_no_stock
+msgid "Not Enough Virtual Stock"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception,description:0
+msgid "Description"
+msgstr ""
+
+#. module: sale_exceptions
+#: help:sale.exception,sequence:0
+msgid "Gives the sequence order when applying the test"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.exception.confirm:0
+msgid "Sale Exceptions On Sale Order"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception.confirm,exception_ids:0
+msgid "Exceptions to resolve"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.exception.confirm:0
+msgid "_Ok"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.exception:0
+#: view:sale.exception.confirm:0
+msgid "Sale Exception"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "TO FIX"
+msgstr ""
+
+#. module: sale_exceptions
+#: help:sale.exception,code:0
+msgid "Python code executed to check if the exception apply or not. The code must apply block = True to apply the exception."
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "Exception"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "Error:"
+msgstr ""
+
+#. module: sale_exceptions
+#: selection:sale.exception,model:0
+msgid "Sale Order"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception.confirm,sale_id:0
+msgid "Sale"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception,active:0
+msgid "Active"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception,name:0
+msgid "Exception Name"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.order,exceptions_ids:0
+msgid "Exceptions"
+msgstr ""
+
+#. module: sale_exceptions
+#: model:ir.actions.act_window,name:sale_exceptions.action_sale_exception_confirm
+#: model:ir.model,name:sale_exceptions.model_sale_exception
+#: view:sale.exception.confirm:0
+msgid "Sale Exceptions"
+msgstr ""
+
+#. module: sale_exceptions
+#: model:ir.actions.act_window,name:sale_exceptions.action_sale_test_tree
+#: model:ir.ui.menu,name:sale_exceptions.menu_sale_test
+msgid "Exception Rules"
+msgstr ""
+
+#. module: sale_exceptions
+#: model:ir.model,name:sale_exceptions.model_sale_order
+msgid "Sales Order"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception,sequence:0
+msgid "Sequence"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception,code:0
+msgid "Python Code"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.order:0
+msgid "Sales"
+msgstr ""
+
+#. module: sale_exceptions
+#: model:sale.exception,name:sale_exceptions.excep_no_zip
+msgid "No ZIP code on destination"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.exception:0
+msgid "Sale Exception Setup"
+msgstr ""
+
+#. module: sale_exceptions
+#: view:sale.exception:0
+msgid "Affected Sales Orders"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception,sale_order_ids:0
+msgid "Sale Orders"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.exception.confirm,ignore:0
+#: field:sale.order,ignore_exceptions:0
+msgid "Ignore Exceptions"
+msgstr ""
+
+#. module: sale_exceptions
+#: field:sale.order,main_exception_id:0
+msgid "Main Exception"
+msgstr ""
+

=== added file 'sale_exceptions/sale_view.xml.OTHER'
--- sale_exceptions/sale_view.xml.OTHER	1970-01-01 00:00:00 +0000
+++ sale_exceptions/sale_view.xml.OTHER	2013-12-05 13:14:00 +0000
@@ -0,0 +1,109 @@
+<?xml version="1.0" ?>
+<openerp>
+    <data>
+
+        <record id="view_sale_exception_tree" model="ir.ui.view">
+            <field name="name">sale.exception.tree</field>
+            <field name="model">sale.exception</field>
+            <field name="type">tree</field>
+            <field name="arch" type="xml">
+                <tree string="Sale Exception">
+                    <field name="active"/>
+                    <field name="name"/>
+                    <field name="description"/>
+                    <field name="model"/>
+                    <field name="sequence"/>
+                </tree>
+            </field>
+        </record>
+
+        <record id="view_sale_exception_form" model="ir.ui.view">
+            <field name="name">sale.exception.form</field>
+            <field name="model">sale.exception</field>
+            <field name="type">form</field>
+            <field name="arch" type="xml">
+                <form string="Sale Exception Setup">
+                    <group colspan="4" col="2">
+                        <field name="name"/>
+                        <field name="description"/>
+                    </group>
+                    <group col="4" colspan="4" groups="base.group_sale_manager">
+                        <field name="active"/>
+                        <field name="sequence"/>
+                        <group colspan="4" col="2" groups="base.group_system">
+                            <field name="model"/>
+                            <field name="code"/>
+                        </group>
+                    </group>
+                    <group colspan="4" col="2">
+                        <separator string="Affected Sales Orders"/>
+                        <newline/>
+                        <field name="sale_order_ids" nolabel="1" domain="[('state', '=', 'draft')]"/>
+                    </group>
+                </form>
+            </field>
+        </record>
+
+        <record id="action_sale_test_tree" model="ir.actions.act_window">
+                  <field name="name">Exception Rules</field>
+                  <field name="res_model">sale.exception</field>
+                  <field name="view_type">form</field>
+                  <field name="view_mode">tree,form</field>
+                  <field name="view_id" ref="view_sale_exception_tree"/>
+                  <field name="context">{'active_test': False}</field>
+              </record>
+
+        <menuitem action="action_sale_test_tree" id="menu_sale_test" parent="base.menu_sale_config_sales" />
+
+
+        <record id="view_order_form" model="ir.ui.view">
+            <field name="name">sale_exceptions.view_order_form</field>
+            <field name="model">sale.order</field>
+            <field name="type">form</field>
+            <field name="priority">100</field>
+            <field name="inherit_id" ref="sale.view_order_form"/>
+            <field name="arch" type="xml">
+                <field name="name" position="after">
+                    <group>
+                    <field name="main_exception_id" options='{"no_open": True}'
+                           class="oe_inline" string="Error:"
+                           attrs="{'invisible':[('main_exception_id','=', False)]}"/>
+                    </group>
+                </field>
+                <xpath expr="//page[@string='Other Information']/group"
+                        position="inside">
+                    <group name="exception" colspan="2" col="2">
+                        <separator string="Exception" colspan="2"/>
+                        <field name="exceptions_ids" colspan="2" nolabel="1"/>
+                    </group>
+                </xpath>
+            </field>
+        </record>
+
+        <record id="view_order_tree" model="ir.ui.view">
+            <field name="name">sale_exceptions.view_order_tree</field>
+            <field name="model">sale.order</field>
+            <field name="type">tree</field>
+            <field name="inherit_id" ref="sale.view_order_tree"/>
+            <field name="arch" type="xml">
+                <field name="state" position="after">
+                    <field name="main_exception_id"/>
+                </field>
+            </field>
+        </record>
+
+        <record id="view_sales_order_filter" model="ir.ui.view">
+            <field name="name">sale_exceptions.view_sales_order_filter</field>
+            <field name="model">sale.order</field>
+            <field name="inherit_id" ref="sale.view_sales_order_filter" />
+            <field name="type">search</field>
+            <field eval="32" name="priority"/>
+            <field name="arch" type="xml">
+                <filter icon="terp-check" string="Sales" position="after">
+                    <separator orientation="vertical"/>
+                    <filter icon="terp-emblem-important" name="tofix" string="TO FIX" domain="[('main_exception_id','!=',False)]"/>
+                </filter>
+            </field>
+        </record>
+    </data>
+</openerp>

=== modified file 'sale_payment_method/__init__.py'
--- sale_payment_method/__init__.py	2013-09-26 08:42:06 +0000
+++ sale_payment_method/__init__.py	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 # -*- coding: utf-8 -*-
 ##############################################################################
 #
@@ -22,3 +23,29 @@
 from . import sale
 from . import payment_method
 from . import account_move
+=======
+# -*- coding: utf-8 -*-
+#################################################################################
+#                                                                               #
+#    sale_payment_method for OpenERP                                            #
+#    Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>   #
+#                                                                               #
+#    This program is free software: you can redistribute it and/or modify       #
+#    it under the terms of the GNU Affero General Public License as             #
+#    published by the Free Software Foundation, either version 3 of the         #
+#    License, or (at your option) any later version.                            #
+#                                                                               #
+#    This program is distributed in the hope that it will be useful,            #
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of             #
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              #
+#    GNU Affero General Public License for more details.                        #
+#                                                                               #
+#    You should have received a copy of the GNU Affero General Public License   #
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.      #
+#                                                                               #
+#################################################################################
+
+import sale
+import payment_method
+import account_move
+>>>>>>> MERGE-SOURCE

=== modified file 'sale_payment_method/__openerp__.py'
--- sale_payment_method/__openerp__.py	2013-09-26 08:41:34 +0000
+++ sale_payment_method/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 # -*- coding: utf-8 -*-
 ##############################################################################
 #
@@ -19,6 +20,29 @@
 #
 ##############################################################################
 
+=======
+# -*- coding: utf-8 -*-
+###############################################################################
+#                                                                             #
+#   sale_payment_method for OpenERP                                            #
+#   Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>  #
+#                                                                             #
+#   This program is free software: you can redistribute it and/or modify      #
+#   it under the terms of the GNU Affero General Public License as            #
+#   published by the Free Software Foundation, either version 3 of the        #
+#   License, or (at your option) any later version.                           #
+#                                                                             #
+#   This program is distributed in the hope that it will be useful,           #
+#   but WITHOUT ANY WARRANTY; without even the implied warranty of            #
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             #
+#   GNU Affero General Public License for more details.                       #
+#                                                                             #
+#   You should have received a copy of the GNU Affero General Public License  #
+#   along with this program.  If not, see <http://www.gnu.org/licenses/>.     #
+#                                                                             #
+###############################################################################
+
+>>>>>>> MERGE-SOURCE
 {
     'name': 'Sale Payment Method',
     'version': '0.2',
@@ -38,12 +62,23 @@
 """,
     'author': 'Akretion',
     'website': 'http://www.akretion.com/',
-    'depends': ['sale',
-                ],
-    'data': ['sale_view.xml',
-             'payment_method_view.xml',
-             'security/ir.model.access.csv',
-             ],
-    'demo': [],
+<<<<<<< TREE
+    'depends': ['sale',
+                ],
+    'data': ['sale_view.xml',
+             'payment_method_view.xml',
+             'security/ir.model.access.csv',
+             ],
+    'demo': [],
+=======
+    'depends': ['sale',
+                ],
+    'data': ['sale_view.xml',
+             'payment_method_view.xml',
+             'security/ir.model.access.csv',
+             'security/rules.xml',
+             ],
+    'demo': [],
+>>>>>>> MERGE-SOURCE
     'installable': True,
 }

=== modified file 'sale_payment_method/account_move.py'
--- sale_payment_method/account_move.py	2013-08-10 16:15:06 +0000
+++ sale_payment_method/account_move.py	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 # -*- coding: utf-8 -*-
 ##############################################################################
 #
@@ -28,3 +29,35 @@
     _columns = {
         'sale_ids': fields.many2many('sale.order', string='Sales Orders'),
     }
+=======
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    Author: Guewen Baconnier
+#    Copyright 2013 Camptocamp SA
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU Affero General Public License as
+#    published by the Free Software Foundation, either version 3 of the
+#    License, or (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU Affero General Public License for more details.
+#
+#    You should have received a copy of the GNU Affero General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+##############################################################################
+
+from openerp.osv import orm, fields
+
+
+class account_move(orm.Model):
+    _inherit = 'account.move'
+
+    _columns = {
+        'order_ids': fields.many2many('sale.order', string='Sales Orders'),
+    }
+>>>>>>> MERGE-SOURCE

=== renamed file 'sale_payment_method/migrations/0.1/post-migration.py' => 'sale_payment_method/migrations/0.1/post-migration.py.THIS'
=== modified file 'sale_payment_method/payment_method.py'
--- sale_payment_method/payment_method.py	2013-09-26 08:41:34 +0000
+++ sale_payment_method/payment_method.py	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 # -*- coding: utf-8 -*-
 ##############################################################################
 #
@@ -24,10 +25,39 @@
 
 
 class payment_method(orm.Model):
+=======
+# -*- coding: utf-8 -*-
+###############################################################################
+#                                                                             #
+#   sale_quick_payment for OpenERP                                            #
+#   Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>  #
+#   Copyright 2013 Camptocamp SA (Guewen Baconnier)                           #
+#                                                                             #
+#   This program is free software: you can redistribute it and/or modify      #
+#   it under the terms of the GNU Affero General Public License as            #
+#   published by the Free Software Foundation, either version 3 of the        #
+#   License, or (at your option) any later version.                           #
+#                                                                             #
+#   This program is distributed in the hope that it will be useful,           #
+#   but WITHOUT ANY WARRANTY; without even the implied warranty of            #
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             #
+#   GNU Affero General Public License for more details.                       #
+#                                                                             #
+#   You should have received a copy of the GNU Affero General Public License  #
+#   along with this program.  If not, see <http://www.gnu.org/licenses/>.     #
+#                                                                             #
+###############################################################################
+
+from openerp.osv import fields, orm
+
+
+class payment_method(orm.Model):
+>>>>>>> MERGE-SOURCE
     _name = "payment.method"
     _description = "Payment Method"
 
     _columns = {
+<<<<<<< TREE
         'name': fields.char('Name',
                             help="The name of the method on the backend"),
         'journal_id': fields.many2one(
@@ -41,3 +71,31 @@
             'Payment Term',
              help="Default payment term of a sale order using this method."),
     }
+=======
+        'name': fields.char('Name',
+                            help="The name of the method on the backend"),
+        'journal_id': fields.many2one(
+            'account.journal',
+            'Journal',
+            help="If a journal a selected, when a payment is recorded "
+                 "on a backend, payment entries will be created in this "
+                 "journal. "),
+        'payment_term_id': fields.many2one(
+            'account.payment.term',
+            'Payment Term',
+            help="Default payment term of a sale order using this method."),
+        'company_id': fields.many2one(
+            'res.company',
+            'Company',
+        ),
+    }
+
+    def _default_company_id(self, cr, uid, context):
+        company_model = self.pool.get('res.company')
+        return company_model._company_default_get(cr, uid, 'payment.method',
+                                                  context=context)
+
+    _defaults = {
+        'company_id': _default_company_id,
+    }
+>>>>>>> MERGE-SOURCE

=== modified file 'sale_payment_method/payment_method_view.xml'
--- sale_payment_method/payment_method_view.xml	2013-09-26 08:44:33 +0000
+++ sale_payment_method/payment_method_view.xml	2013-12-05 13:14:00 +0000
@@ -12,28 +12,54 @@
             <field name="name">sale_payment_method.payment_method.view_form</field>
             <field name="model">payment.method</field>
             <field name="arch" type="xml">
-                <form string="Payment Methods" version="7.0">
-                    <h1>
-                        <field name="name" class="oe_inline"/>
-                    </h1>
-                    <group name="general">
-                        <group name="config">
-                            <field name="journal_id" string="Journal for payment"/>
-                        </group>
-                        <group name="payment_help" class="oe_grey" col="1">
-                            <p attrs="{'invisible': [('journal_id', '=', False)]}">
-                                When the E-commerce backend will receive a payment for a sale order,
-                                payment entries will be generated in the selected journal.
-                            </p>
-                            <p attrs="{'invisible': [('journal_id', '!=', False)]}">
-                                Even if the E-commerce backend receives a payment for a sale order,
-                                no payment entries will be generated.
-                            </p>
-                        </group>
-                    </group>
-                    <group string="Default Values">
-                        <field name="payment_term_id" />
-                    </group>
+<<<<<<< TREE
+                <form string="Payment Methods" version="7.0">
+                    <h1>
+                        <field name="name" class="oe_inline"/>
+                    </h1>
+                    <group name="general">
+                        <group name="config">
+                            <field name="journal_id" string="Journal for payment"/>
+                        </group>
+                        <group name="payment_help" class="oe_grey" col="1">
+                            <p attrs="{'invisible': [('journal_id', '=', False)]}">
+                                When the E-commerce backend will receive a payment for a sale order,
+                                payment entries will be generated in the selected journal.
+                            </p>
+                            <p attrs="{'invisible': [('journal_id', '!=', False)]}">
+                                Even if the E-commerce backend receives a payment for a sale order,
+                                no payment entries will be generated.
+                            </p>
+                        </group>
+                    </group>
+                    <group string="Default Values">
+                        <field name="payment_term_id" />
+                    </group>
+=======
+                <form string="Payment Methods" version="7.0">
+                    <h1>
+                        <field name="name" class="oe_inline"/>
+                    </h1>
+                    <group name="general">
+                        <group name="config">
+                            <field name="company_id" string="Company" />
+                            <field name="journal_id" string="Journal for payment"/>
+                        </group>
+                        <group name="payment_help" class="oe_grey" col="1">
+                            <p attrs="{'invisible': [('journal_id', '=', False)]}">
+                                When the E-commerce backend will receive a payment for a sale order,
+                                payment entries will be generated in the selected journal.
+                            </p>
+                            <p attrs="{'invisible': [('journal_id', '!=', False)]}">
+                                Even if the E-commerce backend receives a payment for a sale order,
+                                no payment entries will be generated.
+                            </p>
+                        </group>
+                    </group>
+                    <group string="Default Values">
+                        <field name="payment_term_id" />
+                    </group>
+>>>>>>> MERGE-SOURCE
                 </form>
             </field>
         </record>

=== modified file 'sale_payment_method/sale.py'
--- sale_payment_method/sale.py	2013-09-01 16:28:01 +0000
+++ sale_payment_method/sale.py	2013-12-05 13:14:00 +0000
@@ -23,6 +23,7 @@
 from openerp.osv import orm, fields, osv
 from openerp.tools.translate import _
 from collections import Iterable
+<<<<<<< TREE
 import openerp.addons.decimal_precision as dp
 
 
@@ -36,6 +37,21 @@
             for order in move.order_ids:
                 result.add(order.id)
         return list(result)
+=======
+import decimal_precision as dp
+
+
+class sale_order(orm.Model):
+    _inherit = 'sale.order'
+
+    def _get_order_from_move(self, cr, uid, ids, context=None):
+        result = set()
+        move_obj = self.pool.get('account.move')
+        for move in move_obj.browse(cr, uid, ids, context=context):
+            for order in move.order_ids:
+                result.add(order.id)
+        return list(result)
+>>>>>>> MERGE-SOURCE
 
     def _get_order_from_line(self, cr, uid, ids, context=None):
         so_obj = self.pool.get('sale.order')
@@ -44,6 +60,7 @@
     def _get_amount(self, cr, uid, ids, fields, args, context=None):
         res = {}
         for order in self.browse(cr, uid, ids, context=context):
+<<<<<<< TREE
             #TODO add support when payment is linked to many order
             paid_amount = 0
             for line in order.payment_ids:    
@@ -58,9 +75,22 @@
         res = {}
         for sale in self.browse(cursor, user, ids, context=context):
             res[sale.id] = bool(sale.payment_ids)
+=======
+            amount = order.amount_total
+            for move in order.payment_ids:
+                amount -= move.amount
+            res[order.id] = amount
+        return res
+
+    def _payment_exists(self, cursor, user, ids, name, arg, context=None):
+        res = {}
+        for sale in self.browse(cursor, user, ids, context=context):
+            res[sale.id] = bool(sale.payment_ids)
+>>>>>>> MERGE-SOURCE
         return res
 
     _columns = {
+<<<<<<< TREE
         'payment_ids': fields.many2many('account.move.line',
                                         string='Payments Entries'),
         'payment_method_id': fields.many2one('payment.method',
@@ -83,11 +113,29 @@
             string='Has automatic payment',
             type='boolean',
             help="It indicates that sales order has at least one payment."),
+=======
+        'payment_ids': fields.many2many('account.move',
+                                        string='Payments Entries'),
+        'payment_method_id': fields.many2one('payment.method',
+                                             'Payment Method',
+                                             ondelete='restrict'),
+        'residual': fields.function(
+            _amount_residual,
+            digits_compute=dp.get_precision('Account'),
+            string='Balance',
+            store=False),
+        'payment_exists': fields.function(
+            _payment_exists,
+            string='Has automatic payment',
+            type='boolean',
+            help="It indicates that sales order has at least one payment."),
+>>>>>>> MERGE-SOURCE
     }
 
     def copy(self, cr, uid, id, default=None, context=None):
         if default is None:
             default = {}
+<<<<<<< TREE
         default['payment_ids'] = False
         return super(sale_order, self).copy(cr, uid, id,
                                             default, context=context)
@@ -294,3 +342,211 @@
                     _('Automatic payment entries are linked '
                       'with the sale order.'))
         return super(sale_order, self).action_cancel(cr, uid, ids, context=context)
+=======
+        default['payment_ids'] = False
+        return super(sale_order, self).copy(cr, uid, id,
+                                            default, context=context)
+
+    def automatic_payment(self, cr, uid, ids, amount=None, context=None):
+        """ Create the payment entries to pay a sale order, respecting
+        the payment terms.
+        If no amount is defined, it will pay the residual amount of the sale
+        order. """
+        if isinstance(ids, Iterable):
+            assert len(ids) == 1, "one sale order at a time can be paid"
+            ids = ids[0]
+        sale = self.browse(cr, uid, ids, context=context)
+        method = sale.payment_method_id
+        if not method:
+            raise osv.except_osv(
+                _('Configuration Error'),
+                _("An automatic payment can not be created for the sale "
+                  "order %s because it has no payment method.") % sale.name)
+
+        if not method.journal_id:
+            raise osv.except_osv(
+                _('Configuration Error'),
+                _("An automatic payment should be created for the sale order %s "
+                  "but the payment method '%s' has no journal defined.") %
+                (sale.name, method.name))
+
+        journal = method.journal_id
+        date = sale.date_order
+        if amount is None:
+            amount = sale.residual
+        if sale.payment_term:
+            term_obj = self.pool.get('account.payment.term')
+            amounts = term_obj.compute(cr, uid, sale.payment_term.id,
+                                       amount, date_ref=date,
+                                       context=context)
+        else:
+            amounts = [(date, amount)]
+
+        # reversed is cosmetic, compute returns terms in the 'wrong' order
+        for date, amount in reversed(amounts):
+            self._add_payment(cr, uid, sale, journal,
+                              amount, date, context=context)
+        return True
+
+    def add_payment(self, cr, uid, ids, journal_id, amount,
+                    date=None, context=None):
+        """ Generate payment move lines of a certain amount linked
+        with the sale order. """
+        if isinstance(ids, Iterable):
+            assert len(ids) == 1, "one sale order at a time can be paid"
+            ids = ids[0]
+        journal_obj = self.pool.get('account.journal')
+
+        sale = self.browse(cr, uid, ids, context=context)
+        if date is None:
+            date = sale.date_order
+        journal = journal_obj.browse(cr, uid, journal_id, context=context)
+        self._add_payment(cr, uid, sale, journal, amount, date, context=context)
+        return True
+
+    def _add_payment(self, cr, uid, sale, journal, amount, date, context=None):
+        """ Generate move lines entries to pay the sale order. """
+        move_obj = self.pool.get('account.move')
+        period_obj = self.pool.get('account.period')
+        period_id = period_obj.find(cr, uid, dt=date, context=context)[0]
+        period = period_obj.browse(cr, uid, period_id, context=context)
+        move_name = self._get_payment_move_name(cr, uid, journal,
+                                                period, context=context)
+        move_vals = self._prepare_payment_move(cr, uid, move_name, sale,
+                                               journal, period, date,
+                                               context=context)
+        move_lines = self._prepare_payment_move_line(cr, uid, move_name, sale,
+                                                     journal, period, amount,
+                                                     date, context=context)
+
+        move_vals['line_id'] = [(0, 0, line) for line in move_lines]
+        move_obj.create(cr, uid, move_vals, context=context)
+
+    def _get_payment_move_name(self, cr, uid, journal, period, context=None):
+        if context is None:
+            context = {}
+        seq_obj = self.pool.get('ir.sequence')
+        sequence = journal.sequence_id
+
+        if not sequence:
+            raise osv.except_osv(
+                _('Configuration Error'),
+                _('Please define a sequence on the journal %s.') %
+                journal.name)
+        if not sequence.active:
+            raise osv.except_osv(
+                _('Configuration Error'),
+                _('Please activate the sequence of the journal %s.') %
+                journal.name)
+
+        ctx = context.copy()
+        ctx['fiscalyear_id'] = period.fiscalyear_id.id
+        name = seq_obj.next_by_id(cr, uid, sequence.id, context=ctx)
+        return name
+
+    def _prepare_payment_move(self, cr, uid, move_name, sale, journal,
+                              period, date, context=None):
+        return {'name': move_name,
+                'journal_id': journal.id,
+                'date': date,
+                'ref': sale.name,
+                'period_id': period.id,
+                'order_ids': [(4, sale.id)],
+                }
+
+    def _prepare_payment_move_line(self, cr, uid, move_name, sale, journal,
+                                   period, amount, date, context=None):
+        """ """
+        partner_obj = self.pool.get('res.partner')
+        currency_obj = self.pool.get('res.currency')
+        partner = partner_obj._find_accounting_partner(sale.partner_id)
+
+        company = journal.company_id
+
+        currency_id = False
+        amount_currency = 0.0
+        if journal.currency and journal.currency.id != company.currency_id.id:
+            currency_id = journal.currency.id
+            amount_currency, amount = (amount,
+                                       currency_obj.compute(cr, uid,
+                                                            currency_id,
+                                                            company.currency_id.id,
+                                                            amount,
+                                                            context=context))
+
+        # payment line (bank / cash)
+        debit_line = {
+            'name': move_name,
+            'debit': amount,
+            'credit': 0.0,
+            'account_id': journal.default_credit_account_id.id,
+            'journal_id': journal.id,
+            'period_id': period.id,
+            'partner_id': partner.id,
+            'date': date,
+            'amount_currency': amount_currency,
+            'currency_id': currency_id,
+        }
+
+        # payment line (receivable)
+        credit_line = {
+            'name': move_name,
+            'debit': 0.0,
+            'credit': amount,
+            'account_id': partner.property_account_receivable.id,
+            'journal_id': journal.id,
+            'period_id': period.id,
+            'partner_id': partner.id,
+            'date': date,
+            'amount_currency': -amount_currency,
+            'currency_id': currency_id,
+        }
+        return debit_line, credit_line
+
+    def onchange_payment_method_id(self, cr, uid, ids, payment_method_id, context=None):
+        if not payment_method_id:
+            return {}
+        result = {}
+        method_obj = self.pool.get('payment.method')
+        method = method_obj.browse(cr, uid, payment_method_id, context=context)
+        if method.payment_term_id:
+            result['payment_term'] = method.payment_term_id.id
+        return {'value': result}
+
+    def action_view_payments(self, cr, uid, ids, context=None):
+        """ Return an action to display the payment linked
+        with the sale order """
+
+        mod_obj = self.pool.get('ir.model.data')
+        act_obj = self.pool.get('ir.actions.act_window')
+
+        payment_ids = []
+        for so in self.browse(cr, uid, ids, context=context):
+            payment_ids += [move.id for move in so.payment_ids]
+
+        ref = mod_obj.get_object_reference(cr, uid, 'account',
+                                           'action_move_journal_line')
+        action_id = False
+        if ref:
+            __, action_id = ref
+        action = act_obj.read(cr, uid, [action_id], context=context)[0]
+
+        # choose the view_mode accordingly
+        if len(payment_ids) > 1:
+            action['domain'] = str([('id', 'in', payment_ids)])
+        else:
+            ref = mod_obj.get_object_reference(cr, uid, 'account',
+                                               'view_move_form')
+            action['views'] = [(ref[1] if ref else False, 'form')]
+            action['res_id'] = payment_ids[0] if payment_ids else False
+        return action
+
+    def action_cancel(self, cr, uid, ids, context=None):
+        for sale in self.browse(cr, uid, ids, context=context):
+            if sale.payment_ids:
+                raise osv.except_osv(
+                    _('Cannot cancel this sales order!'),
+                    _('Automatic payment entries are linked '
+                      'with the sale order.'))
+        return super(sale_order, self).action_cancel(cr, uid, ids, context=context)
+>>>>>>> MERGE-SOURCE

=== modified file 'sale_payment_method/sale_view.xml'
=== added file 'sale_payment_method/security/rules.xml'
--- sale_payment_method/security/rules.xml	1970-01-01 00:00:00 +0000
+++ sale_payment_method/security/rules.xml	2013-12-05 13:14:00 +0000
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<openerp>
+<data noupdate="1">
+
+    <record id="payment_method_rule" model="ir.rule">
+        <field name="name">Payment method multi-company</field>
+        <field name="model_id" ref="model_payment_method" />
+        <field name="global" eval="True" />
+        <field name="domain_force">['|','|',('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id]),('company_id','=',False)]</field>
+    </record>
+
+</data>
+</openerp>

=== modified file 'sale_quick_payment/__init__.py'
--- sale_quick_payment/__init__.py	2013-09-26 08:48:27 +0000
+++ sale_quick_payment/__init__.py	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 # -*- coding: utf-8 -*-
 ##############################################################################
 #
@@ -20,3 +21,27 @@
 ##############################################################################
 
 from . import wizard
+=======
+# -*- coding: utf-8 -*-
+#################################################################################
+#                                                                               #
+#    sale_quick_payment for OpenERP                                             #
+#    Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>   #
+#                                                                               #
+#    This program is free software: you can redistribute it and/or modify       #
+#    it under the terms of the GNU Affero General Public License as             #
+#    published by the Free Software Foundation, either version 3 of the         #
+#    License, or (at your option) any later version.                            #
+#                                                                               #
+#    This program is distributed in the hope that it will be useful,            #
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of             #
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              #
+#    GNU Affero General Public License for more details.                        #
+#                                                                               #
+#    You should have received a copy of the GNU Affero General Public License   #
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.      #
+#                                                                               #
+#################################################################################
+
+import wizard
+>>>>>>> MERGE-SOURCE

=== modified file 'sale_quick_payment/__openerp__.py'
--- sale_quick_payment/__openerp__.py	2013-09-26 08:47:27 +0000
+++ sale_quick_payment/__openerp__.py	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 # -*- coding: utf-8 -*-
 ##############################################################################
 #
@@ -53,3 +54,60 @@
     'demo': [],
     'installable': True,
 }
+=======
+# -*- coding: utf-8 -*-
+###############################################################################
+#                                                                             #
+#   sale_payment_method for OpenERP                                            #
+#   Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>  #
+#                                                                             #
+#   This program is free software: you can redistribute it and/or modify      #
+#   it under the terms of the GNU Affero General Public License as            #
+#   published by the Free Software Foundation, either version 3 of the        #
+#   License, or (at your option) any later version.                           #
+#                                                                             #
+#   This program is distributed in the hope that it will be useful,           #
+#   but WITHOUT ANY WARRANTY; without even the implied warranty of            #
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             #
+#   GNU Affero General Public License for more details.                       #
+#                                                                             #
+#   You should have received a copy of the GNU Affero General Public License  #
+#   along with this program.  If not, see <http://www.gnu.org/licenses/>.     #
+#                                                                             #
+###############################################################################
+
+
+{
+    'name': 'Sale Quick Payment',
+    'version': '0.2',
+    'category': 'Generic Modules/Others',
+    'license': 'AGPL-3',
+    'description': """
+Sale Quick Payment
+==================
+
+Sale Quick Payment gives the possibility to pay a sale order from the
+sale order itself.
+
+The payment will be linked to the sale order.
+
+If you install the module Sale Automatic Workflow, you can forbid the
+validation of an unpaid order and the invoice will be automatically
+reconciled with the payment.
+
+This module was originally designed for the e-commerce sector, but it
+does not preclude to use it in other sectors.
+    """,
+    'author': 'Akretion',
+    'website': 'http://www.akretion.com/',
+    'depends': ['sale_payment_method',
+                'sale_exceptions',
+                ],
+    'data': ['wizard/pay_sale_order.xml',
+             'sale_view.xml',
+             'settings/sale.exception.csv',
+             ],
+    'demo': [],
+    'installable': True,
+}
+>>>>>>> MERGE-SOURCE

=== modified file 'sale_quick_payment/sale_view.xml'
--- sale_quick_payment/sale_view.xml	2013-09-01 16:28:01 +0000
+++ sale_quick_payment/sale_view.xml	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 <?xml version="1.0" encoding="utf-8"?>
 <!--
   sale_quick_payment for OpenERP
@@ -38,3 +39,37 @@
 
     </data>
 </openerp>
+=======
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  sale_quick_payment for OpenERP
+  Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>
+  The licence is in the file __openerp__.py
+-->
+
+<openerp>
+    <data>
+
+        <!-- INHERITED VIEW FOR THE OBJECT : sale_order -->
+
+        <record id="sale_order_view_form" model="ir.ui.view">
+            <field name="name">sale_quick_payment.sale_order.view_form</field>
+            <field name="model">sale.order</field>
+            <field name="inherit_id" ref="sale_payment_method.sale_order_view_form" />
+            <field name="arch" type="xml">
+                <button name="print_quotation" position="after">
+                  <button name="%(open_pay_sale_order)d"
+                      string="Register Payments"
+                      type="action" states="draft,sent"/>
+                </button>
+                <field name="payment_method_id" position="after" >
+                    <group name="payments" string="Generated Payments" colspan="4">
+                        <field name="payment_ids" nolabel="1" />
+                    </group>
+                </field>
+            </field>
+        </record>
+
+    </data>
+</openerp>
+>>>>>>> MERGE-SOURCE

=== modified file 'sale_quick_payment/wizard/pay_sale_order.py'
--- sale_quick_payment/wizard/pay_sale_order.py	2013-09-20 01:11:52 +0000
+++ sale_quick_payment/wizard/pay_sale_order.py	2013-12-05 13:14:00 +0000
@@ -1,3 +1,4 @@
+<<<<<<< TREE
 # -*- coding: utf-8 -*-
 ##############################################################################
 #
@@ -24,6 +25,36 @@
 
 
 class pay_sale_order(orm.TransientModel):
+=======
+# -*- coding: utf-8 -*-
+#################################################################################
+#                                                                               #
+#    Magentoerpconnect for OpenERP                                              #
+#    Copyright (C) 2011 Akretion Sébastien BEAU <sebastien.beau@xxxxxxxxxxxx>   #
+#                                                                               #
+#    This program is free software: you can redistribute it and/or modify       #
+#    it under the terms of the GNU Affero General Public License as             #
+#    published by the Free Software Foundation, either version 3 of the         #
+#    License, or (at your option) any later version.                            #
+#                                                                               #
+#    This program is distributed in the hope that it will be useful,            #
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of             #
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              #
+#    GNU Affero General Public License for more details.                        #
+#                                                                               #
+#    You should have received a copy of the GNU Affero General Public License   #
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.      #
+#                                                                               #
+#################################################################################
+
+
+from openerp.osv.orm import TransientModel
+from openerp.osv import fields
+import decimal_precision as dp
+
+
+class pay_sale_order(TransientModel):
+>>>>>>> MERGE-SOURCE
     _name = 'pay.sale.order'
     _description = 'Wizard to generate a payment from the sale order'
 
@@ -32,8 +63,12 @@
         'amount': fields.float('Amount',
                                digits_compute=dp.get_precision('Sale Price')),
         'date': fields.datetime('Payment Date'),
+<<<<<<< TREE
         'description': fields.char('Description', size=64),
     }
+=======
+    }
+>>>>>>> MERGE-SOURCE
 
     def _get_journal_id(self, cr, uid, context=None):
         if context is None:
@@ -65,6 +100,7 @@
     def pay_sale_order(self, cr, uid, ids, context=None):
         """ Pay the sale order """
         wizard = self.browse(cr, uid, ids[0], context=context)
+<<<<<<< TREE
         sale_obj = self.pool.get('sale.order')
         sale_obj.add_payment(cr, uid,
                              context['active_id'],
@@ -73,6 +109,15 @@
                              wizard.date,
                              description=wizard.description,
                              context=context)
+=======
+        sale_obj = self.pool.get('sale.order')
+        sale_obj.add_payment(cr, uid,
+                             context['active_id'],
+                             wizard.journal_id.id,
+                             wizard.amount,
+                             wizard.date,
+                             context=context)
+>>>>>>> MERGE-SOURCE
         return {'type': 'ir.actions.act_window_close'}
 
     def pay_sale_order_and_confirm(self, cr, uid, ids, context=None):


Follow ups