~xibo-maintainers/xibo/tempel

« back to all changes in this revision

Viewing changes to views/layout-page.twig

  • Committer: GitHub
  • Author(s): Dan Garner
  • Date: 2018-06-20 16:27:37 UTC
  • mfrom: (652)
  • mto: This revision was merged to the branch mainline in revision 653.
  • Revision ID: git-v1:1a1ca01506202d782ed245fa27b6ce6c32f0a216
Merge branch 'release18' into bugfix/1.8.10-pack2

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
                                    {{ inline.inputWithTags("tags", title, null, helpText) }}
31
31
 
32
32
                                    {% set attributes = [
33
 
                                    { name: "data-live-search", value: "true" },
34
 
                                    { name: "data-selected-text-format", value: "count > 4" }
 
33
                                    { name: "data-allow-clear", value: "true" },
 
34
                                    { name: "data-placeholder--id", value: null },
 
35
                                    { name: "data-placeholder--value", value: "" }
35
36
                                    ] %}
36
37
 
37
38
                                    {% set title %}{% trans "Owner" %}{% endset %}
117
118
                        url: "{{ urlFor("user.pref") }}?preference=layoutGrid",
118
119
                        dataType: 'json',
119
120
                        success: function (json) {
120
 
                            if (json.success)
121
 
                                data = JSON.parse(json.data.value);
 
121
                            try {
 
122
                                if (json.success) {
 
123
                                    data = JSON.parse(json.data.value);
 
124
                                }
 
125
                            } catch (e) {
 
126
                                // Do nothing
 
127
                            }
122
128
                        }
123
129
                    });
124
130
                    return data;