Page 1 of 1

Problem with hiding and showing elements

Posted: Sun Jan 11, 2015 2:12 pm
by Adam Garbinski

Hello,

I use fadetoggle function to show/hide some interface elements like GRID1 and GRID2 after clicking. It worked fine in previous Appery version but now it only hides GRID1 but does not show GRID2.

I have following script attached to CLICK event on GRID1 ELEMENT:

Image

this script passes variable, allowing to identify which list item was clicked, to another script responsible for hiding/showing list elements:

Image

Looks like now this script is only capable of hiding GRID1 but does not show GRID2 (as you can see fadetoggle function responsible for showing GRID2 is nested in fadetoggle responsible for hiding GRID1).

Steps to reproduce:
1) Open APP.
2) Enter "Banan" into search box and press ENTER.
3) Click on any table displayed in search results. You will see that it will hide this table but will not show the second element.

You can see how it should work in the previous version available here:

http://www.3mamcukier.pl/index.php/3mc

Can you please help me with that issue? My app is called 3MC and is shared with you.


Problem with hiding and showing elements

Posted: Mon Jan 12, 2015 8:41 am
by Evgene Karachevtsev

Hello Adam,

Sorry, I'm not sure that I could reproduce this issue correctly. When I clicked some table, the app freezes and redirects me to another page. Could you please clarify, do you have the same?


Problem with hiding and showing elements

Posted: Mon Jan 12, 2015 6:05 pm
by Adam Garbinski

Hi Evgene,
Did you try to click on this table?
Image


Problem with hiding and showing elements

Posted: Wed Jan 14, 2015 6:16 pm
by Adam Garbinski

Hello Appery
Any news on that issue?


Problem with hiding and showing elements

Posted: Wed Jan 14, 2015 6:33 pm
by Illya Stepanov

Hi Adam -

Sorry, we need some additional time and also we can't fully replicate the behavior that you have described.


Problem with hiding and showing elements

Posted: Wed Jan 14, 2015 9:10 pm
by Adam Garbinski

Thanks for your update IIlya. If you need more details to replicate the issue then let me know.


Problem with hiding and showing elements

Posted: Thu Jan 15, 2015 3:51 am
by Yurii Orishchuk

Hi Adam,

You should use following js code to get root grid element:

pre

listItem.find("[name*='ArtGrid']").closest('[data-wrapper-for]');

/pre

So in your case correct code is:

pre

Code: Select all

 listItem.find("[name*='ArtGrid']").closest('[data-wrapper-for]').fadeToggle( "fast" , "swing", function(){listItem.find("[name*='EqGrid']").closest('[data-wrapper-for]').fadeToggle( "fast" , "swing");}); 

/pre

Regards.


Problem with hiding and showing elements

Posted: Sun Jan 18, 2015 12:40 pm
by Adam Garbinski

Yurii.
Brilliant support! You are the man :-))))