Hi colleaguesI'm trying to implement next scenario:I have 2 Node.js apps working with a same data. First app hosts a service to input data (let's call it Contracts). Second app is performing (re)calculations for the Contracts on demand.I want to trig...
Hi everyone,
I have an application with OData v2 no-drafts and Fiori Elements with an extended controller of an Object Page. In the Object Page I have a table with some child elements of the main entity (main one is order, child ones are lines of t...
Hi colleagues,
Is there any way in CAP to validate a value agains some range with only one side restricted by just annotations?
unfortunately @assert.range has only 2-sides restriction as per documentation
https://cap.cloud.sap/docs/guides/prov...
Hi colleagues,
usually if multiple errors are expected we throw it like this:
srv.on('CREATE', 'myEntity' req => { if (true) {
req.error(400, 'nope 1');
req.error(400, 'nope 2');
return;
}})
Sometimes though we want to clean up...
Hi colleagues and david.kunz2 especially.
Could you please give an advice of how to throw meaningful errors in CAP actions (Bound one in my case)?
The issue is that an action handler doesn't have a regular req parameter.
The best option I found...
Hi Alex,>> This, by default, doesn't generate a request until you call the submitChanges method.With the create method of ODataListBinding a request is not generated instantly as well but at least a new line appears in the table which doesn't happen ...
Hi dinu.pavithran,thank you, looks like a rough but viable way to go.Should I refer to https://help.sap.com/docs/HANA_SERVICE_CF/7c78579ce9b14a669c1f3295b0d8ca16/20a1569875191014b507cf392724b7eb.htmlhttps://help.sap.com/docs/HANA_SERVICE_CF/7c78579ce...
Thank you, I reproduced successful case. So
this.on('cancelFullPO', this.cancelFullPO); // this will be ignored by CAP, first parameter inside cancelFullPO will be an entity definition, not req
this.on('cancelFullPO', async () => this.cancelFullPO(...
Hi david.kunz2,for me currently the req is definitely the entity definition as you can see below - I printed it in console (also req.error obviously doesn't exist)The difference between your example and my one is that my service is defined by class a...