Question
Blue Rose
NL
Last activity: 5 Jan 2018 5:28 EST
Refresh issue of openWorkByHandle function used in custom control
I have a requirement to show cases (max 5 cases )in a single column in grid and each case should have hyperlink. So i have written a custom control to form hyperlinks.
Below is the code causing reload issue on dash board showing HTTP403.
<%
ClipboardPage myStepPage = tools.getStepPage();
String CaseID = tools.getActive().getStringValue();
if (CaseID !="")
{
String[] ids = CaseID.split(",");
List<String> idList = Arrays.asList(ids);
Iterator it = idList.iterator();
String Case ="";
while(it.hasNext()){
Case = it.next().toString();
ParameterPage paramPage = tools.getParameterPage();
paramPage.putParamValue("workId", Case);
HashStringMap keys = new HashStringMap();
keys.putString("pxObjClass", "Rule-Obj-Activity");
keys.putString("pyClassName", "@baseclass");
keys.putString("pyActivityName", "getInsKey");
tools.doActivity(keys, myStepPage, paramPage);
//******** Create the URL ********//
tools.appendString("<a href=\"\" " + " onClick=" + "\" openWorkByHandle(" + "\'" + tools.getParamValue("CaseKey") +"\'"+ ","+"\'"+false+"\'"+");"+"\"" +">" + Case +"</a>");
if(it.hasNext()){
tools.appendString(" , ");
}
}
}
%>
Please suggest me why the HTTP403 error is coming. PFA
I have a requirement to show cases (max 5 cases )in a single column in grid and each case should have hyperlink. So i have written a custom control to form hyperlinks.
Below is the code causing reload issue on dash board showing HTTP403.
<%
ClipboardPage myStepPage = tools.getStepPage();
String CaseID = tools.getActive().getStringValue();
if (CaseID !="")
{
String[] ids = CaseID.split(",");
List<String> idList = Arrays.asList(ids);
Iterator it = idList.iterator();
String Case ="";
while(it.hasNext()){
Case = it.next().toString();
ParameterPage paramPage = tools.getParameterPage();
paramPage.putParamValue("workId", Case);
HashStringMap keys = new HashStringMap();
keys.putString("pxObjClass", "Rule-Obj-Activity");
keys.putString("pyClassName", "@baseclass");
keys.putString("pyActivityName", "getInsKey");
tools.doActivity(keys, myStepPage, paramPage);
//******** Create the URL ********//
tools.appendString("<a href=\"\" " + " onClick=" + "\" openWorkByHandle(" + "\'" + tools.getParamValue("CaseKey") +"\'"+ ","+"\'"+false+"\'"+");"+"\"" +">" + Case +"</a>");
if(it.hasNext()){
tools.appendString(" , ");
}
}
}
%>
Please suggest me why the HTTP403 error is coming. PFA
Please let me know same function openWorkByHandle can be called using ajax to avoid this http403 error.