Re: Stock by Attributes 5.0 Beta (for v1.5.0)
Installed "creinold_SBA5.1_alpha_version1.5_for_zencart_V1.5.0" on cart version 1.5.5e. The module appears to have installed properly in that it shows the admin section as well as drop-downs in the front end. However, when I try to add in the quantities in "Products with Attributes Stock" in the admin I get the following: WARNING: An Error occurred, please refresh the page and try again.
Here is what my debug says:
Code:
[15-Mar-2017 15:38:32 UTC]
Request URI: /PersonalAdmin/products_with_attributes_stock.php?products_id=18&quantity=10&attributes=33&add_edit=add&action=execute,
#1 trigger_error() called at [/home/REDACTED/public_html/includes/classes/db/mysql/query_factory.php:167]
#2 queryFactory->show_error() called at [/home/REDACTED/public_html/includes/classes/db/mysql/query_factory.php:139]
#3 queryFactory->set_error() called at [/home/REDACTED/public_html/includes/classes/db/mysql/query_factory.php:266]
#4 queryFactory->Execute() called at [/home/REDACTED/public_html/PersonalAdmin/products_with_attributes_stock.php:250]
PHP Fatal error: 1364:Field 'sort' doesn't have a default value :: insert into `products_with_attributes_stock` (`products_id`,`stock_attributes`,`quantity`) values (18,"33",10) ==> (as called by) /home/REDACTED/public_html/PersonalAdmin/products_with_attributes_stock.php on line 250 <== in /home/REDACTED/public_html/includes/classes/db/mysql/query_factory.php on line 167
Thank you for your help.
Re: Stock by Attributes 5.0 Beta (for v1.5.0)
Hmm. Edit about the below: perhaps I've posted here thinking it was the thread associated with a different version of SBA (I'm on list for several). Sorry for toe stepping. Running out of time to edit. But still able to possibly answer questions related to the solution.
A lot going on here, 1) using a very old as far as I know no longer maintained version of SBA, 2) looks like you could use at least three options to move forwards, either alter the database, so that every new item has a default value that is a constant (all new items would have the same sort value), you could modify the database field to autonumber such that each would be assigned a new/unique likely unchangeable sort value. You could modify the query to add a value to the table for that field and that value could be a constant (to be changed later) or it could be determined by the last sort number and incremented in a way applicable to the desired outcome. The drastic action would be to delete the field from the table and any other place that the sort field is used/accessed, but that doesn't seem like a worthwhile venture.
So, it would depend on how you wish to move forward with the issue of that software which doesn't occur with the version that has primarily been discussed, tested, and used on the more recent versions of ZC.
Re: Stock by Attributes 5.0 Beta (for v1.5.0)
Quote:
So, it would depend on how you wish to move forward with the issue of that software which doesn't occur with the version that has primarily been discussed, tested, and used on the more recent versions of ZC.
Hmmm. I guess I missed a module. What is the link to the new version that matches 1.5.5? I did not mean to use a version that was outdated.
Thanks again for your input!
Re: Stock by Attributes 5.0 Beta (for v1.5.0)
Quote:
Originally Posted by
maxmarketing
[/B]
Hmmm. I guess I missed a module. What is the link to the new version that matches 1.5.5? I did not mean to use a version that was outdated.
Thanks again for your input!
So, don't be alarmed about the thread title. I suggest going to the end of the thread and reading back even just a couple of pages to get the lay of the land.
https://www.zen-cart.com/showthread....tock+attribute
Re: Stock by Attributes 5.0 Beta (for v1.5.0)
Thank you for your rapid response. The title of that thread is why I did not proceed with it when I was looking for a module. Good to have clarification.