Page 1 of 2 12 LastLast
Results 1 to 10 of 12
  1. #1
    Join Date
    Nov 2007
    Posts
    141
    Plugin Contributions
    0

    Default [Done v1.4.0] Admin Category Product Status

    I'm having a problem with my admin category/product status control. I can set the status to "off" or "on" in the admin and get the red or green button, but the links still show up on the site when set to "off". I am sure one of the numerous mods I have installed has messed this up, but could use some direction on which file(s) to restore or compare from my backup files.

    Thx Sweet

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Admin Category Product Status

    There appears ti ve a bug in two of the center boxes ...

    /includes/modules/new_products.php

    This section around lines 40-45
    PHP Code:
        $new_products_query "select distinct p.products_id, p.products_image, p.products_tax_class_id, pd.products_name,
                                      p.products_date_added, p.products_price, p.products_type, p.master_categories_id
                               from " 
    TABLE_PRODUCTS " p, " TABLE_PRODUCTS_DESCRIPTION " pd
                               where p.products_id = pd.products_id
                               and pd.language_id = '" 
    . (int)$_SESSION['languages_id'] . "'
                               and p.products_id in (" 
    $list_of_products ")"
    Needs to be updated to:
    PHP Code:
        $new_products_query "select distinct p.products_id, p.products_image, p.products_tax_class_id, pd.products_name,
                                      p.products_date_added, p.products_price, p.products_type, p.master_categories_id
                               from " 
    TABLE_PRODUCTS " p, " TABLE_PRODUCTS_DESCRIPTION " pd
                               where p.products_id = pd.products_id
                               and pd.language_id = '" 
    . (int)$_SESSION['languages_id'] . "'
                               and p.products_status = 1
                               and p.products_id in (" 
    $list_of_products ")"
    And then in the:
    /includes/modules/upcoming_products.php

    around lines 43 to 50
    PHP Code:
        $expected_query "select p.products_id, pd.products_name, products_date_available as date_expected, p.master_categories_id
                           from " 
    TABLE_PRODUCTS " p, " TABLE_PRODUCTS_DESCRIPTION " pd
                           where p.products_id = pd.products_id
                           and p.products_id in (" 
    $list_of_products ")
                           and pd.language_id = '" 
    . (int)$_SESSION['languages_id'] . "' " .
                           
    $display_limit .
                           
    $limit_clause
    to read:
    PHP Code:
        $expected_query "select p.products_id, pd.products_name, products_date_available as date_expected, p.master_categories_id
                           from " 
    TABLE_PRODUCTS " p, " TABLE_PRODUCTS_DESCRIPTION " pd
                           where p.products_id = pd.products_id
                           and p.products_status = 1
                           and p.products_id in (" 
    $list_of_products ")
                           and pd.language_id = '" 
    . (int)$_SESSION['languages_id'] . "' " .
                           
    $display_limit .
                           
    $limit_clause
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Admin Category Product Status

    Moving to Bug Report ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  4. #4
    Join Date
    Nov 2007
    Posts
    141
    Plugin Contributions
    0

    Default Re: Admin Category Product Status

    Thanks for the quick reply Linda. I will apply your suggestion and post back to this thread with my status.

    Sweet

  5. #5
    Join Date
    Nov 2007
    Posts
    141
    Plugin Contributions
    0

    Default Re: [Done v1.4.0] Admin Category Product Status

    I can't find that exact code in my files. I have installed several category listing mods that have modified this section of code. However, the missing code "and p.products_status = 1" seems to be in both files as shown below.

    /includes/modules/new_products.php

    } else {
    $new_products_query = "select distinct p.products_id, p.products_image, p.products_tax_class_id, p.products_date_added,
    p.products_price
    from " . TABLE_PRODUCTS . " p
    left join " . TABLE_SPECIALS . " s
    on p.products_id = s.products_id, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, " .
    TABLE_CATEGORIES . " c
    where p.products_id = p2c.products_id
    and p2c.categories_id = c.categories_id
    and c.parent_id = '" . (int)$new_products_category_id . "'
    and p.products_status = 1 " . $display_limit;
    }


    /includes/modules/new_products.php

    $expected_query = "select p.products_id, pd.products_name, products_date_available as date_expected
    from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, " .
    TABLE_CATEGORIES . " c
    where p.products_id = p2c.products_id
    and p2c.categories_id = c.categories_id
    and c.parent_id = '" . (int)$new_products_category_id . "'" .
    $display_limit . "
    and p.products_id = pd.products_id
    and p.products_status = 1
    and pd.language_id = '" . (int)$_SESSION['languages_id'] . "'
    order by " . EXPECTED_PRODUCTS_FIELD . " " . EXPECTED_PRODUCTS_SORT . "
    limit " . MAX_DISPLAY_UPCOMING_PRODUCTS;

    }

    Sweet

  6. #6
    Join Date
    Aug 2008
    Posts
    115
    Plugin Contributions
    0

    Default Re: [Done v1.4.0] Admin Category Product Status

    There appears to be a bug in two of the center boxes ...
    This simple bug was noticed in Dec '07 , the solution is a terrific and easy fix ...but i wonder why this wasn't just plugged into the current 1.3.8 download files when it was first found - so that people who download their copies from that point forward wouldn't all have to go through the same steps in finding fixing their carts?

    I really like ZenCart but I'm not sure i understand the project sometimes.

  7. #7
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: [Done v1.4.0] Admin Category Product Status

    Cause I goofed ...

    Sometimes, we actually goof in coding thousands of lines of code in each of the Free Releases that we make and sometime we actually moof it up from time to time when writing all of the neat, free code for you to run your online business ... you might also note it was caught shortly after the release date too ...

    I heard a rumor the other day that all of us on the Zen Cart Development Team are ... are ... are ... human ...

    go figure?

    NOTE: go here and play ...
    http://www.zen-cart.com/forum/showthread.php?t=82619
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  8. #8
    Join Date
    Aug 2008
    Posts
    115
    Plugin Contributions
    0

    Default Re: [Done v1.4.0] Admin Category Product Status

    Ajeh,

    No, Sorry - of course we are all human - and i apologize if my comment came off wrong. Lord knows I make more mistakes than most!

    The Zen project is a wonderful venture and I owe you guys much ...but when i read "[Done v1.4.0]" in the title line but didn't see it applied to current 1.3.8 , I thought that there was some reason - one that i didn't understand. Sorry.

    Thanks again!

  9. #9
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: [Done v1.4.0] Admin Category Product Status

    The bug snuck in the v1.3.8 version ... hence, it's in there ...

    But the fixes are posted on the Known Bug Fixes for v1.3.8 and here ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  10. #10
    Join Date
    Dec 2008
    Location
    Saratoga Springs, NY
    Posts
    25
    Plugin Contributions
    1

    Default Re: [Done v1.4.0] Admin Category Product Status

    I think i just found another bug in the new_products module...

    On my website, in the center box for new products, if a product is in category_id (cPath) 1, then the link it generates links it as cPath=0

    Here is an example:

    This is one of the links from the center new products box, from a product from cPath 1, when i click on it, it displays as cPath=0...


    http://www.slotmachinesdirect.com/in...products_id=61


    However, if the product is in a cPath other than 1, it displays just fine, so im not sure what the cause of this is.

    Anyone have any idea where this little bug is located?

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v151 View a product/category in the catalog from a link in admin product/category listing
    By torvista in forum Customization from the Admin
    Replies: 4
    Last Post: 25 Jan 2013, 06:13 PM
  2. v151 Toggling Category/Product Status in admin by clicking on red/green square not working
    By woodlandsprite in forum All Other Contributions/Addons
    Replies: 4
    Last Post: 29 Oct 2012, 11:20 PM
  3. Replies: 10
    Last Post: 30 Apr 2010, 04:46 PM
  4. Main category as a product page: can it be done?
    By nyanko chan in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 3 Jun 2009, 12:44 AM

Bookmarks

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
Zen-Cart, Internet Selling Services, Klamath Falls, OR