3
* Spring Signage Ltd - http://www.springsignage.com
4
* Copyright (C) 2015 Spring Signage Ltd
9
{% extends "form-base.twig" %}
10
{% import "forms.twig" as forms %}
13
{% trans "Google Traffic" %}
16
{% block formButtons %}
17
{% trans "Cancel" %}, XiboDialogClose()
18
{% trans "Save" %}, $("#googleTrafficForm").submit()
21
{% block formFieldActions %}
23
"field": "useDisplayLocation",
26
"operation": "is:checked",
28
".locationControls": { "display": "block" }
31
"field": "useDisplayLocation",
34
"operation": "is:checked",
36
".locationControls": { "display": "block" }
39
"field": "useDisplayLocation",
42
"operation": "is:checked",
44
".locationControls": { "display": "none" }
47
"field": "useDisplayLocation",
50
"operation": "is:checked",
52
".locationControls": { "display": "none" }
55
"field": "useDuration",
58
"operation": "is:checked",
60
".duration-fields": { "display": "none" }
63
"field": "useDuration",
66
"operation": "is:checked",
68
".duration-fields": { "display": "none" }
71
"field": "useDuration",
74
"operation": "is:checked",
76
".duration-fields": { "display": "block" }
79
"field": "useDuration",
82
"operation": "is:checked",
84
".duration-fields": { "display": "block" }
91
<div class="col-md-12">
92
<form id="googleTrafficForm" class="XiboForm form-horizontal" method="post" action="{{ urlFor("module.widget.add", {type: module.widget.type, id: playlist.playlistId}) }}">
93
{% set title %}{% trans "Name" %}{% endset %}
94
{% set helpText %}{% trans "An optional name for this widget" %}{% endset %}
95
{{ forms.input("name", title, "", helpText) }}
97
{% set title %}{% trans "Set a duration?" %}{% endset %}
98
{% set helpText %}{% trans "Select to provide a specific duration for this Widget" %}{% endset %}
99
{{ forms.checkbox("useDuration", title, module.getUseDuration(), helpText) }}
101
{% set title %}{% trans "Duration" %}{% endset %}
102
{% set helpText %}{% trans "The duration in seconds this item should be displayed." %}{% endset %}
103
{{ forms.number("duration", title, module.getModule().defaultDuration, helpText, "duration-fields", "required") }}
105
{% set title %}{% trans "Use the Display Location" %}{% endset %}
106
{% set helpText %}{% trans "Use the location configured on the display" %}{% endset %}
107
{{ forms.checkbox("useDisplayLocation", title, 1, helpText) }}
109
{% set title %}{% trans "Latitude" %}{% endset %}
110
{% set helpText %}{% trans "The Latitude for this widget" %}{% endset %}
111
{{ forms.number("latitude", title, "", helpText, "locationControls") }}
113
{% set title %}{% trans "Longitude" %}{% endset %}
114
{% set helpText %}{% trans "The Longitude for this widget" %}{% endset %}
115
{{ forms.number("longitude", title, "", helpText, "locationControls") }}
117
{% set title %}{% trans "Zoom" %}{% endset %}
118
{% set helpText %}{% trans "How far should the map be zoomed in? The higher the number the closer, 1 represents the entire globe." %}{% endset %}
119
{{ forms.number("zoom", title, 12, helpText) }}
122
{% set message %}{% trans "This module is rendered on the Player which means the Player must have an internet connection." %}{% endset %}
123
{{ forms.message(message, "alert alert-info") }}
125
{% if module.getSetting("apiKey") == "" %}
126
{% set message %}{% trans "The Traffic Widget has not been configured yet, please ask your CMS Administrator to look at it for you." %}{% endset %}
127
{{ forms.message(message, "alert alert-danger") }}
b'\\ No newline at end of file'