diff --git a/apiserver/plane/bgtasks/importer_task.py b/apiserver/plane/bgtasks/importer_task.py
index 27410966f..85ac1c89b 100644
--- a/apiserver/plane/bgtasks/importer_task.py
+++ b/apiserver/plane/bgtasks/importer_task.py
@@ -27,7 +27,7 @@ from plane.db.models import (
User,
)
from .workspace_invitation_task import workspace_invitation
-from plane.bgtasks.user_welcome_task import send_welcome_email
+from plane.bgtasks.user_welcome_task import send_welcome_slack
@shared_task
@@ -58,7 +58,7 @@ def service_importer(service, importer_id):
)
[
- send_welcome_email.delay(
+ send_welcome_slack.delay(
str(user.id),
True,
f"{user.email} was imported to Plane from {service}",
diff --git a/apiserver/plane/bgtasks/user_welcome_task.py b/apiserver/plane/bgtasks/user_welcome_task.py
index c042d0a0b..bea2ee33d 100644
--- a/apiserver/plane/bgtasks/user_welcome_task.py
+++ b/apiserver/plane/bgtasks/user_welcome_task.py
@@ -1,8 +1,5 @@
# Django imports
from django.conf import settings
-from django.core.mail import EmailMultiAlternatives
-from django.template.loader import render_to_string
-from django.utils.html import strip_tags
# Third party imports
from celery import shared_task
@@ -15,31 +12,11 @@ from plane.db.models import User
@shared_task
-def send_welcome_email(user_id, created, message):
+def send_welcome_slack(user_id, created, message):
try:
instance = User.objects.get(pk=user_id)
if created and not instance.is_bot:
- first_name = instance.first_name.capitalize()
- to_email = instance.email
- from_email_string = settings.EMAIL_FROM
-
- subject = f"Welcome to Plane ✈️!"
-
- context = {"first_name": first_name, "email": instance.email}
-
- html_content = render_to_string(
- "emails/auth/user_welcome_email.html", context
- )
-
- text_content = strip_tags(html_content)
-
- msg = EmailMultiAlternatives(
- subject, text_content, from_email_string, [to_email]
- )
- msg.attach_alternative(html_content, "text/html")
- msg.send()
-
# Send message on slack as well
if settings.SLACK_BOT_TOKEN:
client = WebClient(token=settings.SLACK_BOT_TOKEN)
diff --git a/apiserver/plane/db/models/user.py b/apiserver/plane/db/models/user.py
index 5a4f487c1..b0ab72159 100644
--- a/apiserver/plane/db/models/user.py
+++ b/apiserver/plane/db/models/user.py
@@ -104,29 +104,9 @@ class User(AbstractBaseUser, PermissionsMixin):
@receiver(post_save, sender=User)
-def send_welcome_email(sender, instance, created, **kwargs):
+def send_welcome_slack(sender, instance, created, **kwargs):
try:
if created and not instance.is_bot:
- first_name = instance.first_name.capitalize()
- to_email = instance.email
- from_email_string = settings.EMAIL_FROM
-
- subject = f"Welcome to Plane ✈️!"
-
- context = {"first_name": first_name, "email": instance.email}
-
- html_content = render_to_string(
- "emails/auth/user_welcome_email.html", context
- )
-
- text_content = strip_tags(html_content)
-
- msg = EmailMultiAlternatives(
- subject, text_content, from_email_string, [to_email]
- )
- msg.attach_alternative(html_content, "text/html")
- msg.send()
-
# Send message on slack as well
if settings.SLACK_BOT_TOKEN:
client = WebClient(token=settings.SLACK_BOT_TOKEN)
diff --git a/apiserver/templates/emails/auth/user_welcome_email.html b/apiserver/templates/emails/auth/user_welcome_email.html
deleted file mode 100644
index af4e60d99..000000000
--- a/apiserver/templates/emails/auth/user_welcome_email.html
+++ /dev/null
@@ -1,481 +0,0 @@
-
-
-
-
-
-
-
-
- Welcome to Plane ✈️!
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- |
-
-
- |
-
-
- |
-
-
- |
-
-
-
-
-
- |
-
-
- Welcome to Plane!
-
- |
- |
-
-
- |
-
-
-
-
-
- |
- |
- |
-
-
- |
-
-
- We're thrilled you're here. We know this is the beginning of a long and exciting journey, and we want to be there every step of the way.
-
- |
- |
-
-
- |
- |
- |
-
-
- |
-
-
-
-
-
- |
- |
- |
-
-
- |
-
-
- Plane is an open-source issue planning and tracking tool that allows teams to collaborate on projects and prioritize tasks. With Plane, you can easily create and assign issues, set deadlines, and track progress.
-
- |
- |
-
-
- |
- |
- |
-
-
- |
-
-
-
-
-
- |
- |
- |
-
-
- |
-
-
- We have put together some resources to help you get started. Please find them below:
-
-
-
- |
- |
-
-
- |
- |
- |
-
-
- |
-
-
-
-
- |
-
-
-
-
-
- |
- |
- |
-
-
- |
-
-
- Also, if you like Plane, please consider starring us on GitHub. This helps us to grow our community and make Plane even better.
-
- |
- |
-
-
- |
- |
- |
-
-
- |
-
-
-
-
- |
-
-
-
-
-
- |
- |
- |
-
-
- |
-
-
- Note: Plane is still in its early days, not everything will be perfect yet, and hiccups may happen. Please let us know of any suggestions, ideas, or bugs that you encounter on our Discord or GitHub, and we will use your feedback to improve on our upcoming releases.
-
- |
- |
-
-
- |
- |
- |
-
-
- |
-
-
- |
-
-
- |
-
-
- |
-
-
- |
-
-
- |
-
-
-
-
-
-
- |
-
-
-
-
- |
-
-
- |
-
-
- |
-
-
- |
-
-
- |
-
-
-
-
\ No newline at end of file