Skip to content

Commit

Permalink
Rename tender siae interested email to author
Browse files Browse the repository at this point in the history
  • Loading branch information
raphodn committed Nov 9, 2023
1 parent 9b881a5 commit 4ae0d14
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 10 deletions.
17 changes: 11 additions & 6 deletions config/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,11 +368,17 @@
MAILJET_TENDERS_AUTHOR_CONFIRMATION_VALIDATED_TEMPLATE_ID = env.int(
"MAILJET_TENDERS_AUTHOR_CONFIRMATION_VALIDATED_TEMPLATE_ID", 3896680
)
MAILJET_TENDERS_SIAE_INTERESTED_1_TEMPLATE_ID = env.int("MAILJET_TENDERS_SIAE_INTERESTED_1_TEMPLATE_ID", 3867188)
MAILJET_TENDERS_SIAE_INTERESTED_2_TEMPLATE_ID = env.int("MAILJET_TENDERS_SIAE_INTERESTED_2_TEMPLATE_ID", 4306699)
MAILJET_TENDERS_SIAE_INTERESTED_5_TEMPLATE_ID = env.int("MAILJET_TENDERS_SIAE_INTERESTED_5_TEMPLATE_ID", 4306770)
MAILJET_TENDERS_SIAE_INTERESTED_5_MORE_TEMPLATE_ID = env.int(
"MAILJET_TENDERS_SIAE_INTERESTED_5_MORE_TEMPLATE_ID", 3867200
MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_1_TEMPLATE_ID = env.int(
"MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_1_TEMPLATE_ID", 3867188
)
MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_2_TEMPLATE_ID = env.int(
"MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_2_TEMPLATE_ID", 4306699
)
MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_5_TEMPLATE_ID = env.int(
"MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_5_TEMPLATE_ID", 4306770
)
MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_5_MORE_TEMPLATE_ID = env.int(
"MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_5_MORE_TEMPLATE_ID", 3867200
)
MAILJET_TENDERS_AUTHOR_INCREMENTAL_2D_TEMPLATE_ID = env.int(
"MAILJET_TENDERS_AUTHOR_INCREMENTAL_2D_TEMPLATE_ID", 4585824
Expand All @@ -384,7 +390,6 @@


# -- Sendinblue (BREVO)

BREVO_API_KEY = env.str("BREVO_API_KEY", "set-it")
brevo_configuration = sib_api_v3_sdk.Configuration()
brevo_configuration.api_key["api-key"] = BREVO_API_KEY
Expand Down
8 changes: 4 additions & 4 deletions lemarche/www/tenders/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -376,19 +376,19 @@ def send_siae_interested_email_to_author(tender: Tender):
if tender_siae_detail_contact_click_count == 1:
should_send_email = True
email_subject = "Un premier prestataire intéressé !"
template_id = settings.MAILJET_TENDERS_SIAE_INTERESTED_1_TEMPLATE_ID
template_id = settings.MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_1_TEMPLATE_ID
elif tender_siae_detail_contact_click_count == 2:
should_send_email = True
email_subject = "Un deuxième prestataire intéressé !"
template_id = settings.MAILJET_TENDERS_SIAE_INTERESTED_2_TEMPLATE_ID
template_id = settings.MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_2_TEMPLATE_ID
elif tender_siae_detail_contact_click_count == 5:
should_send_email = True
email_subject = "Un cinquième prestataire intéressé !"
template_id = settings.MAILJET_TENDERS_SIAE_INTERESTED_5_TEMPLATE_ID
template_id = settings.MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_5_TEMPLATE_ID
elif tender_siae_detail_contact_click_count % 5 == 0:
should_send_email = True
email_subject = "5 nouveaux prestataires intéressés !"
template_id = settings.MAILJET_TENDERS_SIAE_INTERESTED_5_MORE_TEMPLATE_ID
template_id = settings.MAILJET_TENDERS_AUTHOR_SIAE_INTERESTED_5_MORE_TEMPLATE_ID
else:
pass

Expand Down

0 comments on commit 4ae0d14

Please sign in to comment.