bahar.wadia
Posts: 0
Joined: Wed Aug 07, 2013 2:05 am

Panel Open and Close Events don't fire when part of a Template!

I have a template that has a Panel. The problem is that when I create a Page using this template the Open and Close Events don't fire. As a matter of fact, the Panel does not even show up as a component in the Events section. Also, I cannot add a Panel to a Page created with a Template.

However, if I put some code in the Open and Close Events of the Panel in the Template that code executes, but that is useless.

What am I doing wrong? Please Help!

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

Panel Open and Close Events don't fire when part of a Template!

Hi Bahar.

Unfortunately you can not to access inside the template untill you make "Break appart".

So if you need to make some changes to your template you can do following:

precode

1 Open page.

2 Click on screen component. http://prntscr.com/3ki8uh/direct

3 In properties side bar click on "Break apart page template". http://prntscr.com/3ki8is/direct

/code/pre

That's all.

After these steps your template components will be avaliable for editing.

Regards.

bahar.wadia
Posts: 0
Joined: Wed Aug 07, 2013 2:05 am

Panel Open and Close Events don't fire when part of a Template!

I already know that, but then the changes in the template won't propagate will they?

Seems like a bug or a serious limitation. Which one is it?

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

Panel Open and Close Events don't fire when part of a Template!

Bahar.

If you need to implement common part of the template(with logic inside) you can to do it with editing template.

Follow these steps:

1 Open "templates" and click on your template to open editor. http://prntscr.com/3kj249/direct

2 Template editor will appear.

3 In this editor you can implement all common logic you need for all your pages.

But when you need custom specific logic for certain page - you should to use way described in prev message.

Regards.

bahar.wadia
Posts: 0
Joined: Wed Aug 07, 2013 2:05 am

Panel Open and Close Events don't fire when part of a Template!

It seems like you are missing my point.

I have common logic, more importantly common look and feel. That is why I am using templates. On some screens I need to use a Panel. If I could use the Panel component like any other component and place in the workspace I would not have an issue.

On the other hand, if the Panel events would fire like one would expect when the Panel is placed in the template, because that is the only way a Panel can be placed on a template, it would not be a problem would it?

So once again, is it a bug or a serious limitation. Which one?

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Panel Open and Close Events don't fire when part of a Template!

Hello Bahar,

From appery.io builder you can create events for panel only in template that contains the panel.
But you can create your own event for every child pages youself manually:

code$(document).off("panelopen", '[id="pagePanel_panel_2"]').on( "panelopen", function( event, ui ) {console.log("open");} ); /code

Return to “Issues”