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
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
Christian Merten
haskell-gargantext
Commits
5b622921
Commit
5b622921
authored
May 12, 2022
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FIX] Date Parser for WOS
parent
04520d5f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
10 deletions
+13
-10
gargantext.cabal
gargantext.cabal
+2
-2
Date.hs
src/Gargantext/Core/Text/Corpus/Parsers/Date.hs
+3
-0
WOS.hs
src/Gargantext/Core/Text/Corpus/Parsers/WOS.hs
+8
-8
No files found.
gargantext.cabal
View file @
5b622921
cabal-version:
0.0.5.8.9
cabal-version:
1.12
-- This file has been generated from package.yaml by hpack version 0.34.4.
--
-- see: https://github.com/sol/hpack
name: gargantext
version: 0.0.5.8.9
version:
0.0.5.8.9
synopsis: Search, map, share
description: Please see README.md
category: Data
...
...
src/Gargantext/Core/Text/Corpus/Parsers/Date.hs
View file @
5b622921
...
...
@@ -105,6 +105,9 @@ dateFlow (DucklingFailure txt) = case readDate $ replace " " "T" txt of
Nothing
->
dateFlow
(
ReadFailure1
txt
)
Just
ok
->
DateFlowSuccess
ok
dateFlow
(
ReadFailure1
txt
)
=
case
readDate
txt
of
Nothing
->
dateFlow
$
ReadFailure2
txt
Just
ok
->
DateFlowSuccess
ok
dateFlow
(
ReadFailure2
txt
)
=
case
readDate
$
replace
" "
""
txt
<>
"-01-01T00:00:00"
of
Nothing
->
DateFlowFailure
Just
ok
->
DateFlowSuccess
ok
dateFlow
_
=
DateFlowFailure
...
...
src/Gargantext/Core/Text/Corpus/Parsers/WOS.hs
View file @
5b622921
...
...
@@ -47,11 +47,11 @@ notice = start *> many (fieldWith field) <* end
keys
::
ByteString
->
ByteString
keys
champs
|
champs
==
"AF"
=
"authors"
|
champs
==
"TI"
=
"title"
|
champs
==
"SO"
=
"source"
|
champs
==
"DI"
=
"doi"
|
champs
==
"PD
"
=
"publication_date"
|
champs
==
"AB"
=
"abstract"
|
otherwise
=
champs
keys
field
|
field
==
"AF"
=
"authors"
|
field
==
"TI"
=
"title"
|
field
==
"SO"
=
"source"
|
field
==
"DI"
=
"doi"
|
field
==
"PY
"
=
"publication_date"
|
field
==
"AB"
=
"abstract"
|
otherwise
=
field
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