Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Pierre Goubeaux
co2
Commits
0e2876a2
Commit
0e2876a2
authored
Jan 23, 2019
by
Tibor Katelbach
Browse files
tweaks
parent
6e789d70
Changes
4
Hide whitespace changes
Inline
Side-by-side
assets/js/co.js
View file @
0e2876a2
...
...
@@ -842,6 +842,7 @@ var urlCtrl = {
}
return
hash
;
},
firstLoad
:
true
,
jsController
:
function
(
hash
){
mylog
.
log
(
"
jsController
"
,
hash
);
hash
=
urlCtrl
.
checkAndConvert
(
hash
);
...
...
@@ -922,9 +923,19 @@ var urlCtrl = {
//go get the path , module is given in the hash
//console.log(">>>>>>>>>>>>>>>>>>> module path",path);
}
// console.log(">>>>>>>>>>>>>>>>>>> mod",mod,"> path : ",path,"> urlExtra : ",urlExtra,"> extraParams : ",extraParams);
// alert(baseUrl+'/'+ mod +path+urlExtra+extraParams);
showAjaxPanel
(
baseUrl
+
'
/
'
+
mod
+
path
+
urlExtra
+
extraParams
,
endPoint
.
title
,
endPoint
.
icon
,
res
,
endPoint
);
if
(
path
==
"
dda
"
&&
extraParams
!=
""
&&
urlCtrl
.
firstLoad
){
urlCtrl
.
afterLoad
=
function
()
{
extraParams
=
extraParams
.
substring
(
1
);
extraParamsT
=
extraParams
.
split
(
"
.
"
);
uiCoop
.
prepPreview
(
extraParamsT
[
0
],
extraParamsT
[
1
],
null
,
extraParamsT
[
2
],
extraParamsT
[
3
],
null
);
}
}
}
urlCtrl
.
firstLoad
=
false
;
if
(
endPoint
.
menu
)
$
(
"
.
"
+
endPoint
.
menu
).
removeClass
(
"
hide
"
);
...
...
@@ -1131,7 +1142,7 @@ var urlCtrl = {
}
else
showAjaxPanel
(
baseUrl
+
'
/
'
+
moduleId
+
'
/app/index
'
,
'
Home
'
,
'
home
'
);
}
});
}
);
}
else
{
//if(typeof custom == "undefined" || typeof custom.url=="undefined")
showAjaxPanel
(
baseUrl
+
'
/
'
+
moduleId
+
'
/app/index
'
,
'
Home
'
,
'
home
'
);
...
...
@@ -1144,21 +1155,21 @@ var urlCtrl = {
}
else
showAjaxPanel
(
baseUrl
+
'
/
'
+
moduleId
+
'
/app/index
'
,
'
Home
'
,
'
home
'
);
mylog
.
log
(
"
END loadByHash hash:
"
,
hash
);
location
.
hash
=
hash
;
if
(
location
.
hash
.
indexOf
(
"
#panel
"
)
>=
0
){
panelName
=
location
.
hash
.
substr
(
7
);
mylog
.
log
(
"
panelName
"
,
panelName
);
if
(
userId
==
""
){
if
(
panelName
==
"
box-login
"
)
Login
.
openLogin
();
else
if
(
panelName
==
"
box-register
"
)
$
(
'
#modalRegister
'
).
modal
(
"
show
"
);
}
}
panelName
=
location
.
hash
.
substr
(
7
);
mylog
.
log
(
"
panelName
"
,
panelName
);
if
(
userId
==
""
){
if
(
panelName
==
"
box-login
"
)
Login
.
openLogin
();
else
if
(
panelName
==
"
box-register
"
)
$
(
'
#modalRegister
'
).
modal
(
"
show
"
);
}
}
/*if(typeof back == "function"){
alert("back");
back();
...
...
assets/js/default/directory.js
View file @
0e2876a2
...
...
@@ -672,68 +672,8 @@ function initPageTable(number){
var
parentId
=
$
(
this
).
data
(
"
coop-parentid
"
);
var
parentType
=
$
(
this
).
data
(
"
coop-parenttype
"
);
var
afterLoad
=
null
;
if
(
$
(
this
).
data
(
"
coop-section
"
)
){
coopSection
=
$
(
this
).
data
(
"
coop-section
"
);
if
(
coopSection
==
"
amendments
"
){
afterLoad
=
function
()
{
uiCoop
.
showAmendement
(
true
);
if
(
$
(
"
#form-amendement
"
).
hasClass
(
"
hidden
"
))
$
(
"
#form-amendement
"
).
removeClass
(
"
hidden
"
);
else
$
(
"
#form-amendement
"
).
addClass
(
"
hidden
"
);
};
}
else
if
(
coopSection
==
"
vote
"
){
mylog
.
log
(
"
HERE .openCoopPanelHtml vote
"
);
afterLoad
=
function
()
{
setTimeout
(
function
(){
$
(
"
#coop-container
"
).
animate
({
scrollTop
:
$
(
"
#podVote
"
).
offset
().
top
},
1000
);
},
1000
);
};
}
else
if
(
coopSection
==
"
comments
"
){
afterLoad
=
function
()
{
setTimeout
(
function
(){
$
(
"
#coop-container
"
).
animate
({
scrollTop
:
$
(
"
.btn-select-arg-comment
"
).
offset
().
top
},
1000
);
},
1000
);
};
}
}
coopType
=
coopType
==
"
actions
"
?
"
action
"
:
coopType
;
coopType
=
coopType
==
"
proposals
"
?
"
proposal
"
:
coopType
;
coopType
=
coopType
==
"
resolutions
"
?
"
resolution
"
:
coopType
;
console
.
log
(
"
HERE onclick coopPanelHtml
"
,
coopType
,
coopId
,
idParentRoom
,
parentId
,
parentType
);
if
(
notNull
(
contextData
)
&&
contextData
.
id
==
parentId
&&
contextData
.
type
==
parentType
&&
typeof
isOnepage
==
"
undefined
"
&&
idParentRoom
!=
""
){
toastr
.
info
(
trad
[
"
processing
"
]);
uiCoop
.
startUI
();
$
(
"
#modalCoop
"
).
modal
(
"
show
"
);
onchangeClick
=
false
;
if
(
coopType
==
"
rooms
"
){
uiCoop
.
getCoopData
(
contextData
.
type
,
contextData
.
id
,
"
room
"
,
null
,
coopId
);
}
else
{
setTimeout
(
function
(){
uiCoop
.
getCoopData
(
contextData
.
type
,
contextData
.
id
,
"
room
"
,
null
,
idParentRoom
,
function
(){
toastr
.
info
(
trad
[
"
processing
"
]);
uiCoop
.
getCoopData
(
contextData
.
type
,
contextData
.
id
,
coopType
,
null
,
coopId
);
},
false
);
},
1000
);
}
}
else
{
if
(
coopType
==
"
rooms
"
){
var
hash
=
"
#page.type.
"
+
parentType
+
"
.id.
"
+
parentId
+
"
.view.coop.room.
"
+
idParentRoom
+
"
.
"
+
coopType
+
"
.
"
+
coopId
;
urlCtrl
.
loadByHash
(
hash
);
}
else
{
uiCoop
.
getCoopDataPreview
(
coopType
,
coopId
,
afterLoad
);
}
}
location
.
hash
=
"
#dda?
"
+
coopType
+
"
.
"
+
coopId
+
"
.
"
+
parentId
+
"
.
"
+
parentType
;
uiCoop
.
prepPreview
(
coopType
,
coopId
,
idParentRoom
,
parentId
,
parentType
,
afterLoad
);
});
...
...
assets/js/dynForm/proposal.js
View file @
0e2876a2
...
...
@@ -217,7 +217,7 @@ dynForm = {
beforeBuild
:
function
(){
//alert("before Build orga");
dyFObj
.
setMongoId
(
'
proposals
'
,
function
(){
uploadObj
.
gotoUrl
=
'
#
page.type.proposals.id.
'
+
uploadObj
.
id
;
uploadObj
.
gotoUrl
=
'
#
dda
'
;
//
+uploadObj.id;
});
},
beforeSave
:
function
(){
...
...
@@ -278,6 +278,11 @@ dynForm = {
},
setTitle
:
function
()
{
$
(
"
#ajax-modal-modal-title
"
).
html
(
tradDynForm
.
addMeasure
);
},
rename
:
function
()
{
$
.
each
(
custom
.
dynForm
.
proposal
.
onload
.
rename
,
function
(
k
,
v
)
{
$
(
"
.
"
+
k
).
html
(
v
)
});
}
},
afterSave
:
function
(
data
){
...
...
views/app/search.php
View file @
0e2876a2
...
...
@@ -169,22 +169,19 @@ var scrollEnd = false;
var
currentKFormType
=
""
;
jQuery
(
document
).
ready
(
function
()
{
initCountType
();
var
typeUrl
=
"
?nopreload=true
"
;
if
(
type
!=
''
)
typeUrl
=
"
?type=
"
+
type
+
"
&nopreload=true
"
;
//alert(baseUrl+'/'+moduleId+"/default/directoryjs"+typeUrl);
getAjax
(
'
#page
'
,
baseUrl
+
'
/
'
+
moduleId
+
"
/default/directoryjs
"
+
typeUrl
,
function
(){
//anny double section filter directory
//anny double section filter directory
if
(
type
==
"
all
"
)
searchAllEngine
.
initSearch
();
loadingData
=
false
;
initTypeSearch
(
type
);
initSearchObject
();
startSearch
(
searchObject
.
indexMin
,
null
,
searchCallback
);
initSearchInterface
();
},
"
html
"
);
initSearchInterface
();
...
...
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