Kaynağa Gözat

commit inicial

Rodney Enciso Arias 8 yıl önce
işleme
d9fc8721ad
12 değiştirilmiş dosya ile 344 ekleme ve 0 silme
  1. 76 0
      README.rst
  2. 20 0
      __init__.py
  3. BIN
      __init__.pyc
  4. 34 0
      __openerp__.py
  5. 30 0
      i18n/es.po
  6. 30 0
      i18n/fr.po
  7. 32 0
      i18n/invoicing_voucher_killer.pot
  8. 30 0
      i18n/pt_BR.po
  9. 30 0
      i18n/sl.po
  10. 7 0
      invoice_data.xml
  11. 55 0
      invoice_view.xml
  12. BIN
      static/description/icon.png

+ 76 - 0
README.rst

@@ -0,0 +1,76 @@
+.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
+    :alt: License: AGPL-3
+    
+Prevent the usage of voucher from invoices
+==========================================
+
+This add-on disables the "Register Payment" button on
+customer invoices and the "Pay" button on supplier invoices.
+
+It also disables the voucher-related menus entries such as 
+"Sales Receipts", "Customer Payments", "Purchase Receipts", 
+"Supplier Payments" and "Journal Vouchers", "Sales Receipts Analysis".
+
+More precisely, this module adds a group "Use voucher in Invoices"
+and only users in that group see these buttons and menus.
+
+Installation
+============
+
+This module depends on :
+* account_voucher
+
+This modules are parts of the OCA/bank-payment suite.
+
+Configuration
+=============
+
+There is nothing to configure.
+
+Usage
+=====
+
+See above the description of the module.
+
+
+For further information, please visit:
+
+ * https://www.odoo.com/forum/help-1
+
+Known issues / Roadmap
+======================
+
+ * ...
+ 
+Bug Tracker
+===========
+
+Bugs are tracked on `GitHub Issues <https://github.com/OCA/bank-payment/issues>`_.
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
+`here <https://github.com/OCA/bank-payment/issues/new?body=module:%20account_voucher_killer%0Aversion:%208.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
+
+Credits
+=======
+
+Contributors
+------------
+
+* Nicolas Bessi (camptocamp)
+* Stéphane Bidoul <stephane.bidoul@acsone.eu>
+* Anthony Muschang <anthony.muschang@acsone.eu>
+* Yannick Vaucher
+
+Maintainer
+----------
+
+.. image:: http://odoo-community.org/logo.png
+   :alt: Odoo Community Association
+   :target: http://odoo-community.org
+
+This module is maintained by the OCA.
+
+OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.
+
+To contribute to this module, please visit http://odoo-community.org.
+

+ 20 - 0
__init__.py

@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#   Copyright (c) 2013 Camptocamp SA (http://www.camptocamp.com)
+#   @author Nicolas Bessi
+#
+#    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/>.
+#
+##############################################################################

BIN
__init__.pyc


+ 34 - 0
__openerp__.py

@@ -0,0 +1,34 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#   Copyright (c) 2013 Camptocamp SA (http://www.camptocamp.com)
+#   @author Nicolas Bessi
+#
+#    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': 'Accounting voucher killer',
+ 'version': '8.0.1.0.0',
+ 'category': 'other',
+ 'author': "Camptocamp,Odoo Community Association (OCA)",
+ 'website': 'http://www.camptocamp.com',
+ 'license': 'AGPL-3',
+ 'depends': ['account_voucher'],
+ 'data': ['invoice_data.xml',
+          'invoice_view.xml'],
+ 'test': [],
+ 'installable': True,
+ 'active': False,
+ }

+ 30 - 0
i18n/es.po

@@ -0,0 +1,30 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * account_voucher_killer
+# 
+# Translators:
+# FIRST AUTHOR <EMAIL@ADDRESS>, 2014
+msgid ""
+msgstr ""
+"Project-Id-Version: bank-payment (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-08 00:46+0000\n"
+"PO-Revision-Date: 2016-04-06 00:16+0000\n"
+"Last-Translator: OCA Transbot <transbot@odoo-community.org>\n"
+"Language-Team: Spanish (http://www.transifex.com/oca/OCA-bank-payment-8-0/language/es/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: es\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: account_voucher_killer
+#: model:res.groups,name:account_voucher_killer.invoice_voucher_user
+msgid "Use voucher in Invoices"
+msgstr "Usar resguardos en facturas"
+
+#. module: account_voucher_killer
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group_supp_inv
+msgid "account_voucher_killer.invoice_voucher_user"
+msgstr ""

+ 30 - 0
i18n/fr.po

@@ -0,0 +1,30 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * account_voucher_killer
+# 
+# Translators:
+# Christophe CHAUVET <christophe.chauvet@gmail.com>, 2016
+msgid ""
+msgstr ""
+"Project-Id-Version: bank-payment (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-12-24 00:27+0000\n"
+"PO-Revision-Date: 2016-12-27 16:48+0000\n"
+"Last-Translator: Christophe CHAUVET <christophe.chauvet@gmail.com>\n"
+"Language-Team: French (http://www.transifex.com/oca/OCA-bank-payment-8-0/language/fr/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: fr\n"
+"Plural-Forms: nplurals=2; plural=(n > 1);\n"
+
+#. module: account_voucher_killer
+#: model:res.groups,name:account_voucher_killer.invoice_voucher_user
+msgid "Use voucher in Invoices"
+msgstr "Utiliser les paiements sur les factures"
+
+#. module: account_voucher_killer
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group_supp_inv
+msgid "account_voucher_killer.invoice_voucher_user"
+msgstr "account_voucher_killer.invoice_voucher_user"

+ 32 - 0
i18n/invoicing_voucher_killer.pot

@@ -0,0 +1,32 @@
+# Translation of OpenERP Server.
+# This file contains the translation of the following modules:
+#	* invoicing_voucher_killer
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: OpenERP Server 7.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2014-01-21 12:00+0000\n"
+"PO-Revision-Date: 2014-01-21 12:00+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: invoicing_voucher_killer
+#: view:account.invoice:0
+msgid "Pay"
+msgstr ""
+
+#. module: invoicing_voucher_killer
+#: model:res.groups,name:invoicing_voucher_killer.invoice_voucher_user
+msgid "Use voucher in Invoices"
+msgstr ""
+
+#. module: invoicing_voucher_killer
+#: view:account.invoice:0
+msgid "Register Payment"
+msgstr ""
+

+ 30 - 0
i18n/pt_BR.po

@@ -0,0 +1,30 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * account_voucher_killer
+# 
+# Translators:
+# danimaribeiro <danimaribeiro@gmail.com>, 2016
+msgid ""
+msgstr ""
+"Project-Id-Version: bank-payment (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-08 00:46+0000\n"
+"PO-Revision-Date: 2016-04-06 01:03+0000\n"
+"Last-Translator: danimaribeiro <danimaribeiro@gmail.com>\n"
+"Language-Team: Portuguese (Brazil) (http://www.transifex.com/oca/OCA-bank-payment-8-0/language/pt_BR/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: pt_BR\n"
+"Plural-Forms: nplurals=2; plural=(n > 1);\n"
+
+#. module: account_voucher_killer
+#: model:res.groups,name:account_voucher_killer.invoice_voucher_user
+msgid "Use voucher in Invoices"
+msgstr "Usar recibos nas faturas"
+
+#. module: account_voucher_killer
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group_supp_inv
+msgid "account_voucher_killer.invoice_voucher_user"
+msgstr ""

+ 30 - 0
i18n/sl.po

@@ -0,0 +1,30 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * account_voucher_killer
+# 
+# Translators:
+# Matjaž Mozetič <m.mozetic@matmoz.si>, 2016
+msgid ""
+msgstr ""
+"Project-Id-Version: bank-payment (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-08 00:46+0000\n"
+"PO-Revision-Date: 2016-04-06 04:53+0000\n"
+"Last-Translator: Matjaž Mozetič <m.mozetic@matmoz.si>\n"
+"Language-Team: Slovenian (http://www.transifex.com/oca/OCA-bank-payment-8-0/language/sl/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: sl\n"
+"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n%100==4 ? 2 : 3);\n"
+
+#. module: account_voucher_killer
+#: model:res.groups,name:account_voucher_killer.invoice_voucher_user
+msgid "Use voucher in Invoices"
+msgstr "Uporaba vavčerja pri računih"
+
+#. module: account_voucher_killer
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group
+#: view:account.invoice:account_voucher_killer.invoice_voucher_group_supp_inv
+msgid "account_voucher_killer.invoice_voucher_user"
+msgstr "account_voucher_killer.invoice_voucher_user"

+ 7 - 0
invoice_data.xml

@@ -0,0 +1,7 @@
+<openerp>
+  <data>
+    <record id="invoice_voucher_user" model="res.groups">
+      <field name="name">Use voucher in Invoices</field>
+    </record>
+  </data>
+</openerp>

+ 55 - 0
invoice_view.xml

@@ -0,0 +1,55 @@
+<openerp>
+  <data>
+    <record id="invoice_voucher_group" model="ir.ui.view">
+      <field name="name">Hide voucher in invoice</field>
+      <field name="model">account.invoice</field>
+      <field name="inherit_id" ref="account_voucher.view_invoice_customer" />
+      <field name="arch" type="xml">
+        <xpath expr="//button[@name='invoice_pay_customer'][last()]"
+               position="attributes">
+           <attribute name="groups">account_voucher_killer.invoice_voucher_user</attribute>
+        </xpath>
+        <xpath expr="//button[@name='invoice_pay_customer'][1]"
+               position="attributes">
+           <attribute name="groups">account_voucher_killer.invoice_voucher_user</attribute>
+        </xpath>
+      </field>
+    </record>
+
+    <record id="invoice_voucher_group_supp_inv" model="ir.ui.view">
+      <field name="name">Hide voucher in supplier invoice</field>
+      <field name="model">account.invoice</field>
+      <field name="inherit_id" ref="account_voucher.view_invoice_supplier" />
+      <field name="arch" type="xml">
+        <xpath expr="//button[@name='invoice_pay_customer'][last()]"
+               position="attributes">
+           <attribute name="groups">account_voucher_killer.invoice_voucher_user</attribute>
+        </xpath>
+      </field>
+    </record>
+
+   <record id="account_voucher.menu_action_sale_receipt" model="ir.ui.menu">
+       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
+   </record>
+   
+   <record id="account_voucher.menu_action_vendor_receipt" model="ir.ui.menu">
+       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
+   </record>
+   
+   <record id="account_voucher.menu_action_purchase_receipt" model="ir.ui.menu">
+       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
+   </record>
+   
+   <record id="account_voucher.menu_action_vendor_payment" model="ir.ui.menu">
+       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
+   </record>
+   
+   <record id="account_voucher.menu_encode_entries_by_voucher" model="ir.ui.menu">
+       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
+   </record>
+   
+   <record id="account_voucher.menu_action_sale_receipt_report_all" model="ir.ui.menu">
+       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
+   </record>
+  </data>
+</openerp>

BIN
static/description/icon.png