Commit a76e0bba by Maria Agustina

896 terminada

0 parents
# -*- coding: utf-8 -*-
from . import controllers
from . import models
\ No newline at end of file
# -*- coding: utf-8 -*-
{
'name': "fiscal_compra",
'summary': """
Módulo fiscal_compra""",
'description': """
Módulo fiscal_compra
""",
'author': "ANAC SOFT",
'website': "http://anacsoft.com",
# Categories can be used to filter modules in modules listing
# Check https://github.com/odoo/odoo/blob/master/odoo/addons/base/module/module_data.xml
# for the full list
'category': 'Uncategorized',
'version': '0.21.03.30',
# any module necessary for this one to work correctly
'depends': ['base',
'asw_tpv'],
# always loaded
'data': [
'security/ir.model.access.csv',
'views/views.xml',
'views/menu.xml',
],
# only loaded in demonstration mode
'demo': [
'demo/demo.xml',
],
}
\ No newline at end of file
# -*- coding: utf-8 -*-
from . import controllers
\ No newline at end of file
# -*- coding: utf-8 -*-
from odoo import http
# class MyModule(http.Controller):
# @http.route('/my_module/my_module/', auth='public')
# def index(self, **kw):
# return "Hello, world"
# @http.route('/my_module/my_module/objects/', auth='public')
# def list(self, **kw):
# return http.request.render('my_module.listing', {
# 'root': '/my_module/my_module',
# 'objects': http.request.env['my_module.my_module'].search([]),
# })
# @http.route('/my_module/my_module/objects/<model("my_module.my_module"):obj>/', auth='public')
# def object(self, obj, **kw):
# return http.request.render('my_module.object', {
# 'object': obj
# })
\ No newline at end of file
<odoo>
<data>
<!-- -->
<!-- <record id="object0" model="my_module.my_module"> -->
<!-- <field name="name">Object 0</field> -->
<!-- <field name="value">0</field> -->
<!-- </record> -->
<!-- -->
<!-- <record id="object1" model="my_module.my_module"> -->
<!-- <field name="name">Object 1</field> -->
<!-- <field name="value">10</field> -->
<!-- </record> -->
<!-- -->
<!-- <record id="object2" model="my_module.my_module"> -->
<!-- <field name="name">Object 2</field> -->
<!-- <field name="value">20</field> -->
<!-- </record> -->
<!-- -->
<!-- <record id="object3" model="my_module.my_module"> -->
<!-- <field name="name">Object 3</field> -->
<!-- <field name="value">30</field> -->
<!-- </record> -->
<!-- -->
<!-- <record id="object4" model="my_module.my_module"> -->
<!-- <field name="name">Object 4</field> -->
<!-- <field name="value">40</field> -->
<!-- </record> -->
<!-- -->
</data>
</odoo>
\ No newline at end of file
# -*- coding: utf-8 -*-
from . import compra_borrador
\ No newline at end of file
No preview for this file type
# -*- coding: utf-8 -*-
from odoo import models, fields, api
class hgt_compra_borrador(models.Model):
_name = 'hgt.compra_borrador'
cb_url = fields.Char(
string="URL",
)
cb_cuit = fields.Integer(
string="CUIT",
)
cb_importe = fields.Integer(
string="Importe",
)
cb_empresas = fields.Many2many(
comodel_name='asw.cliente',
relation='compra_borrador_empresa',
column1='asw_cliente_id',
column2='hgt_compra_borrador_id',
string='Empresas'
)
def cargarFacturas(self):
return 0
def asignarProyecto(self):
return 0
def asignarOportunidad(self):
return 0
def generarCarProd(self):
return 0
\ No newline at end of file
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_hgt_compra_borrador,hgt_compra_borrador,model_hgt_compra_borrador,,1,1,1,1
\ No newline at end of file
<odoo>
<data>
<!-- Top menu item -->
<menuitem name="fiscal_compra" id="fiscal_compra.menu_root"/>
<!-- menu categories -->
<menuitem name="Fiscal Compra" id="fiscal_compra.menu_1" parent="fiscal_compra.menu_root"/>
<!-- actions -->
<menuitem name="Compra Borrador" id="fiscal_compra.menu_1_list" parent="fiscal_compra.menu_1"
action="fiscal_compra_borrador_action_window"/>
</data>
</odoo>
\ No newline at end of file
<odoo>
<data>
<!-- <template id="listing"> -->
<!-- <ul> -->
<!-- <li t-foreach="objects" t-as="object"> -->
<!-- <a t-attf-href="#{ root }/objects/#{ object.id }"> -->
<!-- <t t-esc="object.display_name"/> -->
<!-- </a> -->
<!-- </li> -->
<!-- </ul> -->
<!-- </template> -->
<!-- <template id="object"> -->
<!-- <h1><t t-esc="object.display_name"/></h1> -->
<!-- <dl> -->
<!-- <t t-foreach="object._fields" t-as="field"> -->
<!-- <dt><t t-esc="field"/></dt> -->
<!-- <dd><t t-esc="object[field]"/></dd> -->
<!-- </t> -->
<!-- </dl> -->
<!-- </template> -->
</data>
</odoo>
\ No newline at end of file
<odoo>
<data>
<!-- explicit list view definition -->
<!-- actions opening views on models -->
<record model="ir.actions.act_window" id="fiscal_compra_borrador_action_window">
<field name="name">hgt_compra_borrador</field>
<field name="res_model">hgt.compra_borrador</field>
<field name="view_mode">tree,form</field>
</record>
<record model="ir.ui.view" id="fiscal_compra_borrador_list">
<field name="name">Lista hgt_compra_borrador</field>
<field name="model">hgt.compra_borrador</field>
<field name="arch" type="xml">
<tree>
<field name="cb_url"/>
<field name="cb_cuit"/>
<field name="cb_importe"/>
<field name="cb_empresas"/>
</tree>
</field>
</record>
<record model="ir.ui.view" id="fiscal_compra_borrador_form">
<field name="name">Form hgt_compra_borrador</field>
<field name="model">hgt.compra_borrador</field>
<field name="arch" type="xml">
<form>
<header>
<button type="object" class="oe_highlight"
id="cargar_facturas_btn" string="Cargar Facturas"
name="cargarFacturas"/>
<button type="object"
id="asignar_proyecto_btn" string="Asignar a proyecto"
name="asignarProyecto"/>
<button type="object"
id="asignar_oportunidad_btn" string="Asignar a Oportunidad"
name="asignarOportunidad"/>
<button type="object"
id="generar_car_prod_btn" string="Generar Carga de Productos"
name="generarCarProd"/>
</header>
<group col="4">
<field colspan="2" name="cb_url"/>
<field colspan="2" name="cb_cuit"/>
<field colspan="2" name="cb_importe"/>
</group>
<group string="Empresas">
<field name="cb_empresas" nolabel="1" />
</group>
</form>
</field>
</record>
</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!