在App中引入了新功能导入(已使用某些功能)。与所有其他导入不同,应用程序在此崩溃,无法找到导入。导入已在SEGW中定义,代码已在/ IWBEP / IF_MGW_APPL_SRV_RUNTIME〜EXECUTE_ACTION方法中使用,但应用程序从未到达后端执行点。检查(我相信)导入的存在时应用崩溃。必须是SAPUI5问题,在与Gateway Client一起测试时导入,可以正常工作。有什么想法吗?
函数导入调用代码
// Check locking state
var fetchLockStatus = new Promise(function (resolve, reject) {
var sAgreement = oObject.AgrId;
var sGUID = oParamModel.getProperty("/sessionID");
oModel.callFunction("/Agreement_Lock", {
method: 'GET',
urlParameters: {"Agreement_Code": sAgreement, "Agreement_GUID": sGUID},
success: function(oData, response) {
if (oData.AppAccess !== "Y") {
oParamModel.setProperty("/ClosedState", true);
}
resolve(oData);
},
error: function(oError) { }
});
});
var callFetch = function () {
fetchLockStatus
.then(function (fulfilled) {
})
.catch(function (error) {
});
};
callFetch();
引发异常(调用会触发第7行中的错误(onBindingChange @ Object.controller.js?eval:604)
ODataModel-dbg.js:3932 Uncaught (in promise) undefined
(anonymous) @ ODataModel-dbg.js:3932
(anonymous) @ ODataModel-dbg.js:3631
Promise.then (async)
r._processRequest @ ODataModel-dbg.js:3629
r.callFunction @ ODataModel-dbg.js:3928
(anonymous) @ Object.controller.js?eval:608
_onBindingChange @ Object.controller.js?eval:604
a.fireEvent @ EventProvider-dbg.js:229
B._fireChange @ Binding-dbg.js:247
(anonymous) @ ODataContextBinding-dbg.js:73
r.createBindingContext @ ODataModel-dbg.js:1545
O.initialize @ ODataContextBinding-dbg.js:70
h._bindObject @ ManagedObject-dbg.js:2514
h.bindObject @ ManagedObject-dbg.js:2475
a.bindElement @ Element-dbg.js:1089
_bindView @ Object.controller.js?eval:469
(anonymous) @ Object.controller.js?eval:455
Promise.then (async)
_onObjectMatched @ Object.controller.js?eval:451
a.fireEvent @ EventProvider-dbg.js:229
(anonymous) @ Route-dbg.js:96
Promise.then (async)
_routeMatched @ Route-dbg.js:76
(anonymous) @ Route-dbg.js:150
execute @ signals-dbg.js:93
dispatch @ signals-dbg.js:384
dispatch @ signals-dbg.js:187
parse @ crossroads-dbg.js:186
parse @ Router-dbg.js:255
fnHashChanged @ Router-dbg.js:282
a.fireEvent @ EventProvider-dbg.js:229
H.fireHashChanged @ HashChanger-dbg.js:100
execute @ signals-dbg.js:93
dispatch @ signals-dbg.js:384
dispatch @ signals-dbg.js:187
(anonymous) @ hasher-dbg.js:126
setHash @ hasher-dbg.js:375
H.setHash @ HashChanger-dbg.js:111
navTo @ Router-dbg.js:516
_showObject @ Worklist.controller.js?eval:1151
onPress @ Worklist.controller.js?eval:308
a.fireEvent @ EventProvider-dbg.js:229
a.fireEvent @ Element-dbg.js:593
(anonymous) @ ManagedObjectMetadata-dbg.js:426
(anonymous) @ ListItemBase-dbg.js:801
(anonymous) @ jquery.sap.script-dbg.js:64
setTimeout (async)
delayedCall @ jquery.sap.script-dbg.js:60
L.ontap @ ListItemBase-dbg.js:799
a._handleEvent @ Element-dbg.js:301
U._handleEvent @ UIArea-dbg.js:786
dispatch @ jquery-dbg.js:4737
g @ jquery-mobile-custom-dbg.js:1972
p @ jquery-mobile-custom-dbg.js:2050
dispatch @ jquery-dbg.js:4737
c3.handle @ jquery-dbg.js:4549
trigger @ jquery-dbg.js:7819
(anonymous) @ jquery-dbg.js:7903
each @ jquery-dbg.js:365
each @ jquery-dbg.js:137
trigger @ jquery-dbg.js:7902
P @ jquery-mobile-custom-dbg.js:1543
R @ jquery-mobile-custom-dbg.js:1553
dispatch @ jquery-dbg.js:4737
c3.handle @ jquery-dbg.js:4549
函数导入有错误,如在元数据XML输出中看到的(第一个),其他两个是来自同一XML的随机工作示例
<FunctionImport Name="Agreement_Lock" EntitySet="User_AccessSet" m:HttpMethod="GET" ReturnType="ZCONTRACTS_SRV.User_Access">
<Parameter Name="Agreement_Code" MaxLength="10" Type="Edm.String" Mode="In"/>
<Parameter Name="Agreement_GUID" MaxLength="64" Type="Edm.String" Mode="In"/>
</FunctionImport>
<FunctionImport Name="Get_Global_Access" EntitySet="User_AccessSet" m:HttpMethod="GET" ReturnType="ZCONTRACTS_SRV.User_Access"/>
<FunctionImport Name="Get_Chase_Date" EntitySet="Returned_Chase_dateSet" m:HttpMethod="GET" ReturnType="ZCONTRACTS_SRV.Returned_Chase_date">
<Parameter Name="Agreement_Type" MaxLength="3" Type="Edm.String" Mode="In"/>
<Parameter Name="Action_Date" Type="Edm.DateTime" Precision="7" Mode="In"/>
</FunctionImport>