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

ActionField761

Beschrijving: When Job has linked OperationLoss, set Job.RemarkSmallInt1 to 1, else set Job.RemarkSmallInt1 to 0. Custom: Nee

Propertiesbewerken

Property Type Accessor
JobOperationLoss JobOperationLoss Root

XMLbewerken

<Workflow Name="ActionField761" Version="2025.07.28" WorkflowType="Standard" xmlns="urn:Ultimo.Framework.Workflow-mapping">
	<Security EditLevel="10" ViewLevel="20" UserContentLevel="30" />
	<Description>When Job has linked OperationLoss, set Job.RemarkSmallInt1 to 1, else set Job.RemarkSmallInt1 to 0.</Description>
	<Properties>
		<Property	Name="JobOperationLoss"			Type="JobOperationLoss"	Accessor="Root"		Direction="In" />

		<Property	Name="CountJobOperationLoss"	Type="Int64"			Accessor="Internal" />
	</Properties>
	<Execution>
		<UserContent Name="Pre" />

		<Transaction>
			<Choose Name="IfOperationLossIsExist">
				<When Name="OperationLossExist" Condition="${JobOperationLoss.OperationLoss} != Empty">
					<Assign Name="SetJobRemarkSmallInt1" Property="${JobOperationLoss.Id.Job.RemarkSmallInt1}" Value="1" />
				</When>

				<Otherwise Name="OperationLossIsEmpty">
					<GetCount Name="GetOtherJobOperationLosses" Type="JobOperationLoss" OutputProperty="${CountJobOperationLoss}">
						<Joins>
							<Join	Name="Id.Job"	Alias="job"	Type="InnerJoin" />
						</Joins>
						<Filters>
							<CombinedFilter FilterOperator="And">
								<PropertyFilter	PropertyName="Id.Job"	Operator="="		PropertyValue="${JobOperationLoss.Id.Job}" />
								<NotFilter>
									<PropertyEmptyFilter PropertyName="OperationLoss" />
								</NotFilter>
							</CombinedFilter>
						</Filters>
					</GetCount>

					<Choose Name="IfCountIsNotZero">
						<When Name="CountIsNotZero" Condition="${CountJobOperationLoss} &gt; 0">
							<Assign Name="SetJobRemarkSmallInt1" Property="${JobOperationLoss.Id.Job.RemarkSmallInt1}" Value="1" />
						</When>

						<Otherwise Name="CountIsZero">
							<Assign Name="SetJobRemarkSmallInt1" Property="${JobOperationLoss.Id.Job.RemarkSmallInt1}" Value="0" />
						</Otherwise>
					</Choose>
				</Otherwise>
			</Choose>
		</Transaction>

		<UserContent Name="Post" />
	</Execution>
</Workflow>