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

ActionField1891

Beschrijving: Set CcrId from PurchaseRequest to PurchaseRequestLine. Custom: Nee

Propertiesbewerken

Property Type Accessor
PurchaseRequest PurchaseRequest Root

XMLbewerken

<Workflow Name="ActionField1891" Version="2025.07.28" WorkflowType="Standard" xmlns="urn:Ultimo.Framework.Workflow-mapping">
	<Security EditLevel="10" ViewLevel="20" UserContentLevel="30" />
	<Description>Set CcrId from PurchaseRequest to PurchaseRequestLine.</Description>
	<Properties>
		<Property	Name="PurchaseRequest"		Type="PurchaseRequest"				Accessor="Root"		Direction="In" />

		<Property	Name="PurchaseRequestLines"	Type="List[PurchaseRequestLine]"	Accessor="Internal" />
	</Properties>
	<Execution>
		<UserContent Name="Pre" />

		<Transaction>
			<When Name="Check context and status" Condition="${PurchaseRequest.Context} == PurchaseRequestContext.OrderRequest &amp;&amp; ${PurchaseRequest.Status} == PurchaseRequestStatus.Created">
				<Assign Name="Empty StatusRequestedEmployee" Property="${PurchaseRequest.StatusRequestedEmployee}" Value="Empty" />
				<Assign Name="Empty StatusRequestedDate" Property="${PurchaseRequest.StatusRequestedDate}" Value="Empty" />
			</When>

			<GetList Name="Get PurchaseRequestLines" Type="PurchaseRequestLine" OutputProperty="${PurchaseRequestLines}" OrderBy="Id" OrderDirection="Ascending">
				<Filters>
					<PropertyFilter	PropertyName="PurchaseRequest"	Operator="="		PropertyValue="${PurchaseRequest}" />
				</Filters>
			</GetList>

			<ForEach Name="Foreach Line" In="${PurchaseRequestLines}" As="PurchaseRequestLine">
				<Assign Name="Set CostCenter to PurchaseRequestLine" Property="${PurchaseRequestLine.CostCenter}" Value="${PurchaseRequest.CostCenter}" />
			</ForEach>
		</Transaction>

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