SAP ui5 table odata

2020-11-27 15:52:28 浏览数 (1)

代码语言:javascript复制
odataModel.read("/SAPBPMInputData('"   taskId   "')", null, ["$expand=startTypeINPUT/start/DO_SES/Lines"], false, function(data, response){
				// in case the response is incomplete, complement the model with dummy data objects
				ApproveSESComponent.DO_SES.util.ModelBuilder.completeJSONModelAccordingSchema(data, odataModel.getServiceMetadata().dataServices.schema[0], "SAPBPMInputData");
				var oODataJSONModel = new sap.ui.model.json.JSONModel(data);
				oODataJSONModel.setDefaultBindingMode("TwoWay");
				oView.setModel(oODataJSONModel);
				// eases the access for the controller
				oView.setModel(odataModel, "odataModel");
				oTable.setModel(oModel).bindRows("/Lines");
			}, function(oEvent){
				ApproveSESComponent.DO_SES.util.ErrorHandler.handleRequestFailedError(oEvent.response, resourceBundle);
			});

0 人点赞