Skip to content
Snippets Groups Projects
Commit f813d5d2 authored by Benjamin Ulrich's avatar Benjamin Ulrich :speech_balloon:
Browse files

Merge branch '2021.0_1075968_offercurrency' into '2021.0'

[Projekt: xRM-Sales][TicketNr.: 1075968][Preise in Fremdwährung werden nicht...

See merge request xrm/basic!788
parents 657542ca ab5e9511
No related branches found
No related tags found
No related merge requests found
......@@ -2,5 +2,18 @@ import("system.vars");
import("system.result");
import("system.neon");
import("Offer_lib");
import("system.entities");
result.string(OfferUtils.isEditable(vars.get("$field.STATUS")) ? neon.COMPONENTSTATE_AUTO : neon.COMPONENTSTATE_DISABLED);
\ No newline at end of file
var loadConfig = entities.createConfigForLoadingRows()
.entity("OfferItem_entity")
.addParameter("OfferId_param", vars.get("$field.OFFERID"));
var offerItemCount = entities.getRowCount(loadConfig);
if(offerItemCount > 0)
{
result.string(neon.COMPONENTSTATE_DISABLED);
}
else
{
result.string(OfferUtils.isEditable(vars.get("$field.STATUS")) ? neon.COMPONENTSTATE_AUTO : neon.COMPONENTSTATE_DISABLED);
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment