Results 1 to 10 of 81

Hybrid View

  1. #1
    Join Date
    Feb 2009
    Location
    UK
    Posts
    1,303
    Plugin Contributions
    1

    Default Re: Inventory Updater...

    I haven't tried v1.2.0 but one issue I'm having on the previous version is that after adding the Inventory admin page to a user profile other than Superuser, I get

    ...your security clearance does not allow you to access this resource.

    I thought it might be related to the Admin Page Registration, not knowing much about the process I attempted different page key and menu choice but still the same error. Perhaps something in the code.

    Edit: ZC v1.56c, plus plenty of mods which I probably should have listed.
    Last edited by simon1066; 3 Jul 2020 at 06:30 PM.
    Simon

  2. #2
    Join Date
    Feb 2009
    Location
    UK
    Posts
    1,303
    Plugin Contributions
    1

    Default Re: Inventory Updater...

    Quote Originally Posted by simon1066 View Post
    I haven't tried v1.2.0 but one issue I'm having on the previous version is that after adding the Inventory admin page to a user profile other than Superuser, I get

    ...your security clearance does not allow you to access this resource.

    I thought it might be related to the Admin Page Registration, not knowing much about the process I attempted different page key and menu choice but still the same error. Perhaps something in the code.

    Edit: ZC v1.56c, plus plenty of mods which I probably should have listed.
    Found the answer, https://www.zen-cart.com/showthread....97#post1131197

    admin/includes/extra_datafiles/inventory.php

    Code:
    define('FILENAME_INVENTORY', 'inventory.php');
    to

    Code:
    define('FILENAME_INVENTORY', 'inventory');
    Simon

  3. #3
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,915
    Plugin Contributions
    13

    Default Re: Inventory Updater...

    Quote Originally Posted by simon1066 View Post
    Found the answer, https://www.zen-cart.com/showthread....97#post1131197

    admin/includes/extra_datafiles/inventory.php

    Code:
    define('FILENAME_INVENTORY', 'inventory.php');
    to

    Code:
    define('FILENAME_INVENTORY', 'inventory');
    man, what a bloody waste!

    the idea that back in 2013, we had this error, and it was supposed to be corrected back then, and the correction does not fix the problem..... wow.

    i digress....

    your solution does work. the core ZC should have taken care of my error, but alas it does not....

    feel free to implement that. i will do another submit shortly. as well as fix the base zen code. i hope.

    thanks for pointing this out.

    best.
    author of square Webpay.
    mxWorks now has Apple Pay and Google Pay. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  4. #4
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,915
    Plugin Contributions
    13

    Default Re: Inventory Updater...

    @simon1066, version 1.2.1 removes the .php from the filename.

    in addition, hopefully the ZC team will merge this PR that actually does fix this issue for other plugin authors like myself that make the same mistake:

    https://github.com/zencart/zencart/pull/3653

    best.
    author of square Webpay.
    mxWorks now has Apple Pay and Google Pay. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  5. #5
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,915
    Plugin Contributions
    13

    Default Re: Inventory Updater...

    version 1.2.1 now available for download here:

    https://www.zen-cart.com/downloads.php?do=file&id=2279

    update base price as well as inventory!

    also, no modifications necessary to work within admin profile security.

    best.
    author of square Webpay.
    mxWorks now has Apple Pay and Google Pay. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  6. #6
    Join Date
    Feb 2009
    Location
    UK
    Posts
    1,303
    Plugin Contributions
    1

    Default Re: Inventory Updater...

    Inventory Updater v1.2.1
    PHP v7.2.10

    Upgrading to ZCv1.57, I get these myDEBUG logs notices when viewing the Inventory Updater page - I know the notices are not critical but if I don't address these undefined index notices (and many others unrelated to Inventory Updater, across the site) the number of log files will become unmanageable.

    Code:
    [08-Jul-2020 10:59:08 Europe/London] PHP Notice:  Undefined index: sort in D:\wamp64\www\mydomain.co.uk\myadmin\inventory.php on line 73
    [08-Jul-2020 10:59:08 Europe/London] PHP Stack trace:
    [08-Jul-2020 10:59:08 Europe/London] PHP   1. {main}() D:\wamp64\www\mydomain.co.uk\myadmin\index.php:0
    [08-Jul-2020 10:59:08 Europe/London] PHP   2. require() D:\wamp64\www\mydomain.co.uk\myadmin\index.php:11
    [08-Jul-2020 10:59:08 Europe/London] PHP Notice:  Undefined index: sort in D:\wamp64\www\mydomain.co.uk\myadmin\inventory.php on line 285
    [08-Jul-2020 10:59:08 Europe/London] PHP Stack trace:
    [08-Jul-2020 10:59:08 Europe/London] PHP   1. {main}() D:\wamp64\www\mydomain.co.uk\myadmin\index.php:0
    [08-Jul-2020 10:59:08 Europe/London] PHP   2. require() D:\wamp64\www\mydomain.co.uk\myadmin\index.php:11
    
    ... followed by a line 285 entry for every product listed.
    inventory.php line 71-76
    Code:
    $sort = (isset($_GET['sort']) ? $_GET['sort'] : '0');
    	$order_by = " ";
    	switch ($_GET['sort']) {
    		case (0):
    			$order_by = " ORDER BY p.products_sort_order, pd.products_name";
    			break;
    inventory.php line 284-286
    Code:
     <a href="<?= zen_href_link(FILENAME_INVENTORY,
            'action=tg_stat' . '&pid=' . $prod_list->fields['products_id'] . $cid_params . '&sort=' . $_GET['sort'] . '&active=' . $_GET['active'],
            'SSL'); ?>">
    'PHP Notice: Undefined index:' seems to be a bit of a theme with my upgrade to ZCv1.57 - seems to be mainly caused by old mods and my crude hacking of php files, still trying to get my head around the whys and wherefores.
    Simon

  7. #7
    Join Date
    Feb 2009
    Location
    UK
    Posts
    1,303
    Plugin Contributions
    1

    Default Re: Inventory Updater...

    It strikes me that perhaps these notices are a result of the improved error logging in ZCv1.57. TBH I can't remember if ZCv1.56c showed notices or not. In any event I get too many of them.
    Simon

 

 

Similar Threads

  1. Dynamic Price Updater
    By Chrome in forum All Other Contributions/Addons
    Replies: 1683
    Last Post: 27 Apr 2026, 06:21 AM
  2. v154 Quick Updater
    By fabienne in forum General Questions
    Replies: 5
    Last Post: 30 Jan 2015, 01:46 AM
  3. Update Inventory with Suppliers XML inventory feed?
    By mafiasam in forum All Other Contributions/Addons
    Replies: 4
    Last Post: 21 Jun 2007, 11:44 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg