View Single Post
  #5  
Old 03-09-2021, 07:29 PM
 
libyapages libyapages is offline
 

Member
  
Join Date: Mar 2017
Posts: 15
 

Default Re: Payment method depend on shipping method

Solve it
it turns out that X-Cart handles orders in Multi-Vendor as Children, where each child represents a vendor. Therefore, to access methods we need first to specify the child (vendor).

So instead of:
PHP Code:
$this->getShippingMethodName(); 

We need to use:
PHP Code:
$this->getChildren()[0]->getShippingMethodName(); 
Where [0] => first child (vendor) of the order.
__________________
Hakim Elkharbash
Reply With Quote