Error 500 Update Items

0

I'm trying to update a product and I get this error, can you check?

Bug Unresolved For: Modern Point of Sale Solution 0 Votes 9 Replies 2.9k Views
Reported by Abdias Muñoz 2 years ago

1

Replied by Mian Saleem 2 years ago

Hello,

Yes, the variation foreign keys are causing the issue. I will fix this in the next update.

For now, you can run the follow queries after selecting your database.

alter table `modifier_options` drop foreign key `modifier_options_variation_id_foreign`;
alter table `portion_items` drop foreign key `portion_items_variation_id_foreign`;
alter table `portion_essentials` drop foreign key `portion_essentials_variation_id_foreign`;
alter table `portion_choosable_items` drop foreign key `portion_choosable_items_variation_id_foreign`;
alter table `sale_item_variation` drop foreign key `sale_item_variation_variation_id_foreign`;
alter table `purchase_item_variation` drop foreign key `purchase_item_variation_variation_id_foreign`;
alter table `recurring_sale_item_variation` drop foreign key `recurring_sale_item_variation_variation_id_foreign`;
alter table `stock_transfer_item_variation` drop foreign key `stock_transfer_item_variation_variation_id_foreign`;
alter table `return_order_item_variation` drop foreign key `return_order_item_variation_variation_id_foreign`;
alter table `quotation_item_variation` drop foreign key `quotation_item_variation_variation_id_foreign`;
alter table `delivery_item_variation` drop foreign key `delivery_item_variation_variation_id_foreign`;
alter table `stock_adjustment_item_variation` drop foreign key `stock_adjustment_item_variation_variation_id_foreign`;

Thank you

0

Replied by Abdias Muñoz 2 years ago

I ran the query but the problem is with another foreign key (stock_trails_variation_id_foreign), delete it too?

0

Replied by Mian Saleem 2 years ago

Yes, you can delete that too. I will be checking and update this before the next update. Thank you

0

Replied by Abdias Muñoz 2 years ago

I am trying to enter a stock trim and I have this error, what should be the solution?

0

Replied by Mian Saleem 2 years ago

Hello,

I am sorry for the late reply. I didn't understand about stock trim. Can you please explain and let me know the steps to replicate the bug? It will help me find the cause.

Thank you

0

Replied by Abdias Muñoz 2 years ago

Sure, from the steps you followed, you encountered some snags. I create a product to which I add variants, it already allows me to save, however in the update nothing is modified, I think your product update is wrong. Then I go to stock in order to have availability of each of the product variants, that is where I get the error, I checked the database and the stock adjustment information is saved, what is not saved is the information in the stock detail table in the variants, I don't know if I'm explaining myself. This prevents product availability from appearing in the POS and I cannot make sales. As additional information, I tried to enter a product without variants and that stock is maintained in order to generate sales.

0

Replied by Mian Saleem 2 years ago

Thank you very much for sharing the details. I will check tomorrow morning and will update you.

0

Replied by Abdias Muñoz 2 years ago

Very good, I await your response.

0

Replied by Mian Saleem 2 years ago

Hello,

I have tried to follow the step. There was an issue with quantity sync, so I removed the quantity column on the variants. Not quantity can be set on locations tab only. I have added the migration to drop the foreign keys. I am not sure if this issue was related but you can try the demo.

I have updated the live demo and will release the fixed next week.

Thank you

We use Cookies

We use cookies to ensure that we give you the best experience on our website. By continuing to browse the site you are agreeing to our use of cookies.