New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Attribute images not displayed #15
Comments
Images is an aspect covered/addressed by a logged issue in the potteryhouse thread: potteryhouse/stock_by_attribute_1.5.4#29 And comment on line 136 of includes/classes/pad_sba_sequenced_dropdowns.php It has been possible to apply a plugin against SBA to handle such image attributes; however, improvement upon that is needed and to address more than just a single image for a single option name product. If Dynamic Dropdowns are not applied, then the normal image processing is provided regardless of the product being tracked by SBA or not. It is use of DD that does not currently have direct support of images. SBA functions with DD activated or not, the difference is that display and control on the product_info page is limited to standard ZC operation. Attempt to add an invalid SBA tracked product or one that is out-of-stock and not allowed to purchase "out-of-stock" items, then the product is not added to the cart with whatever warnings/notices are normally expected. So sum in total, images are not addressed when Dynamic Dropdowns are presented to the customer. At the moment the thought is that this is to be deferred until Dynamic Dropdowns at least provides the correct html tags with respect to standard ZC attributes. |
If anyone is reading this thread and wants to use attribute images with SBA, here's what you do: a) In includes/modules/YOUR_TEMPLATE/attributes.php, before the NOTIFY_ATTRIBUTES_MODULE_OPTIONS_SQL notifier fires, back up $options_attributes_image (which is clobbered by that notifier). Then restore it afterwards. b) In includes/templates/responsive_sheffield_blue/templates/tpl_modules_attributes.php, at the bottom of the file, if images have not been displayed but $options_attributes_image is not empty, display it. c) Set Admin->Configuration->Stock->SBA Display Attributes Images to true. |
Should not have closed this since people will still have this issue if they want attribute images. |
Better yet, use the latest version of this software (which currently does not include the referenced notifier NOTIFY_ATTRIBUTES_MODULE_OPTIONS_SQL ) and install the software as provided. Therefore such code hacking wouldn't be necessary as suggested/claimed. |
In rearranging code, the variable `$options_attributes_image` became reset on initial pass of every option_name, this causes the attribute image to not be displayed for all image placement settings within the option name manager when the product is not tracked by SBA. Removing the line from a default installed store with this plugin restored the operation of the attributes images and also allowed modifying the display of attribute images based on the setting of `SBA_SHOW_IMAGE_ON_PRODUCT_INFO`; however, all products that had attribute images were affected by the constant. Added a test for if the product is an SBA product to address the associated image controls. This again fixes #15 which somehow became an issue again.
In rearranging code, the variable `$options_attributes_image` became reset on initial pass of every option_name, this causes the attribute image to not be displayed for all image placement settings within the option name manager when the product is not tracked by SBA. Removing the line from a default installed store with this plugin restored the operation of the attributes images and also allowed modifying the display of attribute images based on the setting of `SBA_SHOW_IMAGE_ON_PRODUCT_INFO`; however, all products that had attribute images were affected by the constant. Added a test for if the product is an SBA product to address the associated image controls. This again fixes #15 which somehow became an issue again.
It seems like based on the check in includes/templates/YOUR_TEMPLATE/templates/tpl_modules_attributes.php
you only display images for non-sba products.
The text was updated successfully, but these errors were encountered: