X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (X-Cart 5) (https://forum.x-cart.com/forumdisplay.php?f=56)
-   -   Changing trigger for product review requests (https://forum.x-cart.com/showthread.php?t=77354)

welly 11-19-2019 11:34 AM

Changing trigger for product review requests
 
Hi

I have the Product Review module installed, and I would like to send review reminders. The triggers for sending the reminders are a payment status of 'Paid' and an order status of 'Delivered', but they don't really work for me.

Firstly, my payment statuses can be 'Paid' or 'Authorised' depending on which gateway a customer uses, and I don't bother to change it at the moment (no doubt I could if necessary).

Secondly, and more importantly, I don't use the 'Delivered' status, as I don't use trackable or signed delivery services most of the time and can't make that judgement. I just leave the status as 'Shipped'.

As a result, no reminders are ever sent.

Is there a way to change the reminder to trigger on an order status of 'Shipped' instead, and (less important) to ignore the payment status?

Has anyone done anything similar?

Many thanks

Welly

siddharth.puri@wheelandba 11-26-2019 04:44 PM

Re: Changing trigger for product review requests
 
Hi Welly, I am facing the same problem. I change the payment status to paid however the shipping status to shipped. I want the module to ignore the delivery status. Please let me know if you find a solution to this.

Thanks and Regards
Sid

siddharth.puri@wheelandba 12-04-2019 05:22 PM

Re: Changing trigger for product review requests
 
Hi, I think I have figured it out.
In Review module that is:

classes\XLite\Module\XC\Reviews\Model there is a function protected function isOrderValidForReviewKey()
{
return !$this->getReviewKey()
&& \XLite\Model\Order\Status\Payment::STATUS_PAID === $this->getPaymentStatusCode()
&& (
\XLite\Model\Order\Status\Shipping::STATUS_DELIVER ED === $this->getShippingStatusCode()
|| !$this->isShippable()
);
}

In this take out the condition of Status_Paid

Hopefully that will work

Regards

siddharth.puri@wheelandba 02-27-2020 06:39 PM

Re: Changing trigger for product review requests
 
In httpdocs\classes\XLite\Module\XC\Reviews\Model\ord er.php there is a function
protected function isOrderValidForReviewKey()
{
return !$this->getReviewKey()
&& \XLite\Model\Order\Status\Payment::STATUS_PAID === $this->getPaymentStatusCode()
&& (
\XLite\Model\Order\Status\Shipping::STATUS_DELIVER ED === $this->getShippingStatusCode()
|| !$this->isShippable()
);
}

Change status of delivered to shipping and also add payment status for authorised and paid both



Also, in httpdocs\classes\XLite\Module\XC\Reviews\Model\Ord er\Status
Set status handler for shipped the same those are added for delivered


All times are GMT -8. The time now is 09:34 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.