on 2024 Oct 03 9:05 AM
Hello,
We are uploading Excel data to backend via Function import, in Fiori side via Batch call we are sending payload data.
oModel.callFunction("/uploadBudgetInfo", {
method: "POST",
batchGroupId: "batchFunctionImport",
urlParameters: testUrlParam[i],
changeSetId: "test",
});
oModel.submitChanges({
batchGroupId: "batchFunctionImport", //Same as the batch group id used previously
success: function (oData,response) {
var res = oData;
}.bind(this),
error: function (oError) {
var err = oError;
}
});
But we are getting BatchResponse with 1 collection returntype - cds_zwbsbudget_release.ZD_UPLOADBUDGET_LOG as below -
Function import in Metadata as below,
<FunctionImport Name="uploadBudgetInfo" ReturnType="Collection(cds_zwbsbudget_release.ZD_UPLOADBUDGET_LOG)" m:HttpMethod="POST" sap:action-for="cds_zwbsbudget_release.BudgetType" sap:applicable-path="uploadBudgetInfo_ac">
<Parameter Name="objnr" Type="Edm.String" Mode="In" MaxLength="22" sap:label="Object Number"/>
<Parameter Name="Amount" Type="Edm.String" Mode="In" Nullable="true"/>
<Parameter Name="Currency" Type="Edm.String" Mode="In" MaxLength="5" Nullable="true" sap:label="Transaction Currency"/>
<Parameter Name="status" Type="Edm.String" Mode="In" MaxLength="1" Nullable="true"/>
<Parameter Name="msg_txt" Type="Edm.String" Mode="In" Nullable="true"/>
</FunctionImport>
Please let me know how can I get response data from cds_zwbsbudget_release.ZD_UPLOADBUDGET_LOG, as per ABAP team log is storing inside this.
We are using BAS project and OData V2 service using ABAP RAP.
Request clarification before answering.
Any reason you use a callfunction? A post to an entity for each line would also work.
Regarding your question, it depends on the backend implementation. They need to return this.
A suggestion, have you looked into the spreadsheet importer of @Former Member ? https://spreadsheet-importer.com
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
31 | |
9 | |
8 | |
6 | |
6 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.