+
+ $pos = get_sales_point($this->pos);
+ if (!$pos['cash_sale'] || !$pos['credit_sale'])
+ $this->pos = -1; // mark not editable payment type
+ if ($this->cash) {
+ $this->Location = $pos['pos_location'];
+ $this->location_name = $pos['location_name'];
+ $this->cash_account = $pos['pos_account'];
+ $this->account_name = $pos['bank_account_name'];
+ }