Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odpovědět
1134 Zobrazení

I have created a boolean field on Contacts 'is Employee' and in Customers' list that appears on POS I want to show all the Contacts that have 'is Employee' = True.

Where is the code that returns all customers so I can add this restriction?

Avatar
Zrušit
Nejlepší odpověď

Hi,

Try check the following function.

get clients() {
    if (this.state.query && this.state.query.trim() !== '') {
        return this.env.pos.db.search_partner(this.state.query.trim());
    } else {
        return this.env.pos.db.get_partners_sorted(1000);
    }
}

/addons/point_of_sale/static/src/js/Screens/ClientListScreen/ClientListScreen.js

Regards

Avatar
Zrušit