Skip ke Konten
Menu
Pertanyaan ini telah diberikan tanda
3444 Tampilan


models.load_models({

model: 'stock.production.lot',
fields: ['id','name','product_id','total_qty','life_date'],
domain: function(self){ //done


loaded: function(self,list_lot){

self.list_lot = list_lot;

},
});


var PackLotLinePopupWidget = PopupWidget.extend({
template: 'PackLotLinePopupWidget',
events: _.extend({}, PopupWidget.prototype.events, {
'click .remove-lot': 'remove_lot',
'keydown': 'add_lot',
'blur .packlot-line-input': 'lose_input_focus'
}),

show: function(options){
var self = this;
var product_lot = [];
var lot_list = self.pos.list_lot;

for(var i=0;i<lot_list.length;i++){
if(lot_list[i].product_id[0] == options.pack_lot_lines.order_line.product.id){
product_lot.push(lot_list[i]);
}
}
options.product_lot = product_lot;
this._super(options);
this.focus();
},


Avatar
Buang
Post Terkait Replies Tampilan Aktivitas
1
Jun 22
3538
0
Apr 25
1225
1
Sep 23
7353
2
Jan 19
4007
2
Feb 18
10587