コンテンツへスキップ
メニュー
この質問にフラグが付けられました
1 返信
4667 ビュー

Hey all  ,


I am doing some point of sale customization however i am not sure how to inherit to the point of sale js file .


the current point of sale module js file code :


{

model: 'product.product',

fields: ['display_name', 'list_price','price','pos_categ_id', 'taxes_id', 'ean13', 'default_code',

'to_weight', 'uom_id', 'uos_id', 'uos_coeff', 'mes_type', 'description_sale', 'description',

'product_tmpl_id'],

domain: [['sale_ok','=',true],['available_in_pos','=',true]],

context: function(self){ return { pricelist: self.pricelist.id, display_default_code: false }; },

loaded: function(self, products){

self.db.add_products(products);

},

},

But  i want add a field in product.product , so for example : 


{

model: 'product.product',

fields: ['display_name', 'NEW_FIELD','list_price','price','pos_categ_id', 'taxes_id', 'ean13', 'default_code',

'to_weight', 'uom_id', 'uos_id', 'uos_coeff', 'mes_type', 'description_sale', 'description',

'product_tmpl_id'],

domain: [['sale_ok','=',true],['available_in_pos','=',true]],

context: function(self){ return { pricelist: self.pricelist.id, display_default_code: false }; },

loaded: function(self, products){

self.db.add_products(products);

},

},


How can i go about inheriting this new field in with out completely overriding the point of sale / models.js

アバター
破棄
最善の回答

view this blog for some hint... pospopup post..

https://odooforyou.wordpress.com/

アバター
破棄
関連投稿 返信 ビュー 活動
0
4月 15
6405
1
4月 24
2013
0
6月 22
1821
1
2月 22
5231
2
12月 16
5526