Good Day! guys
Example ..... display_total_amount = pos.pos_session.total_amount;
like this . where can i open the pos.session env in my jscript..
document.getElementById('stotal').value = this.pos.pos_session.total_amount;
or how can i extend this what is standard format..
{
model: 'pos.session',
fields: ['id',
'total_amount','order_qty','journal_ids','name','user_id','config_id','start_at','stop_at','sequence_number','login_number'],
domain: function(self){ return [['state','=','opened'],['user_id','=',self.session.uid]]; },
loaded: function(self,pos_sessions){
self.pos_session = pos_sessions[0];
var orders = self.db.get_orders();
for (var i = 0; i < orders.length; i++) {
self.pos_session.sequence_number =
Math.max(self.pos_session.sequence_number,
orders[i].data.sequence_number+1);
}
},
},
but i can't get the value of data in the database.
any help and advise. thanks :)