Commit 4404ee20 authored by Alexandre Delanoë's avatar Alexandre Delanoë

[API] enabling add with form and add list again.

parent 71fc2e41
...@@ -97,7 +97,7 @@ import qualified Data.Text.IO as T ...@@ -97,7 +97,7 @@ import qualified Data.Text.IO as T
import qualified Gargantext.API.Corpus.Annuaire as Annuaire import qualified Gargantext.API.Corpus.Annuaire as Annuaire
import qualified Gargantext.API.Corpus.Export as Export import qualified Gargantext.API.Corpus.Export as Export
import qualified Gargantext.API.Corpus.New as New import qualified Gargantext.API.Corpus.New as New
-- import qualified Gargantext.API.Ngrams.List as List import qualified Gargantext.API.Ngrams.List as List
import qualified Paths_gargantext as PG -- cabal magic build module import qualified Paths_gargantext as PG -- cabal magic build module
showAsServantErr :: GargError -> ServerError showAsServantErr :: GargError -> ServerError
...@@ -300,7 +300,7 @@ type GargPrivateAPI' = ...@@ -300,7 +300,7 @@ type GargPrivateAPI' =
:> TreeAPI :> TreeAPI
-- :<|> New.Upload -- :<|> New.Upload
-- :<|> New.AddWithForm :<|> New.AddWithForm
:<|> New.AddWithQuery :<|> New.AddWithQuery
-- :<|> "annuaire" :> Annuaire.AddWithForm -- :<|> "annuaire" :> Annuaire.AddWithForm
...@@ -308,16 +308,13 @@ type GargPrivateAPI' = ...@@ -308,16 +308,13 @@ type GargPrivateAPI' =
-- :<|> "scraper" :> WithCallbacks ScraperAPI -- :<|> "scraper" :> WithCallbacks ScraperAPI
-- :<|> "new" :> New.Api -- :<|> "new" :> New.Api
:<|> "wait" :> Summary "Wait test"
:> Capture "x" Int
:> WaitAPI -- Get '[JSON] Int
-- TODO "list"
{-
:<|> "lists" :> Summary "List export API" :<|> "lists" :> Summary "List export API"
:> Capture "listId" ListId :> Capture "listId" ListId
:> List.API :> List.API
-}
:<|> "wait" :> Summary "Wait test"
:> Capture "x" Int
:> WaitAPI -- Get '[JSON] Int
-- /mv/<id>/<id> -- /mv/<id>/<id>
-- /merge/<id>/<id> -- /merge/<id>/<id>
...@@ -407,16 +404,14 @@ serverPrivateGargAPI' (AuthenticatedUser (NodeId uid)) ...@@ -407,16 +404,14 @@ serverPrivateGargAPI' (AuthenticatedUser (NodeId uid))
:<|> withAccess (Proxy :: Proxy TreeAPI) Proxy uid :<|> withAccess (Proxy :: Proxy TreeAPI) Proxy uid
<$> PathNode <*> treeAPI <$> PathNode <*> treeAPI
-- TODO access -- TODO access
-- :<|> addUpload :<|> addCorpusWithForm (UserDBId uid)
-- :<|> (\corpus -> addWithQuery corpus :<|> addWithFile corpus)
-- :<|> addCorpusWithForm (UserDBId uid)
:<|> addCorpusWithQuery (RootId (NodeId uid)) :<|> addCorpusWithQuery (RootId (NodeId uid))
-- :<|> addAnnuaireWithForm -- :<|> addAnnuaireWithForm
-- :<|> New.api uid -- TODO-SECURITY -- :<|> New.api uid -- TODO-SECURITY
-- :<|> New.info uid -- TODO-SECURITY -- :<|> New.info uid -- TODO-SECURITY
:<|> List.api
:<|> waitAPI :<|> waitAPI
-- :<|> List.api
addCorpusWithQuery :: User -> GargServer New.AddWithQuery addCorpusWithQuery :: User -> GargServer New.AddWithQuery
......
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