mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-13 04:53:26 +00:00
fix admin tinymce init, misc admin fixes
This commit is contained in:
@@ -45,5 +45,6 @@ gulp.task('build-vendors', [
|
|||||||
'build-jquery-cookie',
|
'build-jquery-cookie',
|
||||||
'build-requirejs',
|
'build-requirejs',
|
||||||
'build-jquery-treeview',
|
'build-jquery-treeview',
|
||||||
'build-jquery-lazyload'
|
'build-jquery-lazyload',
|
||||||
|
'build-jquery-test-paths'
|
||||||
], function() {});
|
], function() {});
|
@@ -17,6 +17,9 @@ gulp.task('build-admin-js', function(){
|
|||||||
var adminGroup = [
|
var adminGroup = [
|
||||||
config.paths.vendors + 'underscore-amd/underscore.js',
|
config.paths.vendors + 'underscore-amd/underscore.js',
|
||||||
config.paths.vendors + 'jquery-treeview/jquery.treeview.js',
|
config.paths.vendors + 'jquery-treeview/jquery.treeview.js',
|
||||||
|
// config.paths.vendors + 'jquery-file-upload/js/vendor/jquery.ui.widget.js',
|
||||||
|
// config.paths.vendors + 'jquery-file-upload/js/jquery.iframe-transport.js',
|
||||||
|
// config.paths.vendors + 'jquery-file-upload/js/jquery.fileupload.js',
|
||||||
config.paths.src + 'admin/js/jquery.kb-event.js',
|
config.paths.src + 'admin/js/jquery.kb-event.js',
|
||||||
config.paths.src + 'admin/js/template-dialogs.js',
|
config.paths.src + 'admin/js/template-dialogs.js',
|
||||||
config.paths.vendors + 'requirejs/require.js',
|
config.paths.vendors + 'requirejs/require.js',
|
||||||
|
@@ -18,7 +18,7 @@ gulp.task('build-setup-js', function(){
|
|||||||
config.paths.vendors + 'jquery.cookie/jquery.cookie.js',
|
config.paths.vendors + 'jquery.cookie/jquery.cookie.js',
|
||||||
config.paths.src + 'vendors/jquery-validation/js/jquery.validate.js',
|
config.paths.src + 'vendors/jquery-validation/js/jquery.validate.js',
|
||||||
config.paths.src + 'vendors/jquery-validate.password/js/jquery.validate.password.js',
|
config.paths.src + 'vendors/jquery-validate.password/js/jquery.validate.password.js',
|
||||||
config.paths.src + 'setup/js/path_files_tests.jquery.js'
|
config.paths.src + 'vendors/jquery-test-paths/jquery.test-paths.js'
|
||||||
];
|
];
|
||||||
return utils.buildJsGroup(setupGroup, 'setup', 'setup/js', debugMode);
|
return utils.buildJsGroup(setupGroup, 'setup', 'setup/js', debugMode);
|
||||||
});
|
});
|
||||||
|
9
resources/gulp/components/vendors/jquery-test-paths.js
vendored
Normal file
9
resources/gulp/components/vendors/jquery-test-paths.js
vendored
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
var gulp = require('gulp');
|
||||||
|
var config = require('../../config.js');
|
||||||
|
var utils = require('../../utils.js');
|
||||||
|
|
||||||
|
gulp.task('build-jquery-test-paths', function(){
|
||||||
|
return utils.buildJsGroup([
|
||||||
|
config.paths.src + 'vendors/jquery-test-paths/jquery.test-paths.js'
|
||||||
|
], 'jquery.test-paths', 'vendors/jquery-test-paths');
|
||||||
|
});
|
@@ -5,6 +5,14 @@
|
|||||||
@import '../../vendors/jquery-contextmenu/styles/jquery.contextmenu';
|
@import '../../vendors/jquery-contextmenu/styles/jquery.contextmenu';
|
||||||
@import '../../_shared/styles/main';
|
@import '../../_shared/styles/main';
|
||||||
|
|
||||||
|
// override jquery ui theme colors:
|
||||||
|
$uiTextContentColor: #333333;
|
||||||
|
$uiTextTitleColor: #333333;
|
||||||
|
$uiLinkColor: #333333;
|
||||||
|
$uiLinkFocusColor: #333333;
|
||||||
|
$uiLinkActiveColor: #333333;
|
||||||
|
@import '../../_shared/styles/jquery-ui/ui-lightness';
|
||||||
|
|
||||||
/******* GLOBAL CSS for ADMIN *************************************************/
|
/******* GLOBAL CSS for ADMIN *************************************************/
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
@@ -116,6 +124,9 @@ div.finder div.content div.title {
|
|||||||
#mainMenu span.selected {
|
#mainMenu span.selected {
|
||||||
border-top: 3px solid #000000;
|
border-top: 3px solid #000000;
|
||||||
}
|
}
|
||||||
|
#mainContent {
|
||||||
|
margin-top: $mainMenuHeight;
|
||||||
|
}
|
||||||
/******* LEFT SIDE ************************************************************/
|
/******* LEFT SIDE ************************************************************/
|
||||||
#left {
|
#left {
|
||||||
background-color: #fffbcd;
|
background-color: #fffbcd;
|
||||||
|
@@ -39,13 +39,18 @@
|
|||||||
active:$("#tabs ul li").index($('#tabs ul li.current'))
|
active:$("#tabs ul li").index($('#tabs ul li.current'))
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (typeof(tinymce) !== "undefined") {
|
||||||
|
if (tinymce.activeEditor !== null) {
|
||||||
|
tinymce.editors=[]; // remove any existing references
|
||||||
|
}
|
||||||
|
}
|
||||||
tinymce.init({
|
tinymce.init({
|
||||||
selector: "textarea",
|
selector: "textarea",
|
||||||
plugins: [
|
plugins: [
|
||||||
"searchreplace",
|
"searchreplace",
|
||||||
"contextmenu paste"
|
"contextmenu paste"
|
||||||
],
|
],
|
||||||
toolbar: "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent",
|
toolbar: "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent"
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
@@ -61,7 +61,7 @@
|
|||||||
{% block content %}
|
{% block content %}
|
||||||
<div id="admin-app" data-usr="{{ app.getAuthenticatedUser().getId() }}" data-notif-url="{{ path('list_notifications') }}">
|
<div id="admin-app" data-usr="{{ app.getAuthenticatedUser().getId() }}" data-notif-url="{{ path('list_notifications') }}">
|
||||||
<div id="left" class="PNB left-view" style="width:250px;right:auto;" data-tree-url="{{ path("admin_display_tree") }}" 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_display_tree") }}" data-websocket="{{ "ws://" ~ app["conf"].get(["main" ,"websocket-server", "host"]) ~ ":" ~ app["conf"].get(["main" ,"websocket-server", "port"]) ~ "/websockets" }}">
|
||||||
<div class="PNB10" style="right:0; top:28px;">
|
<div class="PNB10" style="right:0; top:0px;">
|
||||||
<div id="FNDR">
|
<div id="FNDR">
|
||||||
{% include 'admin/tree.html.twig' %}
|
{% include 'admin/tree.html.twig' %}
|
||||||
</div>
|
</div>
|
||||||
|
@@ -2,7 +2,7 @@
|
|||||||
{% extends "admin/common/iframe_wrap.html.twig" %}
|
{% extends "admin/common/iframe_wrap.html.twig" %}
|
||||||
|
|
||||||
{% block stylesheet %}
|
{% block stylesheet %}
|
||||||
<link type="text/css" rel="stylesheet" href="/assets/vendors/jquery-ui/css/ui-lightness{% if not app.debug %}.min{% endif %}.css">
|
{#<link type="text/css" rel="stylesheet" href="/assets/vendors/jquery-ui/css/ui-lightness{% if not app.debug %}.min{% endif %}.css">#}
|
||||||
<style>
|
<style>
|
||||||
body{
|
body{
|
||||||
overflow:auto;
|
overflow:auto;
|
||||||
@@ -11,9 +11,10 @@
|
|||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block javascript %}
|
{% block javascript %}
|
||||||
|
|
||||||
<script type="text/javascript" src="/assets/vendors/jquery/jquery{% if not app.debug %}.min{% endif %}.js"></script>
|
<script type="text/javascript" src="/assets/vendors/jquery/jquery{% if not app.debug %}.min{% endif %}.js"></script>
|
||||||
<script type="text/javascript" src="/assets/vendors/jquery-ui/jquery-ui{% if not app.debug %}.min{% endif %}.js"></script>
|
<script type="text/javascript" src="/assets/vendors/jquery-ui/jquery-ui{% if not app.debug %}.min{% endif %}.js"></script>
|
||||||
<script type="text/javascript" src="{{ path('minifier', { 'f' : 'include/path_files_tests.jquery.js' }) }}"></script>
|
<script type="text/javascript" src="/assets/vendors/jquery-test-paths/jquery.test-paths{% if not app.debug %}.min{% endif %}.js"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
$('.path_testable').path_file_test();
|
$('.path_testable').path_file_test();
|
||||||
|
@@ -21,7 +21,7 @@ define([
|
|||||||
eventManager: _.extend({}, Backbone.Events)
|
eventManager: _.extend({}, Backbone.Events)
|
||||||
};
|
};
|
||||||
|
|
||||||
var pullNotifications = function (){
|
window.pullNotifications = function (){
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type: "POST",
|
type: "POST",
|
||||||
url: AdminApp.$scope.data("notif-url"),
|
url: AdminApp.$scope.data("notif-url"),
|
||||||
@@ -31,10 +31,10 @@ define([
|
|||||||
usr : AdminApp.$scope.data("usr")
|
usr : AdminApp.$scope.data("usr")
|
||||||
},
|
},
|
||||||
error: function(){
|
error: function(){
|
||||||
window.setTimeout("pollNotifications();", 10000);
|
window.setTimeout("pullNotifications();", 10000);
|
||||||
},
|
},
|
||||||
timeout: function(){
|
timeout: function(){
|
||||||
window.setTimeout("pollNotifications();", 10000);
|
window.setTimeout("pullNotifications();", 10000);
|
||||||
},
|
},
|
||||||
success: function(data){
|
success: function(data){
|
||||||
if (data) {
|
if (data) {
|
||||||
@@ -44,7 +44,7 @@ define([
|
|||||||
if (data.apps && parseInt(data.apps) > 1) {
|
if (data.apps && parseInt(data.apps) > 1) {
|
||||||
t = Math.round((Math.sqrt(parseInt(data.apps)-1) * 1.3 * 120000));
|
t = Math.round((Math.sqrt(parseInt(data.apps)-1) * 1.3 * 120000));
|
||||||
}
|
}
|
||||||
window.setTimeout("pollNotifications();", t);
|
window.setTimeout("pullNotifications();", t);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user