Odoo POS receipt need to add address from res.partner city in receipt

Viewed 1512

I don't know how to add res.partner object in below screen.js

print_xml: function() {
  var env = {
    widget: this,
    pos: this.pos,
    order: this.pos.get_order(),
    receipt: this.pos.get_order().export_for_printing(),
    paymentlines: this.pos.get_order().get_paymentlines()
  };
  render_receipt: function() {
    var order = this.pos.get_order();
    this.$('.pos-receipt-container').html(QWeb.render('PosTicket',{
      widget:this,
      order: order,
      partner:partner,
      receipt: order.export_for_printing(),
      orderlines: order.get_orderlines(),
      paymentlines: order.get_paymentlines(),
    }));
  };
};

I have tried to add the partner object in above javascript but it's not working. I am new in odoo and i have also not munch knowledge of JavaScript so pls help me to solve this issue. If i am able to add res.partner object in this javascript file then and then only i m available to access the res.partner objcet in my pos.xml file.

I wan't the address details of company and it's not in res_company so how can i fetch the street and other address from res_partner for company ?

1 Answers
Related