Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
In a Point of Sale, by default appears 'Unknown Customer' as client name, so we click on that name, appears a list of customers and select the desired customer to finaly click on the Set Customer button. This is for each sale.
Do you know a way to preset a default customer, say 'Generic Client' avoiding having to select it each time?
I already try on pos.xml, but can only change the name whith out affecting the object.
One of the trick you can use from the backend to set the generic customer in every pos.order where customer is not set.
First, You need to create one "Generic Customer" through xml.
<record id="generic_res_partner" model="res.partner">
<field name="name">Generic Customer</field>
Then inherit the pos.order model and change this method like below.
_inherit = 'pos.order'
def _order_fields(self, ui_order):
order_fields = super(PosOrder, self)._order_fields(ui_order)
generic_customer = self.env.ref('module_name.generic_res_partner').id
order_fields['partner_id'] = ui_order.get('partner_id', False) or generic_customer
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 1/21/15, 4:08 PM|
|Seen: 3430 times|
|Last updated: 4/19/18, 1:43 AM|