From a9318f7fd31eed8fa14d08a92277ba795efbb36c Mon Sep 17 00:00:00 2001 From: tr4ck3ur Date: Sun, 15 Feb 2015 18:10:48 +0100 Subject: Corrigé les images Ajouté la gestion de password Corrigé le slug des users à la création MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jm2l/static/css/jm2l.css | 7 ++++--- jm2l/static/js/jm2l.js | 17 ----------------- jm2l/static/js/plugins.js | 37 +++++++++++++++++++++++++++++++++++++ 3 files changed, 41 insertions(+), 20 deletions(-) (limited to 'jm2l/static') diff --git a/jm2l/static/css/jm2l.css b/jm2l/static/css/jm2l.css index de94fbf..016073c 100644 --- a/jm2l/static/css/jm2l.css +++ b/jm2l/static/css/jm2l.css @@ -44,13 +44,13 @@ a { height:100px; } .invalid { - background:url(../images/invalid.png) no-repeat 0 50%; + background:url(/img/invalid.png) no-repeat 0 50%; padding-left:22px; line-height:24px; color:#ec3f41; } .valid { - background:url(../images/valid.png) no-repeat 0 50%; + background:url(/img/valid.png) no-repeat 0 50%; padding-left:22px; line-height:24px; color:#3aba34; @@ -84,7 +84,8 @@ a { opacity: 0.5; position: absolute; text-align: center; - width: 15px; + width: 15px; + top: -20px; } .Ucarousel-control.left { right: auto; diff --git a/jm2l/static/js/jm2l.js b/jm2l/static/js/jm2l.js index e24c7d0..a700c4a 100644 --- a/jm2l/static/js/jm2l.js +++ b/jm2l/static/js/jm2l.js @@ -1,4 +1,3 @@ - function DoPost(TargetURL) { var Datas=$('#ModalForm').serialize(); $.ajax({ @@ -83,7 +82,6 @@ $(document).ready(function() { }); $('#AjaxModal').on('hidden', function(bla){ - //$(this).data('modal', null); if (bla.target.id.endsWith('-help')) return; if (bla.target.id=='AjaxModal') { @@ -98,7 +96,6 @@ $(document).ready(function() { $('#AjaxPlaceModal').on('hidden', function(bla){ $("#place_type").select2("destroy"); - //$(this).data('modal', null); if (bla.target.id.endsWith('-help')) return; if ($(this).children().length) @@ -152,20 +149,6 @@ $(document).ready(function() { $('a[href="' + SavHash + '"]').tab('show'); } } - - - if (0) { - var editor = CKEDITOR.replace( 'bio', { - saveSubmitURL:'/SaveFrontPage/?part=bio', - on : { blur: function( event ) { event.editor.getCommand( 'save' ).enable(); } - } - } ); - } else { - //CKEDITOR.disableAutoInline = true; - //var editor = CKEDITOR.inline( 'bio' ); - //var editor = CKEDITOR.replace( 'bio' ); - //var editor = CKEDITOR.replace( 'bio' ); - }; jQuery(function() { jQuery('.repeat').each(function() { diff --git a/jm2l/static/js/plugins.js b/jm2l/static/js/plugins.js index f887480..78eecbf 100644 --- a/jm2l/static/js/plugins.js +++ b/jm2l/static/js/plugins.js @@ -22,3 +22,40 @@ }()); // Place any jQuery/helper plugins in here. +function HandleControls() { +// Trig some javascript to handle New Dialog content + $.each( $('.fileupload'), + function( NumCtrl, Ctrl ) { + $("#"+Ctrl.id).fileupload({ + // Uncomment the following to send cross-domain cookies: + //xhrFields: {withCredentials: true}, + //url: '/uploader/proceed/' + url: this.action + }); + // Enable iframe cross-domain access via redirect option: + $("#"+Ctrl.id).fileupload( + 'option', + 'redirect', + window.location.href.replace( + /\/[^\/]*$/, + '/cors/result.html?%s' + ) + ); + $("#"+Ctrl.id).addClass('fileupload-processing'); + $.ajax({ + // Uncomment the following to send cross-domain cookies: + //xhrFields: {withCredentials: true}, + //url: this.action, + url: $("#"+Ctrl.id).fileupload('option', 'url'), + //url: "uploader/proceed/", + dataType: 'json', + context: $("#"+Ctrl.id)[0] + }).always(function () { + $(this).removeClass('fileupload-processing'); + }).done(function (result) { + $(this).fileupload('option', 'done') + .call(this, $.Event('done'), {result: result}); //$(this)}); + }); + } + ); +} \ No newline at end of file -- cgit v1.2.3-54-g00ecf