留言板

AlloyUI Dialog in liferay 6.1

thumbnail
Tom Mahy,修改在11 年前。

AlloyUI Dialog in liferay 6.1

Regular Member 帖子: 103 加入日期: 11-5-11 最近的帖子
Hi,

In liferay 6.0.6 i create a dialog in this way :

var dialog_add_link = new A.Dialog({
				contentBox: '#idhere',
				centered: true,
				constrain2view: true,
				destroyOnClose: true,
				draggable: true,
				width: 550,
				resizable: false,
				stack: true,
				close: false,
				title: "title",
				buttons: [ { text : "save" , handler : function(){ 
								saveLink();
						   }},
				           { text : "cancel" , handler : function(){ 
				        	   	window.location.reload();
				           }}]
				}).render();


This works fine. But in liferay 6.1 the text on the buttons doesn't appear.
I went to check the liferay alloyui site. But the doc tells me i'm doing it right.

Does anyone know what im doing wrong here ?
thumbnail
Mayur Patel,修改在11 年前。

RE: AlloyUI Dialog in liferay 6.1 (答复)

Expert 帖子: 358 加入日期: 10-11-17 最近的帖子
Hey Tom,

I faced same problem today emoticon

You need to use label instead of text, Alloy 3.3 has came with new APIs and modification in existing apis.

 buttons: [ { [b]label[/b]: "save" , handler : function(){ 
                                saveLink();
                           }},
                           { [b]label[/b]: "cancel" , handler : function(){ 
                                   window.location.reload();
                           }}]
}).render();


Refer below for source,
http://deploy.alloyui.com/api

Thanks.
thumbnail
Tom Mahy,修改在11 年前。

RE: AlloyUI Dialog in liferay 6.1

Regular Member 帖子: 103 加入日期: 11-5-11 最近的帖子
Thanks. This works fine.
thumbnail
Mahdi Lashkari,修改在11 年前。

RE: AlloyUI Dialog in liferay 6.1

New Member 帖子: 7 加入日期: 12-5-2 最近的帖子
I faced this problem too, thanks a lot!!
thumbnail
Mayur Patel,修改在11 年前。

RE: AlloyUI Dialog in liferay 6.1

Expert 帖子: 358 加入日期: 10-11-17 最近的帖子
Great to hear this !!! but this is the problem with Alloy-UI not having proper documents, Keeping Outdated API Docs/Posts also creating problem,

Liferay has to come with process to make it more user friendly.

Thanks.
thumbnail
Abhimanyu Saraswat,修改在11 年前。

RE: AlloyUI Dialog in liferay 6.1

Junior Member 帖子: 62 加入日期: 13-2-26 最近的帖子
HI,

I am getting a strange problem can anyone help?
There is a form in the popup I have created which also contains a submit button. When I click on the submit button of this popup it closes. Is there a way out so that the popup does not close after submit.
This is a weird or very simple problem/requirement. Can any one please take out some time to help.

Thanks & Regards
Rahul Saraswat