Vendor product edition = conditional?

  • Posts: 2143
  • Thank you received: 747
10 years 6 months ago #155360

-- url of the page with the problem -- : none yet
-- HikaShop & Market versions -- : actual

Hi again,

You can tell, I've been busy over the weekend, huh? B) Hope you had a good rest, so you survive all my stuff...
Got more news for you, so let me split it up. This being under 'Feature requests', none is badly urgent, only friendly input.

I was thinking that vendor product edition could be sometimes 'risky', yet must and should be generally possible, of course. Only once an order for that product is in the system, it should be 'blocked', IMHO - as a security feature.

Imagine: a vendor is offering i.e. a used car (just as an example). He claims it's from 2012. Ok, someone orders it. Vendor goes and changes it to 2010... which it really is. Customer realises it sooner or later and is sure not happy. Vendor says, "not sure who told you 2012, it always said 2010."

I know, admin is getting an email if vendor edits product (and now even a dedicated one, woohoo!), but it doesn't say what was edited. I guess no other record from the past, and one could claim that even the database backup saying 2012 isn't 'real'. The stink is there. And there are just too many idiots around who cheat and steal and lie wherever a few dollars are lying around.

So again, I'm dreaming i.e. of a mechanism which lets a vendor not edit his product(s) unless they're not involved with any pending order process. Even if they mean it well and have an improved version, have them creating a new product. Technically, and in fact also legally, a feature change on a product, whichever way, makes it a different one. And who knows if "edition" always means only improving the grammar in the description...

Hmm, include at least optionally?

Thanks for reading, and even more for the briefest comment.


Need help with customisations of layouts, style or other site development? PM me!
(Don't forget to turn on "E-mail notification of new messages" )

Please Log in or Create an account to join the conversation.

  • Posts: 26156
  • Thank you received: 4028
  • MODERATOR
10 years 6 months ago #155402

Hi,

This feature is called in our side "validation of product modification"
We want to add some kind of "versionning" in HikaShop / HikaMarket to store the different states of a products, to have access to the history.
With that feature, the idea is to have a "future versionning", so when a vendor will modify a product, it will create a new version but it won't modify the real product. The store owner (an admin) will have to validate the modification, it will update the current product, remove the "future version" and create a "past version" for what the current product was (I hope I didn't lost in the timeline).

Well, in your case I think you can just use a little custom plugin.
We have a lot of triggers in HikaShop and HikaMarket which allow you to create your own cool features.
In your case, you don't want to let a vendor edit a product if there is already an order with that product.
The trigger "onBeforeProductUpdate" will be called every time a product is modified (in the backend or in the frontend).
www.hikashop.com/support/support/documen...ntation.html#product

The idea is to set the variable "$do" to false when you are in the front-end and the product have been ordered once.
You can have the product_id in the object $element and you have to check the table "order" with the table "order_product" for the check.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
The following user(s) said Thank You: lousyfool

Please Log in or Create an account to join the conversation.

  • Posts: 2143
  • Thank you received: 747
10 years 6 months ago #155409

Wow, that new feature sounds pretty exciting! Happy version juggling! :lol:

Trust me please, it'll only be effective if vendors know of (a) the existence, and (b) the potential consequences. We want to prevent evil, not pick up the pieces when it's too late. Some might even make it a sport trying to break it or trick it out - who do you think is John Smith behind that strange IP really...
But then the world isn't THAT bad, maybe, and there's only so and so much one can do without losing the fun entirely. Fact is that it'll be a valid and good 'pro' point for a the customers of a store equipped with such feature.

Then, the second part reads more like Chinese than French to me at first glance. Looks like I'll need to seriously work on my PHP driver's license, and I'm not sure when that's going to happen. Or I just need to find someone to knit the little tool for me. Or someone else here has the need as well. And a heart. No worries, don't expect you to - you guys better focus on the new "VPM" gimmick!

Once again, thanks!


Need help with customisations of layouts, style or other site development? PM me!
(Don't forget to turn on "E-mail notification of new messages" )

Please Log in or Create an account to join the conversation.

  • Posts: 158
  • Thank you received: 8
10 years 6 months ago #155441

Interesting...
Jerome is this "validation of product modification" in the TO-DO for the near-far future or something close to implementation?

Like lousyfool the second part is more like Chinese than Italian to me, I would need to practice in a foolproof local server before daring to trigger anything on the live site...

Please Log in or Create an account to join the conversation.

  • Posts: 26156
  • Thank you received: 4028
  • MODERATOR
10 years 6 months ago #155450

Hi,

The second part of my message is for developers ; if someone wants to write a little custom plugin it explains the global process to follow.

The "validation of product" is something in the TODO list but not for the near future.
I am currently working on the variant/characteristics edition in the front-end ; the development is going well but it requires a lot of time.
About the "validation of product", we are talking with Nicolas in order to know if we add the feature just in HikaMarket or if he want the "history" in HikaShop too. It will change the way that the feature will be added, if I will made something just for my product or something accessible for everyone (= every components around HikaShop).

Anyway, this feature have a good priority in my TODO list, with the "payment / shipping configuration in the front-end".

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
The following user(s) said Thank You: pprle

Please Log in or Create an account to join the conversation.

  • Posts: 2143
  • Thank you received: 747
10 years 6 months ago #155515

Hi again,

At least in my case I'd say take your time and build a nicely working tool rather than rush-rush - as always. I wonder, if meanwhile the notification mail on product edition could be easily amended with the fields that were changed - preferably in a "before / after" format...

But then, admittedly, I haven't really thought about it, and it could as well be more difficult to realise than 'the little plugin' or even the 'VPM', haha...


Need help with customisations of layouts, style or other site development? PM me!
(Don't forget to turn on "E-mail notification of new messages" )

Please Log in or Create an account to join the conversation.

Moderators: Obsidev
Time to create page: 0.076 seconds
Powered by Kunena Forum