Commit 1c6b271a by Maria Agustina

1423

0 parents
from . import models
# -*- coding: utf-8 -*-
###############################################################################
#
# Odoo, Open Source Management Solution
#
# Copyright (c) All rights reserved:
# (c) 2015 TM_FULLNAME
#
# 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': 'hgt_cobranzas',
'summary': 'hgt_cobranzas Module Project',
'version': '0.21.05.27',
'description': """
hgt_cobranzas Module Project.
==============================================
Módulo para cobranzas.
""",
'author': 'HGT',
'maintainer': 'HGT',
'contributors':,
'website': 'http://anacsoft.com',
'license': 'AGPL-3',
'category': 'Uncategorized',
'depends': [
'base',
'asw_crm',
'asw_tpv',
],
'external_dependencies': {
'python': [
],
},
'data': [
'security/ir.model.access.csv',
'view/cobros.xml',
'view/intereses.xml',
'view/menu.xml',
],
'demo': [
],
'js': [
],
'css': [
],
'qweb': [
],
'images': [
],
'test': [
],
'application': True,
'installable': True,
}
from . import cobros
from . import linea_deuda
from . import intereses
from . import comprobante
\ No newline at end of file
# -*- coding: utf-8 -*-
#from odoo.exceptions import UserError
from odoo import models, fields, api
#from datetime import datetime
class vnt_cobros(models.Model):
_name = 'vnt.cobros'
co_cliente = fields.Many2one(
string='Cliente',
comodel_name='hgt.instituciones',
)
co_lin_deuda = fields.Many2many(
string=u"Línea Deuda",
comodel_name='vnt.linea_deuda',
relation="cobro_lin_deuda",
)
co_resumen = fields.Text(
string="Resumen",
)
co_total_deuda = fields.Float(
string="Total Deuda",
)
co_total_interes = fields.Float(
string=u"Total Interés",
)
co_total = fields.Float(
string="Total",
)
# -*- coding: utf-8 -*-
from odoo import models, fields, api, exceptions
class asw_comprobante(models.Model):
_inherit = 'asw.comprobante'
comp_lin_deuda = fields.Many2one(
string=u'Linea Deuda',
comodel_name='vnt.linea_deuda',
ondelete='set null',
)
\ No newline at end of file
# -*- coding: utf-8 -*-
#from odoo.exceptions import UserError
from odoo import models, fields, api
#from datetime import datetime
class vnt_interes(models.Model):
_name = 'vnt.interes'
int_cliente = fields.Many2many(
string=u"Clientes",
comodel_name='hgt.instituciones',
relation="interes_clientes",
)
int_todos = fields.Boolean(
string=u"Todos?",
)
int_ritmo = fields.Selection(
string = 'Ritmo',
selection = [
('mensual', 'Mensual'),
('quincenal', 'Quincenal'),
('semanal', 'Semanal'),
('diaria', 'Diaria'),
],
store = True
)
int_plantilla = fields.Text(
string=u"Plantilla de envío",
)
# -*- coding: utf-8 -*-
#from odoo.exceptions import UserError
from odoo import models, fields, api
#from datetime import datetime
class vnt_linea_deuda(models.Model):
_name = 'vnt.linea_deuda'
#hacer dominio solo facturas emitidas, ventas
ld_factura = fields.One2many(
string='Factura',
comodel_name='hgt.incidencias',
inverse_name='cliente',
)
ld_fecha_vto = fields.Datetime(
string=u'Fecha de Vencimiento',
related='ld_factura.comp_fecha_cancelacion'
)
ld_estado = fields.Selection(
string=u'Estado Factura',
related='ld_factura.comp_estado',
)
ld_total = fields.Monetary(
string=u'Total Factura',
related='ld_factura.comp_total',
)
ld_select = fields.Bool(
string="Seleccionar",
)
\ No newline at end of file
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_vnt_cobros,access_vnt_cobros,model_vnt_cobros,,1,1,1,1
access_vnt_linea_deuda,access_vnt_linea_deuda,model_vnt_linea_deuda,,1,1,1,1
access_vnt_interes,access_vnt_interes,model_vnt_interes,,1,1,1,1
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<data noupdate="0">
<record id="action_vnt_cobros_act_window" model="ir.actions.act_window">
<field name="type">ir.actions.act_window</field>
<field name="name">Cobros</field>
<field name="res_model">vnt.cobros</field>
<field name="view_mode">tree,form</field>
<field name="view_type">form</field>
<field name="target">current</field>
</record>
<record id="view_vnt_cobros_tree" model="ir.ui.view">
<field name="name">Cobros</field>
<field name="model">vnt.cobros</field>
<field name="type">tree</field>
<field name="mode">primary</field>
<field name="priority" eval="16" />
<field name="active" eval="True" />
<field name="arch" type="xml">
<tree>
<field name="co_cliente" />
<field name="co_total_deuda" />
<field name="co_total_interes" />
<field name="co_total" />
</tree>
</field>
</record>
<record id="view_vnt_cobros_form" model="ir.ui.view">
<field name="name">Cobros</field>
<field name="model">vnt.cobros</field>
<field name="type">form</field>
<field name="mode">primary</field>
<field name="priority" eval="16" />
<field name="active" eval="True" />
<field name="arch" type="xml">
<form>
<!--<sheet>-->
<group col="4">
<field name="co_cliente" />
<field name="co_resumen" />
</group>
<group col="4" string="Deudas">
<field name="co_lin_deuda">
<tree create="0" delete="0" edit="0" editable="top">
<field name="ld_factura" />
<field name="ld_fecha_vto" />
<field name="ld_estado" />
<field name="ld_total" />
<field name="ld_select" />
</tree>
</field>
</group>
<group col="4">
<field name="co_total_deuda" />
<field name="co_total_interes" />
<field name="co_total" />
</group>
<!--</sheet>-->
</form>
</field>
</record>
</data>
</odoo>
<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<data noupdate="0">
<record id="action_vnt_interes_act_window" model="ir.actions.act_window">
<field name="type">ir.actions.act_window</field>
<field name="name">Interés</field>
<field name="res_model">vnt_interes</field>
<field name="view_mode">tree,form</field>
<field name="view_type">form</field>
<field name="target">current</field>
</record>
<record id="view_vnt_interes_tree" model="ir.ui.view">
<field name="name">Interés</field>
<field name="model">vnt_interes</field>
<field name="type">tree</field>
<field name="mode">primary</field>
<field name="priority" eval="16" />
<field name="active" eval="True" />
<field name="arch" type="xml">
<tree>
<field name="int_cliente" />
<field name="int_todos"/>
<field name="int_ritmo"/>
</tree>
</field>
</record>
<record id="view_vnt_interes_form" model="ir.ui.view">
<field name="name">Interés</field>
<field name="model">vnt_interes</field>
<field name="type">form</field>
<field name="mode">primary</field>
<field name="priority" eval="16" />
<field name="active" eval="True" />
<field name="arch" type="xml">
<form>
<!--<sheet>-->
<group col="4">
<field name="int_cliente" />
<field name="int_todos"/>
<field name="int_ritmo"/>
<field name="int_plantilla"/>
</group>
<!--</sheet>-->
</form>
</field>
</record>
</data>
</odoo>
<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<data noupdate="0">
<menuitem name="Cobranza" sequence="10" id="hgt_cobranza_cobranza" parent="asw_crm.asw_crm_root" />
<menuitem name="Deudas e Intereses" sequence="20" id="hgt_cobranza_deudas" parent="asw_crm.asw_crm_root" />
<menuitem name="Cobros" parent="hgt_cobranza_deudas" id="hgt_cobranza_cobros" action="action_vnt_cobros_act_window" />
<menuitem name="Configuración de Intereses" parent="hgt_cobranza_deudas" id="hgt_cobranza_config_int" action="action_vnt_interes_act_window" />
</data>
</odoo>
\ No newline at end of file
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!