add petty invoice base
This commit is contained in:
parent
94a90c2f65
commit
3d07e74d28
|
|
@ -0,0 +1,2 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
from . import models
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
{
|
||||
'name': "Petty Invoice",
|
||||
'summary': """Accounting""",
|
||||
'category': 'Odex25-Project/Odex25-Project',
|
||||
'description': """
|
||||
Mark invoice as petty cash one
|
||||
|
||||
""",
|
||||
'version': '0.1',
|
||||
'depends': ['account'],
|
||||
'data': [
|
||||
'views/account_move_view.xml',
|
||||
],
|
||||
}
|
||||
|
|
@ -0,0 +1,34 @@
|
|||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * petty_invoice
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2024-10-27 03:55+0000\n"
|
||||
"PO-Revision-Date: 2024-10-27 03:55+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: petty_invoice
|
||||
#: model_terms:ir.ui.view,arch_db:petty_invoice.view_account_invoice_filter
|
||||
msgid "Created By"
|
||||
msgstr "تم الإنشاء بواسطة"
|
||||
|
||||
#. module: petty_invoice
|
||||
#: model:ir.model,name:petty_invoice.model_account_move
|
||||
msgid "Journal Entry"
|
||||
msgstr "قيد اليومية"
|
||||
|
||||
#. module: petty_invoice
|
||||
#: model:ir.model.fields,field_description:petty_invoice.field_account_bank_statement_line__is_petty_paid
|
||||
#: model:ir.model.fields,field_description:petty_invoice.field_account_move__is_petty_paid
|
||||
#: model:ir.model.fields,field_description:petty_invoice.field_account_payment__is_petty_paid
|
||||
#: model_terms:ir.ui.view,arch_db:petty_invoice.view_account_invoice_filter
|
||||
msgid "Paid by Petty Cash"
|
||||
msgstr "منصرفه من العهد"
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import account_move
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import models, fields
|
||||
|
||||
|
||||
class AccountMove(models.Model):
|
||||
_inherit = 'account.move'
|
||||
|
||||
is_petty_paid = fields.Boolean(string='Paid by Petty Cash', default=False)
|
||||
|
|
@ -0,0 +1,33 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<record id="view_account_invoice_filter" model="ir.ui.view">
|
||||
<field name="name">account.move.paid.petty.inherit.select</field>
|
||||
<field name="model">account.move</field>
|
||||
<field name="inherit_id" ref="account.view_account_invoice_filter"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//field[@name='date']" position="after">
|
||||
<field name="is_petty_paid"/>
|
||||
<filter name="is_petty_paid" string="Paid by Petty Cash"
|
||||
domain="[('is_petty_paid', '=',True)]"/>
|
||||
|
||||
</xpath>
|
||||
<xpath expr="//group" position="inside">
|
||||
<filter name="group_by_created_by" string="Created By" context="{'group_by':'create_uid'}"/>
|
||||
</xpath>
|
||||
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="view_move_form" model="ir.ui.view">
|
||||
<field name="name">account.move.paid.petty.inherit.form</field>
|
||||
<field name="model">account.move</field>
|
||||
<field name="inherit_id" ref="account.view_move_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//field[@name='invoice_date']" position="after">
|
||||
<field name="is_petty_paid" readonly="1"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
Loading…
Reference in New Issue