openerp

How to remove Create and Edit… from many2one field.?

泄露秘密 提交于 2019-12-03 12:27:28
问题 Please advice me How to remove "Create and Edit..." from many2one field.? that item shows below in the many2one fields which I filtered with domain option. OpenERP version 7 回答1: I don't have much idea. Maybe for that you have to make changes in web addons. But an alternative solution is that you can make that many2one field selection . Add widget="selection" attribute in your xml. <field name="Your_many2one_field" widget="selection"> 回答2: Many2one widget (default) Options : Other possible

OpenERP : create new record ,one2many many2one relationship

ⅰ亾dé卋堺 提交于 2019-12-03 09:16:07
I have created on2many field in class A and other field nombre (integer): 'Inventaire' : fields.one2many('class.b','id_classb'), 'nombre' : fields.integer('Nombre'), In class b : 'id_classb' : fields.many2one('class.a', 'ID_classA'), 'ql' : fields.integer('QL'), I want to create a function in class a that create records for object b according to the value of nombre field. for example if nombre =3 I should create 3 object of class b here is my function: def save_b(self, cr, uid, ids, field_name, arg, context): a= self.browse(cr, uid, id) nbr=a.nombre num=22 for i in range(nbr): num+=1 self

Set and get store data Odoo with TransientModel

走远了吗. 提交于 2019-12-03 08:57:39
I'm trying to store config data in odoo, I need to store 3 reference to 'account.journal'. The model is created in database, the view is shown in configuration base menu, the data is store in database when I push the APPLY button BUT when I reload the menu the data is not shown The code use: from openerp import fields, models, osv, api, _ class Configuration(models.TransientModel): _inherit = 'res.config.settings' _name = 'transporte_carta_de_porte.config.settings' ft_mercaderia = fields.Many2one( 'account.journal',string='Debito ft mercaderia', help="Diario de ajuste al transportista por

Inheritance in openERP (odoo)

天大地大妈咪最大 提交于 2019-12-03 08:51:57
问题 I am new in openERP and have an interview. Please explain the idea of different types of inheritance in openERP, i think it total 3 types. please explain it in very simple way from the perspective of interview. P.S: I am familiar with the concept of simple inheritance. 回答1: Inheritance : Inheritance mechanism is used to create idea of re usability.there re usability means that reuse the code of the parent class in any Object Oriented Programming. Advantages : Reduce code redundancy. Provides

How to create program for sending mail automatically from openerp using python

十年热恋 提交于 2019-12-03 07:30:27
How to create program for sending mail automatically from openerp using python? I have created openerp module. I am trying to send mail to a client, when client id is generated. In sale folder in sale.py. When convert lead into client, I want to send mail to client. So in sale.py. I have added following line of code. self.pool.get('email.template').send_mail(cr, uid, email_template_id, object_id,False, context=context) I am getting email_Template_id from email_template database. Explain what is email_template_id, object_id? What is template? What is message? I am totally confused. Is there any

When to use api.one and api.multi in odoo | openerp?

早过忘川 提交于 2019-12-03 06:05:18
问题 Recently odoo (formerly OpenERP) V8 has been released. In new API method decorators are introduced. in models.py methods needs to be decorated with @api.one or @api.multi . Referring odoo documentation i can not determine the exact use. Can anybody explain in detail. Thanks. 回答1: Generally both decoarators are used to decorate a record-style method where ' self ' contains recordset (s). Let me explain in brief when to use @api.one and @api.multi : 1. @api.one : Decorate a record-style method

How to remove Create and Edit… from many2one field.?

荒凉一梦 提交于 2019-12-03 03:43:32
Please advice me How to remove "Create and Edit..." from many2one field.? that item shows below in the many2one fields which I filtered with domain option. OpenERP version 7 Sudhir Arya I don't have much idea. Maybe for that you have to make changes in web addons. But an alternative solution is that you can make that many2one field selection . Add widget="selection" attribute in your xml. <field name="Your_many2one_field" widget="selection"> Many2one widget (default) Options : Other possible options you can use with this widget. no_quick_create - It will remove Create and edit... option. no

Docker.io init.d script not working on start container

心不动则不痛 提交于 2019-12-03 03:33:04
I've a container with odoo on it on the dir "/opt/odoo/". A init script on "/etc/init.d/odoo-server" #!/bin/bash ### BEGIN INIT INFO # Provides: odoo # Required-Start: $remote_fs $syslog # Required-Stop: $remote_fs $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start openerp daemon at boot time # Description: Enable service provided by daemon. # X-Interactive: true ### END INIT INFO ## more info: http://wiki.debian.org/LSBInitScripts PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin DAEMON=/opt/odoo/openerp-server NAME=odoo DESC=odoo CONFIG=/etc/odoo-server.conf

Where OpenERP (Odoo) finds the modules path?

匿名 (未验证) 提交于 2019-12-03 00:50:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I am using Odoo v.8. I want to find out where Odoo finds information where the modules are, to load them. I am aware there is a variable addons_path in the file openerp-server.conf. The only file I have found the variable in is opt/odoo/odoo/debian/openerp-server.conf. It has the following value: addons_path = /usr/lib/python2.7/dist-packages/openerp/addons However, the Odoo application is using modules from "/opt/odoo/odoo/addons" path. Where the Odoo retrieves this information from? If I have a new directory with new modules, where I can

how to update the new module in openerp 7 in ubuntu 12.0? [closed]

▼魔方 西西 提交于 2019-12-02 22:40:48
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 5 years ago . Done,all the possible ways for updating the new module in openerp 7 in ubuntu 12.0. Is there any other way to update the new module in openerp 7 in ubuntu 12.0 ? can anyone help me.. 回答1: Put your module under addons/ directory restart your server Go to OpenERP Menu Setting -> Modules -> Update Modules List and