Skip to content

Commit

Permalink
[IMP] - add next_action_type_id to payment return reason form view
Browse files Browse the repository at this point in the history
Fix payment_return_reason_action_type file name
  • Loading branch information
sbejaoui committed Jul 14, 2020
1 parent 3c0c895 commit efe892a
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 19 deletions.
4 changes: 2 additions & 2 deletions account_payment_return/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@
'initOS GmbH & Co., ',
'website': 'https://github.com/OCA/account-payment',
'data': [
'data/ir_sequence_data.xml',
'security/ir.model.access.csv',
'security/account_payment_return_security.xml',
'views/payment_return_reason_view.xml',
'views/payment_return_view.xml',
'views/account_journal_view.xml',
'data/ir_sequence_data.xml',
'views/account_invoice_view.xml',
'views/payment_return_reason.xml',
'views/payment_return_reason_action_type.xml',
],
'qweb': [
"static/src/xml/account_payment.xml",
Expand Down
1 change: 1 addition & 0 deletions account_payment_return/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
from . import payment_return_reason
from . import account_move
from . import account_journal
from . import payment_return_reason_action_type
17 changes: 0 additions & 17 deletions account_payment_return/models/payment_return_reason.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,6 @@
from odoo import api, fields, models


class PaymentReturnReasonActionType(models.Model):

_name = "payment.return.reason.action.type"
_description = "Payment Return Reason Action Types"
_order = "sequence, id"

name = fields.Char(required=True)
sequence = fields.Integer("Sequence", default=10)
active = fields.Boolean(default=True)
company_id = fields.Many2one(
"res.company",
"Company",
default=lambda self: self.env.user.company_id,
ondelete="cascade",
)


class PaymentReturnReason(models.Model):
_name = "payment.return.reason"
_description = 'Payment return reason'
Expand Down
21 changes: 21 additions & 0 deletions account_payment_return/models/payment_return_reason_action_type.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Copyright 2019 ACSONE SA/NV
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from odoo import api, fields, models


class PaymentReturnReasonActionType(models.Model):

_name = "payment.return.reason.action.type"
_description = "Payment Return Reason Action Types"
_order = "sequence, id"

name = fields.Char(required=True)
sequence = fields.Integer("Sequence", default=10)
active = fields.Boolean(default=True)
company_id = fields.Many2one(
"res.company",
"Company",
default=lambda self: self.env.user.company_id,
ondelete="cascade",
)
1 change: 1 addition & 0 deletions account_payment_return/views/payment_return_reason.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
<group>
<field name="code" required="True"/>
<field name="name" required="True"/>
<field name="next_action_type_id"/>
</group>
</form>
</field>
Expand Down

0 comments on commit efe892a

Please sign in to comment.