araskin3i
Posts: 0
Joined: Fri Dec 20, 2013 2:44 pm

How to programmatically expand a collapsible section

I am trying to programmatically expand out a collapsible section by calling

Appery("MenuDetail_collapseBlockCategories_0").trigger('expand');

but nothing happens on my screen. Is there a bug around this that I am not aware of?

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

How to programmatically expand a collapsible section

Hi,

Are there any console errors (F12)? This is correct if "MenuDetail_collapseBlockCategories_0" component exists.

araskin3i
Posts: 0
Joined: Fri Dec 20, 2013 2:44 pm

How to programmatically expand a collapsible section

Hi Katya,

Thanks for responding. Unfortunately there are no console error. I debugged through it to make sure that the code was being executed. Indeed it was but the problem is nothing actually happened on the screen.

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

How to programmatically expand a collapsible section

Please check in Appery.io UI, probably your collapsible block has another name.

araskin3i
Posts: 0
Joined: Fri Dec 20, 2013 2:44 pm

How to programmatically expand a collapsible section

I considered this. Please take a look at the attached screen shot. Is this the DIV I should be calling the expand event on? Image

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

How to programmatically expand a collapsible section

See attribute 'name'. You should use collapseBlockCategories.

araskin3i
Posts: 0
Joined: Fri Dec 20, 2013 2:44 pm

How to programmatically expand a collapsible section

Thanks Katya. This is correct. I was passing in the ID but that did not work. Once i passed in the 'name' it worked great.

Appery("collapseBlockCategories_0").trigger('expand');

Return to “Issues”