mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-18 15:33:15 +00:00
Remove hard code url
This commit is contained in:
@@ -61,7 +61,7 @@
|
|||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<div id="admin-app" data-usr="{{ app['authentication'].getUser().getId() }}">
|
<div id="admin-app" data-usr="{{ app['authentication'].getUser().getId() }}">
|
||||||
<div id="left" class="PNB left-view" style="width:250px;right:auto;" data-websocket="{{ "ws://" ~ app["conf"].get(["main" ,"websocket-server", "host"]) ~ ":" ~ app["conf"].get(["main" ,"websocket-server", "port"]) ~ "/websockets" }}">
|
<div id="left" class="PNB left-view" style="width:250px;right:auto;" data-tree-url="{{ path("admin_tree_display") }}" data-websocket="{{ "ws://" ~ app["conf"].get(["main" ,"websocket-server", "host"]) ~ ":" ~ app["conf"].get(["main" ,"websocket-server", "port"]) ~ "/websockets" }}">
|
||||||
<div class="PNB10" style="right:0">
|
<div class="PNB10" style="right:0">
|
||||||
<div id="FNDR">
|
<div id="FNDR">
|
||||||
{% include 'admin/tree.html.twig' %}
|
{% include 'admin/tree.html.twig' %}
|
||||||
|
@@ -50,6 +50,19 @@ define([
|
|||||||
})
|
})
|
||||||
};
|
};
|
||||||
|
|
||||||
|
var create = function() {
|
||||||
|
AdminApp.LeftView = new LeftPanel({
|
||||||
|
el: AdminApp.$leftView,
|
||||||
|
eventManager: AdminApp.eventManager,
|
||||||
|
treeUrl: AdminApp.$leftView.data("tree-url")
|
||||||
|
});
|
||||||
|
|
||||||
|
AdminApp.RightView = new RightPanel({
|
||||||
|
el: AdminApp.$rightView,
|
||||||
|
eventManager: AdminApp.eventManager
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
var initialize = function (options) {
|
var initialize = function (options) {
|
||||||
if (false === "wsurl" in options) {
|
if (false === "wsurl" in options) {
|
||||||
throw "You must define a websocket url";
|
throw "You must define a websocket url";
|
||||||
@@ -59,15 +72,7 @@ define([
|
|||||||
WSConnection.connect(options.wsurl);
|
WSConnection.connect(options.wsurl);
|
||||||
}
|
}
|
||||||
|
|
||||||
AdminApp.LeftView = new LeftPanel({
|
create();
|
||||||
el: AdminApp.$leftView,
|
|
||||||
eventManager: AdminApp.eventManager
|
|
||||||
});
|
|
||||||
|
|
||||||
AdminApp.RightView = new RightPanel({
|
|
||||||
el: AdminApp.$rightView,
|
|
||||||
eventManager: AdminApp.eventManager
|
|
||||||
});
|
|
||||||
|
|
||||||
AdminApp.LeftView.activeTree();
|
AdminApp.LeftView.activeTree();
|
||||||
AdminApp.LeftView.clickSelected();
|
AdminApp.LeftView.clickSelected();
|
||||||
@@ -76,6 +81,7 @@ define([
|
|||||||
};
|
};
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
create: create,
|
||||||
initialize: initialize
|
initialize: initialize
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
Reference in New Issue
Block a user