Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
minerva
core
Commits
6489f848
Commit
6489f848
authored
Apr 24, 2019
by
Piotr Gawron
Browse files
sorting in edit project dialog fixed
parent
d78cd97a
Changes
3
Hide whitespace changes
Inline
Side-by-side
frontend-js/src/main/js/GuiConnector.js
View file @
6489f848
...
...
@@ -106,6 +106,13 @@ GuiConnector.prototype.init = function () {
};
}
newUrl
=
""
;
//sorting of datatable column by input value https://stackoverflow.com/a/29221907/1127920
$
.
fn
.
dataTable
.
ext
.
order
[
'
dom-input
'
]
=
function
(
settings
,
col
)
{
return
this
.
api
().
column
(
col
,
{
order
:
'
index
'
}).
nodes
().
map
(
function
(
td
,
i
)
{
return
$
(
'
input
'
,
td
).
val
();
});
}
};
...
...
frontend-js/src/main/js/gui/admin/CommentsAdminPanel.js
View file @
6489f848
...
...
@@ -61,7 +61,8 @@ CommentsAdminPanel.prototype._createGui = function () {
},
{
title
:
'
Content
'
},
{
title
:
'
Removed
'
title
:
'
Removed
'
,
orderable
:
false
},
{
title
:
'
Pinned
'
}]
...
...
frontend-js/src/main/js/gui/admin/EditProjectDialog.js
View file @
6489f848
...
...
@@ -325,13 +325,17 @@ EditProjectDialog.prototype._createMapsTable = function () {
},
{
title
:
'
Name
'
},
{
title
:
'
Default center x
'
title
:
'
Default center x
'
,
orderable
:
false
},
{
title
:
'
Default center y
'
title
:
'
Default center y
'
,
orderable
:
false
},
{
title
:
'
Default zoom level
'
title
:
'
Default zoom level
'
,
orderable
:
false
},
{
title
:
'
Update
'
title
:
'
Update
'
,
orderable
:
false
}]
});
...
...
@@ -397,18 +401,31 @@ EditProjectDialog.prototype._createOverlayTable = function () {
},
{
title
:
'
Description
'
},
{
title
:
'
Public
'
title
:
'
Public
'
,
orderable
:
false
},
{
title
:
'
Default
'
title
:
'
Default
'
,
orderable
:
false
},
{
title
:
'
Owner
'
title
:
'
Owner
'
,
orderable
:
false
},
{
title
:
'
Data
'
title
:
'
Data
'
,
orderable
:
false
},
{
title
:
'
Update
'
title
:
'
Update
'
,
orderable
:
false
},
{
title
:
'
Remove
'
title
:
'
Remove
'
,
orderable
:
false
}],
columnDefs
:
[
{
orderDataType
:
"
dom-input
"
,
type
:
"
string
"
,
targets
:
[
1
,
2
]
}
],
dom
:
'
<"minerva-datatable-toolbar">frtip
'
,
initComplete
:
function
()
{
$
(
"
div.minerva-datatable-toolbar
"
,
$
(
result
)).
html
(
'
<button name="addOverlay">Add overlay</button>
'
);
...
...
@@ -437,7 +454,7 @@ EditProjectDialog.prototype._createOverlayTable = function () {
var
button
=
this
;
return
self
.
getServerConnector
().
getOverlaySourceDownloadUrl
({
overlayId
:
$
(
button
).
attr
(
"
data
"
),
projectId
:
self
.
getProject
().
getProjectId
()
projectId
:
self
.
getProject
().
getProjectId
()
}).
then
(
function
(
url
)
{
return
self
.
downloadFile
(
url
);
}).
then
(
null
,
GuiConnector
.
alert
);
...
...
@@ -622,7 +639,8 @@ EditProjectDialog.prototype.initUsersTab = function () {
var
columns
=
self
.
createUserPrivilegeColumns
();
$
(
usersTable
).
DataTable
({
columns
:
columns
columns
:
columns
,
ordering
:
false
});
return
Promise
.
resolve
();
};
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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