Post by Dabnis » Mon Sep 10, 2018 6:34 pm

V 3.0.2.0
The client has a user-group Trade-A. A product has a discounted price for customer group Trade-A. All works well when a visitor in the customer group logs into the front of the store and places an order, the discounted product price is used, however :
When the client receives a telephone order from a customer in customer group Trade-A and enters an order manually within the admin system, selecting the correct customer group for that telephone client the discounted price for the product is not used, but the products standard none discounted price.

Comments, advice, help welcome

Regards.
Dab

Newbie

Posts

Joined
Tue Jun 01, 2010 2:05 am

Post by straightlight » Mon Sep 10, 2018 9:11 pm

This issue has already been reported on GitHub in the past for v3.0.2.0 release as I hope it has been fixed for the next OC release.

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 Dabnis » Mon Sep 10, 2018 9:26 pm

Thanks for letting me know, I had searched, but did not find any reference to it.

As the 3.1 Alpha is released I'll go & check what has changed.

Regards.
Dab

Newbie

Posts

Joined
Tue Jun 01, 2010 2:05 am

Post by Dabnis » Mon Sep 10, 2018 9:33 pm

There appears to be no mention of a fix for this issue in the 3.1 Alpha release!

In addition I could not find any reference to this in GitHub. Please give git ref or post link.

Anyone know of an extension that will allow site owner to create manual orders that take account of customer group product discounts?

Regards.
Dab.

Newbie

Posts

Joined
Tue Jun 01, 2010 2:05 am

Post by straightlight » Mon Sep 10, 2018 9:58 pm

There appears to be no mention of a fix for this issue in the 3.1 Alpha release!
Nowhere to be said on my previous reply that a mentioned fix has been posted but I did addressed the issue prior and did mentioned on my previous reply a hope to be seen as a fix solution for the next release. Indicating that a fix for this issue has not been applied, however, would be inaccurate information for users unless you are working with the dev team which, doubtfully, they would address these issues on the Bug Reports section of the forum. In addition, the code tab on GitHub may show relative fix to what you are looking for even though no reports have been posted about it.

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 Dabnis » Mon Sep 10, 2018 10:14 pm

Why the agitation: I wrote "There appears to be no mention of a fix for this issue in the 3.1 Alpha release!" in response to your "hope" that it would be in the next release, 3.1.0 Alpha. So what's the reason for the attitude of your response?

It's probably best that I not add more!

Dab

Newbie

Posts

Joined
Tue Jun 01, 2010 2:05 am

Post by Dabnis » Mon Sep 10, 2018 10:28 pm

See this for a fix to this issue : https://github.com/opencart/opencart/pu ... 2c9eb0dd4d

Regards.
Dab

Newbie

Posts

Joined
Tue Jun 01, 2010 2:05 am

Post by straightlight » Tue Sep 11, 2018 12:08 am

The array validations have been recently fixed entirely by Daniel on GitHub.
if (is_array($this->config->get('config_customer_group_display')) && in_array($this->request->post['customer_group_id'], $this->config->get('config_customer_group_display'))) {
has been changed to:

Code: Select all

if (in_array($this->request->post['customer_group_id'], (array)$this->config->get('config_customer_group_display'))) { 
as it has proved to be effective since. However, the enquiry you have addressed this issue is indeed in the right one on the forum.

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 intechmy » Thu Oct 18, 2018 4:21 pm

Hi, after the whole day study and research , finally i found a simple solution for this matter.
We just need do some adjustment on admin dashboard, no coding at all ( i tried all the coding solution, always got errors ).
It's not bug issue for me, It just I failed to understand all the basic features in opencart .

Here the setting steps :
1. at admin dashboard - go to system > setting > edit your store > tab option
2. find setting "Customer Groups" - tick all your existing groups
then you can edit customer order without changing the discounted price

Hope this can use to solve this problem

Newbie

Posts

Joined
Thu Oct 11, 2018 2:23 pm
Location - Malaysia

Post by dejohnson21 » Sun Jan 13, 2019 12:10 am

> The array validations have been recently fixed entirely by Daniel on GitHub.
I am using version 3.0.3.1 now, the issue persists, can someone confirm these changes have not been added to the latest release?

Please if someone can tell me, do I need to delete (comment out) the full 2 lines
if (is_array($this->config->get('config_customer_group_display')) && in_array($this->request->post['customer_group_id'], $this->config->get('config_customer_group_display'))) {

And replace with:

if (in_array($this->request->post['customer_group_id'], (array)$this->config->get('config_customer_group_display'))) {

What file are these lines in?

Is danijelGombac's solution an alternative to this solution?, which is better?

Newbie

Posts

Joined
Wed Sep 05, 2018 9:00 pm

Post by straightlight » Sun Jan 13, 2019 12:28 am

What file are these lines in?
All files containing these lines. Use TextCrawler to track all the relative files.

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 crosland » Wed Oct 14, 2020 2:26 am

straightlight wrote:
Tue Sep 11, 2018 12:08 am
The array validations have been recently fixed entirely by Daniel on GitHub.
if (is_array($this->config->get('config_customer_group_display')) && in_array($this->request->post['customer_group_id'], $this->config->get('config_customer_group_display'))) {
has been changed to:

Code: Select all

if (in_array($this->request->post['customer_group_id'], (array)$this->config->get('config_customer_group_display'))) { 
as it has proved to be effective since. However, the enquiry you have addressed this issue is indeed in the right one on the forum.
Can you show when/where this was changed?

There's no change in the master branch on githuib. I checked a few other branches and could find no evidence of this change anywhere. It seems PR #6855 is closed but has never been merged.

So, has this ever actually been fixed?

If not, which fix is most appropriate? The one you show, or the one in #6855?

Active Member

Posts

Joined
Fri Sep 13, 2019 9:04 pm

Post by straightlight » Wed Oct 14, 2020 3:35 am

If you're looking for clean fix, I would try this:

Code: Select all

if (!empty($this->request->post['customer_group_id']) && $this->config->has('config_customer_group_display') && is_array($this->config->get('config_customer_group_display')) && in_array($this->request->post['customer_group_id'], $this->config->get('config_customer_group_display'))) {

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 crosland » Thu Oct 15, 2020 12:00 am

So I take it the supposed fixes were never actually implemented. The one supposedly implemented by Daniel in 2018 does not work.

Your new, third, "fix" does not work.

Only the fix in #6855 seems to work but this has never been merged as far as I can tell.

Active Member

Posts

Joined
Fri Sep 13, 2019 9:04 pm

Post by straightlight » Thu Oct 15, 2020 12:13 am

crosland wrote:
Thu Oct 15, 2020 12:00 am
So I take it the supposed fixes were never actually implemented. The one supposedly implemented by Daniel in 2018 does not work.

Your new, third, "fix" does not work.

Only the fix in #6855 seems to work but this has never been merged as far as I can tell.
That's because the two possible explanations where:

1 - It has been reported with those "doesn't work" replies.
2 - It has never been confirmed prior to your post on this day which ones was the actual solution based on specific requests / problems.

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
Who is online

Users browsing this forum: No registered users and 33 guests