Categorie: reference Bijgewerkt: 2026-04-08 actionfield workflow actionfield1019

ActionField1019

Beschrijving: Create new Job (TaskPackage) for YearPlanScenarioLines linked to YearPlan. Custom: Nee

Propertiesbewerken

Property Type Accessor
YearPlan YearPlan Root
GotoJobScreen Boolean Optional

XMLbewerken

<Workflow Name="ActionField1019" Version="2025.07.28" WorkflowType="Standard" xmlns="urn:Ultimo.Framework.Workflow-mapping">
	<Security EditLevel="10" ViewLevel="20" UserContentLevel="30" />
	<Description>Create new Job (TaskPackage) for YearPlanScenarioLines linked to YearPlan.</Description>
	<Properties>
		<Property	Name="YearPlan"									Type="YearPlan"										Accessor="Root"		Direction="In" />

		<Property	Name="GotoJobScreen"							Type="Boolean"										Accessor="Optional"	Direction="In"		Default="True"	Comment="Open Job screen with the created Job" />

		<Property	Name="Job"										Type="Job"											Accessor="Internal" />
		<Property	Name="YearPlanScenarioLineMaintenanceMoments"	Type="List[YearPlanScenarioLineMaintenanceMoment]"	Accessor="Internal" />
	</Properties>
	<Execution>
		<UserContent Name="Pre" />

		<Transaction>
			<GetList Name="Get YearPlanScenarioLineMaintenanceMoments having the propert Connect set" Type="YearPlanScenarioLineMaintenanceMoment" OutputProperty="${YearPlanScenarioLineMaintenanceMoments}" OrderBy="Id" OrderDirection="Ascending">
				<Filters>
					<PropertyFilter	PropertyName="Id.YearPlanScenarioLine.Id.YearPlanScenario.Id.YearPlan"	Operator="="		PropertyValue="${YearPlan}" />
					<PropertyFilter	PropertyName="Connect"													Operator="="		PropertyValue="True" />
				</Filters>
			</GetList>
		</Transaction>

		<Validation Name="Check whether any lines have been selected" Condition="${YearPlanScenarioLineMaintenanceMoments.Count} &gt; 0" MessageCode="1978" />

		<ForEach Name="call wf for each YearPlanScenarioLineMaintenanceMoment" In="${YearPlanScenarioLineMaintenanceMoments}" As="YearPlanScenarioLineMaintenanceMoment">
			<WorkflowCall Name="YearPlanScenarioLine_AddToNewJob" WorkflowName="YearPlanScenarioLine_AddToNewJob">
				<Parameter	Name="YearPlanScenarioLine"	Direction="In"		Value="${YearPlanScenarioLineMaintenanceMoment.Id.YearPlanScenarioLine}" />
				<Parameter	Name="Job"					Direction="InOut"	Value="${Job}"																OutputProperty="${Job}" />
			</WorkflowCall>

			<Transaction>
				<Assign Name="reset Connect" Property="${YearPlanScenarioLineMaintenanceMoment.Connect}" Value="False" />
				<Assign Name="reset Disconnect" Property="${YearPlanScenarioLineMaintenanceMoment.Disconnect}" Value="False" />
			</Transaction>
		</ForEach>

		<UserContent Name="Post" />

		<When Name="WhenGotoJobScreen" Condition="${GotoJobScreen} == True">
			<View Name="OpenScreen" ViewName="DataEntryScreen">
				<Parameter	Name="DomainObject"			Direction="In"		Value="${Job}" />
				<Parameter	Name="FocusEditableField"	Direction="In"		Value="=${Job.Description} == Empty" />
			</View>
		</When>
	</Execution>
</Workflow>