Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
purescript-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Grégoire Locqueville
purescript-gargantext
Commits
a934950a
Commit
a934950a
authored
Jul 29, 2019
by
Przemyslaw Kaminski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[DocsTable] orderBy is DateAsc by default, no Maybe type
parent
8e98fe89
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
DocsTable.purs
src/Gargantext/Components/DocsTable.purs
+8
-8
No files found.
src/Gargantext/Components/DocsTable.purs
View file @
a934950a
...
@@ -218,11 +218,11 @@ loadPage :: PageParams -> Aff (Array DocumentsView)
...
@@ -218,11 +218,11 @@ loadPage :: PageParams -> Aff (Array DocumentsView)
loadPage {nodeId, tabType, query, listId, corpusId, params: {limit, offset, orderBy}} = do
loadPage {nodeId, tabType, query, listId, corpusId, params: {limit, offset, orderBy}} = do
logs "loading documents page: loadPage with Offset and limit"
logs "loading documents page: loadPage with Offset and limit"
-- res <- get $ toUrl Back (Tab tabType offset limit (convOrderBy <$> orderBy)) (Just nodeId)
-- res <- get $ toUrl Back (Tab tabType offset limit (convOrderBy <$> orderBy)) (Just nodeId)
let url = (toUrl Back Node (Just nodeId)) <> "/
search
"
let url = (toUrl Back Node (Just nodeId)) <> "/
table
"
res <- post url $ TabPostQuery {
res <- post url $ TabPostQuery {
offset
offset
, limit
, limit
, orderBy: convOrderBy
<$>
orderBy
, orderBy: convOrderBy orderBy
, tabType
, tabType
, query
, query
}
}
...
@@ -241,12 +241,12 @@ loadPage {nodeId, tabType, query, listId, corpusId, params: {limit, offset, orde
...
@@ -241,12 +241,12 @@ loadPage {nodeId, tabType, query, listId, corpusId, params: {limit, offset, orde
, category : r.category
, category : r.category
, ngramCount : r.ngramCount
, ngramCount : r.ngramCount
}
}
convOrderBy (
T.ASC (T.ColumnName "Date"
)) = DateAsc
convOrderBy (
Just (T.ASC (T.ColumnName "Date")
)) = DateAsc
convOrderBy (
T.DESC (T.ColumnName "Date"
)) = DateDesc
convOrderBy (
Just (T.DESC (T.ColumnName "Date")
)) = DateDesc
convOrderBy (
T.ASC (T.ColumnName "Title"
)) = TitleAsc
convOrderBy (
Just (T.ASC (T.ColumnName "Title")
)) = TitleAsc
convOrderBy (
T.DESC (T.ColumnName "Title"
)) = TitleDesc
convOrderBy (
Just (T.DESC (T.ColumnName "Title")
)) = TitleDesc
convOrderBy (
T.ASC (T.ColumnName "Source"
)) = SourceAsc
convOrderBy (
Just (T.ASC (T.ColumnName "Source")
)) = SourceAsc
convOrderBy (
T.DESC (T.ColumnName "Source"
)) = SourceDesc
convOrderBy (
Just (T.DESC (T.ColumnName "Source")
)) = SourceDesc
convOrderBy _ = DateAsc -- TODO
convOrderBy _ = DateAsc -- TODO
...
...
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