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

ActionField1765

Beschrijving: Create leave for employee(s) for a day. Employees are selected in dialog. Custom: Nee

Propertiesbewerken

Property Type Accessor
StartDate DateTime Required
CraftsmanSqlFilter String Optional
Employee Employee Optional
EmployeeSqlFilter String Optional
EndDate DateTime Optional
HourCode HourCode Optional
SkillCategorySqlFilter String Optional

XMLbewerken

<Workflow Name="ActionField1765" Version="2025.07.28" WorkflowType="Standard" xmlns="urn:Ultimo.Framework.Workflow-mapping">
	<Security EditLevel="10" ViewLevel="20" UserContentLevel="30" />
	<Description>Create leave for employee(s) for a day. Employees are selected in dialog.</Description>
	<Properties>
		<Property	Name="StartDate"					Type="DateTime"			Accessor="Required"	Direction="In"						Comment="Use this DateTime to fill in an initial start date in the dialog" />

		<Property	Name="CraftsmanSqlFilter"			Type="String"			Accessor="Optional"	Direction="In"						Comment="Show in the dialog only Craftsmen with this filter" />
		<Property	Name="Employee"						Type="Employee"			Accessor="Optional"	Direction="In"						Comment="Use this Employee as default in the dialog" />
		<Property	Name="EmployeeSqlFilter"			Type="String"			Accessor="Optional"	Direction="In"						Comment="Show in the dialog only Employees with this filter" />
		<Property	Name="EndDate"						Type="DateTime"			Accessor="Optional"	Direction="In"						Comment="Use this DateTime to fill in an initial end date in the dialog" />
		<Property	Name="HourCode"						Type="HourCode"			Accessor="Optional"	Direction="In"						Comment="Use this HourCode as default in the dialog" />
		<Property	Name="SkillCategorySqlFilter"		Type="String"			Accessor="Optional"	Direction="In"						Comment="Show in the dialog only SkillCategories with this filter" />

		<Property	Name="CreatedTimeReservation"		Type="TimeReservation"	Accessor="Internal" />
		<Property	Name="DeletedJobIds"				Type="List[String]"		Accessor="Internal" />
		<Property	Name="DeletedJobSchedulePartsIds"	Type="List[String]"		Accessor="Internal" />
		<Property	Name="Employees"					Type="List[Employee]"	Accessor="Internal" />
		<Property	Name="Recursive"					Type="Boolean"			Accessor="Internal" />
		<Property	Name="TimeslotPattern"				Type="TimeslotPattern"	Accessor="Internal" />
		<Property	Name="UnscheduleJobScheduleParts"	Type="Boolean"			Accessor="Internal"						Default="True"	Comment="If set to False in UserContent Pre, the checkbox 'Unschedule jobs' will be unticked as default." />
	</Properties>
	<Execution>
		<UserContent Name="Pre" />

		<Assign Name="StartDate" Property="${StartDate}" Value="=#setdatetime(#getyear(${StartDate}),#getmonth(${StartDate}),#getday(${StartDate}),0, 0)" />
		<Assign Name="EndDate" Property="${EndDate}" Value="=#setdatetime(#getyear(${StartDate}),#getmonth(${StartDate}),#getday(${StartDate}),23, 59)" />

		<WorkflowCall Name="Validate HourCodes" WorkflowName="HourCode_ValidateAbsenceHourCodes" />

		<SystemDialog Name="AllocateLeaveDialog" DialogName="AllocateLeaveDialog">
			<Parameter	Name="CraftsmanSqlFilter"			Direction="In"		Value="${CraftsmanSqlFilter}" />
			<Parameter	Name="Employee"						Direction="In"		Value="${Employee}" />
			<Parameter	Name="EmployeeSqlFilter"			Direction="In"		Value="EmpCompId='#{Company.Id}' AND (${EmployeeSqlFilter})" />
			<Parameter	Name="SkillCategorySqlFilter"		Direction="In"		Value="${SkillCategorySqlFilter}" />
			<Parameter	Name="EndDate"						Direction="InOut"	Value="${EndDate}"												OutputProperty="${EndDate}" />
			<Parameter	Name="HourCode"						Direction="InOut"	Value="${HourCode}"												OutputProperty="${HourCode}" />
			<Parameter	Name="StartDate"					Direction="InOut"	Value="${StartDate}"											OutputProperty="${StartDate}" />
			<Parameter	Name="UnscheduleJobScheduleParts"	Direction="InOut"	Value="${UnscheduleJobScheduleParts}"							OutputProperty="${UnscheduleJobScheduleParts}" />
			<Parameter	Name="Employees"					Direction="Out"																		OutputProperty="${Employees}" />
			<Parameter	Name="Recursive"					Direction="Out"																		OutputProperty="${Recursive}" />
			<Parameter	Name="TimeslotPattern"				Direction="Out"																		OutputProperty="${TimeslotPattern}" />
		</SystemDialog>

		<Transaction>
			<WorkflowCall Name="TimeReservation_CreateLeaveForEmployee" WorkflowName="TimeReservation_CreateLeaveForEmployee">
				<Parameter	Name="Employees"					Direction="In"		Value="${Employees}" />
				<Parameter	Name="EndDate"						Direction="In"		Value="${EndDate}" />
				<Parameter	Name="HourCode"						Direction="In"		Value="${HourCode}" />
				<Parameter	Name="Recursive"					Direction="In"		Value="${Recursive}" />
				<Parameter	Name="StartDate"					Direction="In"		Value="${StartDate}" />
				<Parameter	Name="TimeslotPattern"				Direction="In"		Value="${TimeslotPattern}" />
				<Parameter	Name="UnscheduleJobScheduleParts"	Direction="In"		Value="${UnscheduleJobScheduleParts}" />
				<Parameter	Name="DeletedJobIds"				Direction="Out"												OutputProperty="${DeletedJobIds}" />
				<Parameter	Name="DeletedJobSchedulePartsIds"	Direction="Out"												OutputProperty="${DeletedJobSchedulePartsIds}" />
			</WorkflowCall>
		</Transaction>

		<When Name="ScheduleMethod" Condition="#{Settings.GraphicOverviewJobScheduler.ScheduleMethod} == JobSequence &amp;&amp; ${DeletedJobIds} != Empty &amp;&amp; ${DeletedJobIds.Count} &gt; 0">
			<Message Name="Show deleted Jobs" MessageCode="3580">
				<Parameter	Name="JobIds"	Direction="In"		Value="${DeletedJobIds}" />
			</Message>
		</When>

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