Yes that was an issue with the version on the main branch. Try https://github.com/potteryhouse/stoc...12345678_ZC154 which is compatible with both zc 1.5.3 and ZC 1.5.4 as a single download with improvements to handle/address multiple attributes.
Printable View
Yes that was an issue with the version on the main branch. Try https://github.com/potteryhouse/stoc...12345678_ZC154 which is compatible with both zc 1.5.3 and ZC 1.5.4 as a single download with improvements to handle/address multiple attributes.
I would like to ask a question.
I have zencart 1.5.4
Some of my products are made with the same things. The customer can choose from 12 colors. This means that if 1 color is sold out, it is sold out for all these products.
With this add on, can i eather display that color as temperarly not available, or that the color can not be chosen, or...?
Can i do this with this add on?
Ok, I've been merging files into and for zen cart v1.5.4 and for the most part it is pretty straight forward. However, there is one file that really has me puzzled. The admin/includes/classes/order.php file that is part of this plugin is no where near similar in any respects to the same file in zen cart v1.5.4! The zen cart version is a much bigger file in size (over 4 times the amount of code), which has left me wondering what do I do now?
I'm upgrading my store to zen cart v1.5.4 for the latest in security upgrades (good to stay current), and all other plugins I use have merged right in without much difficulty. This one though, which I rely on heavily in my store, has me frustrated and not sure what to do. Does any one have any thoughts or suggestions on a course of action I can take? I can usually find my way around in code pretty well and get things working, but this particular problem kinda has me stumped. Any help would be much appreciated.
Thanks!
Not sure which branch you have downloaded, but the admin/includes/classes/order.php file in the mc12345678_zc154 branch has basically two changes as compared to the ZC 1.5.4 version, which increases the size only slightly. Hopefully files are being compared one for one and not comparing say an admin file against a storeside file.
Changes highlighted below are entered into the sql that begins around line 157.
That's the only (functional) change made to this file... Should be a snap to "merge".Code:// START "Stock by Attributes" added to array products_options_values_id and 'value_id' => $attributes->fields['products_options_values_id'],
$attributes = $db->Execute("select products_options, products_options_values, options_values_price,
price_prefix, products_options_values_id,
product_attribute_is_free
from " . TABLE_ORDERS_PRODUCTS_ATTRIBUTES . "
where orders_id = '" . (int)$order_id . "'
and orders_products_id = '" . (int)$orders_products->fields['orders_products_id'] . "'");
if ($attributes->RecordCount()>0) {
while (!$attributes->EOF) {
$this->products[$index]['attributes'][$subindex] = array('option' => $attributes->fields['products_options'],
'value' => $attributes->fields['products_options_values'],
'value_id' => $attributes->fields['products_options_values_id'],
'prefix' => $attributes->fields['price_prefix'],
'price' => $attributes->fields['options_values_price'],
'product_attribute_is_free' =>$attributes->fields['product_attribute_is_free']);
// END "Stock by Attributes"
I've downloaded the latest from the Stock by Attributes thread. Is this not the right one?
When I looked at the code, I did see the two places you highlighted, but what really gave me pause was the drastically different file sizes.
I think I see where the problem is. I've just checked the file sizes and content of the admin/includes/classes/order.php and the includes/classes/order.php file and it seems they are reversed on my test install. This was supposed to be a clean install from BlueHost, and now I'm wondering what else could possibly be wrong - although the test store does seem to be working with out any problems - although I haven't created an order yet ;-)