import org.joget.apps.app.service.AppUtil;
import org.joget.commons.util.LogUtil;
import javax.servlet.http.HttpServletRequest;
import org.joget.apps.datalist.model.DataList;
import org.joget.apps.datalist.model.DataListActionResult;
/**
* @param httpRequest - HTTP Request object of current HTTP Request.
* @param dataList - Datalist object of the current datalist
* @param rowKeys - A String array of record ID(s) for datalist row(s) that is selected for this action
*
* @return DataListActionResult object contains result for datalist to perform next
*/
public DataListActionResult executeAction(HttpServletRequest httpRequest, DataList dataList, String[] rowKeys) {
DataListActionResult result = new DataListActionResult();
result.setType(DataListActionResult.TYPE_REDIRECT);
result.setUrl("REFERER");
if (rowKeys != null && rowKeys.length > 0) {
for (String key : rowKeys) {
// Continue your code here
/* Sample code:
System.out.println(key);
*/
}
}
return result;
}
return executeAction(httpRequest, datalist, rowKeys); |