2017-10-03 10:49:19 -04:00
|
|
|
{{#d-modal-body id="chat-integration-edit-rule_modal" title="chat_integration.edit_rule_modal.title"}}
|
2017-07-31 12:09:21 -04:00
|
|
|
<div>
|
|
|
|
<form {{action "save" on="submit"}}>
|
|
|
|
<table>
|
2021-02-11 05:42:26 -05:00
|
|
|
<tbody>
|
|
|
|
<tr class="input">
|
|
|
|
<td class="label"><label for="provider">{{i18n "chat_integration.edit_rule_modal.provider"}}</label></td>
|
|
|
|
<td>
|
|
|
|
{{i18n (concat "chat_integration.provider." model.channel.provider ".title")}}
|
|
|
|
</td>
|
|
|
|
</tr>
|
2017-07-31 12:09:21 -04:00
|
|
|
|
2021-02-11 05:42:26 -05:00
|
|
|
<tr class="chat-instructions">
|
|
|
|
<td></td>
|
|
|
|
<td></td>
|
|
|
|
</tr>
|
2017-07-31 12:09:21 -04:00
|
|
|
|
2017-08-01 10:20:00 -04:00
|
|
|
<tr class="input">
|
2021-02-11 05:42:26 -05:00
|
|
|
<td class="label"><label for="channel">{{i18n "chat_integration.edit_rule_modal.channel"}}</label></td>
|
2017-08-01 10:20:00 -04:00
|
|
|
<td>
|
2021-02-11 05:42:26 -05:00
|
|
|
{{channel-data provider=model.provider channel=model.channel}}
|
2017-08-01 10:20:00 -04:00
|
|
|
</td>
|
|
|
|
</tr>
|
2021-02-11 05:42:26 -05:00
|
|
|
|
2021-01-26 15:33:15 -05:00
|
|
|
<tr class="chat-instructions">
|
2017-08-01 10:20:00 -04:00
|
|
|
<td></td>
|
2021-02-11 05:42:26 -05:00
|
|
|
<td></td>
|
2017-08-01 10:20:00 -04:00
|
|
|
</tr>
|
2021-02-11 05:42:26 -05:00
|
|
|
|
2017-08-01 10:20:00 -04:00
|
|
|
<tr class="input">
|
2021-02-11 05:42:26 -05:00
|
|
|
<td class="label"><label for="filter">{{i18n "chat_integration.edit_rule_modal.type"}}</label></td>
|
2017-08-01 10:20:00 -04:00
|
|
|
<td>
|
2021-02-11 05:42:26 -05:00
|
|
|
{{combo-box name="type" content=model.rule.available_types value=model.rule.type}}
|
2017-08-01 10:20:00 -04:00
|
|
|
</td>
|
|
|
|
</tr>
|
2021-02-11 05:42:26 -05:00
|
|
|
|
2021-01-26 15:33:15 -05:00
|
|
|
<tr class="chat-instructions">
|
2017-08-01 10:20:00 -04:00
|
|
|
<td></td>
|
2021-02-11 05:42:26 -05:00
|
|
|
<td><label>{{i18n "chat_integration.edit_rule_modal.instructions.type"}}</label></td>
|
2017-08-01 10:20:00 -04:00
|
|
|
</tr>
|
|
|
|
|
2017-07-31 12:09:21 -04:00
|
|
|
<tr class="input">
|
2021-02-11 05:42:26 -05:00
|
|
|
<td class="label"><label for="filter">{{i18n "chat_integration.edit_rule_modal.filter"}}</label></td>
|
2017-07-31 12:09:21 -04:00
|
|
|
<td>
|
2021-02-11 05:42:26 -05:00
|
|
|
{{combo-box name="filter" content=model.rule.available_filters value=model.rule.filter}}
|
2017-07-31 12:09:21 -04:00
|
|
|
</td>
|
|
|
|
</tr>
|
2021-02-11 05:42:26 -05:00
|
|
|
|
2021-01-26 15:33:15 -05:00
|
|
|
<tr class="chat-instructions">
|
2017-07-31 12:09:21 -04:00
|
|
|
<td></td>
|
2021-02-11 05:42:26 -05:00
|
|
|
<td><label>{{i18n "chat_integration.edit_rule_modal.instructions.filter"}}</label></td>
|
2017-07-31 12:09:21 -04:00
|
|
|
</tr>
|
|
|
|
|
2021-02-11 05:42:26 -05:00
|
|
|
{{#if showCategory}}
|
|
|
|
<tr class="input">
|
|
|
|
<td class="label"><label for="category">{{i18n "chat_integration.edit_rule_modal.category"}}</label></td>
|
|
|
|
<td>
|
|
|
|
{{category-chooser
|
|
|
|
name="category"
|
|
|
|
value=model.rule.category_id
|
|
|
|
rootNoneLabel="chat_integration.all_categories"
|
|
|
|
rootNone=true
|
|
|
|
overrideWidths=false
|
|
|
|
}}
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr class="chat-instructions">
|
|
|
|
<td></td>
|
|
|
|
<td><label>{{i18n "chat_integration.edit_rule_modal.instructions.category"}}</label></td>
|
|
|
|
</tr>
|
|
|
|
{{else}}
|
|
|
|
<tr class="input">
|
|
|
|
<td class="label"><label for="group">{{i18n "chat_integration.edit_rule_modal.group"}}</label></td>
|
|
|
|
<td>
|
|
|
|
{{combo-box content=model.groups valueAttribute="id" value=model.rule.group_id none="chat_integration.choose_group"}}
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr class="chat-instructions">
|
|
|
|
<td></td>
|
|
|
|
<td><label>{{i18n "chat_integration.edit_rule_modal.instructions.group"}}</label></td>
|
|
|
|
</tr>
|
|
|
|
{{/if}}
|
2017-07-31 12:09:21 -04:00
|
|
|
|
2021-02-11 05:42:26 -05:00
|
|
|
{{#if siteSettings.tagging_enabled}}
|
|
|
|
<tr class="input">
|
|
|
|
<td class="label"><label for="tags">{{i18n "chat_integration.edit_rule_modal.tags"}}</label></td>
|
|
|
|
<td>
|
|
|
|
{{tag-chooser placeholderKey="chat_integration.all_tags" name="tags" tags=model.rule.tags everyTag=true }}
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr class="chat-instructions">
|
|
|
|
<td></td>
|
|
|
|
<td><label>{{i18n "chat_integration.edit_rule_modal.instructions.tags"}}</label></td>
|
|
|
|
</tr>
|
|
|
|
{{/if}}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2017-07-31 12:09:21 -04:00
|
|
|
</form>
|
2017-10-03 05:42:07 -04:00
|
|
|
</div>
|
2017-07-31 12:09:21 -04:00
|
|
|
{{/d-modal-body}}
|
|
|
|
|
|
|
|
<div class="modal-footer">
|
2017-10-03 05:42:07 -04:00
|
|
|
{{d-button id="save-rule"
|
2021-02-11 05:42:26 -05:00
|
|
|
class="btn-primary btn-large"
|
2019-03-20 06:57:07 -04:00
|
|
|
action="save"
|
|
|
|
actionParam=model.rule
|
|
|
|
title="chat_integration.edit_rule_modal.save"
|
|
|
|
label="chat_integration.edit_rule_modal.save"
|
2021-02-11 05:42:26 -05:00
|
|
|
disabled=saveDisabled
|
|
|
|
}}
|
2017-07-31 12:09:21 -04:00
|
|
|
|
2017-10-03 05:42:07 -04:00
|
|
|
{{d-button class="btn-large"
|
2021-02-11 05:42:26 -05:00
|
|
|
action=(route-action "closeModal")
|
|
|
|
title="chat_integration.edit_rule_modal.cancel"
|
|
|
|
label="chat_integration.edit_rule_modal.cancel"
|
|
|
|
}}
|
2017-10-03 10:49:19 -04:00
|
|
|
</div>
|