Odoo Help

Welcome!

This community 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.

0

Odoo 8 Point Of Sale, How to default the selected button at Price?

By
JC
on 1/7/15, 6:22 AM 427 views

version: odoo8

How do I set the default selected button at Price instead of Quantity?

1
Shawn Varghese
On 1/8/15, 12:45 AM

There is a models.js file at the following path in Point of Sale:

/point_of_sale/static/src/js/models.js

Look for module.NumpadState (probably line 1304). There is default values set here for the keypad, as well as in the reset() function, further down in the module. Changing the 'mode' in both these places seemed to work for me.

The defaults should now look like this:

defaults: {
            buffer: "0",
            mode: "price"
        },

and the reset() function (line: 1354) should look like this:

reset: function() {
            this.set({
                buffer: "0",
                mode: "price"
            });
        },

These changes should change the default selected mode to be 'price' instead of 'quantity'. I have tested this and it seems to work fine. Please let me know if this doesn't seem to be working correctly.

Thanks Shawn. voted for you.

JC
on 1/12/15, 5:36 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 1/7/15, 6:22 AM
Seen: 427 times
Last updated: 3/16/15, 8:10 AM