potteryhouse / stock_by_attribute_1.5.4

Stock by Attribute for Zen Cart 1.5.3
GNU General Public License v2.0
2 stars 5 forks source link

Read Only Attributes in DD require user action #30

Closed mc12345678 closed 8 years ago

mc12345678 commented 9 years ago

At this time Dynamic Dropdowns are used for multi-attribute product. Further, sequenced dropdowns are the only version of this currently implemented. As part of this the following has been observed and needs to be corrected.

If a product has a read only option name associated with it, then when creating the list of attributes and values to select, the sequenced dropdown option of Dynamic Dropdowns requires the user to select the value(s) that are read only instead of simply displaying the value(s).

Read Only option Names should simply be displayed with their associated option values.

mc12345678 commented 8 years ago

Temporarily corrected through an integration function that prevents displaying Dynamic Dropdowns if the product has attributes that are not yet coded for Dynamic Dropdowns. The function (zen_sba_dd_allowed) is in includes/functions/extra_functions/products_with_attributes.php

if the value returned is false then DD should not be allowed for the product.

mc12345678 commented 8 years ago

Need to allow the usage of the single/simple SBA dropdown if the product has attributes, but all but one is READONLY...

mc12345678 commented 8 years ago

Have incorporated the code to allow display of the additional SBA data for a SBA product if the result is that the product has one selectable attribute and the rest as READONLY. This conversion does not yet account for the possibility that one may change the includes/modules/YOUR_TEMPLATE/attributes.php file to add an id[] to the readonly attribute. Code is being committed to the base code in segments to minimize the number of issues corrected per commit. DD still does not handle READONLY, but at least the user will be notified upon product add if the variation selected is out-of-stock or not.

mc12345678 commented 8 years ago

While DD still needs work to fully incorporate many options, the usage of SBA has come a long way and now at least can handle READONLY attributes. Closing this issue in this repo. As necessary can/will open one at the ongoing site to specifically address Dynamic Dropdowns (DD).

The above is incorporated at: https://github.com/mc12345678/Stock_By_Attributes_Combined/commit/e991db49db42c0cb54246e54558d0c26397d0ecc as part of the master tree at: https://github.com/mc12345678/Stock_By_Attributes_Combined/