init.js 523 Bytes
Newer Older
François C. committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
odoo.define('louve_custom_pos.models.init', function(require) {
    "use strict";

    var models = require('point_of_sale.models');

    models.load_fields('product.product', ['multi_barcode_ids']);
    
    models.load_models([
        {
            model:  'product.multi.barcode',
            fields: ['barcode', 'product_id'],
            domain: [],
            loaded: function(self, barcodes){
                self.db.set_multi_barcodes(barcodes)
            },
        },
    ],{'before': 'product.product'});

})