XPage 视图控件链接操作 [英] XPages view control link manipulation
问题描述
我有一个视图控件,并且至少有一列设置了显示为链接"选项.该链接是手动生成的.我想要实现的是添加一个添加到视图列链接的 url 参数.通常的链接是这样的
I have a view control and at least one column has the option "Display as link" set. The link is generated manually. What I want to achieve is to add a url parameter which is added to a view column link. The usual link would like this
"http://host/path/file.nsf/$$OpenDominoDocument.xsp?databaseName=server!!path/file.nsf&documentId=03871DD0B47F88D4C12576AB00623137&action=editDocument"
"http://host/path/file.nsf/$$OpenDominoDocument.xsp?databaseName=server!!path/file.nsf&documentId=03871DD0B47F88D4C12576AB00623137&action=editDocument"
我想要的是:
"http://host/path/file.nsf/$$OpenDominoDocument.xsp?databaseName=server!!path/file.nsf&documentId=03871DD0B47F88D4C12576AB00623137&action=editDocument?param1=value1¶m2=value2¶m2=value2¶m2……"
"http://host/path/file.nsf/$$OpenDominoDocument.xsp?databaseName=server!!path/file.nsf&documentId=03871DD0B47F88D4C12576AB00623137&action=editDocument?param1=value1¶m2=value2&etc..."
必须有一种(大概是简单的)方法来实现这一点 - 不幸的是我不知道如何......任何帮助或提示表示赞赏.
There must be a (presumably easy) way to achieve this - unfortunately I don't know how... Any help or hint is appreciated.
非常感谢.迈克尔
推荐答案
请按照以下步骤操作:1. 转到查看列的所有属性,该列将列值显示为链接.2. 使用以下代码计算 PageUrl.
Follow the below steps: 1. go to All Properties of view Column which displays column values as link. 2. Compute the PageUrl with the below Code.
var col:com.ibm.xsp.component.xp.XspViewColumn = getComponent("viewColumn1");
col.getDocumentUrl()+"¶m1=value1"
这篇关于XPage 视图控件链接操作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!