Skip to content
Snippets Groups Projects
Commit dce088c4 authored by Johannes Goderbauer's avatar Johannes Goderbauer Committed by Benjamin Ulrich
Browse files

Campaign: Steps: Layout and presets modified

parent 3bc18f72
No related branches found
No related tags found
No related merge requests found
......@@ -115,6 +115,12 @@
<entityField>
<name>DATE_EDIT</name>
<valueProcess>%aditoprj%/entity/CampaignStep_entity/entityfields/date_edit/valueProcess.js</valueProcess>
<onValueChange>%aditoprj%/entity/CampaignStep_entity/entityfields/date_edit/onValueChange.js</onValueChange>
<onValueChangeTypes>
<element>MASK</element>
<element>PROCESS</element>
<element>PROCESS_SETVALUE</element>
</onValueChangeTypes>
</entityField>
<entityProvider>
<name>CampaignSteps</name>
......@@ -330,6 +336,7 @@
<textInputAllowed v="true" />
<stateProcess>%aditoprj%/entity/CampaignStep_entity/entityfields/predecessorstep_id/stateProcess.js</stateProcess>
<displayValueProcess>%aditoprj%/entity/CampaignStep_entity/entityfields/predecessorstep_id/displayValueProcess.js</displayValueProcess>
<onValueChange>%aditoprj%/entity/CampaignStep_entity/entityfields/predecessorstep_id/onValueChange.js</onValueChange>
<onValueChangeTypes>
<element>MASK</element>
<element>PROCESS</element>
......
import("system.eMath");
import("system.db");
import("system.datetime");
import("system.neon");
import("system.vars");
import("system.result");
import("Sql_lib")
if(vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW )
{
var predecessorStepId = vars.get("$local.value");
if (predecessorStepId)
{
var predecessorEndDate = newSelect("CAMPAIGNSTEP.DATE_END")
.from("CAMPAIGNSTEP")
.where("CAMPAIGNSTEP.CAMPAIGNSTEPID", predecessorStepId)
.cell();
if (predecessorEndDate) {
vars.set("$field.DATE_START", predecessorEndDate);
//special requirement was defined here: whenever the date comes from an predecessor the interval shall be 1 week (and may differ from the intial interval)
vars.set("$field.DATE_END", eMath.addInt(predecessorEndDate, datetime.ONE_WEEK));
}
}
}
\ No newline at end of file
......@@ -28,6 +28,10 @@
<name>e16e3f66-7e80-4796-acca-6018e86e1b88</name>
<entityField>EMPLOYEE_CONTACT_ID</entityField>
</entityFieldLink>
<entityFieldLink>
<name>568fd355-f13f-4b40-801e-614790091fc5</name>
<entityField>PREDECESSORSTEP_ID</entityField>
</entityFieldLink>
<entityFieldLink>
<name>ea21096b-5885-4f5e-8bd6-c45275b25036</name>
<entityField>DATE_START</entityField>
......@@ -48,10 +52,6 @@
<name>981cf207-6e9b-428e-bd81-0d76b4b2f180</name>
<entityField>DESCRIPTION</entityField>
</entityFieldLink>
<entityFieldLink>
<name>568fd355-f13f-4b40-801e-614790091fc5</name>
<entityField>PREDECESSORSTEP_ID</entityField>
</entityFieldLink>
<entityFieldLink>
<name>eff370e3-6805-46ad-ab7f-03d8a6392420</name>
<entityField>STEPMEDIUM</entityField>
......
......@@ -20,7 +20,7 @@
<entityField>#ENTITY</entityField>
</cardViewTemplate>
<genericViewTemplate>
<name>CampaignStepInfosGeneric</name>
<name>Runtime</name>
<editMode v="false" />
<showDrawer v="true" />
<drawerCaption>Runtime</drawerCaption>
......@@ -37,13 +37,19 @@
</fields>
</genericViewTemplate>
<genericViewTemplate>
<name>Predecessor</name>
<name>StepDetails</name>
<showDrawer v="true" />
<drawerCaption>Details</drawerCaption>
<entityField>#ENTITY</entityField>
<fields>
<entityFieldLink>
<name>c5c7eff5-da6d-4664-9bdc-1cae9dcec461</name>
<name>55a75b16-a80d-4f9c-b8ea-127302d1f913</name>
<entityField>PREDECESSORSTEP_ID</entityField>
</entityFieldLink>
<entityFieldLink>
<name>f7ddecfb-60bc-4a94-8905-7da729b32acd</name>
<entityField>STEPMEDIUM</entityField>
</entityFieldLink>
</fields>
</genericViewTemplate>
<genericViewTemplate>
......@@ -61,19 +67,6 @@
</entityFieldLink>
</fields>
</genericViewTemplate>
<genericViewTemplate>
<name>Medium</name>
<editMode v="false" />
<showDrawer v="false" />
<drawerCaption></drawerCaption>
<entityField>#ENTITY</entityField>
<fields>
<entityFieldLink>
<name>723c67c3-d92e-424e-9350-3caa881a5ef0</name>
<entityField>STEPMEDIUM</entityField>
</entityFieldLink>
</fields>
</genericViewTemplate>
<scoreCardViewTemplate>
<name>KeyScoreInfos</name>
<entityField>#ENTITY</entityField>
......
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