Page 260 of 359 FirstFirst ... 160210250258259260261262270310 ... LastLast
Results 2,591 to 2,600 of 3589
  1. #2591
    Join Date
    Jul 2012
    Posts
    16,798
    Plugin Contributions
    17

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Ahhh, check boxes... I can't say that I've done a lot of testing with them (yet)...

    Is there a reason you have chosen to use check boxes instead of any of the other attribute types?

    One reason I ask is because it is possible to add the product to the cart with no checkboxes marked (product is added with a cost of 0.00), it is also possible to add one product with 1 checkbox marked, but if two or more are marked from the same option name then sba has a problem (will work to resolve that regardless of your final decision in this matter.)

    So, in testing the product referenced above, it is possible to add a product to the cart, but not two at the same time when using two or more check boxes.

    If you would prefer to allow a customer to add x quantity of say Bramen & Mango and y quantity of Limoen & Koffie and press the add-to-cart button one time, then I would suggest adding product attributes grid to your installation instead of check boxes for this "arrangement".
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  2. #2592
    Join Date
    Jul 2012
    Posts
    16,798
    Plugin Contributions
    17

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    I was wrong in my previous post. I stated that checkboxes could at least be handled as part of being stock. So far, the testing that I have done, checkboxes alone do not track well with SBA in that when I had a store setup to not display the cart after adding product, one option name, had two option values. Selecting any combination of check boxes (or none) while stock was applied to one or more of the checked values, did not add the product to the cart.

    Apparently what I saw in the above site, was still being modified as I was testing and the checkboxes had not had stock applied to them (therefore responding as a normal ZC operation). Anyways, I still need to test a few other cases to see what the limits are, but I have the following:

    Okay. Checkboxes... I've started an issue on Github related to checkboxes. Looking for some input.

    I'm beginning to think that checkboxes should not be treated as stock related quantities. Besides the complexity that can be added to the code, I'm thinking about this from the side of stock control...

    A checkbox typically has two states, though it could have a third "intermittent" state at least in assignment. Generally only two states are considered, checked or not checked. Further, general usage seems to be such that, yes I agree/have read/etc... or please add this to the object/purchase. A perceived "normal" usage is like please make this with the added color, style, shape or I'll take that free item with it, or I do have something more to add. While it may be possible to consider each of those traits as something that could be tracked by stock, and actually part of the design/incorporation already is to consider the gift wrap condition (please add gift wrap to this product or not) such that the quantity of giftwrap is not actually tracked, just the fact that such a selection has been made or not.

    By trying to track such items as stockable quantities, if 2 or more checkboxes are applied to a single option name or if two separate option names have checkboxes, then each combination of check/unchecked item must be considered. Now the other alternative is or could be that the checkboxed item itself is (or is not) tracked by stock, such that if someone does offer a checkbox item that represents a physical object (assume x number of "free" things to give away or first y people that select this get it) then the checked item could be tracked separately from the rest of the product. Now, there are certainly ever larger possibilities, but it seems that in the confines of the existing attribute system, that this may be the limit of what can be done without redeveloping the attribute system.

    Anyways, there are obviously a few things to work out when using checkboxes, again I thought I was close to simply cleaning up code, simplifying some of the actions and adding a few features or at least working some of the code to make that easier to do. And along comes someone who is trying their best to setup their store their way and an issue is found. ahh well...
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  3. #2593
    Join Date
    Sep 2011
    Posts
    38
    Plugin Contributions
    0

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Without wanting to get slammed for not searching this thread, which I did, but obviously without the correct search terms, how do I get the stock level so show next to the attribute?

    Ie, http://www.skysports.com.au/index.ph...roducts_id=189 is currently showing 8 total units in stock, but I want it to show 3 black, 1 silver and 4 red

    I am using SBA 1.5.4 and ZC 1.5.5a

    Thanks
    Kenton

  4. #2594
    Join Date
    Jul 2012
    Posts
    16,798
    Plugin Contributions
    17

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Quote Originally Posted by Kenton View Post
    Without wanting to get slammed for not searching this thread, which I did, but obviously without the correct search terms, how do I get the stock level so show next to the attribute?

    Ie, http://www.skysports.com.au/index.ph...roducts_id=189 is currently showing 8 total units in stock, but I want it to show 3 black, 1 silver and 4 red

    I am using SBA 1.5.4 and ZC 1.5.5a

    Thanks
    Kenton
    Hard to say with only the version number as there is/was an issue with an option developed by potteryhouse getting added to the system setup. The problem was recently resolved in the version of SBA hosted/continued on at https://github.com/mc12345678/Stock_...butes_Combined. So the long and short of it is if in the option names manager you have something like simple SBA select (dropdown) as an option, then that option supports reporting the quantity of that attribute remaining. If that is already active for your single dropdown, then the settings are in the stock/attribute settings of the configuration menu. If you are using multiple attributes (multiple option names) then that setting is in Dynamic Dropdowns and the first option name above doesn't matter. If using DD, the quantity only appears at the last available selection or in the case of an out-of-stock option at the point where no further stock is available below the current selection.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  5. #2595
    Join Date
    Sep 2011
    Posts
    38
    Plugin Contributions
    0

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Quote Originally Posted by mc12345678 View Post
    So the long and short of it is if in the option names manager you have something like simple SBA select (dropdown) as an option, then that option supports reporting the quantity of that attribute remaining. If that is already active for your single dropdown, then the settings are in the stock/attribute settings of the configuration menu.
    Bingo! .... (except I can't see the images of the different colours now) but I'd much rather have the stock levels shown.

    Thanks for your timely reply

    Kenton

  6. #2596
    Join Date
    Jul 2012
    Posts
    16,798
    Plugin Contributions
    17

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Quote Originally Posted by Kenton View Post
    Bingo! .... (except I can't see the images of the different colours now) but I'd much rather have the stock levels shown.

    Thanks for your timely reply

    Kenton
    That too is addressed in the latest update.

    There is now an option in the configuration menu (again latest update) that permits display of attribute images as positioned/assigned in the option names manager, an option that allows swapping the image with the selected one (and display of the attribute images assigned) and a third position of allowing swapping but hiding the attributes images designated to the option name/values. Currently in the ZC options, there is no selection for hiding of images (requires CSS if an image is assigned to an option value), so instead, an option has been added to SBA to basically disable the attribute images.

    Now before the crowds rejoice on the image swapping, it primarily works only with product with single attribute at the moment. I'm trying to work on a system for multiple attributes, but it is also possible to do/assign swapping through some other code changes for those with multiple attributes.

    Otherwise, at the bottom of the includes/modules/YOUR_TEMPLATE/attributes.php file there is an if statement surrounding I think options_names_images or something similar. Because of that logic, your previous images are not displayed... Either clear that logic out or set the settings in the configuration menu to offer your attribute display.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  7. #2597
    Join Date
    Jul 2016
    Location
    Amsterdam
    Posts
    5
    Plugin Contributions
    0

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Quote Originally Posted by mc12345678 View Post
    Ahhh, check boxes... I can't say that I've done a lot of testing with them (yet)...

    Is there a reason you have chosen to use check boxes instead of any of the other attribute types?

    One reason I ask is because it is possible to add the product to the cart with no checkboxes marked (product is added with a cost of 0.00), it is also possible to add one product with 1 checkbox marked, but if two or more are marked from the same option name then sba has a problem (will work to resolve that regardless of your final decision in this matter.)

    So, in testing the product referenced above, it is possible to add a product to the cart, but not two at the same time when using two or more check boxes.

    If you would prefer to allow a customer to add x quantity of say Bramen & Mango and y quantity of Limoen & Koffie and press the add-to-cart button one time, then I would suggest adding product attributes grid to your installation instead of check boxes for this "arrangement".

    Best mc12345678,

    Thanks for poiting out towards "Grid".
    This is perfect. I was just using checkboxes because in the older ZC 1.5 this works fine.
    Only one comment by using the new SBA with ZC1.5.5!
    The SBA ../admin/invoice is not working perfect. The attributes will not show up on the invoice by printing this invoice.
    Just install the original ../admin/invoice of the ZC 1.5.5 and all is working fine.
    SBA is already preparred in the invoice.

  8. #2598
    Join Date
    Jul 2012
    Posts
    16,798
    Plugin Contributions
    17

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Quote Originally Posted by Tjalling View Post
    Best mc12345678,

    Thanks for poiting out towards "Grid".
    This is perfect. I was just using checkboxes because in the older ZC 1.5 this works fine.
    Only one comment by using the new SBA with ZC1.5.5!
    The SBA ../admin/invoice is not working perfect. The attributes will not show up on the invoice by printing this invoice.
    Just install the original ../admin/invoice of the ZC 1.5.5 and all is working fine.
    SBA is already preparred in the invoice.
    Couple of things, the older SBA didn't have extra code to receive and process the selected options (extra_cart_actions file) and most older versions of this did not fully support mixed attributes which is where the consideration of multiple checkboxes could come to be a problem if allowed primarily in the case of multiple attributes where "mixed" checkboxes come into play. So, the base ZC code was able to handle a checkbox. Also, something I added to provide a better customer experience is a check of the attributes pushed to the cart when pushed. A check could be done when moving to checkout, but that seems to be too late in the process. Anyways, that check didn't consider checkboxes as part of the process. I've found some ways around it but am right now trying to address some deeper operations.

    Yes, the admin/invoice.php file is the first one attempted to use some newer coding to provide the customid. It does appear to have a problem though an older version of it was functional (could use github to look back on the history of the admin/invoice file and see where the current code was first introduced and revert the changes back to that.) I'll be working on that functionality soon as well because the admin side of the customid needs some work to transition to using the data that it has been storing instead of using what currently exists for the catalog side.

    Thank you though for reminding me of that one. I'm going to add it to my list of issues so that I can knock it out for new users to at least have a functional invoice with SBA.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  9. #2599
    Join Date
    Jul 2012
    Posts
    16,798
    Plugin Contributions
    17

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    Quote Originally Posted by mc12345678 View Post
    Couple of things, the older SBA didn't have extra code to receive and process the selected options (extra_cart_actions file) and most older versions of this did not fully support mixed attributes which is where the consideration of multiple checkboxes could come to be a problem if allowed primarily in the case of multiple attributes where "mixed" checkboxes come into play. So, the base ZC code was able to handle a checkbox. Also, something I added to provide a better customer experience is a check of the attributes pushed to the cart when pushed. A check could be done when moving to checkout, but that seems to be too late in the process. Anyways, that check didn't consider checkboxes as part of the process. I've found some ways around it but am right now trying to address some deeper operations.

    Yes, the admin/invoice.php file is the first one attempted to use some newer coding to provide the customid. It does appear to have a problem though an older version of it was functional (could use github to look back on the history of the admin/invoice file and see where the current code was first introduced and revert the changes back to that.) I'll be working on that functionality soon as well because the admin side of the customid needs some work to transition to using the data that it has been storing instead of using what currently exists for the catalog side.

    Thank you though for reminding me of that one. I'm going to add it to my list of issues so that I can knock it out for new users to at least have a functional invoice with SBA.
    Okay, found and corrected the issue(s).

    For all versions of ZC supported by this plugin, on the admin side in admin/includes/classes/observers/class.products_with_attributes_stock.php at/around line 145, change:
    Code:
    $customid = $products_with_attributes_with_stock_class->zen_get_customid($order->products[$i]['id'],$slipInLoopAttribs);
    to:
    Code:
    $customid = $products_with_attributes_stock_class->zen_get_customid($order->products[$i]['id'],$slipInLoopAttribs);
    By removing the additional with_

    in the applicable ZC version, admin/invoice.php

    Around line 190 depending on the ZC version, change:
    Code:
    $customid = ' ' . $products_with_attributes_class->zen_get_customid($order->products[$i]['id'],$attributes) . ' ';
    to:

    Code:
    $customid = ' ' . $products_with_attributes_stock_class->zen_get_customid($order->products[$i]['id'],$attributes) . ' ';
    by adding the word with underscore: stock_

    Both of these issues were introduced when trying to incorporate/reference a variable that previously was individually declared adding more code changes to the files and while there already was a variable declared that just needed to be "shared". Github has been updated with the above edits applied.

    These are the only places that I found the variable incorrectly referenced as above. The error in the logs directory should identify that there was a call to a member function XXX on null. The XXX represents the function attempted to be called. This also results in a partial blank screen the help for which is provided in the FAQ section of this forum.
    Last edited by mc12345678; 30 Jul 2016 at 02:48 PM.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  10. #2600
    Join Date
    May 2006
    Location
    Montana
    Posts
    291
    Plugin Contributions
    20

    Default Re: Stock by Attribute v4.0 addon for v1.3.5-1.3.9

    I am having an issue that is making me pull my hair out! lol

    History... upgrading a 1.5.0 cart to 1.5.4
    Installed latest "combo" version of SBA from github and get an error in logs as follows when going to a product page - which is blank:

    [20-Aug-2016 13:21:11 America/New_York] PHP Parse error: syntax error, unexpected '[' in /home/elkkidsc/public_html/store2/includes/classes/observers/class.products_with_attributes_stock.php on line 671

    When I look at it in Dreamweaver it shows two lines as "red" indicating an error:
    Name:  sba-error.jpg
Views: 241
Size:  50.2 KB

 

 

Similar Threads

  1. Problems with addon: Dynamic Drop Downs for Stock By Attribute
    By Dunk in forum All Other Contributions/Addons
    Replies: 56
    Last Post: 30 Apr 2014, 07:55 PM
  2. MySQL Problem with Product with Attribute Stock addon
    By rtwingfield in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 20 Sep 2011, 03:35 PM
  3. Hide Zero Quantity Attributes with attribute-stock addon
    By leevil123 in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 11 Feb 2010, 05:06 PM
  4. Replies: 4
    Last Post: 22 Jan 2010, 10:43 PM
  5. Price Products in the grid by 'Stock by Attribute' addon?
    By Salixia in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 27 Oct 2009, 06:03 PM

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