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

ActionField757

Beschrijving: Find ConditionFlawPresents that are linked to JobEqmId, JobPrfId or parts of these objects and not set to Job. Custom: Nee

Propertiesbewerken

Property Type Accessor
Job Job Root
Context Context? Optional
SearchRecursive Boolean Optional

XMLbewerken

<Workflow Name="ActionField757" Version="2025.07.28" WorkflowType="Standard" xmlns="urn:Ultimo.Framework.Workflow-mapping">
	<Security EditLevel="10" ViewLevel="20" UserContentLevel="30" />
	<Description>Find ConditionFlawPresents that are linked to JobEqmId, JobPrfId or parts of these objects and not set to Job.</Description>
	<Properties>
		<Property	Name="Job"								Type="Job"								Accessor="Root"		Direction="In" />

		<Property	Name="Context"							Type="Context?"							Accessor="Optional"	Direction="In"						Comment="Search only for ConditionFlawPresents with this context" />
		<Property	Name="SearchRecursive"					Type="Boolean"							Accessor="Optional"	Direction="In"		Default="True"	Comment="Search for ConditionFlawPresents which are linked to Partof-Equipoment/ProcessFunction etc." />

		<Property	Name="ConditionFlaw"					Type="ConditionFlaw"					Accessor="Internal" />
		<Property	Name="ConditionFlawType"				Type="ConditionFlawType"				Accessor="Internal" />
		<Property	Name="CountJobConditionFlawPresents"	Type="Int64"							Accessor="Internal" />
		<Property	Name="JobConditionFlawPresents"			Type="List[JobConditionFlawPresent]"	Accessor="Internal" />
		<Property	Name="Material"							Type="Material"							Accessor="Internal" />
	</Properties>
	<Execution>
		<UserContent Name="Pre" />

		<When Name="CouldTakeALotOfTime" Condition="${Job.Equipment} == Empty &amp;&amp; ${Job.ProcessFunction} == Empty ">
			<ContinuationQuestion Name="AreYouSure?" MessageCode="1614">
				<Parameter	Name="Job"	Direction="In"		Value="${Job}" />
			</ContinuationQuestion>
		</When>

		<When Name="Only show this dialog when job has context infra" Condition="${Context} != Empty &amp;&amp; ${Context} == ConditionFlawPresentContext.Infra">
			<Dialog Name="filter on some properties of ConditionFlawPresent" TitleCode="SEARCH_FLAWS">
				<Container>
					<SelectionList Name="ConditionFlaw" OutputProperty="${ConditionFlaw}" ColumnName="ConflId" ViewfieldConfiguration="Default" SqlWhereClause="ConflContext = 2" />

					<SelectionList Name="ConditionFlawType" OutputProperty="${ConditionFlawType}" ColumnName="ConfltId" ViewfieldConfiguration="Default" SqlWhereClause="ConfltContext = 2" />

					<SelectionList Name="Material" OutputProperty="${Material}" ColumnName="MatId" ViewfieldConfiguration="Default" />
				</Container>
			</Dialog>
		</When>

		<Transaction>
			<GetList Name="List JobConditionFlawPresents by Job" Type="JobConditionFlawPresent" OutputProperty="${JobConditionFlawPresents}" OrderBy="Id" OrderDirection="Ascending">
				<Filters>
					<PropertyFilter	PropertyName="Id.Job"	Operator="="		PropertyValue="${Job}" />
				</Filters>
			</GetList>

			<ForEach Name="Delete all JobConditionFlawPresents" In="${JobConditionFlawPresents}" As="JobConditionFlawPresent">
				<DeleteObject Name="Delete JobConditionFlawPresent" DomainObject="${JobConditionFlawPresent}" />
			</ForEach>

			<WorkflowCall Name="Search For ConditionFlawPresents by Job and Equipment" WorkflowName="Job_SearchForConditionFlawPresents">
				<Parameter	Name="ConditionFlaw"		Direction="In"		Value="${ConditionFlaw}" />
				<Parameter	Name="ConditionFlawType"	Direction="In"		Value="${ConditionFlawType}" />
				<Parameter	Name="Context"				Direction="In"		Value="${Context}" />
				<Parameter	Name="Equipment"			Direction="In"		Value="${Job.Equipment}" />
				<Parameter	Name="Job"					Direction="In"		Value="${Job}" />
				<Parameter	Name="Material"				Direction="In"		Value="${Material}" />
				<Parameter	Name="ProcessFunction"		Direction="In"		Value="${Job.ProcessFunction}" />
				<Parameter	Name="SearchRecursive"		Direction="In"		Value="${SearchRecursive}" />
			</WorkflowCall>

			<GetCount Name="GetNumberOfJobConditionFlawPresents" Type="JobConditionFlawPresent" OutputProperty="${CountJobConditionFlawPresents}">
				<Filters>
					<PropertyFilter	PropertyName="Id.Job"	Operator="="		PropertyValue="${Job}" />
				</Filters>
			</GetCount>
		</Transaction>

		<UserContent Name="Post" />

		<When Name="CountIsZero" Condition="${CountJobConditionFlawPresents} == 0">
			<Message Name="NoJobConditionFlawPresentsFound" MessageCode="1227" />
		</When>
	</Execution>
</Workflow>