Post by straightlight » Thu Oct 12, 2017 4:24 am

The following steps are for Opencart v3.0.2.0 release. If your site is running in production, put your site under maintenance.

1 - Take a screenshot of your admin free checkout payment module configurations.
2 - Uninstall the free checkout payment module.
3 - In admin/controller/extension/payment/free_checkout.php file,

find:

Code: Select all

if (isset($this->request->post['free_checkout_order_status_id'])) {
			$data['free_checkout_order_status_id'] = $this->request->post['free_checkout_order_status_id'];
		} else {
			$data['free_checkout_order_status_id'] = $this->config->get('free_checkout_order_status_id');
		}
replace with:

Code: Select all

if (isset($this->request->post['payment_free_checkout_order_status_id'])) {
			$data['payment_free_checkout_order_status_id'] = $this->request->post['payment_free_checkout_order_status_id'];
		} else {
			$data['payment_free_checkout_order_status_id'] = $this->config->get('payment_free_checkout_order_status_id');
		}
In admin/view/template/extension/payment/free_checkout.twig file,

find:

Code: Select all

<select name="free_checkout_order_status_id" id="input-order-status" class="form-control">
                {% for order_status in order_statuses %}
                {% if order_status.order_status_id == free_checkout_order_status_id %}
                <option value="{{ order_status.order_status_id }}" selected="selected">{{ order_status.name }}</option>
                {% else %}
                <option value="{{ order_status.order_status_id }}">{{ order_status.name }}</option>
                {% endif %}
                {% endfor %}
replace with:

Code: Select all

<select name="payment_free_checkout_order_status_id" id="input-order-status" class="form-control">
                {% for order_status in order_statuses %}
                {% if order_status.order_status_id == payment_free_checkout_order_status_id %}
                <option value="{{ order_status.order_status_id }}" selected="selected">{{ order_status.name }}</option>
                {% else %}
                <option value="{{ order_status.order_status_id }}">{{ order_status.name }}</option>
                {% endif %}
                {% endfor %}
4 - Reinstall the free checkout payment module.
5 - Reconfigure the free checkout payment module.
6 - Test a transaction during checkout.
7 - When successful, disable the site maintenance (if running in production).

This should overall resolve the status issues along with other variables.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by omanincense » Fri Oct 13, 2017 5:12 pm

I have followed the instructions exactly, but whenever i go to the "Order Status" sittings it was set to Canceled, even i edit it to any other status, it will go back to Canceled again...!!

New member

Posts

Joined
Tue Oct 03, 2017 8:13 pm

Post by omanincense » Sat Oct 14, 2017 6:16 am

Dear,

Anymore ideas to solve this problem?!

New member

Posts

Joined
Tue Oct 03, 2017 8:13 pm

Post by straightlight » Sat Oct 14, 2017 6:24 am

Which OC version are you using? Have you cleared the cache, saas cache and the modification cache?

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by omanincense » Sat Oct 14, 2017 5:49 pm

I'm using version 3.0.2.0 and i cleared all the cache.

Also, whenever i change the Order status in the "Free Checkout" extension to any status, it will go back to "Canceled" ..

That's making me crazy

New member

Posts

Joined
Tue Oct 03, 2017 8:13 pm

Post by straightlight » Sat Oct 14, 2017 6:53 pm

Are you using any extensions such as journal2 theme?

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by boyjah » Fri Oct 27, 2017 6:51 pm

I am having the same problem. OpenCart 3.0.2.0, using standard OpenCart theme. Changing status of Free Checkout and saving it always reverts to Cancelled.

Newbie

Posts

Joined
Tue May 02, 2017 12:55 pm

Post by straightlight » Fri Oct 27, 2017 7:51 pm

Have you followed the instructions above?

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by Busta1066 » Mon Nov 13, 2017 5:55 pm

So i have the same issue, i have tried the above fix, but to no avail. I am using 3.0.2 and have the journal 2 theme installed. When i try to change the status of the free check out to complete it just goes back to cancel every time... driving me nuts to get this one issue fixed. Any help in resolving this would be amazing

Thanks :)

Newbie

Posts

Joined
Fri Feb 03, 2017 11:29 pm

Post by Sebiix3 » Sat Nov 18, 2017 11:34 am

This is not working for me for some reason :/ I already tried this a few times, also reinstalled a few times but i still get always canceled.. Any other idea how to fix this?

Newbie

Posts

Joined
Sat Nov 11, 2017 8:01 pm

Post by straightlight » Sat Nov 18, 2017 11:43 pm

Are you using any extensions such as Journal2?

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by Sebiix3 » Sun Nov 19, 2017 6:33 am

straightlight wrote:
Sat Nov 18, 2017 11:43 pm
Are you using any extensions such as Journal2?
Nope, i am not using any extensions ._. I also tried the official update from github which includes the fix too, but this sadly didnt change anything.
Is it possible to change the free checkout to "complete" without using the adminpanel?

Newbie

Posts

Joined
Sat Nov 11, 2017 8:01 pm

Post by straightlight » Sun Nov 19, 2017 7:04 am

Let's troubleshoot this issue. In your admin/controller/extension/free_checkout.php file,

find:

Code: Select all

$this->session->data['success'] = $this->language->get('text_success');
add above:

Code: Select all

echo "<pre />\n";
print_r($this->request->post);
echo "</pre>\n";

exit;
Then, go back to the admin free checkout page and save your settings again. An array will be shown. Please post this array.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by Sebiix3 » Mon Nov 20, 2017 9:05 am

straightlight wrote:
Sun Nov 19, 2017 7:04 am
Let's troubleshoot this issue. In your admin/controller/extension/free_checkout.php file,

find:

Code: Select all

$this->session->data['success'] = $this->language->get('text_success');
add above:

Code: Select all

echo "<pre />\n";
print_r($this->request->post);
echo "</pre>\n";

exit;
Then, go back to the admin free checkout page and save your settings again. An array will be shown. Please post this array.
Hey, i did it and this is the result:

Code: Select all

Array
(
    [free_checkout_order_status_id] => 5
    [payment_free_checkout_status] => 1
    [payment_free_checkout_sort_order] => 
)
Thanks for your help :)

Newbie

Posts

Joined
Sat Nov 11, 2017 8:01 pm

Post by straightlight » Mon Nov 20, 2017 9:09 am

free_checkout_order_status_id
Exactly as I suspected. As you can see, from my above steps, you either did not followed that particular instructions or you did not cleared all caches properly from the Opencart admin or you did cleared out all caches from the Opencart admin but you might be using Journal2 which prevents proper cache clean-ups.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by Sebiix3 » Mon Nov 20, 2017 9:14 am

straightlight wrote:
Mon Nov 20, 2017 9:09 am
free_checkout_order_status_id
Exactly as I suspected. As you can see, from my above steps, you either did not followed that particular instructions or you did not cleared all caches properly from the Opencart admin or you did cleared out all caches from the Opencart admin but you might be using Journal2 which prevents proper cache clean-ups.
Ohhh, well i maybe failed on my own.. does "clearing the caches" mean to clear browser caches or is there an other way to clear the cache? Google said something about system->storage->cache on the root directoy. Do i just need to delete the folders inside the cache folder? :O

Newbie

Posts

Joined
Sat Nov 11, 2017 8:01 pm

Post by straightlight » Mon Nov 20, 2017 9:16 am

Clearing all caches means:

- Admin dashboard right square icon - both caches inside the modal.
- Admin - > extensions - > modifications - > refresh button
- Browser cache, close browser, re-open the browser and to go back to the admin-end of Opencart.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by Sebiix3 » Mon Nov 20, 2017 9:23 am

straightlight wrote:
Mon Nov 20, 2017 9:16 am
Clearing all caches means:

- Admin dashboard right square icon - both caches inside the modal.
- Admin - > extensions - > modifications - > refresh button
- Browser cache, close browser, re-open the browser and to go back to the admin-end of Opencart.
This actually fixed it! Thanks so much for your help. :-*

Newbie

Posts

Joined
Sat Nov 11, 2017 8:01 pm

Post by straightlight » Mon Nov 20, 2017 9:25 am

Great. As you can see, this fix is working as intended.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by johnslsbr » Tue Nov 28, 2017 5:31 pm

Hi ,

I have followed the information and still not working. However I defiantly am using Journal 2 is there a fix ?

Regards

Newbie

Posts

Joined
Tue Nov 28, 2017 5:28 pm
Who is online

Users browsing this forum: No registered users and 18 guests