Bladeren bron

Agregar fondo de imagen de la copania para presupuesto

sebas 3 jaren geleden
commit
5ad802cc67
5 gewijzigde bestanden met toevoegingen van 95 en 0 verwijderingen
  1. 21 0
      __init__.py
  2. 30 0
      __openerp__.py
  3. 29 0
      image_header_company.py
  4. 15 0
      image_header_company_view.xml
  5. BIN
      static/description/icon.png

+ 21 - 0
__init__.py

@@ -0,0 +1,21 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#
+#    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/>.
+#
+##############################################################################
+
+import image_header_company
+# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

+ 30 - 0
__openerp__.py

@@ -0,0 +1,30 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#    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': 'Imagen de marca de agua de Compania',
+    'version': '1.0',
+    'category': 'Account',
+    'description': """Imagen de marca de agua de Compania.""",
+    'author': 'Eiru Software/Sebastian Penayo',
+    'website': 'http://www.eirusoftware.com/',
+    'depends': ['base'],
+    'data': ['image_header_company_view.xml'],
+    'installable': True,
+}
+# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

+ 29 - 0
image_header_company.py

@@ -0,0 +1,29 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+#    OpenERP, Open Source Management Solution
+#    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
+#
+#    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/>.
+#
+##############################################################################
+
+from openerp import models, fields, tools, api
+
+class ResCompany(models.Model):
+    _name = 'res.company'
+    _inherit = 'res.company'
+    _description = 'Imagen de marca de agua de Compania'
+
+    image = fields.Binary('Marca de agua')

+ 15 - 0
image_header_company_view.xml

@@ -0,0 +1,15 @@
+<?xml version="1.0"?>
+<openerp>
+    <data>
+        <record id="image_header_company_view" model="ir.ui.view">
+            <field name="name">res.company.image</field>
+            <field name="model">res.company</field>
+            <field name="inherit_id" ref="base.view_company_form"/>
+            <field name="arch" type="xml">
+                <field name="company_registry" position="after">
+                    <field name="image" widget="image" class="oe_avatar"/>
+                </field>
+            </field>
+        </record>
+    </data>
+</openerp>

BIN
static/description/icon.png