This commit is contained in:
Marwan Alwali 2025-05-07 11:15:46 +03:00
parent 82eb770a89
commit cb4366f028
18 changed files with 182 additions and 274 deletions

View File

@ -1003,7 +1003,7 @@ class LeadForm(forms.ModelForm):
queryset=CarMake.objects.filter(is_sa_import=True),
widget=forms.Select(
attrs={
"class": "form-control form-control-sm",
"hx-get": "",
"hx-include": "#id_id_car_make",
"hx-select": "#div_id_id_car_model",
@ -1018,7 +1018,7 @@ class LeadForm(forms.ModelForm):
id_car_model = forms.ModelChoiceField(
label=_("Model"),
queryset=CarModel.objects.none(),
widget=forms.Select(attrs={"class": "form-control form-control-sm"}),
widget=forms.Select(),
required=True,
)

View File

@ -18,12 +18,12 @@ class AddClassMixin:
:return: class names form-control or form-select
"""
for field_name, field in self.fields.items():
if isinstance(field.widget, forms.Select):
existing_classes = field.widget.attrs.get('class', '')
field.widget.attrs['class'] = f"{existing_classes} form-select form-select-sm".strip()
else:
existing_classes = field.widget.attrs.get('class', '')
field.widget.attrs['class'] = f"{existing_classes} form-control form-control-sm".strip()
# if isinstance(field.widget, forms.Select):
# existing_classes = field.widget.attrs.get('class', '')
# field.widget.attrs['class'] = f"{existing_classes} form-select form-select-sm".strip()
# else:
existing_classes = field.widget.attrs.get('class', '')
field.widget.attrs['class'] = f"{existing_classes} form-control form-control-sm".strip()
class LocalizedNameMixin:

View File

@ -151,6 +151,7 @@ from django_tables2 import SingleTableView
from django_tables2.export.views import ExportMixin
from appointment.models import Appointment, AppointmentRequest, Service, StaffMember
from .models import SaleOrder
from .services import (
decodevin,
get_make,
@ -3831,11 +3832,9 @@ class EstimateDetailView(LoginRequiredMixin, PermissionRequiredMixin, DetailView
if estimate.get_itemtxs_data():
calculator = CarFinanceCalculator(estimate)
finance_data = calculator.get_finance_data()
invoice_obj = InvoiceModel.objects.all().filter(ce_model=estimate).first()
kwargs["data"] = finance_data
kwargs["invoice"] = (
InvoiceModel.objects.all().filter(ce_model=estimate).first()
)
kwargs["invoice"] = invoice_obj
return super().get_context_data(**kwargs)
@ -7654,11 +7653,12 @@ def pricing_page(request):
# @require_POST
def submit_plan(request):
dealer = get_user_type(request)
selected_plan_id = request.POST.get("selected_plan")
pp = PlanPricing.objects.get(pk=selected_plan_id)
order = Order.objects.create(
user=request.user,
user=dealer.user,
plan=pp.plan,
pricing=pp.pricing,
amount=pp.price,
@ -7674,14 +7674,14 @@ def payment_callback(request):
payment_id = request.GET.get("id")
history = models.PaymentHistory.objects.filter(transaction_id=payment_id).first()
payment_status = request.GET.get("status")
order = Order.objects.filter(user=dealer,status=AbstractOrder.STATUS.NEW).first()
order = Order.objects.filter(user=dealer.user,status=AbstractOrder.STATUS.NEW).first()
if payment_status == "paid":
billing_info,created = BillingInfo.objects.get_or_create(
user=dealer.user,
tax_number=dealer.vrn,
name=dealer.arabic_name,
street=dealer.entity.address,
street=dealer.address,
zipcode=dealer.entity.zip_code,
city=dealer.entity.city,
country=dealer.entity.country,

View File

@ -50,3 +50,15 @@
@keyframes spin {
to { transform: rotate(360deg); }
}
.form-select select {
padding: 0 16px 0 48px;
right: auto;
left: 0;
direction: rtl;
}
.form-select:after {
left: 16px;
right: auto;
}

View File

@ -3780,8 +3780,9 @@ textarea.form-control-lg {
.form-select {
--phoenix-form-select-bg-img: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTUwIiBoZWlnaHQ9IjE1MCIgdmlld0JveD0iMCAwIDE1MCAxNTAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik03NS4zNDggMTI3LjE5MkM3Mi40MzgxIDEyNy4xOTIgNjkuODUxNCAxMjYuMjIyIDY3LjkxMTUgMTI0LjI4Mkw1LjgzMjE1IDYyLjIwMjNDMS42Mjg4NyA1OC4zMjIzIDEuNjI4ODcgNTEuNTMyNCA1LjgzMjE1IDQ3LjY1MjVDOS43MTIxMSA0My40NDkyIDE2LjUwMiA0My40NDkyIDIwLjM4MiA0Ny42NTI1TDc1LjM0OCAxMDIuMjk1TDEyOS45OTEgNDcuNjUyNUMxMzMuODcxIDQzLjQ0OTIgMTQwLjY2MSA0My40NDkyIDE0NC41NDEgNDcuNjUyNUMxNDguNzQ0IDUxLjUzMjQgMTQ4Ljc0NCA1OC4zMjIzIDE0NC41NDEgNjIuMjAyM0w4Mi40NjEzIDEyNC4yODJDODAuNTIxMyAxMjYuMjIyIDc3LjkzNDcgMTI3LjE5MiA3NS4zNDggMTI3LjE5MloiIGZpbGw9IiMzMTM3NEEiLz4KPC9zdmc+Cg==");
align-content: start;
display: block;
text-align: start;
text-align: right;
width: 100%;
padding: 0.5rem 1rem 0.5rem 2.5rem;
font-size: 0.8rem;
@ -3808,9 +3809,12 @@ textarea.form-control-lg {
}
@media (prefers-reduced-motion: reduce) {
.form-select {
-webkit-transition: none;
-webkit-transition:right;
-o-transition: none;
transition: none;
right: auto;
left: 0;
direction: rtl;
}
}
.form-select:focus {

View File

@ -1138,6 +1138,9 @@ select {
select {
word-wrap: normal;
padding: 0 16px 0 48px;
right: auto;
left: 0;
}
select:disabled {
opacity: 1;
@ -3784,8 +3787,9 @@ textarea.form-control-lg {
.form-select {
--phoenix-form-select-bg-img: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTUwIiBoZWlnaHQ9IjE1MCIgdmlld0JveD0iMCAwIDE1MCAxNTAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik03NS4zNDggMTI3LjE5MkM3Mi40MzgxIDEyNy4xOTIgNjkuODUxNCAxMjYuMjIyIDY3LjkxMTUgMTI0LjI4Mkw1LjgzMjE1IDYyLjIwMjNDMS42Mjg4NyA1OC4zMjIzIDEuNjI4ODcgNTEuNTMyNCA1LjgzMjE1IDQ3LjY1MjVDOS43MTIxMSA0My40NDkyIDE2LjUwMiA0My40NDkyIDIwLjM4MiA0Ny42NTI1TDc1LjM0OCAxMDIuMjk1TDEyOS45OTEgNDcuNjUyNUMxMzMuODcxIDQzLjQ0OTIgMTQwLjY2MSA0My40NDkyIDE0NC41NDEgNDcuNjUyNUMxNDguNzQ0IDUxLjUzMjQgMTQ4Ljc0NCA1OC4zMjIzIDE0NC41NDEgNjIuMjAyM0w4Mi40NjEzIDEyNC4yODJDODAuNTIxMyAxMjYuMjIyIDc3LjkzNDcgMTI3LjE5MiA3NS4zNDggMTI3LjE5MloiIGZpbGw9IiMzMTM3NEEiLz4KPC9zdmc+Cg==");
display: block;
align-content: start;
width: 100%;
text-align: start;
text-align: right;
padding: 0.5rem 2.5rem 0.5rem 1rem;
font-size: 0.8rem;
font-weight: 600;

View File

@ -1,9 +1,10 @@
@font-face {
font-family: 'SaudiRiyalFont';
src: url('static/fonts/SaudiRiyalFont.woff2') format('woff2'),
url('static/fonts/SaudiRiyalFont.woff') format('woff'),
url('static/fonts/SaudiRiyalFont.ttf') format('truetype');
src: url('data:font/woff2;charset=utf-8;base64,AAEAAAAOAIAAAwBgRkZUTaeTaogAAAcsAAAAHEdERUYAFQAUAAAHEAAAABxPUy8yVD/gEAAAAWgAAABgY21hcAAQAacAAAHYAAABQmN2dCAAIQJ5AAADHAAAAARnYXNw//8AAwAABwgAAAAIZ2x5ZkNtdysAAAMsAAABXGhlYWQrFeKTAAAA7AAAADZoaGVhB5UDvwAAASQAAAAkaG10eA2GALsAAAHIAAAAEGxvY2EA2ABUAAADIAAAAAptYXhwAEgAlwAAAUgAAAAgbmFtZXvm85wAAASIAAACTHBvc3S1ak3uAAAG1AAAADIAAQAAAAEAAOjiFBRfDzz1AAsD6AAAAADj3kPWAAAAAOPeW4AAIf84BBkDIAAAAAgAAgAAAAAAAAABAAADIP84AFoEggAAAAAEGQABAAAAAAAAAAAAAAAAAAAABAABAAAABABmAAIAAAAAAAIAAAABAAEAAABAAC4AAAAAAAQEggGQAAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAUJAAAAAAAAAAAAAIAAAAAAAAAAAAAAAFBmR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+1ADIAAAABAAAAAAAAAAAAAAAAAAAAAAAEAAAAAQACAQIHdW5pRkRGQwAAAAAAAf//AAIAAQAAAAAAAAAMABQABAAAAAIAAAABAAAAAQAAAAAAAQAAAADf1ssxAAAAAOPeQ9YAAAAA495bgA==') format('woff');
font-weight: normal;
font-style: normal;
font-display: swap;
}
.currency {
@ -26,4 +27,26 @@
.rtl .fa-chevron-right {
transform: scaleX(-1);
}
}
.spinner-container {
display: flex;
align-items: center;
gap: 10px;
padding: 10px;
color: #555;
font-size: 14px;
}
.spinner {
width: 18px;
height: 18px;
border: 3px solid #ccc;
border-top-color: #333;
border-radius: 50%;
animation: spin 0.6s linear infinite;
}
@keyframes spin {
to { transform: rotate(360deg); }
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 MiB

View File

@ -120,85 +120,7 @@
/* Echarts Total Sales */
/* -------------------------------------------------------------------------- */
const contactsBySourceChartInit = () => {
const { getColor, getData, toggleColor } = window.phoenix.utils;
const chartElContainer = document.querySelector(
'.echart-contact-by-source-container'
);
const chartEl = chartElContainer.querySelector('.echart-contact-by-source');
const chartLabel = chartElContainer.querySelector('[data-label]');
if (chartEl) {
const userOptions = getData(chartEl, 'echarts');
const chart = window.echarts.init(chartEl);
const data = [
{ value: 80, name: 'Organic Search' },
{ value: 65, name: 'Paid Search' },
{ value: 40, name: 'Direct Traffic' },
{ value: 220, name: 'Social Media' },
{ value: 120, name: 'Referrals' },
{ value: 35, name: 'Others Campaigns' }
];
const totalSource = data.reduce((acc, val) => val.value + acc, 0);
if (chartLabel) {
chartLabel.innerHTML = totalSource;
}
const getDefaultOptions = () => ({
color: [
getColor('primary'),
getColor('success'),
getColor('info'),
getColor('info-light'),
toggleColor(getColor('danger-lighter'), getColor('danger-darker')),
toggleColor(getColor('warning-light'), getColor('warning-dark'))
],
tooltip: {
trigger: 'item',
borderWidth: 0,
position: (...params) => handleTooltipPosition(params),
extraCssText: 'z-index: 1000'
},
responsive: true,
maintainAspectRatio: false,
series: [
{
name: 'Contacts by Source',
type: 'pie',
radius: ['55%', '90%'],
startAngle: 90,
avoidLabelOverlap: false,
itemStyle: {
borderColor: getColor('body-bg'),
borderWidth: 3
},
label: {
show: false
},
emphasis: {
label: {
show: false
}
},
labelLine: {
show: false
},
data
}
],
grid: {
bottom: 0,
top: 0,
left: 0,
right: 0,
containLabel: false
}
});
echartSetOption(chart, userOptions, getDefaultOptions);
}
};
// dayjs.extend(advancedFormat);
@ -1338,7 +1260,6 @@
const { docReady } = window.phoenix.utils;
docReady(contactsBySourceChartInit);
docReady(contactsCreatedChartInit);
docReady(newUsersChartsInit);
docReady(newLeadsChartsInit);

View File

@ -40,12 +40,12 @@
<link href="{% static 'vendors/flatpickr/flatpickr.min.css' %}" rel="stylesheet">
<link href="{% static 'css/custom.css' %}" rel="stylesheet">
<link rel="stylesheet" href="https://unicons.iconscout.com/release/v4.0.8/css/line.css">
{% if LANGUAGE_CODE == 'en' %}
<link href="{% static 'css/theme.min.css' %}" type="text/css" rel="stylesheet" id="style-default">
<link href="{% static 'css/user.min.css' %}" type="text/css" rel="stylesheet" id="user-style-default">
{% else %}
{% if LANGUAGE_CODE == 'ar' %}
<link href="{% static 'css/theme-rtl.min.css' %}" type="text/css" rel="stylesheet" id="style-rtl">
<link href="{% static 'css/user-rtl.min.css' %}" type="text/css" rel="stylesheet" id="user-style-rtl">
{% else %}
<link href="{% static 'css/theme.min.css' %}" type="text/css" rel="stylesheet" id="style-default">
<link href="{% static 'css/user.min.css' %}" type="text/css" rel="stylesheet" id="user-style-default">
{% endif %}
<script src="{% static 'js/main.js' %}"></script>
<script src="{% static 'js/jquery.min.js' %}"></script>

View File

@ -2,20 +2,21 @@
{% load i18n static crispy_forms_filters %}
{% block content %}
<h1>{% if object %}Update{% else %}Create{% endif %}</h1>
<form method="post">
{% csrf_token %}
{{ form|crispy }}
<button
type="submit"
name="add_lead"
id="lead-save"
class="btn btn-phoenix-primary"
>
<i class="fa-solid fa-floppy-disk"></i> {{ _("Save") }}
</button>
<a href="{% url 'lead_list' %}" class="btn btn-phoenix-secondary">
<i class="fa-solid fa-ban"></i> {{ _("Cancel") }}
</a>
</form>
<div class="container-fluid">
<h1>{% if object %}{{ _("Update") }}{% else %}{{ _("Create") }}{% endif %}</h1>
<div class="row mb-3">
<div class="col-sm-6 col-md-8">
<form class="form" method="post">
{% csrf_token %}
{{ form|crispy }}
<button type="submit" name="add_lead" id="lead-save" class="btn btn-phoenix-primary">
<i class="fa-solid fa-floppy-disk"></i> {{ _("Save") }}
</button>
<a href="{{request.META.HTTP_REFERER}}" class="btn btn-phoenix-secondary">
<i class="fa-solid fa-ban"></i> {{ _("Cancel") }}
</a>
</form>
</div>
</div>
</div>
{% endblock %}

View File

@ -26,7 +26,12 @@
{% csrf_token %}
{{ form|crispy }}
<div class="col-12">
<button class="btn btn-primary" type="submit"><i class="fa-solid fa-floppy-disk"></i> {% trans "Save" %}</button>
<button class="btn btn-phoenix-primary" type="submit">
<i class="fa-solid fa-floppy-disk"></i> {% trans "Save" %}
</button>
<a href="{{request.META.HTTP_REFERER}}" class="btn btn-phoenix-secondary">
<i class="fa-solid fa-ban"></i> {{ _("Cancel") }}
</a>
</div>
</form>
</div>

View File

@ -45,16 +45,19 @@
<thead>
<tr class="bg-body-highlight">
<th class="border-top border-translucent">{% trans "Type" %}</th>
<th class="border-top border-translucent ps-3">{% trans "Account Name" %}</th>
<th class="border-top border-translucent">{% trans "Code" %}</th>
<th class="border-top border-translucent text-end pe-3">{% trans "Balance Type" %}</th>
<th class="border-top border-translucent text-end pe-3">{% trans "Active" %}</th>
<th class="border-top border-translucent text-end align-middle pe-0 ps-4" scope="col"></th>
</tr>
</thead>
<tbody class="list">
{% for account in accounts %}
</thead>
<tbody class="list">
{% for account in accounts %}
<div class="modal fade" id="deleteModal"
data-bs-backdrop="static"
data-bs-keyboard="false"
@ -89,6 +92,7 @@
</div>
</div>
<tr>
<td class="align-middle ps-3 fw-lighter">{{ account.role_bs|upper }}</td>
<td class="align-middle ps-3">{{ account.name }}</td>
<td class="align-middle">{{ account.code }}</td>
<td class="align-middle text-end py-3 pe-3">

View File

@ -3,20 +3,24 @@
{% load crispy_forms_filters %}
{% block title %}{% trans "Add Organization" %}{% endblock title %}
{% block content %}
<div class="row my-4">
<div class="container-fluid">
<h3>{% trans "Add Organization" %}</h3>
<form class="row g-3 mb-9" method="post" enctype="multipart/form-data">
{% csrf_token %}
{{ redirect_field }}
{{ form|crispy }}
<div class="d-flex mb-3">
<a href="{{request.META.HTTP_REFERER}}" class="btn btn-phoenix-primary me-2 px-6">{% trans "Cancel"|capfirst %}</a>
<button class="btn btn-primary" type="submit">
<!--<i class="bi bi-save"></i> -->
{{ _("Save") }}
</button>
</div>
</form>
<div class="row mb-3">
<div class="col-sm-6 col-md-8">
<form class="form" method="post" enctype="multipart/form-data">
{% csrf_token %}
{{ redirect_field }}
{{ form|crispy }}
<button class="btn btn-phoenix-primary" type="submit">
<i class="fa-solid fa-floppy-disk"></i>
{{ _("Save") }}
</button>
<a href="{{request.META.HTTP_REFERER}}" class="btn btn-phoenix-secondary">
<i class="fa-solid fa-ban"></i> {% trans "Cancel" %}
</a>
</form>
</div>
</div>
</div>
{% endblock %}

View File

@ -3,7 +3,7 @@
<table class="table table-hover table-compare mb-0">
<thead>
<tr class="border-bottom border-200">
<th style="width: 30%; min-width: 280px;" class="ps-4 bg-white position-sticky start-0 border-end border-200"></th>
<th style="width: 30%; min-width: 280px;" class="ps-4 position-sticky start-0 border-end border-200"></th>
{% for plan in plan_list %}
<th class="text-center py-3 {% if forloop.counter0 == current_userplan_index %}bg-primary-soft{% endif %}" style="width: calc(70%/{{ plan_list|length }});">
<div class="d-flex flex-column align-items-center">
@ -20,7 +20,7 @@
</thead>
<tbody>
{% for quota_row in plan_table %}
<tr class="border-bottom border-200 {% cycle 'bg-white' 'bg-light' %}">
<tr class="border-bottom border-200 ">
<th class="ps-4 fw-normal position-sticky start-0 bg-inherit border-end border-200">
<div class="d-flex flex-column py-2">
{% if quota_row.0.url %}<a href="{{ quota_row.0.url }}" class="text-decoration-none text-dark">{% endif %}
@ -58,15 +58,15 @@
</tbody>
<tfoot>
<tr class="border-bottom border-200">
<th class="ps-4 bg-white position-sticky start-0 border-end border-200"></th>
<th colspan="{{ plan_list|length }}" class="text-center py-3 bg-light">
<th class="ps-4 position-sticky start-0 border-end border-200"></th>
<th colspan="{{ plan_list|length }}" class="text-center py-3">
<h6 class="mb-0 fw-bold">{% trans 'Pricing' %}</h6>
</th>
</tr>
{% if user.is_authenticated %}
<tr class="border-bottom border-200">
<th class="ps-4 bg-white position-sticky start-0 border-end border-200"></th>
<th class="ps-4 position-sticky start-0 border-end border-200"></th>
{% for plan in plan_list %}
<td class="text-center py-3 {% if forloop.counter0 == current_userplan_index %}bg-primary-soft{% endif %}">
{% if plan != userplan.plan and not userplan.is_expired and not userplan.plan.is_free %}
@ -80,7 +80,7 @@
{% endif %}
<tr>
<th class="ps-4 bg-white position-sticky start-0 border-end border-200"></th>
<th class="ps-4 position-sticky start-0 border-end border-200"></th>
{% for plan in plan_list %}
<td class="p-3 {% if forloop.counter0 == current_userplan_index %}bg-primary-soft{% endif %}">
{% if plan.available %}
@ -88,7 +88,7 @@
{% if not plan.is_free %}
{% for plan_pricing in plan.planpricing_set.all %}
{% if plan_pricing.visible %}
<div class="p-3 rounded-2 {% if plan_pricing.plan == userplan.plan %}bg-success-soft{% else %}bg-light{% endif %}">
<div class="p-3 rounded-2 {% if plan_pricing.plan == userplan.plan %}bg-success-soft{% else %}bg-body{% endif %}">
{% if plan_pricing.pricing.url %}<a href="{{ plan_pricing.pricing.url }}" class="text-decoration-none text-dark">{% endif %}
<div class="d-flex justify-content-between align-items-center mb-1">
<span class="fw-semibold">{{ plan_pricing.pricing.name }}</span>
@ -107,7 +107,7 @@
{% endif %}
{% endfor %}
{% else %}
<div class="p-3 rounded-2 bg-light">
<div class="p-3 rounded-2">
<div class="d-flex justify-content-between align-items-center mb-1">
<span class="fw-semibold">{% trans "Free" %}</span>
<span class="badge bg-secondary bg-opacity-10 text-secondary fs-10">{% trans "no expiry" %}</span>

View File

@ -13,7 +13,6 @@
.pricing-card .card.selected {
border-color: #0d6efd;
box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.4);
background-color: #f0f8ff;
}
.btn-check:checked + .btn .card {
@ -25,18 +24,15 @@
.card.selected {
border-color: #0d6efd;
box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.4);
background-color: #f0f8ff;
}
.summary-box {
background: #f8f9fa;
border: 1px solid #dee2e6;
border: 1px solid #8d8f94;
border-radius: 0.5rem;
padding: 1.5rem;
}
.summary-box h5 {
border-bottom: 1px solid #dee2e6;
padding-bottom: 0.5rem;
margin-bottom: 1rem;
}
@ -53,7 +49,7 @@
{% block content %}
<div class="container py-5">
<h1 class="text-center mb-5">Choose Your Plan</h1>
<h1 class="text-center mb-5">{{ _("Choose Your Plan")}}</h1>
<form method="POST" action="{% url 'submit_plan' %}" id="wizardForm">
{% csrf_token %}
@ -94,38 +90,38 @@
<h4 class="mb-4">2. {{ _("Enter Your Information")}}</h4>
<div class="row g-3">
<div class="col-md-6">
<label class="form-label">{{ _("First Name")}}</label>
<label class="form-label" for="first_name">{{ _("First Name")}}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-user"></i></span>
<input type="text" name="first_name" id="first_name" class="form-control" required placeholder="John" value="{{ request.user.first_name }}">
<input type="text" name="first_name" id="first_name" class="form-control form-control-sm" required placeholder="{{ _("First Name")}}" value="{{ request.user.first_name }}">
</div>
</div>
<div class="col-md-6">
<label class="form-label">{{ _("Last Name")}}</label>
<label class="form-label" for="last_name">{{ _("Last Name")}}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-user"></i></span>
<input type="text" name="last_name" id="last_name" class="form-control" required placeholder="Doe" value="{{ request.user.last_name }}">
<input type="text" name="last_name" id="last_name" class="form-control form-control-sm" required placeholder="{{ _("Last Name")}}" value="{{ request.user.last_name }}">
</div>
</div>
<div class="col-md-6">
<label class="form-label">{{ _("Email Address")}}</label>
<label class="form-label" for="email">{{ _("Email Address")}}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-envelope"></i></span>
<input type="email" name="email" id="email" class="form-control" required placeholder="email@example.com" value="{{ request.user.email }}">
<input type="email" name="email" id="email" class="form-control form-control-sm" required placeholder="email@example.com" value="{{ request.user.email }}">
</div>
</div>
<div class="col-md-6">
<label class="form-label">{{ _("Phone Number")}}</label>
<label class="form-label" for="phone">{{ _("Phone Number")}}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-phone"></i></span>
<input type="text" name="phone" id="phone" class="form-control" required placeholder="056XXXXXXX" value="{{ request.user.dealer.phone_number.raw_input }}">
<input type="text" name="phone" id="phone" class="form-control form-control-sm" dir="ltr" placeholder="{{ _("Phone Number")}}" value="{{ request.user.dealer.phone_number.raw_input }}" required>
</div>
</div>
<div class="col-md-6">
<label class="form-label">{{ _("Company") }}</label>
<label class="form-label" for="company">{{ _("Company") }}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-building"></i></span>
<input type="text" name="company" id="company" class="form-control" placeholder="ABC Company">
<input type="text" name="company" id="company" class="form-control form-control-sm" placeholder="{{ _("Company") }}" value="{{ request.user.dealer.get_local_name }}">
</div>
</div>
</div>
@ -136,38 +132,38 @@
<h4 class="mb-4">3. {{ _("Payment Information")}}</h4>
<div class="row g-3">
<div class="col-md-6">
<label class="form-label">{{ _("Cardholder Name")}}</label>
<label class="form-label" for="card_name">{{ _("Cardholder Name")}}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-user"></i></span>
<input type="text" name="card_name" id="card_name" class="form-control" placeholder="John Doe" required>
<input type="text" name="card_name" id="card_name" class="form-control form-control-sm" placeholder="{{ _("Cardholder Name")}}" required>
</div>
</div>
<div class="col-md-6">
<label class="form-label">{{ _("Card Number")}}</label>
<label class="form-label" for="card_number">{{ _("Card Number")}}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-credit-card"></i></span>
<input type="text" name="card_number" id="card_number" class="form-control" placeholder="1234 5678 9012 3456"
<input type="text" name="card_number" id="card_number" class="form-control form-control-sm" placeholder="{{ _("Card Number")}}"
maxlength="19" pattern="^\d{4}\s\d{4}\s\d{4}\s\d{4}$"
inputmode="numeric" required title="Enter a 16-digit card number">
</div>
</div>
<div class="col-md-4">
<label class="form-label">{{ _("Expiry Date")}} (MM/YY)</label>
<label class="form-label" for="card_expiry">{{ _("Expiry Date")}} (MM/YY)</label>
<div class="input-group">
<span class="input-group-text"><i class="far fa-calendar-alt"></i></span>
<input type="text" name="card_expiry" id="card_expiry" class="form-control" placeholder="08/28"
<input type="text" name="card_expiry" id="card_expiry" class="form-control form-control-sm" placeholder="{{ _("Expiry Date")}}"
maxlength="5" pattern="^(0[1-9]|1[0-2])\/\d{2}$"
inputmode="numeric" required title="Enter expiry in MM/YY format">
</div>
</div>
<div class="col-md-2">
<label class="form-label">{{ _("CVV") }}</label>
<label class="form-label" for="card_cvv">{{ _("CVV") }}</label>
<div class="input-group">
<span class="input-group-text"><i class="fas fa-lock"></i></span>
<input type="text" name="card_cvv" id="card_cvv" class="form-control" placeholder="123"
<input type="text" name="card_cvv" id="card_cvv" class="form-control form-control-sm" placeholder="{{ _("CVV") }}"
maxlength="3" pattern="^\d{3}$"
inputmode="numeric" required title="Enter 3-digit CVV">
</div>

View File

@ -105,10 +105,11 @@
<button id="accept_estimate" onclick="setFormAction('approved')" class="btn btn-phoenix-secondary" data-bs-toggle="modal" data-bs-target="#confirmModal"><span class="d-none d-sm-inline-block"><i class="fa-solid fa-check-double"></i> {% trans 'Mark As Accept' %}</span></button>
{% elif estimate.status == 'approved' %}
{% if estimate.sale_orders.first %}
<a href="{% url 'invoice_create' estimate.pk %}" class="btn btn-phoenix-primary"><span class="d-none d-sm-inline-block"><i class="fa-solid fa-receipt"></i> {% trans 'Create Invoice' %}</span></a>
<a href="{% url 'invoice_create' estimate.pk %}" class="btn btn-phoenix-primary"><span class="d-none d-sm-inline-block"><i class="fa-solid fa-receipt"></i> {% trans 'Create Invoice' %}</span></a>
<a href="{% url 'preview_sale_order' estimate.pk %}" class="btn btn-phoenix-primary"><span class="d-none d-sm-inline-block">{{ _("Preview Sale Order") }}</span></a>
{% else %}
<a href="{% url 'create_sale_order' estimate.pk %}" class="btn btn-phoenix-primary"><span class="d-none d-sm-inline-block"><i class="fa-solid fa-file-import"></i> {% trans 'Create Sale Order' %}</span></a>
{% comment %} <a href="{% url 'preview_sale_order' estimate.pk %}" class="btn btn-phoenix-primary"><span class="d-none d-sm-inline-block">{% trans 'Preview Sale Order' %}</span></a> {% endcomment %}
{% comment %} {% endcomment %}
{% endif %}
{% elif estimate.status == 'in_review' %}
<a href="{% url 'estimate_preview' estimate.pk %}" class="btn btn-phoenix-primary"><span class="d-none d-sm-inline-block"><i class="fa-regular fa-eye"></i> {% trans 'Preview' %}</span></a>

View File

@ -119,94 +119,36 @@
{% else %}
<link href="{% static 'css/theme-rtl.min.css' %}" type="text/css" rel="stylesheet" id="style-rtl">
<link href="{% static 'css/user-rtl.min.css' %}" type="text/css" rel="stylesheet" id="user-style-rtl">
{% endif %}
{% endif %}
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css">
</head>
<body>
{% if not estimate.is_completed %}
{% if estimate.is_completed %}
<main class="main" id="top">
<div class="px-3">
<div class="row min-vh-100 flex-center p-5">
<div class="col-12 col-xl-10 col-xxl-8">
<div class="row justify-content-center align-items-center g-5">
<div class="col-12 col-lg-6 text-center order-lg-1"><img class="img-fluid w-lg-100 d-dark-none" src="{% static 'images/spot-illustrations/404-illustration.png' %}" alt="" width="400" /><img class="img-fluid w-md-50 w-lg-100 d-light-none" src="../../assets/img/spot-illustrations/dark_404-illustration.png" alt="" width="540" /></div>
<div class="col-12 col-lg-6 text-center text-lg-start"><img class="img-fluid mb-6 w-50 w-lg-75 d-dark-none" src="{% static 'images/spot-illustrations/404.png' %}" alt="" /><img class="img-fluid mb-6 w-50 w-lg-75 d-light-none" src="../../assets/img/spot-illustrations/dark_404.png" alt="" />
<h2 class="text-body-secondary fw-bolder mb-3">Page Missing!</h2>
<p class="text-body mb-5">But no worries! Our ostrich is looking everywhere <br class="d-none d-sm-block" />
<p class="text-body mb-5">ERROR FETCHING DATA</p>
</div>
</div>
</div>
</div>
</div>
<script>
var navbarTopStyle = window.config.config.phoenixNavbarTopStyle;
var navbarTop = document.querySelector('.navbar-top');
if (navbarTopStyle === 'darker') {
navbarTop.setAttribute('data-navbar-appearance', 'darker');
}
var navbarVerticalStyle = window.config.config.phoenixNavbarVerticalStyle;
var navbarVertical = document.querySelector('.navbar-vertical');
if (navbarVertical && navbarVerticalStyle === 'darker') {
navbarVertical.setAttribute('data-navbar-appearance', 'darker');
}
</script>
<div class="support-chat-row">
<div class="row-fluid support-chat">
<div class="card bg-body-emphasis">
<div class="card-header d-flex flex-between-center px-4 py-3 border-bottom border-translucent">
<h5 class="mb-0 d-flex align-items-center gap-2">Demo widget<span class="fa-solid fa-circle text-success fs-11"></span></h5>
<div class="btn-reveal-trigger">
<button class="btn btn-link p-0 dropdown-toggle dropdown-caret-none transition-none d-flex" type="button" id="support-chat-dropdown" data-bs-toggle="dropdown" data-boundary="window" aria-haspopup="true" aria-expanded="false" data-bs-reference="parent"><span class="fas fa-ellipsis-h text-body"></span></button>
<div class="dropdown-menu dropdown-menu-end py-2" aria-labelledby="support-chat-dropdown"><a class="dropdown-item" href="#!">Request a callback</a><a class="dropdown-item" href="#!">Search in chat</a><a class="dropdown-item" href="#!">Show history</a><a class="dropdown-item" href="#!">Report to Admin</a><a class="dropdown-item btn-support-chat" href="#!">Close Support</a></div>
</div>
</div>
<div class="card-body chat p-0">
<div class="d-flex flex-column-reverse scrollbar h-100 p-3">
<div class="text-end mt-6"><a class="mb-2 d-inline-flex align-items-center text-decoration-none text-body-emphasis bg-body-hover rounded-pill border border-primary py-2 ps-4 pe-3" href="#!">
<p class="mb-0 fw-semibold fs-9">I need help with something</p><span class="fa-solid fa-paper-plane text-primary fs-9 ms-3"></span>
</a><a class="mb-2 d-inline-flex align-items-center text-decoration-none text-body-emphasis bg-body-hover rounded-pill border border-primary py-2 ps-4 pe-3" href="#!">
<p class="mb-0 fw-semibold fs-9">I cant reorder a product I previously ordered</p><span class="fa-solid fa-paper-plane text-primary fs-9 ms-3"></span>
</a><a class="mb-2 d-inline-flex align-items-center text-decoration-none text-body-emphasis bg-body-hover rounded-pill border border-primary py-2 ps-4 pe-3" href="#!">
<p class="mb-0 fw-semibold fs-9">How do I place an order?</p><span class="fa-solid fa-paper-plane text-primary fs-9 ms-3"></span>
</a><a class="false d-inline-flex align-items-center text-decoration-none text-body-emphasis bg-body-hover rounded-pill border border-primary py-2 ps-4 pe-3" href="#!">
<p class="mb-0 fw-semibold fs-9">My payment method not working</p><span class="fa-solid fa-paper-plane text-primary fs-9 ms-3"></span>
</a>
</div>
<div class="text-center mt-auto">
<div class="avatar avatar-3xl status-online"><img class="rounded-circle border border-3 border-light-subtle" src="../../assets/img/team/30.webp" alt="" /></div>
<h5 class="mt-2 mb-3">Eric</h5>
<p class="text-center text-body-emphasis mb-0">Ask us anything well get back to you here or by email within 24 hours.</p>
</div>
</div>
</div>
<div class="card-footer d-flex align-items-center gap-2 border-top border-translucent ps-3 pe-4 py-3">
<div class="d-flex align-items-center flex-1 gap-3 border border-translucent rounded-pill px-4">
<input class="form-control outline-none border-0 flex-1 fs-9 px-0" type="text" placeholder="Write message" />
<label class="btn btn-link d-flex p-0 text-body-quaternary fs-9 border-0" for="supportChatPhotos"><span class="fa-solid fa-image"></span></label>
<input class="d-none" type="file" accept="image/*" id="supportChatPhotos" />
<label class="btn btn-link d-flex p-0 text-body-quaternary fs-9 border-0" for="supportChatAttachment"> <span class="fa-solid fa-paperclip"></span></label>
<input class="d-none" type="file" id="supportChatAttachment" />
</div>
<button class="btn p-0 border-0 send-btn"><span class="fa-solid fa-paper-plane fs-9"></span></button>
</div>
</div>
</div>
<button class="btn btn-support-chat p-0 border border-translucent"><span class="fs-8 btn-text text-primary text-nowrap">Chat demo</span><span class="ping-icon-wrapper mt-n4 ms-n6 mt-sm-0 ms-sm-2 position-absolute position-sm-relative"><span class="ping-icon-bg"></span><span class="fa-solid fa-circle ping-icon"></span></span><span class="fa-solid fa-headset text-primary fs-8 d-sm-none"></span><span class="fa-solid fa-chevron-down text-primary fs-7"></span></button>
</div>
</main>
{% else%}
{% comment %} <div class="button-row">
<button id="download-pdf" class="btn btn-primary">
<i class="fas fa-download"></i> {% trans 'Download Estimate' %}
</button>
<button id="accept" class="btn btn-success" data-bs-toggle="modal" data-bs-target="#acceptModal">
<i class="fas fa-check-circle"></i> {% trans 'Accept Estimate' %}
</button>
<button id="reject" class="btn btn-danger" data-bs-toggle="modal" data-bs-target="#rejectModal">
<i class="fas fa-times-circle"></i> {% trans 'Reject Estimate' %}
</button>
</div> {% endcomment %}
<div class="row p-2">
<div class="col-2">
<button class="btn btn-sm btn-danger w-100" onclick="window.history.back()">الرجوع&nbsp;/&nbsp;Back</button>
</div>
<div class="col-2">
<button class="btn btn-sm btn-primary w-100" id="download-pdf">تحميل&nbsp;/&nbsp;Download</button>
</div>
<div class="col-8"></div>
</div>
<div class="estimate-row" id="estimate-content">
<!-- Header -->
@ -220,11 +162,11 @@
<!-- Details -->
<div class="estimate-details">
{% comment %} <p><strong>{% trans "Estimate Number" %} :</strong> <span class="highlight">#{{estimate.estimate_number}}</span></p> {% endcomment %}
<p><strong>{% trans "Date" %} :</strong> {{estimate.date_in_review}}</p>
<p><strong>{% trans "Customer" %} :</strong> {{estimate.customer.customer_name}}</p>
<p><strong>{% trans "Email" %} :</strong> {{estimate.customer.email}}</p>
<p><strong>{% trans "Terms" %} :</strong> {{estimate.terms|title}}</p>
<p><strong>{{ _("Estimate Number") }} :</strong> <span class="highlight">#{{estimate.estimate_number}}</span></p>
<p><strong>{{ _("Date") }} :</strong> {{estimate.date_in_review}}</p>
<p><strong>{{ _("Customer") }} :</strong> {{estimate.customer.customer_name}}</p>
<p><strong>{{ _("Email") }} :</strong> {{estimate.customer.email}}</p>
<p><strong>{{ _("Terms") }} :</strong> {{estimate.terms|title}}</p>
</div>
@ -233,13 +175,13 @@
<table class="table table-bordered">
<thead>
<tr>
<th>{% trans "VIN" %}</th>
<th>{% trans "Make" %}</th>
<th>{% trans "Model" %}</th>
<th>{% trans "Year" %}</th>
<th class="text-center">{% trans "Quantity" %}</th>
<th class="text-center">{% trans "Unit Price" %}</th>
<th class="text-center">{% trans "Total" %}</th>
<th>{{ _("VIN") }}</th>
<th>{{ _("Make") }}</th>
<th>{{ _("Model") }}</th>
<th>{{ _("Year") }}</th>
<th class="text-center">{{ _("Quantity") }}</th>
<th class="text-center">{{ _("Unit Price") }}</th>
<th class="text-center">{{ _("Total") }}</th>
</tr>
</thead>
<tbody>
@ -248,10 +190,10 @@
<td>{{ car.vin }}</td>
<td>{{ car.make }}</td>
<td>{{ car.model }}</td>
<td>{{ car.year }}</td>
<td class="text-center">{{ car.quantity }}</td>
<td class="text-center">{{ car.unit_price }}</td>
<td class="highlight fw-semibold text-center">{{ car.total }}</td>
<td>{{ car.year }}</td>
<td class="text-center">{{ car.quantity }}</td>
<td class="text-center">{{ car.unit_price }}</td>
<td class="highlight fw-semibold text-center">{{ car.total }}</td>
</tr>
{% endfor %}
</tbody>
@ -260,8 +202,8 @@
<!-- Additional Charges (VAT and Services) -->
<div class="additional-charges">
<p><strong>{% trans "VAT" %} ({{vat}}%):</strong> <span class="highlight">{{data.vat}} {{ CURRENCY }}</span></p>
<p><strong>{% trans "Additional Services" %}:</strong>
<p><strong>{{ _("VAT") }} ({{vat}}%):</strong> <span class="highlight">{{data.vat}} <span class="currency">{{ CURRENCY }}</span></span></p>
<p><strong>{{ _("Additional Services") }} :</strong>
<br>
{% for service in data.additional_services %}
<span class="highlight">{{service.name}} - {{service.price}} {{ CURRENCY }}</span><br>
@ -271,7 +213,7 @@
<!-- Total -->
<div class="estimate-total">
<p><strong>{%trans "Total Amount" %}:</strong> <span class="highlight">{{data.grand_total}} {{ CURRENCY }}</span></p>
<p><strong>{{ _("Total Amount") }} :</strong> <span class="highlight">{{data.grand_total}} <span class="currency">{{ CURRENCY }}</span></span></p>
</div>
<!-- Footer Note -->
@ -308,15 +250,6 @@
html2pdf().from(element).set(options).save();
});
document.getElementById('confirmAccept').addEventListener('click', function () {
// Handle the accept action here
$('#acceptModal').modal('hide');
});
document.getElementById('confirmReject').addEventListener('click', function () {
// Handle the reject action here
$('#rejectModal').modal('hide');
});
</script>
</body>
</html>