fix bugs and stripe
This commit is contained in:
parent
9a7e3fe740
commit
21a256a26f
17 changed files with 542 additions and 88 deletions
90
custom_ui/templates/emails/downpayment.html
Normal file
90
custom_ui/templates/emails/downpayment.html
Normal file
|
|
@ -0,0 +1,90 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Down Payment Required</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
line-height: 1.6;
|
||||
color: #333;
|
||||
background-color: #f4f4f4;
|
||||
margin: 0;
|
||||
padding: 20px;
|
||||
}
|
||||
.container {
|
||||
max-width: 600px;
|
||||
margin: 0 auto;
|
||||
background-color: #ffffff;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
.header {
|
||||
text-align: center;
|
||||
padding-bottom: 20px;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
.header h1 {
|
||||
color: #2c3e50;
|
||||
margin: 0;
|
||||
}
|
||||
.content {
|
||||
padding: 20px 0;
|
||||
}
|
||||
.payment-details {
|
||||
background-color: #ecf0f1;
|
||||
padding: 15px;
|
||||
border-radius: 5px;
|
||||
margin: 20px 0;
|
||||
}
|
||||
.payment-details h2 {
|
||||
margin-top: 0;
|
||||
color: #e74c3c;
|
||||
}
|
||||
.cta-button {
|
||||
display: inline-block;
|
||||
background-color: #3498db;
|
||||
color: #ffffff;
|
||||
padding: 12px 24px;
|
||||
text-decoration: none;
|
||||
border-radius: 5px;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
margin: 20px 0;
|
||||
}
|
||||
.footer {
|
||||
text-align: center;
|
||||
padding-top: 20px;
|
||||
border-top: 1px solid #eee;
|
||||
color: #7f8c8d;
|
||||
font-size: 14px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="header">
|
||||
<h1>Thank You for Confirming Your Quote</h1>
|
||||
</div>
|
||||
<div class="content">
|
||||
<p>Dear Valued Customer,</p>
|
||||
<p>Thank you for accepting our quote for services at {{ company_name }}. We're excited to work with you and appreciate your trust in our team.</p>
|
||||
<p>To proceed with scheduling your service, a half down payment is required. This helps us secure the necessary resources and ensures everything is prepared for your appointment.</p>
|
||||
<div class="payment-details">
|
||||
<h2>Payment Details</h2>
|
||||
<p><strong>Sales Order Number:</strong> {{ sales_order_number }}</p>
|
||||
<p><strong>Down Payment Amount:</strong> ${{ total_amount }}</p>
|
||||
</div>
|
||||
<p>Please click the button below to make your secure payment through our payment processor:</p>
|
||||
<a href="{{ base_url }}/api/method/custom_ui.api.public.payments.half_down_stripe_payment?sales_order={{ sales_order_number }}" class="cta-button">Make Payment</a>
|
||||
<p>If you have any questions or need assistance, feel free to contact us. We're here to help!</p>
|
||||
<p>Best regards,<br>The Team at {{ company_name }}</p>
|
||||
</div>
|
||||
<div class="footer">
|
||||
<p>This is an automated email. Please do not reply directly.</p>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
251
custom_ui/templates/emails/general_estimation.html
Normal file
251
custom_ui/templates/emails/general_estimation.html
Normal file
|
|
@ -0,0 +1,251 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Estimate from {{ company }}</title>
|
||||
<style>
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
background-color: #f4f4f4;
|
||||
}
|
||||
.email-container {
|
||||
max-width: 600px;
|
||||
margin: 0 auto;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
.letterhead {
|
||||
text-align: center;
|
||||
padding: 30px 20px;
|
||||
background-color: #ffffff;
|
||||
border-bottom: 3px solid #0066cc;
|
||||
}
|
||||
.letterhead img {
|
||||
max-width: 250px;
|
||||
height: auto;
|
||||
}
|
||||
.company-name {
|
||||
font-size: 28px;
|
||||
font-weight: bold;
|
||||
color: #333333;
|
||||
margin: 10px 0;
|
||||
}
|
||||
.content {
|
||||
padding: 40px 30px;
|
||||
}
|
||||
.greeting {
|
||||
font-size: 18px;
|
||||
color: #333333;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.intro-text {
|
||||
font-size: 16px;
|
||||
color: #555555;
|
||||
line-height: 1.6;
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
.estimate-box {
|
||||
background-color: #f8f9fa;
|
||||
border: 2px solid #e0e0e0;
|
||||
border-radius: 8px;
|
||||
padding: 25px;
|
||||
margin: 30px 0;
|
||||
}
|
||||
.estimate-label {
|
||||
font-size: 14px;
|
||||
color: #666666;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 1px;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
.estimate-value {
|
||||
font-size: 16px;
|
||||
color: #333333;
|
||||
margin-bottom: 20px;
|
||||
line-height: 1.5;
|
||||
}
|
||||
.estimate-value:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.price-section {
|
||||
background-color: #0066cc;
|
||||
color: #ffffff;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
margin-top: 20px;
|
||||
text-align: center;
|
||||
}
|
||||
.price-label {
|
||||
font-size: 14px;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 1px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.price-amount {
|
||||
font-size: 36px;
|
||||
font-weight: bold;
|
||||
}
|
||||
.additional-section {
|
||||
background-color: #fff9e6;
|
||||
border-left: 4px solid #ffc107;
|
||||
padding: 20px;
|
||||
margin: 30px 0;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.additional-label {
|
||||
font-size: 14px;
|
||||
color: #856404;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 1px;
|
||||
margin-bottom: 10px;
|
||||
font-weight: bold;
|
||||
}
|
||||
.additional-text {
|
||||
font-size: 15px;
|
||||
color: #333333;
|
||||
line-height: 1.6;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
.action-buttons {
|
||||
text-align: center;
|
||||
margin: 40px 0;
|
||||
padding: 20px;
|
||||
}
|
||||
.btn {
|
||||
display: inline-block;
|
||||
padding: 14px 28px;
|
||||
margin: 8px;
|
||||
text-decoration: none;
|
||||
border-radius: 6px;
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
transition: opacity 0.3s;
|
||||
}
|
||||
.btn:hover {
|
||||
opacity: 0.85;
|
||||
}
|
||||
.btn-accept {
|
||||
background-color: #28a745;
|
||||
color: #ffffff;
|
||||
}
|
||||
.btn-decline {
|
||||
background-color: #dc3545;
|
||||
color: #ffffff;
|
||||
}
|
||||
.btn-call {
|
||||
background-color: #ffc107;
|
||||
color: #333333;
|
||||
}
|
||||
.closing-text {
|
||||
font-size: 16px;
|
||||
color: #555555;
|
||||
line-height: 1.6;
|
||||
margin-top: 30px;
|
||||
}
|
||||
.contact-info {
|
||||
font-size: 15px;
|
||||
color: #0066cc;
|
||||
font-weight: bold;
|
||||
margin-top: 15px;
|
||||
}
|
||||
.footer {
|
||||
background-color: #f8f9fa;
|
||||
padding: 30px;
|
||||
text-align: center;
|
||||
border-top: 1px solid #e0e0e0;
|
||||
}
|
||||
.footer-text {
|
||||
font-size: 14px;
|
||||
color: #666666;
|
||||
line-height: 1.6;
|
||||
}
|
||||
@media only screen and (max-width: 600px) {
|
||||
.content {
|
||||
padding: 30px 20px;
|
||||
}
|
||||
.estimate-box {
|
||||
padding: 20px;
|
||||
}
|
||||
.price-amount {
|
||||
font-size: 28px;
|
||||
}
|
||||
.company-name {
|
||||
font-size: 24px;
|
||||
}
|
||||
.btn {
|
||||
display: block;
|
||||
margin: 10px auto;
|
||||
max-width: 250px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="email-container">
|
||||
<!-- Letterhead Section -->
|
||||
<div class="letterhead">
|
||||
{% if letterhead_image %}
|
||||
<img src="{{ letterhead_image }}" alt="{{ company }} Logo">
|
||||
{% else %}
|
||||
<div class="company-name">{{ company }}</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<!-- Main Content -->
|
||||
<div class="content">
|
||||
<div class="greeting">Hello {{ customer_name }},</div>
|
||||
|
||||
<div class="intro-text">
|
||||
Thank you for considering {{ company }} for your project. We are pleased to provide you with the following estimate for the services requested.
|
||||
</div>
|
||||
|
||||
<!-- Estimate Details Box -->
|
||||
<div class="estimate-box">
|
||||
<div class="estimate-label">Service Location</div>
|
||||
<div class="estimate-value">{{ address }}</div>
|
||||
|
||||
<!-- Price Section -->
|
||||
<div class="price-section">
|
||||
<div class="price-label">Total Estimate</div>
|
||||
<div class="price-amount">{{ price }}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Additional Notes (Conditional) -->
|
||||
{% if additional %}
|
||||
<div class="additional-section">
|
||||
<div class="additional-label">Additional Notes</div>
|
||||
<div class="additional-text">{{ additional }}</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<!-- Action Buttons -->
|
||||
<div class="action-buttons">
|
||||
<a href="{{ base_url }}/api/method/custom_ui.api.public.estimates.update_response?name={{ estimate_name }}&response=Accepted" class="btn btn-accept">Accept</a>
|
||||
<a href="{{ base_url }}/api/method/custom_ui.api.public.estimates.update_response?name={{ estimate_name }}&response=Rejected" class="btn btn-decline">Decline</a>
|
||||
<a href="{{ base_url }}/api/method/custom_ui.api.public.estimates.update_response?name={{ estimate_name }}&response=Requested%20call" class="btn btn-call">Request a Call</a>
|
||||
</div>
|
||||
|
||||
<!-- Closing -->
|
||||
<div class="closing-text">
|
||||
This estimate is valid for 30 days from the date of this email. If you have any questions or would like to proceed with this estimate, please don't hesitate to contact us.
|
||||
{% if company_phone %}
|
||||
<div class="contact-info">Call us at: {{ company_phone }}</div>
|
||||
{% endif %}
|
||||
<br>
|
||||
We look forward to working with you!
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Footer -->
|
||||
<div class="footer">
|
||||
<div class="footer-text">
|
||||
<strong>{{ company }}</strong><br>
|
||||
This is an automated message. Please do not reply directly to this email.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
0
custom_ui/templates/emails/snw_install_estimation.html
Normal file
0
custom_ui/templates/emails/snw_install_estimation.html
Normal file
Loading…
Add table
Add a link
Reference in a new issue