Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
co2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jean-Baptiste HUBER
co2
Commits
dcc6337a
Commit
dcc6337a
authored
Feb 13, 2019
by
Clément Damiens
Browse files
Options
Browse Files
Download
Plain Diff
Merged branch master into master
parents
3c5d46cd
79b0b324
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
68 additions
and
13 deletions
+68
-13
controllers/DatamigrationController.php
controllers/DatamigrationController.php
+24
-0
views/network/simplyDirectory.php
views/network/simplyDirectory.php
+44
-13
No files found.
controllers/DatamigrationController.php
View file @
dcc6337a
...
...
@@ -5478,6 +5478,30 @@ if( Role::isSuperAdmin(Role::getRolesUserId(Yii::app()->session["userId"]) )){
echo
"Number of user with preferences modified : "
.
$nbUser
;
}
}
public
function
actionReferenceFail
()
{
if
(
Role
::
isSuperAdmin
(
Role
::
getRolesUserId
(
Yii
::
app
()
->
session
[
"userId"
])
)){
$nbUser
=
0
;
$mails
=
PHDB
::
find
(
Cron
::
COLLECTION
,
array
(
"status"
=>
"fail"
,
"tpl"
=>
"referenceEmailInElement"
)
);
//Rest::json($mails); exit;
foreach
(
$mails
as
$keyE
=>
$elt
)
{
$res
=
PHDB
::
update
(
Cron
::
COLLECTION
,
array
(
"_id"
=>
new
MongoId
(
$keyE
)),
array
(
'$set'
=>
array
(
"status"
=>
"pending"
)
)
);
if
(
$res
[
"ok"
]
==
1
){
$nbUser
++
;
}
else
{
echo
"<br/> Error with user id : "
.
$key
;
}
}
//Rest::json($tags); exit;
echo
"Number of mails with status modified : "
.
$nbUser
;
}
}
}
...
...
views/network/simplyDirectory.php
View file @
dcc6337a
...
...
@@ -46,6 +46,7 @@ Yii::app()->theme->baseUrl. '/assets');
<script
type=
"text/javascript"
>
var
contextMapNetwork
=
[];
var
activeMapNetwork
=
[];
//var contextNow = [];
var
currentKFormType
=
""
;
var
indexStepInit
=
100
;
...
...
@@ -174,8 +175,8 @@ function addTooltips(){
function
bindNetwork
(){
// mylog.log("bindNetwork");
$
(
'
#btn-toogle-map
'
).
click
(
function
(
e
){
showMapNetwork
();
$
(
'
#btn-toogle-map
'
).
click
(
function
(
e
){
showMapNetwork
();
updateMap
();
});
...
...
@@ -218,6 +219,7 @@ function bindNetwork(){
});
$
(
'
#btn-menu-launch
'
).
click
(
function
(){
//alert('#btn-menu-launch');
// mylog.log("#btn-menu-launch", $(this).hasClass("active"));
if
(
!
$
(
this
).
hasClass
(
"
active
"
)){
$
(
this
).
addClass
(
"
active
"
);
...
...
@@ -576,6 +578,7 @@ function dataSuccess(data, indexMin, indexMax, locality){
// mylog.log("Tags element", o.tags);
mapElements
.
push
(
o
);
contextMapNetwork
.
push
(
o
);
activeMapNetwork
.
push
(
o
);
});
//end each
if
(
str
==
""
)
{
...
...
@@ -672,6 +675,22 @@ function dataSuccess(data, indexMin, indexMax, locality){
$
(
"
#countResult
"
).
html
(
length
+
"
résultat
"
+
s
);
geoShapeCity
();
$
.
unblockUI
();
if
(
typeof
networkJson
.
skin
.
open
!=
"
undefined
"
){
if
(
typeof
networkJson
.
skin
.
open
.
lists
!=
"
undefined
"
&&
networkJson
.
skin
.
open
.
lists
==
true
){
//$("#btn-toogle-map").trigger("click");
setTimeout
(
function
(){
showMapNetwork
();
calendarNetwork
();
},
1000
);
//alert("HERE");
}
if
(
typeof
networkJson
.
skin
.
open
.
filter
!=
"
undefined
"
&&
networkJson
.
skin
.
open
.
filter
==
true
){
//alert("HERE");
$
(
"
#btn-menu-launch
"
).
trigger
(
"
click
"
);
}
}
}
function
tagActivedUpdate
(
checked
,
tag
,
parent
){
...
...
@@ -1320,22 +1339,22 @@ function updateMap(){
filteredList
=
contextMapNetwork
;
}
}
activeMapNetwork
=
filteredList
;
$
.
each
(
filteredList
,
function
(
e
,
v
){
$
(
"
.contain_
"
+
v
.
type
+
"
_
"
+
v
.
id
).
show
(
700
);
});
//contextNow = filteredList;
if
(
typeof
networkJson
.
add
!=
"
undefined
"
&&
typeof
networkJson
.
add
.
event
!=
"
undefined
"
&&
networkJson
.
add
.
event
==
true
){
$
(
"
#profil-content-calendar
"
).
fullCalendar
(
'
destroy
'
);
calendar
.
showCalendar
(
"
#profil-content-calendar
"
,
filteredList
,
"
month
"
);
$
(
"
#profil-content-calendar
"
).
fullCalendar
(
"
gotoDate
"
,
moment
(
Date
.
now
()));
$
(
window
).
on
(
'
resize
'
,
function
(){
$
(
"
#profil-content-calendar
"
).
fullCalendar
(
'
destroy
'
);
calendar
.
showCalendar
(
"
#profil-content-calendar
"
,
filteredList
,
"
month
"
);
});
}
calendarNetwork
();
//
if( typeof networkJson.add != "undefined" && typeof networkJson.add.event != "undefined" && networkJson.add.event == true){
//
$("#profil-content-calendar").fullCalendar('destroy');
//
calendar.showCalendar("#profil-content-calendar", filteredList, "month");
//
$("#profil-content-calendar").fullCalendar("gotoDate", moment(Date.now()));
//
$(window).on('resize', function(){
//
$("#profil-content-calendar").fullCalendar('destroy');
//
calendar.showCalendar("#profil-content-calendar", filteredList, "month");
//
});
//
}
...
...
@@ -1353,6 +1372,18 @@ function updateMap(){
$
.
unblockUI
();
}
function
calendarNetwork
(){
if
(
typeof
networkJson
.
add
!=
"
undefined
"
&&
typeof
networkJson
.
add
.
event
!=
"
undefined
"
&&
networkJson
.
add
.
event
==
true
){
$
(
"
#profil-content-calendar
"
).
fullCalendar
(
'
destroy
'
);
calendar
.
showCalendar
(
"
#profil-content-calendar
"
,
activeMapNetwork
,
"
month
"
);
$
(
"
#profil-content-calendar
"
).
fullCalendar
(
"
gotoDate
"
,
moment
(
Date
.
now
()));
$
(
window
).
on
(
'
resize
'
,
function
(){
$
(
"
#profil-content-calendar
"
).
fullCalendar
(
'
destroy
'
);
calendar
.
showCalendar
(
"
#profil-content-calendar
"
,
activeMapNetwork
,
"
month
"
);
});
}
}
function
addTabMap
(
element
,
tab
){
if
(
"
undefined
"
!=
typeof
element
.
geo
&&
element
.
geo
!=
null
)
tab
.
push
(
element
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment