Be sure your post includes:
Hello there,
1. Isomorphic SmartClient/SmartGWT Framework (v8.3p_2013-12-07/PowerEdition)
2. Browser - Firefox 26
4. //isc_RPCResponseStart-->[{invalidateCache:false,isDSResponse:true,operationType:"add",queueStatus:0,status:0,data:null}]//isc_RPCResponseEnd
6. My client side code is as follows where I am sending some data to the server to just print out the output. But when it returns from the server I get a empty listgrid record. what is the cause for this.
and on the server side my add method is very simple for now where I am just printing the data I received from the client
Hello there,
1. Isomorphic SmartClient/SmartGWT Framework (v8.3p_2013-12-07/PowerEdition)
2. Browser - Firefox 26
4. //isc_RPCResponseStart-->[{invalidateCache:false,isDSResponse:true,operationType:"add",queueStatus:0,status:0,data:null}]//isc_RPCResponseEnd
6. My client side code is as follows where I am sending some data to the server to just print out the output. But when it returns from the server I get a empty listgrid record. what is the cause for this.
Code:
if (fieldName.equals("Approve")) { IButton button = new IButton(); button.setHeight(18); button.setWidth(65); button.setTitle("Approve"); button.addClickHandler(new ClickHandler() { public void onClick(ClickEvent event) { DebugTools.print("SOID " + record.getAttribute("supplierOrderID") + " SODID" + record.getAttribute("sodID")+" sordID "+record.getAttribute("sordID")); approveProduct(record.getAttribute("supplierOrderID"), record.getAttribute("sodID"),record.getAttribute("sordID")); } private void approveProduct(String supplierOrderID, String sodID, String sordID) { Record record = new Record(); record.setAttribute("supplierOrderID", supplierOrderID); record.setAttribute("sodID", sodID); record.setAttribute("sordID",sordID); historyGrid.addData(record, callback); } DSCallback callback = new DSCallback() { @Override public void execute(DSResponse response, Object rawData, DSRequest request) { Record[] records = response.getData(); if (records != null && records.length > 0) { Record record = records[0]; JavaScriptObject js = record.getJsObj(); JSONObject json = new JSONObject(js); System.out.println(" RETURNED APPROVED PRODUCT FROM SORA FRAME!! " + json.toString()); System.out.println(" records.length " + records.length); for (int i = 0; i < records.length; i++) { Record recordd = records[i]; JavaScriptObject jss = recordd.getJsObj(); JSONObject jsonn = new JSONObject(jss); System.out.println(jsonn.toString()); } } } };
and on the server side my add method is very simple for now where I am just printing the data I received from the client
Code:
public DSResponse add(DSRequest dsRequest) throws Exception { DSResponse dsResponse = new DSResponse(); Long user_idlong = SessionUtills.getSessionUser(dsRequest.getHttpServletRequest()); System.out.println("sodID " + dsRequest.getFieldValue("sodID").toString()); System.out.println("PRODUCT APPROVED !!!!!!!!!!!!!" + " SUPPLIER ORDER ID " + dsRequest.getFieldValue("supplierOrderID").toString()); return dsResponse; }
Comment