<#include "/admin/util/editor/editor.html" /> <#assign senderName = defaultSenderName> <#assign subject = ""> <#assign message = ""> <#assign positionEntryDirectoryIdDemand = -1> <#assign positionEntryDirectoryUserGuid = -1> <#assign sendNotification = true> <#assign idDirectory = -1> <#assign statusText = ""> <#assign baseURL = ""> <#if config?exists> <#assign senderName = config.senderName> <#assign subject = config.subject> <#assign message = config.message> <#assign positionEntryDirectoryIdDemand = config.positionEntryDirectoryIdDemand> <#assign positionEntryDirectoryUserGuid = config.positionEntryDirectoryUserGuid> <#assign idDirectory = config.idDirectory> <#assign statusText = config.statusText> <#assign sendNotification = config.sendNotification> <#assign baseURL = config.baseURL>

#i18n{module.workflow.notifycrm.task_notify_crm_config.title}


<@combo name="idDirectory" items=list_directories default_value=idDirectory />

<#if list_entries_id_demand?exists>

<@combo name="positionEntryDirectoryIdDemand" items=list_entries_id_demand default_value=positionEntryDirectoryIdDemand /> 
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_task_entry_directory_id_demand_comment}

<#if list_entries_user_guid?exists && is_user_attribute_ws_active>

<@combo name="positionEntryDirectoryUserGuid" items=list_entries_user_guid default_value=positionEntryDirectoryUserGuid /> 
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_task_entry_directory_user_guid_comment}

checked="checked" />  #i18n{module.workflow.notifycrm.task_notify_crm_config.label_send_notification.yes} checked="checked" />  #i18n{module.workflow.notifycrm.task_notify_crm_config.label_send_notification.no}


#i18n{module.workflow.notifycrm.task_notify_crm_config.label_crm_webapp_base_url_comment} : ${defaultCRMWebAppBaseURL!}


<#if sendNotification>


#i18n{module.workflow.notifycrm.task_notify_crm_config.label_sender_name_comment}


#i18n{module.workflow.notifycrm.task_notify_crm_config.label_subject_comment}


#i18n{module.workflow.notifycrm.task_notify_crm_config.label_message_comment}


<#if config?exists && config.idDirectory!=-1>
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_directory_comment}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_directory} #i18n{module.workflow.notifycrm.task_notify_crm_config.label_freemarker}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_status} ${status}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_directory_title} ${directory_title}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_directory_description} ${directory_description}

<#if is_user_attribute_ws_active>
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_user_attribute_comment}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_user_attribute} #i18n{module.workflow.notifycrm.task_notify_crm_config.label_freemarker}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_first_name} ${first_name}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_last_name} ${last_name}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_email} ${email}
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_phone_number} ${phone_number}

<#if tasks_list?exists && tasks_list?has_content>
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_tasks_list_comment} <#list tasks_list as task>
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_task_title} #i18n{module.workflow.notifycrm.task_notify_crm_config.label_task_type} #i18n{module.workflow.notifycrm.task_notify_crm_config.label_freemarker}
${task.getTitle( locale )!} ${task.taskType.title!} ${task_${task.id!}}

#i18n{module.workflow.notifycrm.task_notify_crm_config.label_entry_directory_comment} <#list list_entries_freemarker as entry>
#i18n{module.workflow.notifycrm.task_notify_crm_config.label_entry} #i18n{module.workflow.notifycrm.task_notify_crm_config.label_freemarker}
${entry.title!} ${position_${entry.position}}

<@initEditor />