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
148
Issues
148
List
Board
Labels
Milestones
Merge Requests
7
Merge Requests
7
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
gargantext
haskell-gargantext
Commits
71b8eeb2
Commit
71b8eeb2
authored
Oct 10, 2022
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FEAT] Giving the instance Name to the user
parent
11db8126
Pipeline
#3263
passed with stage
in 93 minutes and 55 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
16 deletions
+18
-16
CHANGELOG.md
CHANGELOG.md
+2
-0
gargantext.cabal
gargantext.cabal
+1
-1
Mail.hs
src/Gargantext/Core/Mail.hs
+14
-14
stack.yaml
stack.yaml
+1
-1
No files found.
CHANGELOG.md
View file @
71b8eeb2
## Version 0.0.6.7.1
*
[
BACK
][
OPTIM
][
Ngrams Table, queries optimization (#144)
](
https://gitlab.iscpif.fr/gargantext/haskell-gargantext/issues/144
)
*
[
BACK
][
CONFIG
]
gargantext.ini needs new field
BACKEND_NAME = THE INSTANCE NAME
## Version 0.0.6.7
*
[
GRAPH
][
FIX
]
Nodes with one edge only are removed now
...
...
gargantext.cabal
View file @
71b8eeb2
...
...
@@ -5,7 +5,7 @@ cabal-version: 1.12
-- see: https://github.com/sol/hpack
name: gargantext
version: 0.0.6.7.1
version:
0.0.6.7.1
synopsis: Search, map, share
description: Please see README.md
category: Data
...
...
src/Gargantext/Core/Mail.hs
View file @
71b8eeb2
...
...
@@ -17,7 +17,7 @@ import Data.Text (Text, unlines, splitOn)
import
Gargantext.Core.Types.Individu
import
Gargantext.Database.Schema.User
(
UserLight
(
..
))
import
Gargantext.Prelude
import
Gargantext.Prelude.Config
(
gc_url
)
import
Gargantext.Prelude.Config
(
gc_url
,
gc_backend_name
)
import
Gargantext.Database.Prelude
-- import Gargantext.Prelude.Config (gc_url)
import
Gargantext.Prelude.Mail
(
gargMail
,
GargMail
(
..
))
...
...
@@ -34,7 +34,9 @@ data SendEmail = SendEmail Bool
type
EmailAddress
=
Text
type
Name
=
Text
type
ServerAddress
=
Text
data
ServerAddress
=
ServerAddress
{
sa_name
::
Text
,
sa_url
::
Text
}
data
MailModel
=
Invitation
{
invitation_user
::
NewUser
GargPassword
}
|
PassUpdate
{
passUpdate_user
::
NewUser
GargPassword
}
...
...
@@ -50,7 +52,7 @@ mail mailCfg model = do
let
(
m
,
u
)
=
email_to
model
subject
=
email_subject
model
body
=
emailWith
(
view
gc_url
cfg
)
model
body
=
emailWith
(
ServerAddress
(
view
gc_backend_name
cfg
)
(
view
gc_url
cfg
))
model
liftBase
$
gargMail
mailCfg
(
GargMail
{
gm_to
=
m
,
gm_name
=
Just
u
,
gm_subject
=
subject
...
...
@@ -76,14 +78,14 @@ email_to' (NewUser u m _) = (m,u)
------------------------------------------------------------------------
bodyWith
::
ServerAddress
->
MailModel
->
[
Text
]
bodyWith
server
(
Invitation
u
)
=
[
"Congratulation, you have been granted a user account to test the"
,
"new GarganText platform!"
bodyWith
server
@
(
ServerAddress
name
_url
)
(
Invitation
u
)
=
[
"Congratulation, you have been granted a user account to test the"
,
"new GarganText platform
called "
<>
name
<>
"
!"
]
<>
(
email_credentials
server
u
)
bodyWith
server
(
PassUpdate
u
)
=
[
"Your account password have been updated on the GarganText platform!"
]
<>
(
email_credentials
server
u
)
bodyWith
server
(
MailInfo
_
_
)
=
[
"Your last analysis is over on the server: "
<>
server
]
bodyWith
(
ServerAddress
_
url
)
(
MailInfo
_
_
)
=
[
"Your last analysis is over on the server: "
<>
url
]
bodyWith
_server
(
ForgotPassword
{
user
=
UserLight
{
userLight_forgot_password_uuid
=
Nothing
}})
=
[
"Cannot send you link to forgot password, no UUID"
]
bodyWith
server
(
ForgotPassword
{
user
=
UserLight
{
userLight_forgot_password_uuid
=
Just
uuid
}})
=
...
...
@@ -91,7 +93,7 @@ bodyWith server (ForgotPassword { user = UserLight { userLight_forgot_password_u
,
forgot_password_link
server
uuid
]
forgot_password_link
::
ServerAddress
->
Text
->
Text
forgot_password_link
server
uuid
=
server
<>
"/#/forgotPassword?uuid="
<>
uuid
<>
"&server="
<>
encodeText
server
forgot_password_link
(
ServerAddress
_
server
)
uuid
=
server
<>
"/#/forgotPassword?uuid="
<>
uuid
<>
"&server="
<>
encodeText
server
------------------------------------------------------------------------
email_subject
::
MailModel
->
Text
...
...
@@ -102,7 +104,7 @@ email_subject (ForgotPassword _) = "[GarganText] Forgot Password"
email_credentials
::
ServerAddress
->
NewUser
GargPassword
->
[
Text
]
email_credentials
server
(
NewUser
u
_
(
GargPassword
p
))
=
email_credentials
(
ServerAddress
_
server
)
(
NewUser
u
_
(
GargPassword
p
))
=
[
""
,
"You can log in to: "
<>
server
,
"Your username is: "
<>
u
...
...
@@ -113,22 +115,20 @@ email_credentials server (NewUser u _ (GargPassword p)) =
email_disclaimer
::
[
Text
]
email_disclaimer
=
[
""
,
"If you log in you agree with the following terms of use:"
,
" https://gitlab.iscpif.fr/humanities/tofu/tree/master"
,
""
,
""
,
"/!
\\
Please note that your account is opened for beta tester only. Hence"
,
"we cannot guarantee neither the perenniality nor the stability of the"
,
"service at this stage. It is therefore advisable to back up important"
,
"data regularly."
,
""
,
"/!
\\
Gargantext is an academic service supported by ISC-PIF partners."
,
"/!
\\
Gargantext is an academic service supported by
CNRS/
ISC-PIF partners."
,
"In case of congestion on this service, access to members of the ISC-PIF"
,
"partners will be privileged."
,
""
,
"If you log in you agree with the following terms of use:"
,
" https://gitlab.iscpif.fr/humanities/tofu/tree/master"
,
""
,
"Your feedback will be valuable for further development of the platform,"
,
"do not hesitate to contact us and to contribute on our forum:"
,
""
,
" https://discourse.iscpif.fr/c/gargantext"
,
""
]
...
...
stack.yaml
View file @
71b8eeb2
...
...
@@ -33,7 +33,7 @@ ghc-options:
extra-deps
:
-
git
:
https://gitlab.iscpif.fr/gargantext/haskell-gargantext-prelude.git
commit
:
0
8096a4913572cf22762fa77613340207ec6d9fd
commit
:
0
3c3c381ba9df6da02a7a3c8d7b78cde9a380d04
-
git
:
https://gitlab.iscpif.fr/gargantext/gargantext-graph.git
commit
:
588e104fe7593210956610cab0041fd16584a4ce
# Data Mining Libs
...
...
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