Closed sprankhub closed 5 years ago
Hi Simon, Thanks for me this is working locally - are you seeing any JS errors? Can you copy and paste to me the full output once you click "Insert widget" interested mainly to see if the positions="0" which should be the default or if it's completely empty.
Checked it again. Seems to be a much smaller problem as I initially thought. I somehow had empty positions like that (no idea why):
{{widget type="theextensionlab_megamenu/widget_attribute_list" category_id="23" option_ids="{\"133\":[{\"position\":\"\"}],\"172\":[{\"position\":\"\"}]}" display_on="small,medium,large" list_columns="1" template="theextensionlab/megamenu/attributes/list.phtml"}}
If you now edit this widget, only edit the positions of the selected attribute options and save, the positions will not be saved. The code will remain the same.
Thanks for the update, can see this now in Chrome, I should have a fix for you by this time tomorow (aslong as it's not super complicated).
Quick update, i've narrowed the issue down to a few lines in the loop clone.each(function(pair) { in our json/serializer.js. But still working on it.
Currently unable to figure this one out i'm afraid. It looks like in certain browsers if you just go to update the position it doesn't update untill you check and uncheck that row. This is something todo with the toJSON rather than toQueryString that we are using not taking into account the new values on webkit browsers
Will get there but it may take me a while, in the meantime does the job in firefox or you can just update the outputted code directly.
No worries, I think it is not really THAT important. I initially thought the problem is more serious, but now it is just a tiny unimportant bug.
If I try to insert the widget
theextensionlab_megamenu/widget_attribute_list
, select some attribute options and enter a position, the position is not written to the generated markup. It shows the position attribute, but does not show the position value.