Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
haskell-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
195
Issues
195
List
Board
Labels
Milestones
Merge Requests
12
Merge Requests
12
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
gargantext
haskell-gargantext
Commits
cbcf903c
Commit
cbcf903c
authored
Mar 10, 2022
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FIX] Phylo Document list
parent
109d8b9e
Pipeline
#2554
failed with stage
in 43 minutes and 58 seconds
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
9 deletions
+9
-9
Tools.hs
src/Gargantext/Core/Viz/Phylo/API/Tools.hs
+8
-8
PhyloTools.hs
src/Gargantext/Core/Viz/Phylo/PhyloTools.hs
+1
-1
No files found.
src/Gargantext/Core/Viz/Phylo/API/Tools.hs
View file @
cbcf903c
...
@@ -121,15 +121,15 @@ context2phyloDocument :: TimeUnit
...
@@ -121,15 +121,15 @@ context2phyloDocument :: TimeUnit
context2phyloDocument
timeUnit
context
(
ngs_terms
,
ngs_sources
)
=
do
context2phyloDocument
timeUnit
context
(
ngs_terms
,
ngs_sources
)
=
do
let
contextId
=
_context_id
context
let
contextId
=
_context_id
context
(
date
,
date'
)
<-
context2date
context
timeUnit
(
date
,
date'
)
<-
context2date
context
timeUnit
text
<-
Map
.
lookup
contextId
ngs_terms
sources
<-
Map
.
lookup
contextId
ngs_sources
let
pure
$
Document
date
date'
(
toText
text
)
Nothing
(
toText
sources
)
where
toText
x
=
Set
.
toList
$
Set
.
map
unNgramsTerm
x
toText
x
=
Set
.
toList
$
Set
.
map
unNgramsTerm
x
text'
=
maybe
[]
toText
$
Map
.
lookup
contextId
ngs_terms
sources'
=
maybe
[]
toText
$
Map
.
lookup
contextId
ngs_sources
pure
$
Document
date
date'
text'
Nothing
sources'
context2date
::
Context
HyperdataDocument
->
TimeUnit
->
Maybe
(
Date
,
Text
)
context2date
::
Context
HyperdataDocument
->
TimeUnit
->
Maybe
(
Date
,
Text
)
context2date
context
timeUnit
=
do
context2date
context
timeUnit
=
do
...
...
src/Gargantext/Core/Viz/Phylo/PhyloTools.hs
View file @
cbcf903c
...
@@ -140,7 +140,7 @@ periodsToYears periods = (Set.fromList . sort . concat)
...
@@ -140,7 +140,7 @@ periodsToYears periods = (Set.fromList . sort . concat)
findBounds
::
[
Date
]
->
(
Date
,
Date
)
findBounds
::
[
Date
]
->
(
Date
,
Date
)
findBounds
[]
=
panic
"[G.C.V.P.PhyloTools]
nod D
ates for find bounds"
findBounds
[]
=
panic
"[G.C.V.P.PhyloTools]
empty d
ates for find bounds"
findBounds
dates
=
findBounds
dates
=
let
dates'
=
sort
dates
let
dates'
=
sort
dates
in
(
head'
"findBounds"
dates'
,
last'
"findBounds"
dates'
)
in
(
head'
"findBounds"
dates'
,
last'
"findBounds"
dates'
)
...
...
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