Hi Isomorphic,
I have a problem in my application (v12.0p_2020-03-11) when I explicitly name "fetch" as operationId to use in an exportData() call.
Here this happens on the server side:
Important note: I do not have an explicit operationBinding like this:
Something strange also happens in the showcase sample (v12.0p_2020-04-12), where with operationId: "fetch" in the normal request, the JSON-export operationBinding is used serverside (resulting in a downloaded file named "Results.json").
This might be related, although I'm not sure:
Best regards
Blama
I have a problem in my application (v12.0p_2020-03-11) when I explicitly name "fetch" as operationId to use in an exportData() call.
Here this happens on the server side:
Code:
16:54:53.564 [https-openssl-nio-443-exec-8] ERROR com.lmscompany.lms.server.LMSIDACall - com.lmscompany.lms.server.LMSIDACall top-level exception java.lang.ClassCastException: java.lang.String cannot be cast to java.util.Map at com.isomorphic.rpc.RPCManager.completeResponse(RPCManager.java:1093) ~[isomorphic_core_rpc.jar:?] at com.isomorphic.rpc.RPCManager.send(RPCManager.java:723) ~[isomorphic_core_rpc.jar:?] at com.isomorphic.servlet.IDACall.processRPCTransaction(IDACall.java:183) ~[isomorphic_core_rpc.jar:?] at com.lmscompany.lms.server.LMSIDACall.processRequest(LMSIDACall.java:54) [classes/:?] at com.isomorphic.servlet.IDACall._processRequest(IDACall.java:119) [isomorphic_core_rpc.jar:?] at com.isomorphic.servlet.IDACall.doPost(IDACall.java:79) [isomorphic_core_rpc.jar:?] at javax.servlet.http.HttpServlet.service(HttpServlet.java:660) [servlet-api.jar:?] at com.isomorphic.servlet.BaseServlet.service(BaseServlet.java:176) [isomorphic_core_rpc.jar:?] at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) [servlet-api.jar:?]
Code:
<operationBinding operationType="fetch" operationId="fetch" />
Something strange also happens in the showcase sample (v12.0p_2020-04-12), where with operationId: "fetch" in the normal request, the JSON-export operationBinding is used serverside (resulting in a downloaded file named "Results.json").
This might be related, although I'm not sure:
Code:
isc.ListGrid.create({ ID: "countryList", width:500, height:250, top:70, alternateRecordStyles:true, dataSource: worldDSExport, autoFetchData: true, fields:[ {name:"countryName", title:"Country"}, {name:"capital", title:"Capital"}, {name:"continent", title:"Continent"}, {name:"independence", title:"Nationhood", width:100}, {name:"population", title:"Population"} ], showFilterEditor: true }); isc.DynamicForm.create({ ID: "exportForm", width:300, fields: [ { name: "exportType", title: "Export Type", type:"select", width:"*", defaultToFirstOption: true, valueMap: { "csv" : "CSV" , "xml" : "XML", "json" : "JSON", "xls" : "XLS (Excel97)", "ooxml" : "OOXML (Excel2007)" } }, { name: "showInWindow", title: "Show in Window", type: "boolean", align:"left" } ] }); isc.Button.create({ ID: "exportButton", title: "Export", left: 320, click: function () { var exportAs = exportForm.getField("exportType").getValue(); var showInWindow = exportForm.getField("showInWindow").getValue(); if (exportAs == "json") { // JSON exports are server-side only, so use the OperationBinding on the DataSource countryList.exportData({ operationId: "customJSONExport", exportDisplay: showInWindow ? "window" : "download"}); } else { // exportAs is not JSON, so we can set that with requestProperties countryList.exportData({ exportAs: exportAs, [B]operationId: "fetch",[/B] exportDisplay: showInWindow ? "window" : "download" }); } } });
Blama
Comment