1
0
mirror of https://github.com/hrfee/jfa-go.git synced 2024-11-05 01:40:10 +00:00
Commit Graph

68 Commits

Author SHA1 Message Date
8888807780
remove debug print, add another 2021-12-30 17:30:29 +00:00
d19f7d6b53
mailgun: better handle different api url formats 2021-12-30 02:55:00 +00:00
36f3860c4c
SMTP: Always use plaintext as main body
Adding the HTML as the alternative body caused the plaintext email to
always appear. Should fix #164.
2021-11-10 20:12:31 +00:00
Stefan Schokker
b7236319ec Actually use correct variable, actually use variable correctly and added a loadConfig entry 2021-11-09 21:18:54 +01:00
Stefan Schokker
556c31d4ea Add checkbox that allows invalid SMTP certificates to be used. 2021-11-08 20:48:55 +01:00
eeb9b07bce
admin: add manual "Send Password reset" to accounts tab
Only appears with Reset links enabled.
Pressing this sends a PWR link to the users selected.
if one user is selected, or if one of you selected users doesn't have a
method of contact, a link is given to the admin to send to them
manually.
2021-10-13 15:04:22 +01:00
77799b2917
smtp: only construct email once
also switch layout in email file to group each driver and its methods
together.
2021-10-07 16:19:06 +01:00
d560df5b1e
switch smtp library, add, HELLO hostname option
now using xhit/go-simple-mail, as I wanted to add an option to change
the hostname sent in the HELLO message but this is only possible with
STARTTLS in jordan-wright/email. New option can be seen in Settings >
SMTP with advanced settings turned on.
2021-10-07 12:01:42 +01:00
548dceda28
don't give smtp plainauth if no username & password
for #141, just a guess
2021-08-26 21:03:02 +01:00
e67b2e91fb
invite: auto-append /invite if missing to url_base 2021-08-26 18:53:22 +01:00
9693ce3dcd
settings: add redundant URL base for pwr
having it under "Invite Emails" when they weren't in use was confusing.
If only one is set in the config file, it'll be used for both.
2021-07-27 16:53:16 +01:00
9885c25a2e
email: cleanup; allow re-enabling of custom email without changes 2021-07-24 19:49:08 +01:00
f763cfb53a
announcements: fix [] on {{ .username }} 2021-07-16 20:57:11 +01:00
25a8d3807e
announcements: {{ .username }} 2021-07-16 19:46:05 +01:00
b10b558358
announcements: add {username}
also works in the subject.
2021-07-16 19:39:06 +01:00
833d02b032
matrix: end-to-end encryption by default
Existing chats will remain unencrypted but new ones will be.
2021-07-13 19:02:16 +01:00
d4096d0062
pwr: trim suffix, not prefix for links 2021-06-24 14:24:08 +01:00
Harvey Tindall
6fb8f1ed7f
Merge pull request #112 from hrfee/matrix
Matrix Integration
2021-05-31 21:12:57 +01:00
561c461a18
PWR: TrimPrefix instead of Replace for PWR links 2021-05-30 00:07:18 +01:00
89fb3fa619
Matrix: Notifications 2021-05-29 21:05:12 +01:00
a6447165b7
add email notify enable/disable; remove (de)hyphening
hyphen/dehyphen conflicted with new migration for email contact
preference, and it's been a while since this has been an issue so i've
just commented it out for now.
2021-05-21 22:46:46 +01:00
f8f5f35cc1
PIN verification, notifications, multiple notif providers
Discord, Email & Telegram can be enabled, although email is always
enabled right now (will fix). Also apparently markdown hyperlinks don't
work in Discord, eventually will implement something to convert them to
embeds.
2021-05-21 21:35:25 +01:00
18bcd55972
remove debug println 2021-05-17 01:32:22 +01:00
057f306ed9
hide/ignore ssl_cert when on windows
x509.SystemCertPool is unavailable on windows, so any value is ignored
and the setting is hidden on the web UI.
2021-05-17 01:16:59 +01:00
33f8070e57
cleanup; fix stripping with DEBUG=on 2021-05-16 15:00:13 +01:00
ea0293bd4e
Split some settings into new "messages" section
Most email dependant sections now depend on this. Also renamed more
email things.
2021-05-07 21:53:29 +01:00
36edd4ab0d
Telegram: Use markdown for custom emails/announcements
Had no idea telegram supported this, pretty cool.
2021-05-07 16:33:44 +01:00
716d6a931a
Telegram: Send messages via telegram
Most messages are now sent as plaintext via telegram when suitable.
2021-05-07 16:06:47 +01:00
99875b9176
almost complete telegram user verification
When signing up, the user is given a pin code which they send to a
telegram bot. This provides user verification, but more importantly
allows the bot to message the user, as the Telegram API requires the
user to interact with the bot before it can do the opposite.

The bot should recognize the correct language, but a /lang command is
also provided to change it.

The verification process is pretty much functional but ui is still
broken, and it isn't properly integrated yet.
2021-05-07 01:08:12 +01:00
488c2f5df5
fix broken url in welcome email 2021-05-02 14:44:19 +01:00
59a014f681
fix title for invite emails 2021-05-02 12:50:04 +01:00
8fdab39b18
use templateEmail and show conditionals in editor 2021-04-15 15:34:17 +01:00
55e21f8be3
accounts: add user enable/disable & emails 2021-04-12 21:28:36 +01:00
7a3e0d60f9
add expiry to welcome email, add dummy emailer for debugging
the "yourAccountWillExpire" has also been added to the editor for #81.
To use the dummy emailer, set [email]/method to "dummy".
2021-04-08 14:20:13 +01:00
3f8414c70a
use unix timestamp for inv created & usedBy
usedBy is still stored as a string in invites.json to cope with existing
invites with times stored formatted. knz/strtime requires cgo for
strptime, so it has been replaced with the native itchyny/timefmt-go.
2021-04-06 21:25:44 +01:00
30f16e7207
email: use strconv.Itoa instead of sprintf 2021-04-02 15:56:34 +01:00
9370913ace
add password reset link option
When enabled (in Settings > Password Resets), a magic link will be sent
instead of a PIN when the user tries reset their password. By doing
this the user doesn't have to keep the Jellyfin tab open to enter the
code.
2021-03-30 22:41:28 +01:00
43e5bbbe21
add option to trust specific cert for SMTP 2021-03-15 21:57:42 +00:00
1e9d184508
implement user expiry functionality
All works now, but i'll add a field on the accounts tab for users with
an expiry, as well as a 'disabled' badge.
2021-02-28 15:41:06 +00:00
40fc5e9604
Fix email editor when plaintext setting enabled 2021-02-22 16:40:37 +00:00
52d9cda61a
Move email rendering to browser
the email preview no longer has a delay after each change. This also
avoids a race condition in which the email currently being edited could
be actually sent.
2021-02-22 00:43:36 +00:00
058cac2e7b
implement email editor w/ live(?) preview
not accessible in the ui currently, but the object is available as
window.ee for testing.
2021-02-20 22:49:59 +00:00
938523c18b
fix urls in custom email/announcements
Uses a nasty algorithm found in stripmd.go to change all occurrences
of '[linktext](link)' to just 'link' before passing to a decent markdown
stripper.
2021-02-20 01:03:11 +00:00
cc4e12c405
finish backend of custom emails
biggest bodge i've ever done but it works i guess.
2021-02-20 00:22:40 +00:00
eb406ef951
Implement email template generation
Variables are surrounded by {}, and initial (default) templates are
generated on demand from the plaintext version of emails. The custom
emails are intended to only be used if the user actually changes them,
as they lose the features of the default ones, such as tables.
2021-02-19 21:38:20 +00:00
5c87d109a3
use descriptive variable names in email translations
in preparation for an email editor.
2021-02-19 17:50:50 +00:00
93b5b483cc
add plaintext email option, use text/template
text/template is used on plaintext emails to avoid escaping of certain
characters.
2021-02-18 18:26:23 +00:00
27ef931670
add possible dark mode fix for Outlook 2021-02-18 17:47:15 +00:00
fa433c88a8
add announcement emails
After selecting users in the accounts tab, you can press 'Announce',
then write a subject and message (with markdown), and an email will be
sent to each selected user.
2021-02-18 14:58:53 +00:00
ea99966057
refactor, move route loading to router.go 2021-02-12 14:59:16 +00:00