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
7dce5289
Commit
7dce5289
authored
Sep 10, 2021
by
Przemyslaw Kaminski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[facet] fix abstract search for documents
parent
1d311b08
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
Facet.hs
src/Gargantext/Database/Query/Facet.hs
+2
-1
No files found.
src/Gargantext/Database/Query/Facet.hs
View file @
7dce5289
...
...
@@ -334,8 +334,9 @@ viewDocuments cId t mQuery = proc () -> do
let
query
=
(
fromMaybe
""
mQuery
)
iLikeQuery
=
T
.
intercalate
""
[
"%"
,
query
,
"%"
]
abstractLHS
h
=
fromNullable
(
pgStrictText
""
)
$
toNullable
h
.->>
(
pgStrictText
"abstract"
)
restrict
-<
((
n
^.
node_name
)
`
ilike
`
(
pgStrictText
iLikeQuery
))
.||
(
(
fromNullable
(
pgStrictText
""
)
((
toNullable
$
n
^.
node_hyperdata
)
.->>
(
pgStrictText
"source"
)))
`
ilike
`
(
pgStrictText
iLikeQuery
)
)
(
abstractLHS
(
n
^.
node_hyperdata
))
`
ilike
`
(
pgStrictText
iLikeQuery
)
--((n^.node_hyperdata .:? "source") `ilike` (pgStrictText iLikeQuery))
-- NOTE Title is under node_name
-- Abstract is under node_hyperdata -> source
...
...
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