[FIX] website: fix html editor view to be edited

Before this commit, the view selected to be edited by the html editor was the wrong one
This was caused by the simplification brought about by commit a2ae219d4e
which transfered from python to js the decision to make a view a header for the [customize] menu (on the website
In this case, the first view in the return list of python was the header, and the second the actual view

Now that python just sends a list of unique views without any distinction whatsoever, the right view to pick when entering the html editor is the first one, at index 0

opw 760279

Closes #18603
This commit is contained in:
Lucas Perais (lpe)
2017-08-03 09:36:01 +02:00
parent 7ac19968f7
commit ac3bfee8f3
+1 -1
View File
@@ -57,7 +57,7 @@ var ViewEditor = AceCommon.ViewEditor.extend({
self.$('#ace-view-list').val(viewId).change();
} else {
if (views.length >= 2) {
var mainTemplate = views[1];
var mainTemplate = views[0];
self.$('#ace-view-list').val(mainTemplate.id).trigger('change');
}
window.location.hash = hash;