Skip to content
Snippets Groups Projects
Commit 2d428088 authored by Benjamin Ulrich's avatar Benjamin Ulrich :speech_balloon: Committed by Sebastian Pongratz
Browse files

[Projekt: xRM-Sales][TicketNr.: 1081927][Feld "Volumen (€)" im Bereich Details...

[Projekt: xRM-Sales][TicketNr.: 1081927][Feld "Volumen (€)" im Bereich Details im VP sollte nicht editierbar sein sowie automatisch befüllt werden ]
parent 6902540c
No related branches found
No related tags found
No related merge requests found
......@@ -4,6 +4,7 @@
<title>${FORECAST_ENGLISH}</title>
<majorModelMode>DISTRIBUTED</majorModelMode>
<documentation>%aditoprj%/entity/Forecast_entity/documentation.adoc</documentation>
<afterSave>%aditoprj%/entity/Forecast_entity/afterSave.js</afterSave>
<titlePlural>Forecasts</titlePlural>
<recordContainer>db</recordContainer>
<entityFields>
......
import("system.entities");
import("Sql_lib");
import("system.vars");
var objectType = vars.get("$field.OBJECT_TYPE");
if(objectType == "Salesproject")
{
var objectRowId = vars.get("$field.OBJECT_ROWID");
var volume = newSelect("sum(VOLUME)")
.from("FORECAST")
.where("FORECAST.OBJECT_TYPE", "Salesproject")
.and("FORECAST.OBJECT_ROWID", objectRowId)
.cell();
var config = entities.createConfigForUpdatingRows()
.uid(objectRowId)
.addParameter("IgnoreChecklists_param", true)
.fieldValues({"VOLUME": volume})
.entity("Salesproject_entity");
entities.updateRow(config);
}
\ No newline at end of file
......@@ -116,6 +116,7 @@
<outputFormat>#,##0.00</outputFormat>
<inputFormat>#,##0.00</inputFormat>
<groupable v="true" />
<state>READONLY</state>
</entityField>
<entityConsumer>
<name>Organisations</name>
......@@ -868,6 +869,7 @@
<outputFormat>#,##0.00</outputFormat>
<inputFormat>#,##0.00</inputFormat>
<groupable v="true" />
<state>READONLY</state>
<valueProcess>%aditoprj%/entity/Salesproject_entity/entityfields/volumeweighted/valueProcess.js</valueProcess>
</entityField>
<entityAggregateField>
......
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