AJAX Attribute Manager

install on 1.0.8.7 attribute manage tab not shown - AJAX Attribute Manager

install on 1.0.8.7 attribute manage tab not shown

by Omar_one » Fri Dec 03, 2021 9:06 pm

Hello Raiwa,
I just install the last version of ajax_attribute_manager on 1.0.8.7 and the attribute manage tab not shown when editing product, and all the tabs now they don't work example if I press on Product Images tab it will go to admin/index.php

thank you in advance
Omar
Omar_one
VIP Member
VIP Member
Posts: 483
Joined: Fri Oct 25, 2019 5:06 pm
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by raiwa » Sat Dec 04, 2021 7:01 am

I just checked again in a clean 1.0.8.7 and 1.0.8.8 shop and everything works like expected.

Does the Attribute Manager group show in the configuration menu?
Do you get any error message shown or logged?
"last version" is 4.3.1?
Is it a new Phoenix installation or has it been updated?
Do you have any other addon/modification added which may interfere on the catalog page?
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
raiwa
PhoenixCart Developer
PhoenixCart Developer
Posts: 1212
Joined: Sat Dec 21, 2019 8:08 am
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by Omar_one » Sat Dec 04, 2021 2:51 pm

raiwa wrote: Does the Attribute Manager group show in the configuration menu?
yes, Attribute Manager group show in the configuration
raiwa wrote: Do you get any error message shown or logged?
"last version" is 4.3.1?
yes it is 4.3.1 , there is one error

Code: Select all

PHP Fatal error:  DB: [1060] Duplicate column name 'sort_order' 
in /home/xxxx/public_html/xxxxx/includes/system/versioned/1.0.8.1/database_core.php on line 44
raiwa wrote: Is it a new Phoenix installation or has it been updated?
Do you have any other addon/modification added which may interfere on the catalog page?
updated , the main addon they are the supporters code
,, when I visit the admin->catalog-> editing products ..(its shown two header there )
the tabs what's comes with Phoenix installation(Product specific,Language specific and Product Images) they shown but when press on it it go the main admin page .. and the another tabs not show
Omar_one
VIP Member
VIP Member
Posts: 483
Joined: Fri Oct 25, 2019 5:06 pm
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by raiwa » Sat Dec 04, 2021 6:55 pm

It seems there is a glitch for new installations in:
admin/attributeManager/classes/attributeManagerConfig.class.php line 180 change to:

Code: Select all

       if (mysqli_num_rows($db->query("SELECT * FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_SCHEMA='". DB_DATABASE . "' AND TABLE_NAME='products_attributes' AND COLUMN_NAME LIKE 'sort_order'")) != 1 ) {
Note: "!mysqli_num_rows" changed to "mysqli_num_rows" at the beginning and "== 1" changed to "!= 1" at the end
Although the original version works in my test store, it may be more stable for other DBs like this.

Please report back and I'll update the package with the fix.
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
raiwa
PhoenixCart Developer
PhoenixCart Developer
Posts: 1212
Joined: Sat Dec 21, 2019 8:08 am
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by Omar_one » Sun Dec 05, 2021 6:17 pm

raiwa wrote:It seems there is a glitch for new installations in:
admin/attributeManager/classes/attributeManagerConfig.class.php line 180 change to:

Code: Select all

       if (mysqli_num_rows($db->query("SELECT * FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_SCHEMA='". DB_DATABASE . "' AND TABLE_NAME='products_attributes' AND COLUMN_NAME LIKE 'sort_order'")) != 1 ) {
Note: "!mysqli_num_rows" changed to "mysqli_num_rows" at the beginning and "== 1" changed to "!= 1" at the end
Although the original version works in my test store, it may be more stable for other DBs like this.

Please report back and I'll update the package with the fix.
The tabs not working still and there is on the error log file new error

Code: Select all

Duplicate column name 'sort_order' from <ALTER TABLE `am_attributes_to_templates` CHANGE `products_options_sort_order` `sort_order` INT(11) NULL DEFAULT '0';> 
in /home/xxxx/public_html/xxxxx/includes/system/versioned/1.0.8.1/database_core.php on line 44


when I press on any tab the url become like this

Code: Select all

/admin/#section_images_content
Omar_one
VIP Member
VIP Member
Posts: 483
Joined: Fri Oct 25, 2019 5:06 pm
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by raiwa » Mon Dec 06, 2021 7:57 am

A: Delete the column "products_options_sort_order" in the "am_attributes_to_templates" table
OR
B: Run the uninstall script and load again the Admin: Categories: Edit Product page
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
raiwa
PhoenixCart Developer
PhoenixCart Developer
Posts: 1212
Joined: Sat Dec 21, 2019 8:08 am
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by Omar_one » Mon Dec 06, 2021 5:42 pm

raiwa wrote:A: Delete the column "products_options_sort_order" in the "am_attributes_to_templates" table
OR
B: Run the uninstall script and load again the Admin: Categories: Edit Product page
Thank you, this fix the issue and now the tab show, but if I press save ,, the option saved but I get the blank page also if I press on the language flags as I have Multilanguage shop
I get blank page

Code: Select all

This page isn’t working xxxxx is currently unable to handle this request.
HTTP ERROR 500

and here is the error log file

Code: Select all

PHP Notice:  Undefined offset: 5 in /home/test/public_html/shop/admin/attributeManager/classes/attributeManager.class.php on line 238
Uncaught Error: Call to undefined method hook_admin_catalog_ajaxAttribManager::listen_productActionSave() 
in /home/test/public_html/shop/includes/hooks/admin/catalog/ajaxAttribManager.php:39
Stack trace:
#0 /home/test/public_html/shop/includes/system/versioned/1.0.8.1/hooks.php(150): hook_admin_catalog_ajaxAttribManager->listen_updateProductAction(Array)
#1 /home/test/public_html/shop/admin/includes/segments/process_action.php(19): hooks->cat('updateProductAc...')
#2 /home/test/public_html/shop/admin/catalog.php(32): require('/home/test/p...')
#3 {main}
  thrown in /home/test/public_html/shop/includes/hooks/admin/catalog/ajaxAttribManager.php on line 39
there is many Undefined offset errors just different offset no. like 5,8,4,3 but on same line 238

thank you in advance for your help
Omar
Omar_one
VIP Member
VIP Member
Posts: 483
Joined: Fri Oct 25, 2019 5:06 pm
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by Omar_one » Mon Dec 06, 2021 5:49 pm

deleting the

Code: Select all

?>
in /home/test/public_html/shop/includes/hooks/admin/catalog/ajaxAttribManager.php on line 39

now I can save, and there is no any more the blank page, but still the errors

Code: Select all

PHP Notice:  Undefined offset: 5 in /home/test/public_html/shop/admin/attributeManager/classes/attributeManager.class.php 
on line 238
there is many Undefined offset errors just different offset no. like 5,8,4,3 but on same line 238
Omar_one
VIP Member
VIP Member
Posts: 483
Joined: Fri Oct 25, 2019 5:06 pm
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by raiwa » Mon Dec 06, 2021 6:06 pm

Omar_one wrote:
raiwa wrote:A: Delete the column "products_options_sort_order" in the "am_attributes_to_templates" table
OR
B: Run the uninstall script and load again the Admin: Categories: Edit Product page
Thank you, this fix the issue and now the tab show, but if I press save ,, the option saved but I get the blank page also if I press on the language flags as I have Multilanguage shop
I get blank page

Code: Select all

This page isn’t working xxxxx is currently unable to handle this request.
HTTP ERROR 500

and here is the error log file

Code: Select all

PHP Notice:  Undefined offset: 5 in /home/test/public_html/shop/admin/attributeManager/classes/attributeManager.class.php on line 238
Uncaught Error: Call to undefined method hook_admin_catalog_ajaxAttribManager::listen_productActionSave() 
in /home/test/public_html/shop/includes/hooks/admin/catalog/ajaxAttribManager.php:39
Stack trace:
#0 /home/test/public_html/shop/includes/system/versioned/1.0.8.1/hooks.php(150): hook_admin_catalog_ajaxAttribManager->listen_updateProductAction(Array)
#1 /home/test/public_html/shop/admin/includes/segments/process_action.php(19): hooks->cat('updateProductAc...')
#2 /home/test/public_html/shop/admin/catalog.php(32): require('/home/test/p...')
#3 {main}
  thrown in /home/test/public_html/shop/includes/hooks/admin/catalog/ajaxAttribManager.php on line 39
there is many Undefined offset errors just different offset no. like 5,8,4,3 but on same line 238

thank you in advance for your help
Omar
This error:
hook_admin_catalog_ajaxAttribManager->listen_updateProductAction(Array)
shows that you are using version 3.4.0.
Please update to 3.4.2.

The notice errors are produced if you have no option/attribute value name entered. Check this and make sure all options/attributes values have a name.
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
raiwa
PhoenixCart Developer
PhoenixCart Developer
Posts: 1212
Joined: Sat Dec 21, 2019 8:08 am
Contact:

Re: install on 1.0.8.7 attribute manage tab not shown

by raiwa » Mon Dec 06, 2021 6:19 pm

Omar_one wrote:deleting the

Code: Select all

?>
in /home/test/public_html/shop/includes/hooks/admin/catalog/ajaxAttribManager.php on line 39

now I can save, and there is no any more the blank page, but still the errors

It's better to remove the ending "?>" but if it produces problems, you may have a blank line or blank space at the beginning of another file, maybe a language file. Check this.

On my test installation I have no problem with it.
but I get the blank page also if I press on the language flags as I have Multilanguage shop
Just checked and yes, the language buttons push back to the product listing. I'll have a look tomorrow.
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
raiwa
PhoenixCart Developer
PhoenixCart Developer
Posts: 1212
Joined: Sat Dec 21, 2019 8:08 am
Contact: