odoo

Removing items from an Existing Selection in Odoo

Removing items from an Existing Selection in Odoo Question: I have pre-existing keys in a selection in a contact form. I added new keys using “selection_add” parameter and I wanted to find out what would be the opposite of a selection_add parameter to remove any old keys from a selection. Asked By: Jeff Nyak || …

Total answers: 2

Odoo Error, a partner cannot follow twice the same object

Odoo Error, a partner cannot follow twice the same object Question: I have receiving this odoo error when I try to duplicate a set of record. I have inherited [‘mail.thread’, ‘ir.needaction_mixin’] in the current class. I didn’t found any solution online or myself or from odoo. Still stuck here around four days. Can anybody have …

Total answers: 3

Merge Two PDF by PyPDF2 but got error Unexpected destination '/__WKANCHOR_2'

Merge Two PDF by PyPDF2 but got error Unexpected destination '/__WKANCHOR_2' Question: from PyPDF2 import PdfFileMerger, PdfFileReader filepath_list = [‘/tmp/abc.pdf’,’/tmp/xyz.pdf’] merger = PdfFileMerger() for file_name in filepath_list: with open(file_name, ‘rb’) as f: merger.append(f) merger.write(“result.pdf”) While merger 2 pdf by python code I got Error Unexpected destination ‘/__WKANCHOR_2’ and I working with following code, please provide …

Total answers: 3

How can I filter by image format on the dialog window when I upload an image in Odoo?

How can I filter by image format on the dialog window when I upload an image in Odoo? Question: I have a model with an image attribute: image = fields.Binary( string=”Imagen”, required=True ) Inside the view a show it with: <field name=”image” widget=”image” /> This open an operating system dialog window that allows me to …

Total answers: 2

Odoo8 website transfer input value from product page to cart page

Odoo8 website transfer input value from product page to cart page Question: I’m working on project in odoov8. I need to add a field on the product page and then create an order which includes this field. To be more specific, I have added Start Date field on the product page, I can select a …

Total answers: 1

Odoo creating an invoice with Web Service API (PHP)

Odoo creating an invoice with Web Service API (PHP) Question: I am trying to create an invoice on Odoo using Odoo Web Service API (via PHP) which is based on XML-RPC using the code example in the official API documentation. I have succeeded to create a customer using the code provided in the documentation : …

Total answers: 1

How to develop (run and debug) modules in Odoo v11 on Visual Studio Code in Ubuntu?

How to develop (run and debug) modules in Odoo v11 on Visual Studio Code in Ubuntu? Question: Is it possible to run and debug Odoo on Visual Studio Code? If yes please share me the configuration. Visual Studio Code is a source code editor developed by Microsoft for Windows, Linux and macOS. It includes support …

Total answers: 5

Get document attachment list in qweb report Odoo

Get document attachment list in qweb report Odoo Question: I am using qweb reports to generate a document which should have associated attachments using the document module of Odoo. But I don’t know how to display the list of attachments associated to a document in the qweb/pdf report. Please note that I am not asking …

Total answers: 1

How to use cursors in Odoo?

How to use cursors in Odoo? Question: I don’t understand using cursor in version 9! Do you need cursor? In below example after call function in console line get: <openerp.sql_db.Cursor object at 0x7f94f4c0b0d0> @api.multi def my_func(self): cursor = self.env.cr print(cursor) Any simple example when and why use cursor? Asked By: user_odoo || Source Answers: You …

Total answers: 3

What does |= (pipe equal) sign do in python?

What does |= (pipe equal) sign do in python? Question: I saw a piece of code in a project where following is written: move = Move.create({ ‘name’: repair.name, ‘product_id’: repair.product_id.id, ‘product_uom’: repair.product_uom.id or repair.product_id.uom_id.id, ‘product_uom_qty’: repair.product_qty, ‘partner_id’: repair.address_id.id, ‘location_id’: repair.location_id.id, ‘location_dest_id’: repair.location_dest_id.id, ‘restrict_lot_id’: repair.lot_id.id, }) moves |= move moves.action_done() What does the |= meaning here? …

Total answers: 3