Commit e4c0ac4d authored by Karen Konou's avatar Karen Konou

[Docs table] reenable date filter, fix date query string

parent 73e07f35
...@@ -48,8 +48,7 @@ chartWith options = ...@@ -48,8 +48,7 @@ chartWith options =
getEvents (Options { onClick }) = getEvents (Options { onClick }) =
{ click: listenerFn1 \e -> case onClick of { click: listenerFn1 \e -> case onClick of
-- sanitize parsing (see MouseEvent comment) -- sanitize parsing (see MouseEvent comment)
Just _ -> pure unit Just fn -> RX.pick (e :: MouseEvent) # fn
-- Just fn -> RX.pick (e :: MouseEvent) # fn
Nothing -> pure unit Nothing -> pure unit
} }
......
...@@ -47,7 +47,7 @@ import Gargantext.Types (ListId, NodeID, NodeType(..), OrderBy(..), SidePanelSta ...@@ -47,7 +47,7 @@ import Gargantext.Types (ListId, NodeID, NodeType(..), OrderBy(..), SidePanelSta
import Gargantext.Types as GT import Gargantext.Types as GT
import Gargantext.Utils (sortWith, (?)) import Gargantext.Utils (sortWith, (?))
import Gargantext.Utils.CacheAPI as GUC import Gargantext.Utils.CacheAPI as GUC
import Gargantext.Utils.QueryString (joinQueryStrings, mQueryParam, mQueryParamS, queryParam, queryParamS) import Gargantext.Utils.QueryString (joinQueryStrings, mQueryParam, mQueryParamS, mQueryParamS', queryParam, queryParamS)
import Gargantext.Utils.Reactix as R2 import Gargantext.Utils.Reactix as R2
import Gargantext.Utils.Toestand as GUT import Gargantext.Utils.Toestand as GUT
import Gargantext.Utils.Toestand as T2 import Gargantext.Utils.Toestand as T2
...@@ -709,7 +709,7 @@ tableRouteWithPage { listId, nodeId, params: { limit, offset, orderBy, searchTyp ...@@ -709,7 +709,7 @@ tableRouteWithPage { listId, nodeId, params: { limit, offset, orderBy, searchTyp
st = queryParam "searchType" searchType st = queryParam "searchType" searchType
tt = queryParamS "tabType" (showTabType' tabType) tt = queryParamS "tabType" (showTabType' tabType)
q = queryParamS "query" query q = queryParamS "query" query
y = mQueryParam "year" yearFilter y = mQueryParamS' "year" yearFilter
deleteAllDocuments :: Session -> Int -> AffRESTError (Array Int) deleteAllDocuments :: Session -> Int -> AffRESTError (Array Int)
deleteAllDocuments session = delete session <<< documentsRoute deleteAllDocuments session = delete session <<< documentsRoute
......
...@@ -20,6 +20,10 @@ mQueryParamS :: forall a. String -> (a -> String) -> Maybe a -> String ...@@ -20,6 +20,10 @@ mQueryParamS :: forall a. String -> (a -> String) -> Maybe a -> String
mQueryParamS _ _ Nothing = "" mQueryParamS _ _ Nothing = ""
mQueryParamS key mFunc (Just v) = queryParamS key $ mFunc v mQueryParamS key mFunc (Just v) = queryParamS key $ mFunc v
mQueryParamS' :: String -> Maybe String -> String
mQueryParamS' _ Nothing = ""
mQueryParamS' key (Just v) = queryParamS key v
joinQueryStrings :: Array String -> String joinQueryStrings :: Array String -> String
joinQueryStrings qs = joinQueryStrings qs =
case uncons qs of case uncons qs of
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment