@@ -599,8 +599,8 @@ var urlCtrl = {
599
599
"#admin.createfile" : { title :'IMPORT DATA' , icon : 'download' } ,
600
600
"#log.monitoring" : { title :'LOG MONITORING ' , icon : 'plus' } ,
601
601
"#adminpublic.index" : { title :'SOURCE ADMIN' , icon : 'download' } ,
602
- "#adminpublic.createfile" : { title :'IMPORT DATA' , icon : 'download' , useHeader : true } ,
603
- "#adminpublic.adddata" : { title :'ADDDATA ' , icon : 'download' , useHeader : true } ,
602
+ "#adminpublic.createfile" : { title :'IMPORT DATA' , icon : 'download' , useHeader : false } ,
603
+ "#adminpublic.adddata" : { title :'ADDDATA ' , icon : 'download' } ,
604
604
"#admin.cleantags" : { title : 'CLEAN TAGS' , icon : 'download' } ,
605
605
"#default.directory" : { title :'COMMUNECTED DIRECTORY' , icon : 'connectdevelop' , menuId :"menu-btn-directory" } ,
606
606
"#default.news" : { title :'COMMUNECTED NEWS ' , icon : 'rss' , menuId :"menu-btn-news" } ,
@@ -2174,25 +2174,17 @@ var collection = {
2174
2174
if ( data . result ) {
2175
2175
if ( data . list == '$unset' ) {
2176
2176
if ( location . hash . indexOf ( "#page" ) >= 0 ) {
2177
- if ( location . hash . indexOf ( "view.directory.dir.collections" ) >= 0 && contextData . id == userId ) {
2178
- loadDataDirectory ( "collections" , "star" ) ;
2179
- } else {
2180
- $ ( ".favorisMenu" ) . removeClass ( "text-yellow" ) ;
2181
- $ ( ".favorisMenu" ) . children ( "i" ) . removeClass ( "fa-star" ) . addClass ( 'fa-star-o' ) ;
2182
- }
2177
+ $ ( ".favorisMenu" ) . removeClass ( "text-yellow" ) ;
2178
+ $ ( ".favorisMenu" ) . children ( "i" ) . removeClass ( "fa-star" ) . addClass ( 'fa-star-o' ) ;
2183
2179
} else {
2184
2180
$ ( el ) . children ( "i" ) . removeClass ( "fa-star text-red" ) . addClass ( 'fa-star-o' ) ;
2185
2181
delete userConnected . collections [ collection ] [ what ] [ id ] ;
2186
2182
}
2187
2183
}
2188
2184
else {
2189
2185
if ( location . hash . indexOf ( "#page" ) >= 0 ) {
2190
- if ( location . hash . indexOf ( "view.directory.dir.collections" ) >= 0 && contextData . id == userId ) {
2191
- loadDataDirectory ( "collections" , "star" ) ;
2192
- } else {
2193
- $ ( ".favorisMenu" ) . addClass ( "text-yellow" ) ;
2194
- $ ( ".favorisMenu" ) . children ( "i" ) . removeClass ( "fa-star-o" ) . addClass ( 'fa-star' ) ;
2195
- }
2186
+ $ ( ".favorisMenu" ) . addClass ( "text-yellow" ) ;
2187
+ $ ( ".favorisMenu" ) . children ( "i" ) . removeClass ( "fa-star-o" ) . addClass ( 'fa-star' ) ;
2196
2188
}
2197
2189
else
2198
2190
$ ( el ) . children ( "i" ) . removeClass ( "fa-star-o" ) . addClass ( 'fa-star text-red' ) ;
@@ -2241,8 +2233,7 @@ var uploadObj = {
2241
2233
gotoUrl : null ,
2242
2234
isSub : false ,
2243
2235
update : false ,
2244
- contentKey :"profil" ,
2245
- folder : "communecter" , //on force pour pas casser toutes les vielles images
2236
+ folder : moduleId , //on force pour pas casser toutes les vielles images
2246
2237
set : function ( type , id ) {
2247
2238
uploadObj . type = type ;
2248
2239
mylog . log ( "set uploadObj.id" , id ) ;
@@ -2273,7 +2264,7 @@ var dyFObj = {
2273
2264
formData . key = ctrl ;
2274
2265
mylog . warn ( "here--- -------- elementLocations" , dyFInputs . locationObj ) ;
2275
2266
mylog . warn ( "here--- -------- elementLocations" , dyFInputs . locationObj . elementLocations ) ;
2276
- if ( dyFInputs . locationObj . centerLocation ) {
2267
+ if ( dyFInputs . locationObj . elementLocations ) {
2277
2268
//formData.multiscopes = elementLocation;
2278
2269
mylog . warn ( "here--- -------- centerLocation" , dyFInputs . locationObj . centerLocation ) ;
2279
2270
formData . address = dyFInputs . locationObj . centerLocation . address ;
@@ -2488,10 +2479,6 @@ var dyFObj = {
2488
2479
$ . unblockUI ( ) ;
2489
2480
$ ( "#openModal" ) . modal ( "hide" ) ;
2490
2481
mylog . warn ( "--------------- Open Form " , type , afterLoad , data ) ;
2491
- uploadObj . contentKey = "profil" ;
2492
- if ( type == "addPhoto" )
2493
- uploadObj . contentKey = "slider" ;
2494
-
2495
2482
mylog . dir ( data ) ;
2496
2483
//global variables clean up
2497
2484
dyFInputs . locationObj . elementLocation = null ;
@@ -2764,12 +2751,6 @@ var dyFInputs = {
2764
2751
urlCtrl . loadByHash ( location . hash ) ;
2765
2752
$ ( '#ajax-modal' ) . modal ( "hide" ) ;
2766
2753
} ) ;
2767
-
2768
- $ ( "#ajax-modal .modal-header" ) . removeClass ( "bg-dark bg-purple bg-red bg-azure bg-green bg-green-poi bg-orange bg-yellow bg-blue bg-turq bg-url" )
2769
- . addClass ( "bg-dark" ) ;
2770
-
2771
- $ ( "#ajax-modal-modal-title" ) . html ( "<i class='fa fa-camera'></i> Publier une photo" ) ;
2772
-
2773
2754
} , 500 ) ;
2774
2755
}
2775
2756
} ,
@@ -2885,37 +2866,22 @@ var dyFInputs = {
2885
2866
if ( locObj . address . addressCountry )
2886
2867
strHTML += locObj . address . addressCountry ;
2887
2868
if ( locObj . address . postalCode )
2888
- strHTML += ", " + locObj . address . postalCode ;
2869
+ strHTML += " , " + locObj . address . postalCode ;
2889
2870
if ( locObj . address . addressLocality )
2890
- strHTML += ", " + locObj . address . addressLocality ;
2871
+ strHTML += " , " + locObj . address . addressLocality ;
2891
2872
if ( locObj . address . streetAddress )
2892
- strHTML += ", " + locObj . address . streetAddress ;
2873
+ strHTML += " , " + locObj . address . streetAddress ;
2893
2874
var btnSuccess = "" ;
2894
2875
var locCenter = "" ;
2895
2876
if ( dyFInputs . locationObj . countLocation == 0 ) {
2896
2877
btnSuccess = "btn-success" ;
2897
- locCenter = "<span class='lblcentre'> addresse principale </span>" ;
2878
+ locCenter = "<span class='lblcentre'>(localité centrale) </span>" ;
2898
2879
}
2899
2880
2900
- strHTML =
2901
- "<div class='col-md-12 col-sm-12 col-xs-12 text-left shadow2 padding-15 margin-top-15 margin-bottom-15'>" +
2902
- "<span class='pull-left locationEl" + dyFInputs . locationObj . countLocation + " locel text-red bold'>" +
2903
- "<i class='fa fa-home fa-2x'></i> " +
2904
- strHTML +
2905
- "</span> " +
2906
-
2907
- "<a href='javascript:dyFInputs.locationObj.removeLocation(" + dyFInputs . locationObj . countLocation + ")' " +
2908
- "class=' locationEl" + dyFInputs . locationObj . countLocation + " btn btn-sm btn-danger pull-right'> " +
2909
- "<i class='fa fa-times'></i> Effacer" +
2910
- "</a>" +
2911
-
2912
- "<a href='javascript:dyFInputs.locationObj.setAsCenter(" + dyFInputs . locationObj . countLocation + ")' " +
2913
- "class='margin-right-5 centers pull-right center" + dyFInputs . locationObj . countLocation + " locationEl" + dyFInputs . locationObj . countLocation + " btn btn-sm " + btnSuccess + "'> " +
2914
- "<i class='fa fa-map-marker'></i> " + locCenter +
2915
- "</a>" +
2916
-
2917
- "</div>" ;
2918
- $ ( ".locationlocation" ) . append ( strHTML ) ;
2881
+ strHTML = "<a href='javascript:dyFInputs.locationObj.removeLocation(" + dyFInputs . locationObj . countLocation + ")' class=' locationEl" + dyFInputs . locationObj . countLocation + " btn'> <i class='text-red fa fa-times'></i></a>" +
2882
+ "<span class='locationEl" + dyFInputs . locationObj . countLocation + " locel text-azure'>" + strHTML + "</span> " +
2883
+ "<a href='javascript:dyFInputs.locationObj.setAsCenter(" + dyFInputs . locationObj . countLocation + ")' class='centers center" + dyFInputs . locationObj . countLocation + " locationEl" + dyFInputs . locationObj . countLocation + " btn btn-xs " + btnSuccess + "'> <i class='fa fa-map-marker'></i>" + locCenter + "</a> <br/>" ;
2884
+ $ ( ".locationlocation" ) . prepend ( strHTML ) ;
2919
2885
dyFInputs . locationObj . countLocation ++ ;
2920
2886
} ,
2921
2887
copyPCForm2Dynform : function ( postalCodeObj ) {
@@ -2963,7 +2929,7 @@ var dyFInputs = {
2963
2929
delete v . center ;
2964
2930
} )
2965
2931
$ ( ".centers" ) . removeClass ( 'btn-success' ) ;
2966
- $ ( ".center" + ix ) . addClass ( 'btn-success' ) . append ( " <span class='lblcentre'> addresse principale </span>" ) ;
2932
+ $ ( ".center" + ix ) . addClass ( 'btn-success' ) . append ( " <span class='lblcentre'>(localité centrale) </span>" ) ;
2967
2933
dyFInputs . locationObj . centerLocation = dyFInputs . locationObj . elementLocations [ ix ] ;
2968
2934
dyFInputs . locationObj . elementLocations [ ix ] . center = true ;
2969
2935
}
@@ -3021,6 +2987,7 @@ var dyFInputs = {
3021
2987
var startDate = "" ;
3022
2988
var endDate = "" ;
3023
2989
$ ( "#ajaxFormModal #allDay" ) . val ( $ ( "#ajaxFormModal #allDay" ) . is ( ':checked' ) ) ;
2990
+
3024
2991
if ( allDay ) {
3025
2992
$ ( ".dateTimeInput" ) . addClass ( "dateInput" ) ;
3026
2993
$ ( ".dateTimeInput" ) . removeClass ( "dateTimeInput" ) ;
@@ -3255,15 +3222,13 @@ var typeObj = {
3255
3222
}
3256
3223
} } ,
3257
3224
"addPhoto" :{
3258
- icon :"upload" ,
3259
- color :"dark" ,
3260
3225
dynForm : {
3261
3226
jsonSchema : {
3262
- title : "Ajouter des images à l'album ?" ,
3263
- icon : "upload " ,
3227
+ title : "Uploader une image ?" ,
3228
+ icon : "question-cirecle-o " ,
3264
3229
noSubmitBtns : true ,
3265
3230
properties : {
3266
- image : dyFInputs . imageAddPhoto ,
3231
+ image : dyFInputs . imageAddPhoto
3267
3232
}
3268
3233
}
3269
3234
} } ,
@@ -3921,6 +3886,5 @@ function test(params, itemType){
3921
3886
$ ( document ) . ready ( function ( ) {
3922
3887
setTimeout ( function ( ) { checkPoll ( ) } , 10000 ) ;
3923
3888
document . onkeyup = keyboardNav . checkKeycode ;
3924
- if ( notNull ( userId ) && userId != "" )
3925
- bindRightClicks ( ) ;
3889
+ bindRightClicks ( ) ;
3926
3890
} ) ;
0 commit comments