3
* Spring Signage Ltd - http://www.springsignage.com
4
* Copyright (C) 2016 Spring Signage Ltd
10
{% extends "form-base.twig" %}
11
{% import "forms.twig" as forms %}
14
{% trans "Edit Notification" %}
17
{% block callBack %}notificationFormOpen{% endblock %}
19
{% block formButtons %}
20
{% trans "Help" %}, XiboHelpRender("{{ help }}")
21
{% trans "Cancel" %}, XiboDialogClose()
22
{% trans "Save" %}, $("#notificationForm").submit()
27
<div class="col-md-12">
28
<ul class="nav nav-tabs" role="tablist">
29
<li class="active"><a href="#general" role="tab" data-toggle="tab"><span>{% trans "General" %}</span></a></li>
30
<li><a href="#message-body" role="tab" data-toggle="tab"><span>{% trans "Message" %}</span></a></li>
31
<li><a href="#audience" role="tab" data-toggle="tab"><span>{% trans "Audience" %}</span></a></li>
33
<form id="notificationForm" class="XiboForm form-horizontal" method="put" action="{{ urlFor("notification.edit", {id: notification.notificationId}) }}">
34
<div class="tab-content">
35
<div class="tab-pane active" id="general">
36
{% set title %}{% trans "Subject" %}{% endset %}
37
{% set helpText %}{% trans "A subject line for the notification - used as a title." %}{% endset %}
38
{{ forms.input("subject", title, notification.subject, helpText, "", "required") }}
40
{% set title %}{% trans "Release Date" %}{% endset %}
41
{% set helpText %}{% trans "The date when this notification will be published" %}{% endset %}
42
{{ forms.dateTime("releaseDt", title, notification.releaseDt, helpText, "starttime-control", "required") }}
44
{% set title %}{% trans "Email?" %}{% endset %}
45
{% set helpText %}{% trans "Should the notification be emailed?" %}{% endset %}
46
{{ forms.checkBox("isEmail", title, notification.isEmail, helpText) }}
48
{% set title %}{% trans "Interrupt?" %}{% endset %}
49
{% set helpText %}{% trans "Should the notification interrupt nagivation in the Web Portal? Including Login." %}{% endset %}
50
{{ forms.checkBox("isInterrupt", title, notification.isInterrupt, helpText) }}
53
<div class="tab-pane" id="message-body">
54
{% set title %}{% trans "Add the body of your message in the box below. If you are going to target this message to a Display/DisplayGroup be aware that the formatting you apply here will be removed." %}{% endset %}
55
{{ forms.message(title) }}
57
{{ forms.textarea("body", "", notification.body, "", "", 10) }}
59
<div class="tab-pane" id="audience">
60
{% set title %}{% trans "Users" %}{% endset %}
61
{% set helpText %}{% trans "Please select one or more users / groups who will receive this notification." %}{% endset %}
63
{ name: "data-live-search", value: "true" },
64
{ name: "data-selected-text-format", value: "count > 4" }
66
{% set transUserGroups %}{% trans "Groups" %}{% endset %}
67
{% set transUsers %}{% trans "Users" %}{% endset %}
68
{% set optionGroups = [
69
{id: "group", label: transUserGroups},
70
{id: "user", label: transUsers}
72
{{ forms.dropdown("userGroupIds[]", "dropdownmulti", title, userGroupIds, {group: userGroups, user: users}, "groupId", "group", helpText, "", "", "", "", attributes, optionGroups) }}
75
{% set title %}{% trans "Displays" %}{% endset %}
76
{% set helpText %}{% trans "Please select one or more displays / groups for this notification to be shown on - Layouts will need the notification widget." %}{% endset %}
78
{ name: "data-live-search", value: "true" },
79
{ name: "data-selected-text-format", value: "count > 4" }
81
{% set transGroups %}{% trans "Groups" %}{% endset %}
82
{% set transDisplays %}{% trans "Display" %}{% endset %}
83
{% set optionGroups = [
84
{id: "group", label: transGroups},
85
{id: "display", label: transDisplays}
87
{{ forms.dropdown("displayGroupIds[]", "dropdownmulti", title, displayGroupIds, {group: displayGroups, display: displays}, "displayGroupId", "displayGroup", helpText, "", "", "", "", attributes, optionGroups) }}
b'\\ No newline at end of file'