Daamon Posted August 2, 2016 Author Share Posted August 2, 2016 I've had a reply to my issue raised in GitHub, now closed: " This is due to a bug in an old/3rd party skin" - no other information was given, prompting questions: - How do I check what skin is currently in use? - Is it easily changed / how? - And any recommendations on a skin which isn't old or 3rd party / will work OK? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 2, 2016 Share Posted August 2, 2016 Your best result would come with Foundation. I made a lot of cosmetic changes to my Foundation, so I copied it, renamed it to suit myself, and use that on our sites. That way my tweaks don't get over-written with each upgrade. Of course if there IS a change in the Foundation files in an upgrade, I make those edits to my version. Sometimes I can tell what skin someone here on the forum is using by looking at the Source Code. There's usually something with the skin name in it. Bsmither would probably be the one who can spot your skin easily. Please provide your store url. Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 2, 2016 Author Share Posted August 2, 2016 Hi @Dirty Butter. Cheers for the prompt reply. My store URL is:Â http://www.mravic.org.au/shop/ Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 2, 2016 Share Posted August 2, 2016 It's Mican - a v5 skin Any idea how modified it is, or is it basically stock? I never used Mican, but it sure looks stock to me. Bsmither's assessment will be more reliable. Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 2, 2016 Author Share Posted August 2, 2016 I very much doubt if it's heavily modified - as we invariably don't tinker unless we're trying to fix something. I've had a look at the files in the skins\mican\templates directory and all are 19 August 2014 except two dated 26 October 2015: content.profile.php and content.register.php. I can't recall if these were updated for a reason - I'd have to dig through other threads I've started here... Other folders contain files dated 19 August 2014 or even a date in 2012. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 3, 2016 Share Posted August 3, 2016 You could use a file difference program like BeyondCompare to compare the stock Mican skin with yours. Then it would be a matter of backing up your skin file and trying the stock Foundation skin, adding any edits that were required - based on what was not stock in yours. I'd be willing to bet that most, if not all, the Mican changes you have are now part of stock Foundation. Of course there would be cosmetic changes you needed to make, but the site should work properly - you are on 6.0.12 now, aren't you? (There was a flurry of GitHub activity today - that's often an indication that a new upgrade is coming fairly soon.) You don't have to delete your Mican skin - just add in the choice of Foundation while you kick the tires. Â Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 3, 2016 Author Share Posted August 3, 2016 Where do I get a copy of the stock Mican file from? I can't see anywhere in the File Manager structure where it might be. Yes, we're now on CC6012. Does Mican come with CC? If so, what I don't understand is if we're on the latest version, why is this skin still available if it causes issues? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 3, 2016 Share Posted August 3, 2016 A lot of people upgraded to CC v6 but kept their v5 skins. There are changes that have to be made to keep v5 skins working properly - I've seen that from other threads here. But I changed over to Foundation as soon as possible after changing to v6. https://www.cubecart.com/extensions/skins/mican Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 3, 2016 Author Share Posted August 3, 2016 Cheers for the link. It says "compatible with CC6" but yet the last update is 22 April 2015 - before CC6012. So is it compatible with CC6012? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 3, 2016 Share Posted August 3, 2016 I don't know the answer to that. But you were having this issue when you were on 6.0.8, weren't you? Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 3, 2016 Author Share Posted August 3, 2016 Yes, I believe we were. So now I have some more things to explore... Is it just the template I do a file compare on? Or any others: the XML? the script.js? the css style files? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 3, 2016 Share Posted August 3, 2016 Anything that comes in the Mican download is suspect and should be compared. According to the Announcement thread on here 6.0.4 came out in April of 2015. So I guess any v6 past that could "potentially" have v5 skin issues that needed addressing. I've reached the end of any help I can be for you on this. Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 3, 2016 Author Share Posted August 3, 2016 You've been great - thank you! Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 3, 2016 Share Posted August 3, 2016 You're welcome - it remains to be seen just how helpful I've been though - Bsmither's ideas ALWAYS trump any suggestions I can make!!!!! Quote Link to comment Share on other sites More sharing options...
bsmither Posted August 3, 2016 Share Posted August 3, 2016 We need to steer away from bringing a storefront skin into this conversation. Losing data from an order summary while the admin is managing these orders in the backend (admin functions) involves the backend skin found at /admin/skins/default/. Even though an identical bug was (supposedly) fixed with a code change in an admin skin template, the response to this current issue about a bug in a third-party skin is non-sensical. We are still waiting for a report on the analysis of the POST seen in the waterfall from the admin saving the order summary. Also, instruct your staff that when viewing the waterfall, take a screen capture of the entire waterfall window. We will now have a record of most of the activity that we can refer to when additional questions come up. Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 3, 2016 Author Share Posted August 3, 2016 @bsmither Thanks for that and, on reflection, it makes sense. All but 3 of the files in the admin/skins/default/templates folder are dated 16 June 2016. The three older ones all dated 19 August 2014 are licence.error.php, modules.index.php and upgrade.index.php. Elsewhere, ie7.css is dated 19 August 2014. All other files are 16 June 2016. It'll be me doing the analysis on the POST and I'll get the waterfall screen capture too. Thanks! Quote Link to comment Share on other sites More sharing options...
bsmither Posted August 3, 2016 Share Posted August 3, 2016 The three files mentioned are residue from CubeCart 5. They are safe to delete. Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 4, 2016 Author Share Posted August 4, 2016 On 8/2/2016 at 9:14 AM, bsmither said: To view the POSTing, you will need to view the "waterfall". I prefer Firefox with the Firebug addon, but Firefox has its own internal "Network" tab and other browsers have their own set of developer tools. In Firefox, click the menu icon at the upper-right (looks like a hamburger). Select "Developer" (looks like a wrench). Select Network. A new window pops up. View an order that has NOT had the text option values disappear. Visit the Inventory tab. Take notes on the values of textual options -- just in case they disappear. Make some small edit -- perhaps adding a Note that the customer will not see. Save. In the Developer Netork window, you will see the waterfall populate. The first line is the POST. Click once on that line. A new panel opens with the details of that POST. Click the PARAMS tab. In the Request Payload, scroll to where you see: You should be able to find the text-based options. If you don't find what you took notes of earlier, then there is a problem with the HTML page and the variables that the form is POSTing back. @bsmither Above instructions followed. Two files uploaded: 1) Waterfall screenshot, as requested... 2) PARAMS in a .txt file (personal information removed) Next steps? order_params.txt Quote Link to comment Share on other sites More sharing options...
bsmither Posted August 4, 2016 Share Posted August 4, 2016 I find this in the text capture of the PARAMS tab: Lines 132-155: -----------------------------236551371019030 Content-Disposition: form-data; name="inv[2602][product_id]" 55 -----------------------------236551371019030 Content-Disposition: form-data; name="inv[2602][productOptions][18][102]" -----------------------------236551371019030 Content-Disposition: form-data; name="inv[2602][productOptions][17][103]" -----------------------------236551371019030 Content-Disposition: form-data; name="inv[2602][productOptions][16][104]" -----------------------------236551371019030 Content-Disposition: form-data; name="inv[2602][productOptions][15][105]" -----------------------------236551371019030 Content-Disposition: form-data; name="inv[2602][price]" 35.00 The variables (actually called 'keys') that start with inv[2602][productOptions] have as part of the keys a pair of numbers, such as [18][102] and [17][103]. These keys with number-pairs are the text entry boxes. There are no corresponding values (as seen like the product_id and price). So, working on the theory that the HTML of the form is not coded correctly, let's review: /admin/skins/default/templates/element.product_options.php, near line 27: <div class="dymanic_options"> <label for="option_{$option.option_id}" class="return">{$option.option_name}{if $option.required} ({$LANG.common.required}){/if}</label><br> <span rel="{$product.id}"> {if $option.type == '1'} <input type="text" class="text_calc" placeholder="{if $option.price}({$option.symbol}{$option.price}){/if}" name="inv[{$product.id}][productOptions][{$option.option_id}][{$option.assign_id}]" id="option_{$option.option_id}" value="{$option.value}" rel="{$option.symbol}{$option.decimal_price}"> {elseif $option.type == '2'} <textarea class="text_calc" name="inv[{$product.id}][productOptions][{$option.option_id}][{$option.assign_id}]" rel="{$option.symbol}{$option.decimal_price}" placeholder="{if $option.price}({$option.symbol}{$option.price}){/if}" id="option_{$option.option_id}">{$option.value}</textarea> {/if} </span> </div> In the <input type="text"> and the <textarea> lines, each uses {$option.value} (seen near the end of the statement). Please confirm that the code in your copy of this file has {$option.value}. Also: /admin/skins/default/templates/orders.index.php, near line 339: <td> <span class="editable" name="inv[{$product.id}][name]">{$product.name}</span> {include file='templates/element.product_options.php'} </td> Make sure that your copy of this file uses the {includes} statement, and does not have actual code to show the options. Lastly, I have seen evidence of an alternate admin skin available for CubeCart. So, in admin, Store Settings, Layout tab, make sure "Default Admin skin" is set to 'default'. Â Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 4, 2016 Author Share Posted August 4, 2016 8 hours ago, bsmither said: I find this in the text capture of the PARAMS tab: @bsmither Hi. I think I searched for "product options" (with the space), hence not finding anything - sorry for the confusion. 8 hours ago, bsmither said: /admin/skins/default/templates/element.product_options.php, near line 27: Please confirm that the code in your copy of this file has {$option.value}. This appears to be the case. The file "Last Modified Date" is 16 June 2016. Code lines copied below: <input type="text" class="text_calc" placeholder="{if $option.price}({$option.symbol}{$option.price}){/if}" name="inv[{$product.id}][productOptions][{$option.option_id}][{$option.assign_id}]" id="option_{$option.option_id}" value="{$option.value}" rel="{$option.symbol}{$option.decimal_price}"> <textarea  class="text_calc" name="inv[{$product.id}][productOptions][{$option.option_id}][{$option.assign_id}]" rel="{$option.symbol}{$option.decimal_price}" placeholder="{if $option.price}({$option.symbol}{$option.price}){/if}" id="option_{$option.option_id}">{$option.value}</textarea> 8 hours ago, bsmither said: /admin/skins/default/templates/orders.index.php, near line 339: Make sure that your copy of this file uses the {includes} statement, and does not have actual code to show the options. This appears to be the case - note it's "include" not "includes", no "s", in the code. The file "Last Modified Date" is 16 June 2016. Code line copied below: {include file='templates/element.product_options.php'} 8 hours ago, bsmither said: Lastly, I have seen evidence of an alternate admin skin available for CubeCart. So, in admin, Store Settings, Layout tab, make sure "Default Admin skin" is set to 'default'. Confirmed, Admin skin is set as "default" (see screen shot) and this is the only option. Thanks.  Quote Link to comment Share on other sites More sharing options...
bsmither Posted August 4, 2016 Share Posted August 4, 2016 The next step, and possibly the last without getting into some really serious troubleshooting, is to examine the source HTML as received by the browser. You will be able to use the Developer screen, Inspector tab to scroll through the HTML and find the form elements. In the template source, where it has {$option.value}, this placeholder gets populated with the text string -- the text that is missing when getting POSTed. Is there a value for the input (or textarea if that is the type of text entry) in the HTML as seen by the browser? Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 7, 2016 Author Share Posted August 7, 2016 Hi @bsmither. I "think" I've got what you're asking for - I've attached two screenshots: 1) of an order which hasn't been changed and saved, and where the text entries are showing (rego removed, but was present); and 2) an order which has been changed and where the text is no longer appearing. Screenshots are taken with the Inspector showing the HTML. Is this what you were asking for? Â Quote Link to comment Share on other sites More sharing options...
bsmither Posted August 7, 2016 Share Posted August 7, 2016 Almost... On the order that still has text options showing, we need to see the HTML source of the Inventory tab. So, look for this: <div id="order_inventory" class="tab_content"> <h3>Order Inventory</h3> <div style="display: none;"> <span class="actions"> <i class="fa fa-trash" title="Delete"></i> After locating the above, scroll further down a few lines to find: <span class="editable" name="inv[###][name]">name_of_product</span> where ### is a number. Then, just after that, you will find the input of type="text". Be sure to scroll horizontally so we can see the value="???" attribute of the input tag. Quote Link to comment Share on other sites More sharing options...
Daamon Posted August 7, 2016 Author Share Posted August 7, 2016 Hi @bsmither. Two screenshots attached: 1) Order summary showing details (rego removed); 2) Inventory tab (as requested) showing relevant fields - blank, and HTML code. Please note that these Inventory fields have never contained any data ever since I intoroduced them.This is covered in a separate thread: ...but not pursued because having the data in the Order Summary was good enough. Quote Link to comment Share on other sites More sharing options...
bsmither Posted August 7, 2016 Share Posted August 7, 2016 Is what I am looking at above, an order that has never been edited? Are you saying that even for orders that have not been changed, you have never seen the text-based options displayed on the Inventory tab? The General tab uses {$product.options_text} (which is a simple text string), where the Inventory tab uses {$product.options} (which is an array). (Note: in both cases, {$product} is an array element from {$PRODUCTS}.) If this is the case, and we now know that the template code is valid, and that an unedited order will have the necessary data in the database table CubeCart_order_inventory "product_options" and "options_array" columns, then the thing left to discern is where in the controller code the $product's $options array is not getting built. But, before we proceed, please verify that the order shown above has not been administratively edited/saved in any way. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.