CVE-2022-3004 (Other, published 2022-09-20T10:15Z)
Description: value: Cross-site Scripting (XSS) - Stored in GitHub repository yetiforcecompany/yetiforcecrm prior to 6.4.0.
Severity: nan (CVSS v3 base score: 5.4)
Weakness: CWE-79 \u2014 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
Repository: https://github.com/yetiforcecompany/yetiforcecrm
Files changed:
config/version.php
layouts/basic/modules/Settings/Workflows/AdvanceFilterCondition.tpl
layouts/basic/modules/Settings/Workflows/CreateEntity.tpl
layouts/basic/modules/Settings/Workflows/EditTask.tpl
layouts/basic/modules/Settings/Workflows/FieldExpressions.tpl
layouts/basic/modules/Settings/Workflows/ListViewContents.tpl
layouts/basic/modules/Settings/Workflows/ListViewHeader.tpl
layouts/basic/modules/Settings/Workflows/SortActionsModal.tpl
layouts/basic/modules/Settings/Workflows/Step1.tpl
layouts/basic/modules/Settings/Workflows/Step2.tpl
layouts/basic/modules/Settings/Workflows/Step3.tpl
layouts/basic/modules/Settings/Workflows/TasksList.tpl
modules/Settings/Workflows/actions/TaskAjax.php
modules/Settings/Workflows/views/EditTask.php
Commit message: Improved worflow panel


Vulnerable code:
	'appVersion' => '6.4.13',
*
							<option value="{$FIELD_MODEL->$columnNameApi()}"
				<input name="{if !empty($SELECTED_FIELD_MODEL)}{$SELECTED_FIELD_MODEL->get('name')}{/if}" data-value="value"
				<input type="hidden" name="column_condition" value="{$CONDITION}" />
<input type="hidden" value="{$REFERENCE_FIELD_NAME}" name="reference_field" id="reference_field" />
																	'assigned_user_id' => \App\Language::translate('LBL_PARENT_OWNER'),
																	'triggerUser' => \App\Language::translate('LBL_TRIGGER_USER',$QUALIFIED_MODULE)
																	]
																]}
							<option value="{$FIELD_MODEL->getName()}"
								data-fieldtype="{$FIELD_MODEL->getFieldType()}"
								data-field-name="{$FIELD_MODEL->getName()}"
								data-reference="{$FIELD_MODEL->isReferenceField()}">
							value="{$SOURCE_MODULE}">{\App\Language::translate('LBL_SOURCE_MODULE', $QUALIFIED_MODULE)}: {\App\Language::translate($SOURCE_MODULE, $SOURCE_MODULE)}</option>
							value="destinyModule::{$RELATED_MODULE_MODEL_NAME}">{\App\Language::translate('LBL_DESTINY_MODULE', $QUALIFIED_MODULE)} {\App\Language::translate($RELATED_MODULE_MODEL_NAME, $RELATED_MODULE_MODEL_NAME)}</option>
						value="{$FIELD_MAP['value']}" />
					<input type="hidden" name="valuetype" value="{$FIELD_MAP['valuetype']}" />
														'assigned_user_id' => \App\Language::translate('LBL_PARENT_OWNER'),
														'triggerUser' => \App\Language::translate('LBL_TRIGGER_USER',$QUALIFIED_MODULE)
														]
													]}
							<option value="{$FIELD_MODEL->getName()}"
								data-field-name="{$FIELD_MODEL->getName()}"
								data-reference="{$FIELD_MODEL->isReferenceField()}">
							value="destinyModule::{$RELATED_MODULE_MODEL->get('name')}">{\App\Language::translate('LBL_DESTINY_MODULE', $QUALIFIED_MODULE)} {\App\Language::translate($RELATED_MODULE_MODEL->get('name'),$RELATED_MODULE_MODEL->get('name'))}</option>
						<option value="{$FIELD_MODEL->getName()}" data-fieldtype="{$FIELD_MODEL->getFieldType()}"
							data-field-name="{$FIELD_MODEL->getName()}"
							data-reference="{$FIELD_MODEL->isReferenceField()}">
				<option value="destinyModule::{$RELATED_MODULE_MODEL->get('name')}">{\App\Language::translate('LBL_DESTINY_MODULE', $QUALIFIED_MODULE)} {\App\Language::translate($RELATED_MODULE_MODEL->get('name'), $RELATED_MODULE_MODEL->get('name'))}</option>
					<input type="hidden" name="module" value="{$MODULE}" />
					<input type="hidden" name="taskType" id="taskType" value="{$TASK_TYPE_MODEL->get('tasktypename')}" />
									type="text" value="{$TASK_MODEL->get('summary')}" />
											value="{if !empty($DAYS)}{$DAYS}{/if}"
													value="{$DATETIME_FIELD->get('name')}">{\App\Language::translate($DATETIME_FIELD->get('label'), $DATETIME_FIELD->getModuleName())}</option>
*
							<span name="{$MODULE_MODEL->get('name')}" class="useFieldElement">
										data-placeholder="{\App\Language::translate('LBL_USE_FIELD',$QUALIFIED_MODULE)}">
											<option value="{$MODULE_FIELD->getName()}">{\App\Language::translate($MODULE_FIELD->get('label'),$MODULE_MODEL->getName())}</option>
								<span name="{$RELATED_MODULE_MODEL->get('name')}" class="useFieldElement">
											data-placeholder="{\App\Language::translate('LBL_USE_FIELD',$QUALIFIED_MODULE)}">
												<option value="{$MODULE_FIELD->getName()}">{\App\Language::translate($MODULE_FIELD->get('label'), $MODULE_FIELD->getModuleName())}</option>
									data-placeholder="{\App\Language::translate('LBL_USE_FUNCTION',$QUALIFIED_MODULE)}">
										<option value="{$FIELD_EXPRESSIONS_KEY}">{\App\Language::translate($FIELD_EXPRESSION_VALUE,$QUALIFIED_MODULE)}</option>
					<br/>
					<br/>
						<p><h5>{\App\Language::translate('LBL_RAW_TEXT',$QUALIFIED_MODULE)}</h5></p>
						<p><h5>{\App\Language::translate('LBL_EXAMPLE_FIELD_NAME',$QUALIFIED_MODULE)}</h5></p>
						<p><h5>{\App\Language::translate('LBL_EXAMPLE_EXPRESSION',$QUALIFIED_MODULE)}</h5></p>
{*<!--
/*********************************************************************************
** The contents of this file are subject to the vtiger CRM Public License Version 1.0
* ("License"); You may not use this file except in compliance with the License
* The Original Code is:  vtiger CRM Open Source
* The Initial Developer of the Original Code is vtiger.
* Portions created by vtiger are Copyright (C) vtiger.
* All Rights Reserved.
*
********************************************************************************/

{strip}
	<div class="template-contents">
		<table border=1 style="font-size:11px; width:100%; table-layout: fixed; border-collapse: collapse;">
			<thead>
                <tr bgcolor=#c0c0c0>
                    <td style="text-align: center">
                        <strong>Item Code</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Item Name</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Quantity</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>List Price</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Item Total</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Discount</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Total After Discount</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Total</strong>
                    </td>
                </tr>
			</thead>
			<tbody>
                <!-- foreach item=LINEITEM from=$RECORD.LINEITEMS -->
                <tr>
                    <td align=right style="text-align: center; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.hdnProductcode} {/literal}   
                    </td>
                    <td align=right style="text-align: center; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.productName} {/literal}   
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.quantity} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.listprice} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.productTotal} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal}{$LINEITEM.discount_amount}{/literal}&nbsp;&nbsp;
                        ({literal}{$LINEITEM.discount_percent}{/literal} %)
                    </td>
					<td align=left style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.totalAfterDiscount} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.netPrice} {/literal}
                    </td>
				</tr>
				<!-- /foreach -->
                <tr>
                    <td colspan=7 style="word-wrap: break-word; text-align: right;">Items Total</td>
                    <td style="text-align: right; word-wrap: break-word;">
                        {literal} {$RECORD.hdnSubTotal} {/literal}
                    </td>
                </tr>
                <tr>
                    <td colspan=7 style="word-wrap: break-word; text-align: right;">Discount({literal}{$RECORD.discount_percentage_final}{/literal}%)</td>
                    <td style="text-align: right; word-wrap: break-word;">
                        {literal}{$RECORD.discountTotal_final}{/literal}
                    </td>
                </tr>
                <tr>
                    <td colspan=7 style="word-wrap: break-word; text-align: right;">Pre Tax Total</td>
                    <td style="text-align: right; word-wrap:  break-word;">
						{literal}{$RECORD.pre_tax_total}{/literal}
                    </td>
                </tr>
                <tr>
                    <td colspan=7 style="word-wrap: break-word; text-align: right;">Tax({literal}{$RECORD.tax_totalpercent}{/literal})%</td>
                    <td style="text-align: right; word-wrap: break-word;">
						{literal}{$RECORD.tax_totalamount}{/literal}
                    </td>
                </tr>
                <tr>
                    <td colspan=7 style="word-wrap: break-word; text-align: right;">
                        <span style="font-weight: bold">GRAND TOTAL</span>
                        <strong style=" word-wrap: break-word;">
                            ({literal}{$RECORD.currency_symbol}{/literal})
                        </strong>
                    </td>
                    <td style="text-align: right; word-wrap: break-word;">
                        <strong style=" word-wrap: break-word;">{literal}{$RECORD.hdnGrandTotal}{/literal}</strong>
                    </td>
				</tr>
			</tbody>
		</table>
	</div>
{/strip}               
{*<!--
/*********************************************************************************
** The contents of this file are subject to the vtiger CRM Public License Version 1.0
* ("License"); You may not use this file except in compliance with the License
* The Original Code is:  vtiger CRM Open Source
* The Initial Developer of the Original Code is vtiger.
* Portions created by vtiger are Copyright (C) vtiger.
* All Rights Reserved.
*
********************************************************************************/

{strip}
	<div class="template-contents">
		<table border=1 style="font-size:11px; width:100%; table-layout: fixed; border-collapse: collapse;">
			<thead>
                <tr bgcolor=#c0c0c0>
                    <td style="text-align: center">
                        <strong>Item Code</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Item Name</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Quantity</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>List Price</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Item Total</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Discount</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Total After Discount</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Tax</strong>
                    </td>
                    <td style="text-align: center">
                        <strong>Total</strong>
                    </td>
                </tr>
			</thead>
			<tbody>
                <!-- foreach item=LINEITEM from=$RECORD.LINEITEMS -->
                <tr>
                    <td align=right style="text-align: center; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.hdnProductcode} {/literal}   
                    </td>
                    <td align=right style="text-align: center; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.productName} {/literal}   
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.quantity} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.listprice} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.productTotal} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal}{$LINEITEM.discount_amount}{/literal}&nbsp;&nbsp;
                        ({literal}{$LINEITEM.discount_percent}{/literal} %)
                    </td>
					<td align=left style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.totalAfterDiscount} {/literal}
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.taxTotal} {/literal}&nbsp; &nbsp;
                        ({literal}{$LINEITEM.item_tax_totalpercent}{/literal} %)
                    </td>
                    <td align=right style="text-align: right; vertical-align : top; word-wrap: break-word;">
                        {literal} {$LINEITEM.netPrice} {/literal}
                    </td>
				</tr>
				<!-- /foreach -->
                <tr>
                    <td colspan=8 style="word-wrap: break-word; text-align: right;">Items Total</td>
                    <td style="text-align: right; word-wrap: break-word;">
                        {literal} {$RECORD.hdnSubTotal} {/literal}
                    </td>
                </tr>
                <tr>
                    <td colspan=8 style="word-wrap: break-word; text-align: right;">Discount({literal}{$RECORD.discount_percentage_final}{/literal}%)</td>
                    <td style="text-align: right; word-wrap: break-word;">
                        {literal}{$RECORD.discountTotal_final}{/literal}
                    </td>
                </tr>
                <tr>
                    <td colspan=8 style="word-wrap: break-word; text-align: right;">Pre Tax Total</td>
                    <td style="text-align: right; word-wrap:  break-word;">
						{literal}{$RECORD.pre_tax_total}{/literal}
                    </td>
                </tr>
                <tr>
                    <td colspan=8 style="word-wrap: break-word; text-align: right;">
                        <span style="font-weight: bold">GRAND TOTAL</span>
                        <strong style=" word-wrap: break-word;">
                            ({literal}{$RECORD.currency_symbol}{/literal})
                        </strong>
                    </td>
                    <td style="text-align: right; word-wrap: break-word;">
                        <strong style=" word-wrap: break-word;">{literal}{$RECORD.hdnGrandTotal}{/literal}</strong>
                    </td>
				</tr>
			</tbody>
		</table>
	</div>
{/strip}               
	<input type="hidden" value="{$ORDER_BY}" id="orderBy" />
	<input type="hidden" value="{$SORT_ORDER}" id="sortOrder" />
							<a {if !($LISTVIEW_HEADER->has('sort'))} class="listViewHeaderValues u-cursor-pointer js-listview_header" data-js="click" data-nextsortorderval="{if $COLUMN_NAME eq $LISTVIEW_HEADER->get('name')}{$NEXT_SORT_ORDER}{else}ASC{/if}" data-columnname="{$LISTVIEW_HEADER->get('name')}" {/if}>{\App\Language::translate($LISTVIEW_HEADER->get('label'), $QUALIFIED_MODULE)}
								{if $COLUMN_NAME eq $LISTVIEW_HEADER->get('name')}&nbsp;&nbsp;<span class="{$SORT_IMAGE}"></span>{/if}</a>
						{if method_exists($LISTVIEW_ENTRY,'getDetailViewUrl')}data-recordurl="{$LISTVIEW_ENTRY->getDetailViewUrl()}" {/if}>
							<td class="listViewEntryValue {$WIDTHTYPE}" data-name="{$LISTVIEW_HEADERNAME}">
														href='{$RECORD_LINK_URL}'
												class="{$RECORD_LINK->get('class')}
												<span class="{$RECORD_LINK->getIcon()}" title="{\App\Language::translate($RECORD_LINK->getLabel(), $QUALIFIED_MODULE)}"></span>
						{else} onclick='window.location.href = "{$MODULE_MODEL->getCreateViewUrl()}"'
						data-url="{Settings_Workflows_Module_Model::getImportViewUrl()}"
								value="{$MODULE_MODEL->getName()}">
						<option value="{$WORKFLOW_ID}">{$ACTION['summary']}</option>
						<option value="{$WORKFLOW_ID}">{$ACTION['summary']}</option>
			<input type="hidden" name="mode" value="Step2"/>
			<input type="hidden" name="parent" value="Settings"/>
			<input type="hidden" class="step" value="1"/>
			<input type="hidden" name="record" value="{$RECORDID}"/>
			<input type="hidden" id="weekStartDay" data-value='{$WEEK_START_ID}'/>
				<br/>
								   value="{\App\Language::translate($MODULE_MODEL->getName(), $MODULE_MODEL->getName())}">
							<input type='hidden' name='module_name' value="{$MODULE_MODEL->get('name')}">
									data-placeholder="Select Module...">
									<option value="{$MODULE_MODEL->getName()}" {if isset($SELECTED_MODULE) && $SELECTED_MODULE == $MODULE_MODEL->getName()} selected {/if}>
							   data-validation-engine='validate[required]' value="{$WORKFLOW_MODEL->get('summary')}"
							   id="summary"/>
										name="execution_condition" {if $EXECUTION_CONDITION eq $LABEL_ID} checked="checked" {/if}	value="{$LABEL_ID}"/>
								</label><br/>
			<br/>
		  class="tpl-Settings-Workflows-Step2 form-horizontal">
		<input type="hidden" name="module" value="Workflows"/>
		<input type="hidden" name="action" value="Save"/>
		<input type="hidden" name="parent" value="Settings"/>
		<input type="hidden" class="step" value="2"/>
		<input type="hidden" name="summary" value="{$WORKFLOW_MODEL->get('summary')}"/>
		<input type="hidden" name="record" value="{$WORKFLOW_MODEL->get('record')}"/>
		<input type="hidden" name="module_name" value="{$WORKFLOW_MODEL->get('module_name')}"/>
		<input type="hidden" name="execution_condition" value="{$WORKFLOW_MODEL->get('execution_condition')}"/>
		<input type="hidden" name="conditions" id="advanced_filter" value=''/>
			   value="{\App\Purifier::encodeHtml(\App\Json::encode($WORKFLOW_MODEL->get('conditions')))}"/>
		<input type="hidden" name="filtersavedinnew" value="{$WORKFLOW_MODEL->get('filtersavedinnew')}"/>
		<input type="hidden" name="schtypeid" value="{$WORKFLOW_MODEL->get('schtypeid')}"/>
		<input type="hidden" name="schtime" value="{$WORKFLOW_MODEL->get('schtime')}"/>
		<input type="hidden" name="schdate" value="{$WORKFLOW_MODEL->get('schdate')}"/>
		<input type="hidden" name="params" value="{\App\Purifier::encodeHtml($WORKFLOW_MODEL->get('params'))}"/>
			   value="{\App\Purifier::encodeHtml(\App\Json::encode($WORKFLOW_MODEL->get('schdayofweek')))}"/>
			   value="{\App\Purifier::encodeHtml(\App\Json::encode($WORKFLOW_MODEL->get('schdayofmonth')))}"/>
			   value="{\App\Purifier::encodeHtml($WORKFLOW_MODEL->get('schannualdates'))}"/>
						<span class="col-md-6"><input type="radio" name="conditionstype" class="alignMiddle" checked=""/>&nbsp;&nbsp;<span
									class="alignMiddle">{\App\Language::translate('LBL_USE_EXISTING_CONDITIONS',$QUALIFIED_MODULE)}</span></span>
													class="alignMiddle recreate"/>&nbsp;&nbsp;<span
									class="alignMiddle">{\App\Language::translate('LBL_RECREATE_CONDITIONS',$QUALIFIED_MODULE)}</span></span>
					<br/>
						<strong>{\App\Language::translate('LBL_CHOOSE_FILTER_CONDITIONS',$MODULE)}</strong></h5>
		<br/>
		<br/><br/>
		<input type="hidden" name="module" value="Workflows"/>
		<input type="hidden" name="record" value="{$RECORD}"/>
		<input type="hidden" class="step" value="3"/>
						   data-url="{$TASK_RECORD->getEditViewUrl()}">{\App\Language::translate($TASK_RECORD->getTaskType()->get('label'), $QUALIFIED_MODULE)}</a>
		<br/>
							<a class="px-2 u-cursor-move js-drag" data-js="ui-sortable-handle"><img class="align-baseline" src="{\App\Layout::getImagePath('drag.png')}" title="{\App\Language::translate('LBL_DRAG',$QUALIFIED_MODULE)}" /></a> <input type="checkbox" class="taskStatus" data-statusurl="{$TASK->getChangeStatusUrl()}" {if $TASK->isActive()} checked="" {/if} />
						<td width="60%">{$TASK->getName()}
										<a data-url="{$TASK->getEditViewUrl()}">
									<a class="deleteTask" data-deleteurl="{$TASK->getDeleteActionUrl()}">
		$workflowId = $request->get('for_workflow');
			$record = $request->get('task_id');
			$taskObject->summary = htmlspecialchars($request->get('summary'));
					'field' => $request->get('select_date_field'),
							$taskObject->{$fieldName} = $request->getRaw($fieldName);
		// Adding option Line Item block for Individual tax mode
		$individualTaxBlockLabel = \App\Language::translate('LBL_LINEITEM_BLOCK_GROUP', $qualifiedModuleName);
		$individualTaxBlockValue = $viewer->view('LineItemsGroupTemplate.tpl', $qualifiedModuleName, true);
		// Adding option Line Item block for group tax mode
		$groupTaxBlockLabel = \App\Language::translate('LBL_LINEITEM_BLOCK_INDIVIDUAL', $qualifiedModuleName);
		$groupTaxBlockValue = $viewer->view('LineItemsIndividualTemplate.tpl', $qualifiedModuleName, true);

		$templateVariables = [
			$individualTaxBlockValue => $individualTaxBlockLabel,
			$groupTaxBlockValue => $groupTaxBlockLabel,
		];
		$viewer->assign('TEMPLATE_VARIABLES', $templateVariables);

Fixed code:
	'appVersion' => '6.4.14',
* Contributor(s): YetiForce S.A.
							<option value="{$FIELD_MODEL->$columnNameApi()|escape}"
				<input name="{if !empty($SELECTED_FIELD_MODEL)}{$SELECTED_FIELD_MODEL->get('name')|escape}{/if}" data-value="value"
				<input type="hidden" name="column_condition" value="{$CONDITION|escape}" />
<input type="hidden" value="{$REFERENCE_FIELD_NAME|escape}" name="reference_field" id="reference_field" />
												'assigned_user_id' => \App\Language::translate('LBL_PARENT_OWNER'),
												'triggerUser' => \App\Language::translate('LBL_TRIGGER_USER',$QUALIFIED_MODULE)
												]
											]}
							<option value="{$FIELD_MODEL->getName()|escape}"
								data-fieldtype="{$FIELD_MODEL->getFieldType()|escape}"
								data-field-name="{$FIELD_MODEL->getName()|escape}"
								data-reference="{$FIELD_MODEL->isReferenceField()|escape}">
							value="{$SOURCE_MODULE|escape}">{\App\Language::translate('LBL_SOURCE_MODULE', $QUALIFIED_MODULE)}: {\App\Language::translate($SOURCE_MODULE, $SOURCE_MODULE)}</option>
							value="destinyModule::{$RELATED_MODULE_MODEL_NAME|escape}">{\App\Language::translate('LBL_DESTINY_MODULE', $QUALIFIED_MODULE)} {\App\Language::translate($RELATED_MODULE_MODEL_NAME, $RELATED_MODULE_MODEL_NAME)}</option>
						value="{$FIELD_MAP['value']|escape}" />
					<input type="hidden" name="valuetype" value="{$FIELD_MAP['valuetype']|escape}" />
												'assigned_user_id' => \App\Language::translate('LBL_PARENT_OWNER'),
												'triggerUser' => \App\Language::translate('LBL_TRIGGER_USER',$QUALIFIED_MODULE)
												]
											]}
							<option value="{$FIELD_MODEL->getName()|escape}"
								data-field-name="{$FIELD_MODEL->getName()|escape}"
								data-reference="{$FIELD_MODEL->isReferenceField()|escape}">
							value="destinyModule::{$RELATED_MODULE_MODEL->get('name')|escape}">{\App\Language::translate('LBL_DESTINY_MODULE', $QUALIFIED_MODULE)} {\App\Language::translate($RELATED_MODULE_MODEL->get('name'),$RELATED_MODULE_MODEL->get('name'))}</option>
						<option value="{$FIELD_MODEL->getName()|escape}" data-fieldtype="{$FIELD_MODEL->getFieldType()|escape}"
							data-field-name="{$FIELD_MODEL->getName()|escape}"
							data-reference="{$FIELD_MODEL->isReferenceField()|escape}">
				<option value="destinyModule::{$RELATED_MODULE_MODEL->get('name')|escape}">{\App\Language::translate('LBL_DESTINY_MODULE', $QUALIFIED_MODULE)} {\App\Language::translate($RELATED_MODULE_MODEL->get('name'), $RELATED_MODULE_MODEL->get('name'))}</option>
					<input type="hidden" name="module" value="{$MODULE|escape}" />
					<input type="hidden" name="taskType" id="taskType" value="{\App\Purifier::encodeHtml($TASK_TYPE_MODEL->get('tasktypename'))}" />
									type="text" value="{\App\Purifier::encodeHtml($TASK_MODEL->get('summary'))}" />
											value="{if !empty($DAYS)}{$DAYS|escape}{/if}"
													value="{$DATETIME_FIELD->get('name')|escape}">{\App\Language::translate($DATETIME_FIELD->get('label'), $DATETIME_FIELD->getModuleName())}</option>
* Contributor(s): YetiForce S.A.
							<span name="{$MODULE_MODEL->get('name')|escape}" class="useFieldElement">
									data-placeholder="{\App\Language::translate('LBL_USE_FIELD',$QUALIFIED_MODULE)}">
											<option value="{$MODULE_FIELD->getName()|escape}">{\App\Language::translate($MODULE_FIELD->get('label'),$MODULE_MODEL->getName())}</option>
								<span name="{$RELATED_MODULE_MODEL->get('name')|escape}" class="useFieldElement">
										data-placeholder="{\App\Language::translate('LBL_USE_FIELD',$QUALIFIED_MODULE)}">
												<option value="{$MODULE_FIELD->getName()|escape}">{\App\Language::translate($MODULE_FIELD->get('label'), $MODULE_FIELD->getModuleName())}</option>
								data-placeholder="{\App\Language::translate('LBL_USE_FUNCTION',$QUALIFIED_MODULE)}">
										<option value="{$FIELD_EXPRESSIONS_KEY|escape}">{\App\Language::translate($FIELD_EXPRESSION_VALUE,$QUALIFIED_MODULE)}</option>
					<br />
					<br />
						<p>
						<h5>{\App\Language::translate('LBL_RAW_TEXT',$QUALIFIED_MODULE)}</h5>
						</p>
						<p>
						<h5>{\App\Language::translate('LBL_EXAMPLE_FIELD_NAME',$QUALIFIED_MODULE)}</h5>
						</p>
						<p>
						<h5>{\App\Language::translate('LBL_EXAMPLE_EXPRESSION',$QUALIFIED_MODULE)}</h5>
						</p>
	<input type="hidden" value="{$ORDER_BY|escape}" id="orderBy" />
	<input type="hidden" value="{$SORT_ORDER|escape}" id="sortOrder" />
							<a {if !($LISTVIEW_HEADER->has('sort'))} class="listViewHeaderValues u-cursor-pointer js-listview_header" data-js="click" data-nextsortorderval="{if $COLUMN_NAME eq $LISTVIEW_HEADER->get('name')}{$NEXT_SORT_ORDER}{else}ASC{/if}" data-columnname="{$LISTVIEW_HEADER->get('name')|escape}" {/if}>{\App\Language::translate($LISTVIEW_HEADER->get('label'), $QUALIFIED_MODULE)}
								{if $COLUMN_NAME eq $LISTVIEW_HEADER->get('name')}&nbsp;&nbsp;<span class="{$SORT_IMAGE|escape}"></span>{/if}</a>
						{if method_exists($LISTVIEW_ENTRY,'getDetailViewUrl')}data-recordurl="{$LISTVIEW_ENTRY->getDetailViewUrl()|escape}" {/if}>
							<td class="listViewEntryValue {$WIDTHTYPE}" data-name="{$LISTVIEW_HEADERNAME|escape}">
														href='{$RECORD_LINK_URL|escape}'
												class="{$RECORD_LINK->get('class')|escape}
												<span class="{$RECORD_LINK->getIcon()|escape}" title="{\App\Language::translate($RECORD_LINK->getLabel(), $QUALIFIED_MODULE)}"></span>
						{else} onclick='window.location.href = "{$MODULE_MODEL->getCreateViewUrl()|escape}"'
						data-url="{Settings_Workflows_Module_Model::getImportViewUrl()|escape}"
								value="{$MODULE_MODEL->getName()|escape}">
						<option value="{$WORKFLOW_ID}">{\App\Purifier::encodeHtml($ACTION['summary'])}</option>
						<option value="{$WORKFLOW_ID}">{\App\Purifier::encodeHtml($ACTION['summary'])}</option>
* Contributor(s): YetiForce S.A.
			<input type="hidden" name="mode" value="Step2" />
			<input type="hidden" name="parent" value="Settings" />
			<input type="hidden" class="step" value="1" />
			<input type="hidden" name="record" value="{$RECORDID}" />
			<input type="hidden" id="weekStartDay" data-value='{$WEEK_START_ID|escape}' />
				<br />
								value="{\App\Language::translate($MODULE_MODEL->getName(), $MODULE_MODEL->getName())}">
							<input type='hidden' name='module_name' value="{$MODULE_MODEL->get('name')|escape}">
								data-placeholder="Select Module...">
									<option value="{$MODULE_MODEL->getName()|escape}" {if isset($SELECTED_MODULE) && $SELECTED_MODULE == $MODULE_MODEL->getName()} selected {/if}>
							data-validation-engine='validate[required]' value="{\App\Purifier::encodeHtml($WORKFLOW_MODEL->get('summary'))}"
							id="summary" />
										name="execution_condition" {if $EXECUTION_CONDITION eq $LABEL_ID} checked="checked" {/if} value="{$LABEL_ID|escape}" />
								</label><br />
			<br />
* Contributor(s): YetiForce S.A.
		class="tpl-Settings-Workflows-Step2 form-horizontal">
		<input type="hidden" name="module" value="Workflows" />
		<input type="hidden" name="action" value="Save" />
		<input type="hidden" name="parent" value="Settings" />
		<input type="hidden" class="step" value="2" />
		<input type="hidden" name="summary" value="{\App\Purifier::encodeHtml($WORKFLOW_MODEL->get('summary'))}" />
		<input type="hidden" name="record" value="{$WORKFLOW_MODEL->get('record')|escape}" />
		<input type="hidden" name="module_name" value="{$WORKFLOW_MODEL->get('module_name')|escape}" />
		<input type="hidden" name="execution_condition" value="{\App\Purifier::encodeHtml($WORKFLOW_MODEL->get('execution_condition'))}" />
		<input type="hidden" name="conditions" id="advanced_filter" value='' />
			value="{\App\Purifier::encodeHtml(\App\Json::encode($WORKFLOW_MODEL->get('conditions')))}" />
		<input type="hidden" name="filtersavedinnew" value="{$WORKFLOW_MODEL->get('filtersavedinnew')|escape}" />
		<input type="hidden" name="schtypeid" value="{$WORKFLOW_MODEL->get('schtypeid')|escape}" />
		<input type="hidden" name="schtime" value="{$WORKFLOW_MODEL->get('schtime')|escape}" />
		<input type="hidden" name="schdate" value="{$WORKFLOW_MODEL->get('schdate')|escape}" />
		<input type="hidden" name="params" value="{\App\Purifier::encodeHtml($WORKFLOW_MODEL->get('params'))}" />
			value="{\App\Purifier::encodeHtml(\App\Json::encode($WORKFLOW_MODEL->get('schdayofweek')))}" />
			value="{\App\Purifier::encodeHtml(\App\Json::encode($WORKFLOW_MODEL->get('schdayofmonth')))}" />
			value="{\App\Purifier::encodeHtml($WORKFLOW_MODEL->get('schannualdates'))}" />
						<span class="col-md-6"><input type="radio" name="conditionstype" class="alignMiddle" checked="" />&nbsp;&nbsp;<span
								class="alignMiddle">{\App\Language::translate('LBL_USE_EXISTING_CONDITIONS',$QUALIFIED_MODULE)}</span></span>
								class="alignMiddle recreate" />&nbsp;&nbsp;<span
								class="alignMiddle">{\App\Language::translate('LBL_RECREATE_CONDITIONS',$QUALIFIED_MODULE)}</span></span>
					<br />
						<strong>{\App\Language::translate('LBL_CHOOSE_FILTER_CONDITIONS',$MODULE)}</strong>
					</h5>
		<br />
		<br /><br />
* Contributor(s): YetiForce S.A.
		<input type="hidden" name="module" value="Workflows" />
		<input type="hidden" name="record" value="{$RECORD}" />
		<input type="hidden" class="step" value="3" />
							data-url="{$TASK_RECORD->getEditViewUrl()|escape}">{\App\Language::translate($TASK_RECORD->getTaskType()->get('label'), $QUALIFIED_MODULE)}</a>
		<br />
							<a class="px-2 u-cursor-move js-drag" data-js="ui-sortable-handle"><img class="align-baseline" src="{\App\Layout::getImagePath('drag.png')}" title="{\App\Language::translate('LBL_DRAG',$QUALIFIED_MODULE)}" /></a> <input type="checkbox" class="taskStatus" data-statusurl="{$TASK->getChangeStatusUrl()|escape}" {if $TASK->isActive()} checked="" {/if} />
						<td width="60%">{\App\Purifier::encodeHtml($TASK->getName())}
										<a data-url="{$TASK->getEditViewUrl()|escape}">
									<a class="deleteTask" data-deleteurl="{$TASK->getDeleteActionUrl()|escape}">
		$workflowId = !$request->isEmpty('for_workflow') ? $request->getInteger('for_workflow') : 0;
			$record = !$request->isEmpty('task_id') ? $request->getInteger('task_id') : 0;
			$taskObject->summary = \App\Purifier::decodeHtml($request->getByType('summary', \App\Purifier::TEXT));
					'field' => $request->getByType('select_date_field', \App\Purifier::ALNUM),
							$taskObject->{$fieldName} = \App\Purifier::decodeHtml($request->getByType($fieldName, \App\Purifier::TEXT));