MIG hr_expense_change For odoo 12.0

This commit is contained in:
Bhoomi
2019-09-13 12:02:13 -04:00
committed by Connor Christian
parent 42db727267
commit eaa69853b1
3 changed files with 6 additions and 6 deletions

View File

@@ -1,7 +1,7 @@
{
'name': 'HR Expense Change',
'author': 'Hibou Corp. <hello@hibou.io>',
'version': '11.0.1.0.0',
'version': '12.0.1.0.0',
'category': 'Employees',
'sequence': 95,
'summary': 'Technical foundation for changing expenses.',

View File

@@ -1,11 +1,11 @@
from odoo.addons.hr_expense.tests.test_expenses import TestCheckJournalEntry
from odoo.addons.hr_expense.tests.test_expenses import TestAccountEntry
class TestExpenseChange(TestCheckJournalEntry):
class TestAccountEntry(TestAccountEntry):
def test_expense_change_basic(self):
# posts expense and gets move ready at self.expense.account_move_id.id
self.test_journal_entry()
self.test_account_entry()
self.assertEqual(self.expense.expense_line_ids.date, self.expense.account_move_id.date)
ctx = {'active_model': 'hr.expense', 'active_ids': self.expense.expense_line_ids.ids}

View File

@@ -32,10 +32,10 @@
</record>
<!-- Add Button to Existing Forms -->
<record id="hr_expense_form_view_inherit" model="ir.ui.view">
<record id="hr_expense_view_form_inherit" model="ir.ui.view">
<field name="name">hr.expense.form.inherit</field>
<field name="model">hr.expense</field>
<field name="inherit_id" ref="hr_expense.hr_expense_form_view"/>
<field name="inherit_id" ref="hr_expense.hr_expense_view_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='state']" position="before">
<button name="%(action_view_hr_expense_change)d" string="Change"