Skip to content

Commit

Permalink
[MIG] card_installment: Migration to 17.0
Browse files Browse the repository at this point in the history
closes #425

Signed-off-by: Juan José Scarafía <jjs@adhoc.com.ar>
  • Loading branch information
rov-adhoc committed Dec 13, 2023
1 parent 0b9f8d4 commit 5146360
Show file tree
Hide file tree
Showing 5 changed files with 66 additions and 11 deletions.
49 changes: 49 additions & 0 deletions card_installment/README.rst
@@ -0,0 +1,49 @@
Card Installment
=======================


Module that adds a "Cards" menu
which allows you to define installment plans for debit/credit cards
by defining: fantasy name, installment plan, divisor, coefficient, bank discount.


Installation
============
To install this module, you need to:
#. Just install this module.

Configuration
=============
To configure this module, you need to:
#. No configuration nedeed.

Usage
=====
To use this module, you need to:
#. Go to Cards menu and define installment plans for debit/credit cards
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
:alt: Try me on Runbot
:target: http://runbot.adhoc.com.ar/

Bug Tracker
===========
Bugs are tracked on `GitHub Issues
<https://github.com/ingadhoc/account-invoicing/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.

Credits
=======

Images
------
* |company| |icon|

Contributors
------------

Maintainer
----------
|company_logo|
This module is maintained by the |company|.
To contribute to this module, please visit https://www.adhoc.com.ar.
5 changes: 3 additions & 2 deletions card_installment/__manifest__.py
Expand Up @@ -6,18 +6,19 @@
'author': 'ADHOC SA',
'website': "https://www.adhoc.com.ar",
'category': 'Technical',
'version': "16.0.1.0.0",
'version': "17.0.1.0.0",
'depends': ['product', 'account'],
'license': 'LGPL-3',
'images': [
],
'installable': False,
'installable': True,
'data': [
'security/ir.model.access.csv',
'security/ir_rule.xml',
'data/account_card.xml',
'data/decimal_installment_coeficent.xml',
'views/account_card.xml',
'views/card_installment_view.xml',
],
'demo': [
'demo/product_product.xml',
Expand Down
2 changes: 1 addition & 1 deletion card_installment/models/account_card.py
Expand Up @@ -8,6 +8,7 @@
class AccountCard(models.Model):
_name = 'account.card'
_description = 'Credit Card'
_check_company_auto = True

name = fields.Char(
'name',
Expand All @@ -20,7 +21,6 @@ class AccountCard(models.Model):
)
company_id = fields.Many2one(
'res.company',
string='company',
default=lambda self: self.env.company.id
)
active = fields.Boolean(
Expand Down
16 changes: 8 additions & 8 deletions card_installment/models/account_card_installment.py
Expand Up @@ -15,25 +15,25 @@ class AccountCardInstallment(models.Model):
required=True,
)
name = fields.Char(
'Fantasy name',
default='/'
'Fantasy Name',
default='/',
help = 'Nombre informativo del plan a mostrar'
)
divisor = fields.Integer(
string='Divisor',
help = 'Número por el cual se dividirá el total de cuotas que pagará el usuario final'
)
installment = fields.Integer(
string='installment plan',
help='Number of installment'
string='Installment Plan',
help='Plan de cuotas a informar, en caso de utilizar método de pago electrónico: el valor del plan a informar al gateway de pago'
)
surcharge_coefficient = fields.Float(
string='coefficient',
default=1.0,
digits='Installment coefficient',
help='Coeficiente con iva incluido'
help='Factor a aplicar sobre el monto total para calcular el cargo financiero'
)
bank_discount = fields.Float(
string='bank discount',
help='Bank discount'
help='Porcentaje de reintegro (el reintegro se efectúa sobre el total incluído el recargo financiero) que acuerda el vendedor con el banco o marca de tarjeta para devolución en compra'
)
active = fields.Boolean(
'Active',
Expand Down
5 changes: 5 additions & 0 deletions card_installment/views/card_installment_view.xml
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<menuitem action="action_account_card" id="menu_account_card" parent="account.root_payment_menu" sequence="20" />
<menuitem action="action_card_installment" id="menu_account_finacial_plans" parent="account.root_payment_menu" sequence="21" />
</odoo>

0 comments on commit 5146360

Please sign in to comment.