Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.

Custom Approval Container Issue

Avatar

Level 10

I am creating a Custom Approval container.

The requirement is as simple as having several process related fields at the bottom of the TaskForm container.

I tried to modified the Flex source (as mentioned in the documentation) and it just works. However, the three tabs (Task Details, Form and Attachments) are not shown.

Is this the default behavior? Is it possible to show them in the Custom Approval container?

Thanks for any advise,

Nith

9 Replies

Avatar

Former Community Member

Hi Nith,

The Approval Container was coded that way in the example by using the hideAllContainerView() method.  You can either remove that call or you can  add UI widgets like a button to make calls to the SwfConnector object  to display or hide the views you want using the following methods:

- showTaskDetailsView

- hideTaskDetailsView

- showAttachmentsView

- hideAttachmentsView

- showFormView

- hideFormView

See the SwfConnector page for more details: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/lc/procmgmt/formbridge/SwfConnect....

Hope that helps!

...Gil

Avatar

Level 10

Hi Gil,

I got your point how to make these tabs visible. However, I tried in my implementation which is not working.

My code is something like this: 

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" xmlns:lc="http://www.adobe.com/2006/livecycle" xmlns:ac="*"  creationComplete="lcConnector.setReady();lcConnector.showAttachmentsView()" layout="absolute" >

I called the method on creationComplete event of the main application.

lcConnection is the SwfConnector object.

Is this the right place to invoke this method?

Nith

Avatar

Former Community Member

Hi Nith,


You need to bind it to the setWorkspaceData event and of course remove the hideAllContainersView() function.

Try making the call in a function that is bound to the setWorkspaceData event handler. It works for me:

...

public function returnWorkspaceSession(event:SwfDataEvent):void
{


lcConnector.task = event.task;

lcConnector.showAttachmentsView();
//Configure the form to be displayed in the model component.
model.configureLoadForm(lcConnector);
var fullname:String;
var instructions:String;
instructions = lcConnector.task.instructions;
fullname = lcConnector.getAuthenticatedUser().displayName;
personalMessage.text = 'Hi ' + fullname + '. ' + instructions;
}

....

<!-- Establish communication with LiveCycle Workspace ES2 -->
<lc:SwfConnector id="lcConnector"
formInitialData="handleFormInitialData(event)"
setWorkspaceData="returnWorkspaceSession(event)"
unload="handleUnload()"/>

Hope that helps!

...Gil

Avatar

Level 10

Hi Gil,

Many thanks. It works!

Now there is another issue:

I am able to see all three tabs now. However, If I click on the attachments tab, the form(iframe) is visible on top of the Attachments panel.

The same happens for Task Details tab too. What should I do to hide the Form Area when I click on any other tabs?

Thanks,

Nith

Avatar

Former Community Member

Can you send me your source at gilbertyulivecycle@gmail.com? I'm not seeing this behavior at all.

Avatar

Level 2

Hi All

I am trying to customize the ApprovalContainer to show the attachment view as you discussed, I add the line showAttachmentView() but it didn't work for me still no attachment view.

Also I cannot find  hideAllContainersView() function to remove if it is the cause ???

Any help??

Avatar

Level 2

I found where it is many thanks

Avatar

Former Community Member

Hey Nith,

How did you fix the form area issue? When I click on the other tabs, the form area is still enabled.