Author Topic: The workflow for U or A is unknown, take a look on model/orders function handleS  (Read 602 times)

Iryn3l

  • Jr. Member
  • **
  • Posts: 99
  • A beginner
I discovered this error after the call of a client who did not receive the order by e-mail and did not reach my e-mail, and in the commands / VM I did not notice it
I recently changed the status A to L but at status U I didn't change anything other than editing its name

---
VirtueMart 3.8.4 10335
Joomla! 3.9.20
PHP 7.3

Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3482
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
What is the stock handling for A and U in Your system ? In my case both are reserved.

Jörgen @ Kreativ Fotografi
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

Iryn3l

  • Jr. Member
  • **
  • Posts: 99
  • A beginner
COM_VIRTUEMART_ORDER_STATUS_CONFIRMED_BY_SHOPPER >>> U >>> RESERVED
A that has become U is removed
but I don't use it anymore, it's for older orders, I just changed it to L (that's all)

One more question if we are still in this chapter, should I have only one status "Is Removed" and until then it should only be "reserved"?
Of course excluding these with return to stock.

Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3482
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
You can not change U to L.

It is like changing You phone number. The old number will have no recipient. The phone number as order status is the key. You can change the content for the key. But changing the key erases the old key. I hope you get what I mean.
You can add L but do not remove U.

U or L are the keys U is still used in every location it is stored, orders and otherwise.

Jörgen
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

pinochico

  • 3rd party VirtueMart Developer
  • Full Member
  • *
  • Posts: 1137
    • MiniJoomla
  • Skype Name: support-easysoftware
  • VirtueMart Version: 3
Status U is used in lot of extensions and I think in core VM.

Why do you think you change it to your custom?

Then you have this result - mistake admin, done
www.minijoomla.org  - new portal for Joomla!, Virtuemart and other extensions
XML Easy Feeder - feeds from products, orders and database table
Virtuemart Email Manager - customs email templates

Iryn3l

  • Jr. Member
  • **
  • Posts: 99
  • A beginner
I changed "A" to "L", .... NOT "U" >>> Sorry for my mistake when I explained
I meant "A" that has become "L"  > stock handling is "RESERVED" for this
This "A" was a status that I created (it was not in the standard Vm created)

Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3482
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
if you change A to L you will break keys. This will impact data already in your database. Trust me on this.

Please add L DO NOT DELETE A.

Jörgen
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

Iryn3l

  • Jr. Member
  • **
  • Posts: 99
  • A beginner
I recreated A and all the commands that were originally in this A status appeared here. In the meantime, I had noticed some errors, for example in mass invoicing, it generates invoices for very old orders.

Now I have another problem, I made a mistake
While switching bulk 26 orders, I forgot to select only the status I was interested in changing and closed the browser instinctively.


This status in which I wanted to change , sent the recipient contact details to a courier company and receives a transport code back.

I only sent for 6 out of 26 until the browser closes.
Trying to close I destroyed the database it seems and the orders from the last 24 hours or more I can't see them anymore


Can anything else be done to fix this?
You have some advice

AH

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3450
  • VirtueMart Version: 3.8.9
Dont ever delete an order status code

It causes many unexpected issues!

For example in order list - if the status is no longer available - it will show the order status as being the first in the order status list

Regards
A

Joomla 3.9.26
php 7.4

Iryn3l

  • Jr. Member
  • **
  • Posts: 99
  • A beginner
Yes now I noticed that it can create errors, I did not delete the status of the order I just renamed it .. I did not think that it can create the same errors as if it were deleted
Now it's solved after I re-created "A"

Can anyone  with the second problem, which has appeared in the meantime, help me with some advice?

<<<< Now I have another problem, I made a mistake
While switching bulk 26 orders, I forgot to select only the status I was interested in changing and closed the browser instinctively.
This status in which I wanted to change , sent the recipient contact details to a courier company and receives a transport code back.
I only sent for 6 out of 26 until the browser closes.
Trying to close I destroyed the database it seems and the orders from the last 24 hours or more I can't see them anymore >>>

Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3482
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
Please notice, You do not rename it, you change the key value doing that. In practice this is the same as deleting the key and creating a new item. The item IS the key value with properties: reserved etc. The rest of the database does not understand that You have renamed it. The name is the KEY. Please understand this and You will know why you get into trouble.

All existing references to A will not find status A because it does not exist any more when "renamed" or deleted. Do never rename or delete a used status code.

Jörgen @ Kreativ Fotografi
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

AH

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3450
  • VirtueMart Version: 3.8.9
Changing the name - I was not aware of any issues regarding this?
Regards
A

Joomla 3.9.26
php 7.4

Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3482
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
@AH Changing the "name" of the key from A to L, is of course not the same as changing the descriptive name. Sorry about the confusion. Changing the descriptive name of the status "Cancelled" to Confirmed should not give any issues. I hope I cleared everything up.

Jörgen
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

Iryn3l

  • Jr. Member
  • **
  • Posts: 99
  • A beginner
Now I understand, thank you for your help