Commit 48b94816 authored by Przemyslaw Kaminski's avatar Przemyslaw Kaminski

Merge branch 'dev' into dev-corpora-from-write-nodes

parents 1afd4017 1667c63e
Pipeline #1892 passed with stage
in 38 minutes and 11 seconds
## Version 4.0.0.2
## Version 0.0.3.9.1
* Graph Update fix
* Document view: full text removed
## Version 0.0.0.2
* Fix the community detection.
* TextFlow starts to make sense
## Version 4.0.0.1
## Version 0.0.0.1
* Very first version (main functions ready for tests) of Haskell Version
of Gargantext. Previous versions (3) were written with another
language and another framework (Python/Javascript mainly).
......@@ -6,10 +6,10 @@ DATE="2018-03-08 07:18:18"
# use tutoriel code
#tmux -d video
xterm -e "tutoriel"
#xterm -e "tutoriel"
gource --start-date $DATE ../gargantext-hs &
gource --start-date $DATE gargantext-hs/purescript-gargantext
gource --start-date $DATE ../gargantext-hs/purescript-gargantext
#tmux -a video
# Share video ?
......
#!/bin/bash
stack install --profile --test --fast # --haddock
stack install --nix --profile --test --fast # --haddock
##
## GargantText serveur configuration
## Authors: team@gargantext.org
## Licence CNRS/AGPLv3-MIT/CECILL-INRIA
#
# Fee free to improve it
# Thanks for sharing to all community
# Specific NGINX informations
#
# You should look at the following URL's in order to grasp a solid understanding
# of Nginx configuration files in order to fully unleash the power of Nginx.
# http://wiki.nginx.org/Pitfalls
......@@ -43,8 +33,8 @@ server {
# Comment this for maintenance only
server {
#server_name v4.gargantext.org;
server_name maintenanceOnly.gargantext.org;
server_name v4.gargantext.org;
#server_name maintenanceOnly.gargantext.org;
add_header Cache-Control "no-cache";
......
name: gargantext
version: '0.0.3.7'
version: '0.0.3.9.1'
synopsis: Search, map, share
description: Please see README.md
category: Data
......
......@@ -46,6 +46,7 @@ import Gargantext.Database.Admin.Types.Hyperdata (HyperdataAnnuaire(..), Hyperda
import Gargantext.Database.Admin.Types.Hyperdata.Contact (hyperdataContact)
import Gargantext.Database.Admin.Types.Node
import Gargantext.Prelude (($), liftBase, (.), printDebug, pure)
import qualified Gargantext.Utils.Aeson as GUA
------------------------------------------------------------------------
type API = "contact" :> Summary "Contact endpoint"
......@@ -105,10 +106,10 @@ addContact _uId _nId _p logStatus = do
------------------------------------------------------------------------
-- TODO unPrefix "pn_" FromJSON, ToJSON, ToSchema, adapt frontend.
instance FromJSON AddContactParams where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
parseJSON = genericParseJSON (defaultOptions { sumEncoding = GUA.defaultTaggedObject })
instance ToJSON AddContactParams where
toJSON = genericToJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
toJSON = genericToJSON (defaultOptions { sumEncoding = GUA.defaultTaggedObject })
instance ToSchema AddContactParams
instance Arbitrary AddContactParams where
......
......@@ -35,6 +35,7 @@ import Gargantext.Database.Action.Flow.Pairing (pairing)
import Gargantext.Database.Action.Flow.Types (FlowCmdM)
import Gargantext.Database.Admin.Types.Node
import Gargantext.Prelude (Ord, Eq, (<$>), ($), liftBase, (.), printDebug, pure, show, cs, (<>), panic)
import qualified Gargantext.Utils.Aeson as GUA
import Prelude (Enum, Bounded, minBound, maxBound)
import Servant
import Servant.Job.Async (JobFunction(..), serveJobsAPI)
......@@ -149,10 +150,10 @@ updateNode _uId _nId _p logStatus = do
------------------------------------------------------------------------
-- TODO unPrefix "pn_" FromJSON, ToJSON, ToSchema, adapt frontend.
instance FromJSON UpdateNodeParams where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
parseJSON = genericParseJSON (defaultOptions { sumEncoding = GUA.defaultTaggedObject })
instance ToJSON UpdateNodeParams where
toJSON = genericToJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
toJSON = genericToJSON (defaultOptions { sumEncoding = GUA.defaultTaggedObject })
instance ToSchema UpdateNodeParams
instance Arbitrary UpdateNodeParams where
......
......@@ -42,6 +42,7 @@ import Gargantext.Database.Query.Table.NodeNode (selectPublicNodes)
import Gargantext.Core.Utils.DateUtils (utc2year)
import Gargantext.Database.Schema.Node -- (NodePoly(..))
import Gargantext.Prelude
import qualified Gargantext.Utils.Aeson as GUA
------------------------------------------------------------------------
type API = API_Home
......@@ -140,10 +141,10 @@ data PublicData = PublicData
instance FromJSON PublicData where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
parseJSON = genericParseJSON (defaultOptions { sumEncoding = GUA.defaultTaggedObject })
instance ToJSON PublicData where
toJSON = genericToJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
toJSON = genericToJSON (defaultOptions { sumEncoding = GUA.defaultTaggedObject })
instance ToSchema PublicData
instance Arbitrary PublicData where
......
......@@ -74,12 +74,10 @@ api nId (SearchQuery q SearchContact) o l order = do
-----------------------------------------------------------------------
data SearchType = SearchDoc | SearchContact
deriving (Generic)
instance FromJSON SearchType
where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance ToJSON SearchType
where
toJSON = genericToJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance FromJSON SearchType where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance ToJSON SearchType where
toJSON = genericToJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance ToSchema SearchType
instance Arbitrary SearchType where
arbitrary = elements [SearchDoc, SearchContact]
......@@ -90,12 +88,10 @@ data SearchQuery =
, expected :: !SearchType
}
deriving (Generic)
instance FromJSON SearchQuery
where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance ToJSON SearchQuery
where
toJSON = genericToJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance FromJSON SearchQuery where
parseJSON = genericParseJSON defaultOptions
instance ToJSON SearchQuery where
toJSON = genericToJSON defaultOptions
instance ToSchema SearchQuery
{-
where
......@@ -110,13 +106,11 @@ data SearchResult =
SearchResult { result :: !SearchResultTypes}
deriving (Generic)
instance FromJSON SearchResult
where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance FromJSON SearchResult where
parseJSON = genericParseJSON defaultOptions
instance ToJSON SearchResult
where
toJSON = genericToJSON (defaultOptions { sumEncoding = ObjectWithSingleField })
instance ToJSON SearchResult where
toJSON = genericToJSON defaultOptions
instance ToSchema SearchResult
{-
......@@ -133,12 +127,10 @@ data SearchResultTypes =
| SearchResultContact { contacts :: ![Row] }
| SearchNoResult { message :: !Text }
deriving (Generic)
instance FromJSON SearchResultTypes
where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = defaultTaggedObject })
instance ToJSON SearchResultTypes
where
toJSON = genericToJSON (defaultOptions { sumEncoding = defaultTaggedObject })
instance FromJSON SearchResultTypes where
parseJSON = genericParseJSON (defaultOptions { sumEncoding = defaultTaggedObject })
instance ToJSON SearchResultTypes where
toJSON = genericToJSON (defaultOptions { sumEncoding = defaultTaggedObject })
instance Arbitrary SearchResultTypes where
arbitrary = do
......
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