Browse Source

Jan 8 [UPDT] : Updated 'contacts_birthday_greetings'

pull/299/head
AjmalCybro 1 year ago
parent
commit
c7d7d62549
  1. 2
      contacts_birthday_greetings/__manifest__.py
  2. 35
      contacts_birthday_greetings/data/mail_template_data.xml
  3. 7
      contacts_birthday_greetings/doc/RELEASE_NOTES.md
  4. 2
      contacts_birthday_greetings/models/res_partner.py
  5. 0
      contacts_birthday_greetings/static/description/assets/screenshots/birthday_greet_2.png
  6. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/birthday_greetings_template_1.png
  7. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/birthday_greetings_template_2.png
  8. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/birthday_greetings_template_3.png
  9. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/greetings.png
  10. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/hero.gif
  11. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/hero_gif_file.gif
  12. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/img.png
  13. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/temp_1.png
  14. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/temp_2.png
  15. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/temp_3.png
  16. BIN
      contacts_birthday_greetings/static/description/assets/screenshots/temp_33.png
  17. BIN
      contacts_birthday_greetings/static/description/galaxy_cupcakes-removebg-preview.png
  18. 14
      contacts_birthday_greetings/static/description/index.html
  19. BIN
      contacts_birthday_greetings/static/src/img/birthday_greetings.png
  20. BIN
      contacts_birthday_greetings/static/src/img/birthday_greetings_2.png
  21. BIN
      contacts_birthday_greetings/static/src/img/cupcake.png
  22. BIN
      contacts_birthday_greetings/static/src/img/galaxy_cupcakes.png
  23. 130
      contacts_birthday_greetings/views/mail_template_data.xml
  24. 6
      contacts_birthday_greetings/views/res_config_settings_views.xml

2
contacts_birthday_greetings/__manifest__.py

@ -21,7 +21,7 @@
#############################################################################
{
'name': "Contacts Birthday Greetings",
'version': '16.0.1.0.0',
'version': '16.0.1.0.1',
'summary': """Contacts Birthday Greetings""",
"category": 'Contacts',
'description': """Module helps to Automatically Send Happy Birthday

35
contacts_birthday_greetings/data/mail_template_data.xml

@ -1,13 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="0">
<record id="email_template_birthday_greeting" model="mail.template">
<record id="email_template_birthday_greeting_one" model="mail.template">
<field name="name">Birthday Greetings Template 1</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="subject">Happy Birthday {{object.name}}</field>
<field name="email_from">"{{object.cbg_company_id.name or object.user_id.name}}" &lt;{{ (object.cbg_company_id.email or object.user_id.email) }}&gt;</field>
<field name="email_to">{{object.email}}</field>
<field name="partner_to">{{object.id}}</field>
<field name="body_html" type="html">
<div style="margin: 0px; padding: 0px;">
<p style="margin: 0px; padding: 0px; font-size: 13px;">
@ -34,37 +33,36 @@
</record>
<record id="email_template_birthday_greeting_two" model="mail.template">
<record id="email_template_birthday_two_greeting" model="mail.template">
<field name="name">Birthday Greetings Template 2</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="subject">Happy Birthday {{object.name}}</field>
<field name="email_from">"{{ object.cbg_company_id.name or object.user_id.name}}" &lt;{{ (object.cbg_company_id.email or object.user_id.email) }}&gt;</field>
<field name="email_to">{{object.email}}</field>
<field name="partner_to">{{object.id}}</field>
<field name="body_html" type="html">
<link href="https://fonts.googleapis.com/css?family=Dancing+Script"
rel="stylesheet"/>
<div style="background-color: #ab669a;width: 100% !important;border-radius: 0px;-webkit-border-radius: 0px; -moz-border-radius: 0px;">
<div style="background-color: white;width: 100% !important;border-radius: 0px;-webkit-border-radius: 0px; -moz-border-radius: 0px;">
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 18px;">
style="margin: 0px; color: #7b1b21; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 18px;">
<strong>Happy</strong>
</h3>
</div>
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 36px;">
style="margin: 0px; color: #7b1b21; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 36px;">
<strong>Birthday</strong>
</h3>
</div>
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 20px;">
style="margin: 0px; color: #7b1b21; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 20px;">
<span t-field="object.name"/>
</h3>
</div>
<div align="center">
<img src="contacts_birthday_greetings/static/src/img/birthday_greetings.png"
<img src="https://img.freepik.com/premium-photo/happy-birthday-cake-png-white-background_1009855-95.jpg?w=826"
alt="image" title="image"
style="outline: none;text-decoration: none;-ms-interpolation-mode: bicubic;clear: both;display: inline-block !important;border: none;height: auto;float: none;width: 100%;max-width: 600px;"
class="v-src-width v-src-max-width" width="600"
@ -72,7 +70,7 @@
</div>
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 36px;">
style="margin: 0px; color: #7b1b21; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 36px;">
<strong>From all of us at</strong>
<t t-esc="object.cbg_company_id.name or object.user_id.company_id.name"/>
</h3>
@ -83,30 +81,23 @@
</record>
<record id="email_template_birthday_greeting_three" model="mail.template">
<record id="email_template_birthday_three_greeting" model="mail.template">
<field name="name">Birthday Greetings Template 3</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="subject">Happy Birthday {{object.name}}</field>
<field name="email_from">"{{ object.cbg_company_id.name or object.user_id.name}}" &lt;{{ (object.cbg_company_id.email or object.user_id.email) }}&gt;</field>
<field name="email_to">{{object.email}}</field>
<field name="partner_to">{{object.id}}</field>
<field name="body_html" type="html">
<link href="https://fonts.googleapis.com/css?family=Dancing+Script"
rel="stylesheet"/>
<div style="background-image: url(/contacts_birthday_greetings/static/src/img/birthday_greetings_2.png); background-position: center top;background-color: transparent; width: 100% !important;height:1050px !important;" >
<div style="text-align: center;font-weight: normal;font-size: 20px; padding-top: 210px;">
Today is your special day!
</div>
<div style="text-align: center;font-weight: normal;font-size: 30px; padding-top: 45px;">
Happy Birthday
</div>
<div style="text-align: center;font-weight: normal;font-size: 25px; padding-top: 30px;">
<div style="background-image: url(https://i.pinimg.com/736x/94/24/ca/9424cab58c8d38ed2431eb1f41217f7a.jpg); background-position: center top; background-repeat: no-repeat;background-color: transparent; width: 100% !important;height:1050px !important;" >
<div style="text-align: center;font-weight: normal;font-size: 25px; padding-top: 30ex;">
<span t-field="object.name"/>
</div>
<div align="center">
<img src="contacts_birthday_greetings/static/src/img/galaxy_cupcakes.png"
<img src="https://pngimg.com/d/chocolate_cake_PNG50.png"
alt="image" title="image"
style="outline: none;text-decoration: none;-ms-interpolation-mode: bicubic;clear: both;display: inline-block !important;border: none;height: auto;float: none;"
style="outline: none;text-decoration: none;-ms-interpolation-mode: bicubic;clear: both;display: inline-block !important;border: none;height: auto;float: none;padding-top: 3ex;"
class="v-src-width v-src-max-width" width="250"
border="0" align="middle"/>
</div>

7
contacts_birthday_greetings/doc/RELEASE_NOTES.md

@ -3,4 +3,9 @@
#### 11.01.2023
#### Version 16.0.1.0.0
#### ADD
- Initial commit for Contacts Birthday Greetings
- Initial commit for Contacts Birthday Greetings
#### 04.01.2024
#### Version 16.0.1.0.1
#### UPDT
- Bug fix for twice-sent mail and template issue

2
contacts_birthday_greetings/models/res_partner.py

@ -63,4 +63,4 @@ class ResPartner(models.Model):
template_id)
templates.sudo().send_mail(
partner.id, force_send=True,
email_layout_xmlid='mail.mail_notification_light')
email_layout_xmlid='mail.mail_notification_light')

0
contacts_birthday_greetings/static/description/assets/screenshots/bithday_greet_2.png → contacts_birthday_greetings/static/description/assets/screenshots/birthday_greet_2.png

Before

Width:  |  Height:  |  Size: 114 KiB

After

Width:  |  Height:  |  Size: 114 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/birthday_greetings_template_1.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 122 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/birthday_greetings_template_2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 308 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/birthday_greetings_template_3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 375 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/greetings.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 133 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/hero.gif

Binary file not shown.

Before

Width:  |  Height:  |  Size: 106 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/hero_gif_file.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 110 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/img.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 66 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/temp_1.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/temp_2.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 207 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/temp_3.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 221 KiB

BIN
contacts_birthday_greetings/static/description/assets/screenshots/temp_33.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 139 KiB

BIN
contacts_birthday_greetings/static/description/galaxy_cupcakes-removebg-preview.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 176 KiB

14
contacts_birthday_greetings/static/description/index.html

@ -12,8 +12,6 @@
style="background-color: #7C7BAD !important; color: #fff !important; font-weight: 600 !important; padding: 5px 15px 8px !important; margin: 0 5px !important;">
<i class="fa fa-check mr-1"></i>Community
</div>
</div>
</div>
</div>
@ -31,7 +29,7 @@
Module helps to Automatically Send Happy Birthday
Email to Customers on Their Birthdays
</p>
<img src="./assets/screenshots/hero.gif" class="img-responsive"
<img src="./assets/screenshots/hero_gif_file.gif" class="img-responsive"
width="100%" height="auto"/>
</div>
</div>
@ -184,7 +182,7 @@
style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1.3rem !important;">
Set the Birth date of the contacts.
</p>
<img src="assets/screenshots/bithday_greet_1.png"
<img src="assets/screenshots/img.png"
class="img-responsive img-thumbnail border" width="100%"
height="auto"/>
</div>
@ -198,7 +196,7 @@
Go to Settings --> Choose template to send birthday wishing
email to contacts.
</p>
<img src="assets/screenshots/bithday_greet_2.png"
<img src="assets/screenshots/birthday_greet_2.png"
class="img-responsive img-thumbnail border" width="100%"
height="auto"/>
</div>
@ -215,14 +213,14 @@
style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1.5rem !important; margin-top: 25px;">
Template 1
</div>
<img src="assets/screenshots/birthday_greetings_template_1.png"
<img src="assets/screenshots/temp_1.png"
class="img-responsive img-thumbnail border" width="100%"
height="auto"/>
<div
style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1.5rem !important;margin-top: 25px;">
Template 2
</div>
<img src="assets/screenshots/birthday_greetings_template_2.png"
<img src="assets/screenshots/temp_2.png"
class="img-responsive img-thumbnail border" width="100%"
height="auto"/>
@ -230,7 +228,7 @@
style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1.5rem !important;margin-top: 25px;">
Template 3
</div>
<img src="assets/screenshots/birthday_greetings_template_3.png"
<img src="assets/screenshots/temp_33.png"
class="img-responsive img-thumbnail border" width="100%"
height="auto"/>
</div>

BIN
contacts_birthday_greetings/static/src/img/birthday_greetings.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 141 KiB

BIN
contacts_birthday_greetings/static/src/img/birthday_greetings_2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 44 KiB

BIN
contacts_birthday_greetings/static/src/img/cupcake.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 42 KiB

BIN
contacts_birthday_greetings/static/src/img/galaxy_cupcakes.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 161 KiB

130
contacts_birthday_greetings/views/mail_template_data.xml

@ -1,130 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="0">
<record id="email_template_birthday_greeting" model="mail.template">
<field name="name">Birthday Greetings Template 1</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="subject">Happy Birthday {{object.name}}</field>
<field name="email_from">"{{ object.company_id.name or object.user_id.name}}" &lt;{{ (object.company_id.email or object.user_id.email) }}&gt;</field>
<field name="email_to">{{object.email}}</field>
<field name="partner_to">{{object.id}}</field>
<field name="body_html" type="html">
<div style="margin: 0px; padding: 0px;">
<p style="margin: 0px; padding: 0px; font-size: 13px;">
Dear <t t-out="object.name"/>,
<br/>
<br/>
Wish you a Happy Birthday! We hope that you have a great
year and accomplish all the
fabulous goals you have set. May the coming years have
filled with happiness, peace, and
love. Have a great day ahead.
<br/>
<br/>
Many happy returns!
<br/>
<br/>
</p>
Sincerely,
<br/>
<t t-out="object.user_id.company_id.name"/>
</div>
</field>
<field name="auto_delete" eval="True"/>
</record>
<record id="email_template_birthday_greeting_two" model="mail.template">
<field name="name">Birthday Greetings Template 2</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="subject">Happy Birthday {{object.name}}</field>
<field name="email_from">"{{ object.company_id.name or object.user_id.name}}" &lt;{{ (object.company_id.email or object.user_id.email) }}&gt;</field>
<field name="email_to">{{object.email}}</field>
<field name="partner_to">{{object.id}}</field>
<field name="body_html" type="html">
<link href="https://fonts.googleapis.com/css?family=Dancing+Script"
rel="stylesheet"/>
<div style="background-color: #ab669a;width: 100% !important;border-radius: 0px;-webkit-border-radius: 0px; -moz-border-radius: 0px;">
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 18px;">
<strong>Happy</strong>
</h3>
</div>
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 36px;">
<strong>Birthday</strong>
</h3>
</div>
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 20px;">
<span t-field="object.name"/>
</h3>
</div>
<div align="center">
<img src="contacts_birthday_greetings/static/src/img/birthday_greetings.png"
alt="image" title="image"
style="outline: none;text-decoration: none;-ms-interpolation-mode: bicubic;clear: both;display: inline-block !important;border: none;height: auto;float: none;width: 100%;max-width: 600px;"
class="v-src-width v-src-max-width" width="600"
border="0" align="middle"/>
</div>
<div>
<h3 class="v-text-align v-font-size"
style="margin: 0px; color: #ffffff; line-height: 140%; text-align: center; word-wrap: break-word; font-weight: normal; font-family: 'Dancing Script', cursive; font-size: 36px;">
<strong>From all of us at</strong>
<span t-field="object.user_id.company_id.name"/>
</h3>
</div>
</div>
</field>
<field name="auto_delete" eval="True"/>
</record>
<record id="email_template_birthday_greeting_three" model="mail.template">
<field name="name">Birthday Greetings Template 3</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="subject">Happy Birthday {{object.name}}</field>
<field name="email_from">"{{ object.company_id.name or object.user_id.name}}" &lt;{{ (object.company_id.email or object.user_id.email) }}&gt;</field>
<field name="email_to">{{object.email}}</field>
<field name="partner_to">{{object.id}}</field>
<field name="body_html" type="html">
<link href="https://fonts.googleapis.com/css?family=Dancing+Script"
rel="stylesheet"/>
<div style="background-image: url(/contacts_birthday_greetings/static/src/img/birthday_greetings_2.png); background-position: center top;background-color: transparent; width: 100% !important;height:1050px !important;" >
<div style="text-align: center;font-weight: normal;font-size: 20px; padding-top: 210px;">
Today is your special day!
</div>
<div style="text-align: center;font-weight: normal;font-size: 30px; padding-top: 45px;">
Happy Birthday
</div>
<div style="text-align: center;font-weight: normal;font-size: 25px; padding-top: 30px;">
<span t-field="object.name"/>
</div>
<div align="center">
<img src="contacts_birthday_greetings/static/src/img/galaxy_cupcakes.png"
alt="image" title="image"
style="outline: none;text-decoration: none;-ms-interpolation-mode: bicubic;clear: both;display: inline-block !important;border: none;height: auto;float: none;"
class="v-src-width v-src-max-width" width="250"
border="0" align="middle"/>
</div>
<div style="text-align: center;font-weight: normal;font-size: 30px; padding-top: 20px;">
<strong>From all of us at</strong>
<br></br>
<span t-field="object.user_id.company_id.name"/>
</div>
<div style="text-align: center;font-weight: normal;font-size: 20px; padding-top: 25px;">
We hope your day is filled with good things,
<br></br>
and that the year ahead is even better than the last!
</div>
</div>
</field>
<field name="auto_delete" eval="True"/>
</record>
</data>
</odoo>

6
contacts_birthday_greetings/views/res_config_settings_views.xml

@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="res_config_settings_view_mail_track" model="ir.ui.view">
<field name="name">res.config.settings.view.form.inherit</field>
<field name="model">res.config.settings</field>
@ -17,16 +16,11 @@
<div class="row mt16" >
<label for="greetings_mail_template_id" class="col-lg-4 o_light_label"/>
<field name="greetings_mail_template_id" class="oe_inline"/>
</div>
</div>
</div>
</div>
</xpath>
</field>
</record>
</odoo>

Loading…
Cancel
Save