Merge branch 'main' of http://10.10.1.120:3000/tenhal_admin/haikal
This commit is contained in:
commit
f8f33c0f58
1
.idea/car_inventory.iml
generated
1
.idea/car_inventory.iml
generated
@ -27,6 +27,7 @@
|
||||
<orderEntry type="library" name="tesseract.js" level="application" />
|
||||
<orderEntry type="library" name="line" level="application" />
|
||||
<orderEntry type="library" name="@turf/turf" level="application" />
|
||||
<orderEntry type="library" name="apexcharts" level="application" />
|
||||
</component>
|
||||
<component name="TemplatesService">
|
||||
<option name="TEMPLATE_CONFIGURATION" value="Django" />
|
||||
|
||||
2
.idea/jsLibraryMappings.xml
generated
2
.idea/jsLibraryMappings.xml
generated
@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="JavaScriptLibraryMappings">
|
||||
<file url="file://$PROJECT_DIR$" libraries="{@turf/turf, @zxing, bootstrap-icons, jquery, jquery-3.5.1, line, quagga, sweetalert2, tesseract.js}" />
|
||||
<file url="file://$PROJECT_DIR$" libraries="{@turf/turf, @zxing, apexcharts, bootstrap-icons, jquery, jquery-3.5.1, line, quagga, sweetalert2, tesseract.js}" />
|
||||
</component>
|
||||
</project>
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -75,10 +75,6 @@ from django.urls import reverse, reverse_lazy
|
||||
from django.contrib import messages
|
||||
from django.db.models import Sum, F, Count
|
||||
from django.db import transaction
|
||||
# from two_factor.utils import default_device
|
||||
|
||||
# from two_factor.views import OTPRequiredMixin
|
||||
|
||||
from .forms import VendorForm
|
||||
from .services import (
|
||||
decodevin,
|
||||
@ -155,7 +151,6 @@ def switch_language(request):
|
||||
return redirect("/")
|
||||
|
||||
|
||||
|
||||
def dealer_signup(request, *args, **kwargs):
|
||||
if request.method == "POST":
|
||||
data = json.loads(request.body)
|
||||
@ -235,11 +230,11 @@ class OTPView(View, LoginRequiredMixin):
|
||||
messages.error(request, _("Invalid OTP. Please try again."))
|
||||
return render(request, self.template_name)
|
||||
|
||||
def verify_otp(self, otp_code, user):
|
||||
device = default_device(user)
|
||||
if device and device.verify_token(otp_code):
|
||||
return True
|
||||
return False
|
||||
# def verify_otp(self, otp_code, user):
|
||||
# device = default_device(user)
|
||||
# if device and device.verify_token(otp_code):
|
||||
# return True
|
||||
# return False
|
||||
|
||||
|
||||
|
||||
@ -255,6 +250,7 @@ class HomeView(TemplateView):
|
||||
def get_context_data(self, **kwargs):
|
||||
context = super().get_context_data(**kwargs)
|
||||
dealer = get_user_type(self.request)
|
||||
|
||||
total_cars = models.Car.objects.filter(dealer=dealer).count()
|
||||
total_reservations = models.CarReservation.objects.filter(
|
||||
reserved_until__gte=timezone.now()
|
||||
|
||||
5
populate.py
Normal file
5
populate.py
Normal file
@ -0,0 +1,5 @@
|
||||
from datetime import datetime
|
||||
from zoneinfo import ZoneInfo
|
||||
|
||||
START_DTTM = datetime(year=2022, month=10, day=1, tzinfo=ZoneInfo('Asia/Riyadh'))
|
||||
|
||||
38
static/js/apexcharts.js
Normal file
38
static/js/apexcharts.js
Normal file
File diff suppressed because one or more lines are too long
@ -79,25 +79,13 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function getCookie(name) {
|
||||
let cookieValue = null;
|
||||
if (document.cookie && document.cookie !== '') {
|
||||
const cookies = document.cookie.split(';');
|
||||
for (let cookie of cookies) {
|
||||
cookie = cookie.trim();
|
||||
if (cookie.substring(0, name.length + 1) === (name + '=')) {
|
||||
cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return cookieValue;
|
||||
}
|
||||
|
||||
|
||||
const url = "{% url 'account_signup' %}";
|
||||
let submit_btn = document.getElementById('submit_btn');
|
||||
const csrfToken = getCookie('csrftoken');
|
||||
const csrftoken = getCookie('csrftoken');
|
||||
|
||||
submit_btn.addEventListener('click', async () => {
|
||||
const allFormData = getAllFormData();
|
||||
@ -108,7 +96,7 @@ const url = "{% url 'account_signup' %}";
|
||||
const response = await fetch(url, {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'X-CSRFToken': csrfToken,
|
||||
'X-CSRFToken': csrftoken,
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
body: JSON.stringify(allFormData),
|
||||
|
||||
@ -6,7 +6,6 @@
|
||||
data-bs-theme=""
|
||||
data-navigation-type="default"
|
||||
data-navbar-horizontal-shape="default">
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
@ -26,7 +25,7 @@
|
||||
<link rel="manifest" href="{% static 'images/favicons/manifest.json' %}">
|
||||
<meta name="msapplication-TileImage" content="{% static 'images/logos/logo-d.png' %}">
|
||||
<meta name="theme-color" content="#ffffff">
|
||||
<script src="https://cdn.jsdelivr.net/npm/apexcharts"></script>
|
||||
|
||||
|
||||
<script src="{% static 'vendors/simplebar/simplebar.min.js' %}"></script>
|
||||
<script src="{% static 'js/config.js' %}"></script>
|
||||
@ -48,70 +47,20 @@
|
||||
<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 %}
|
||||
<script src="{% static 'js/main.js' %}"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/apexcharts"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.7.1/jquery.min.js"
|
||||
integrity="sha512-v2CJ7UaYy4JwqLDIrZUI/4hqeoQieOmAZNXBeQyjo21dadnwR+8ZaIJVT8EE2iyI61OV8e6M8PP2/4hpQINQ/g=="
|
||||
crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
||||
|
||||
|
||||
|
||||
{% block customCSS %}
|
||||
{% endblock %}
|
||||
</head>
|
||||
<body>
|
||||
<main class="main" id="top">
|
||||
{% include 'header.html' %}
|
||||
<div class="content">
|
||||
{% block period_navigation %}{% endblock period_navigation %}
|
||||
{% block content %}{% endblock content%}
|
||||
{% block body %}{% endblock body%}
|
||||
{% include 'footer.html' %}
|
||||
</div>
|
||||
</main>
|
||||
{% block customJS %}
|
||||
<script src="{% static 'django_ledger/bundle/djetler.bundle.js' %}"></script>
|
||||
<script>
|
||||
{% if entity_slug %}
|
||||
let entitySlug = "{{ view.kwargs.entity_slug }}"
|
||||
{% endif %}
|
||||
|
||||
{% if from_date and to_date %}
|
||||
let fromDate = "{{ from_date | date:'Y-m-d' }}";
|
||||
let toDate = "{{ to_date | date:'Y-m-d' }}";
|
||||
{% endif %}
|
||||
|
||||
{% if date_navigation_url %}
|
||||
let dateNavigationUrl = "{{ date_navigation_url }}"
|
||||
let datePickers = document.querySelectorAll("[id^='djl-datepicker']")
|
||||
datePickers.forEach(dp => djLedger.getCalendar(dp.attributes.id.value, dateNavigationUrl))
|
||||
{% endif %}
|
||||
</script>
|
||||
|
||||
{% endblock %}
|
||||
|
||||
<!-- ===============================================-->
|
||||
<!-- JavaScripts-->
|
||||
<!-- ===============================================-->
|
||||
<script src="{% static 'vendors/popper/popper.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/bootstrap/bootstrap.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/anchorjs/anchor.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/is/is.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/fontawesome/all.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/lodash/lodash.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/list.js/list.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/feather-icons/feather.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/dayjs/dayjs.min.js' %}"></script>
|
||||
<script src="{% static 'js/phoenix.js' %}"></script>
|
||||
<script src="{% static 'vendors/echarts/echarts.min.js' %}"></script>
|
||||
<script src="{% static 'js/crm-analytics.js' %}"></script>
|
||||
<script src="{% static 'js/travel-agency-dashboard.js' %}"></script>
|
||||
<script src="{% static 'js/main.js' %}"></script>
|
||||
<script src="{% static 'vendors/mapbox-gl/mapbox-gl.js' %}"></script>
|
||||
<script src="https://unpkg.com/@turf/turf@6/turf.min.js"></script>
|
||||
<script src="https://unpkg.com/htmx.org@2.0.4"></script>
|
||||
<script src="{% static 'vendors/swiper/swiper-bundle.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/flatpickr/flatpickr.min.js' %}"></script>
|
||||
<script src="{% static 'django_ledger/bundle/djetler.bundle.js' %}"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/apexcharts"></script>
|
||||
<script>
|
||||
|
||||
{% if messages %}
|
||||
{% if messages %}
|
||||
{% for message in messages %}
|
||||
|
||||
const Toast = Swal.mixin({
|
||||
@ -137,6 +86,58 @@ function notify(tag,msg){
|
||||
titleText: msg
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<main class="main" id="top">
|
||||
{% include 'header.html' %}
|
||||
|
||||
|
||||
<div class="content">
|
||||
|
||||
{% block period_navigation %}
|
||||
|
||||
{% endblock period_navigation %}
|
||||
|
||||
{% block content %}
|
||||
{% endblock content%}
|
||||
{% block body %}
|
||||
{% endblock body%}
|
||||
|
||||
|
||||
{% include 'footer.html' %}
|
||||
</div>
|
||||
|
||||
</main>
|
||||
{% block customJS %}
|
||||
<script src="{% static 'django_ledger/bundle/djetler.bundle.js' %}"></script>
|
||||
|
||||
|
||||
{% endblock %}
|
||||
|
||||
<!-- ===============================================-->
|
||||
<!-- JavaScripts-->
|
||||
<!-- ===============================================-->
|
||||
<script src="{% static 'vendors/popper/popper.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/bootstrap/bootstrap.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/anchorjs/anchor.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/is/is.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/fontawesome/all.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/lodash/lodash.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/list.js/list.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/feather-icons/feather.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/dayjs/dayjs.min.js' %}"></script>
|
||||
<script src="{% static 'js/phoenix.js' %}"></script>
|
||||
<script src="{% static 'vendors/echarts/echarts.min.js' %}"></script>
|
||||
<script src="{% static 'js/crm-analytics.js' %}"></script>
|
||||
<script src="{% static 'js/travel-agency-dashboard.js' %}"></script>
|
||||
|
||||
<script src="{% static 'vendors/mapbox-gl/mapbox-gl.js' %}"></script>
|
||||
<script src="https://unpkg.com/@turf/turf@6/turf.min.js"></script>
|
||||
<script src="https://unpkg.com/htmx.org@2.0.4"></script>
|
||||
<script src="{% static 'vendors/swiper/swiper-bundle.min.js' %}"></script>
|
||||
<script src="{% static 'vendors/flatpickr/flatpickr.min.js' %}"></script>
|
||||
<script>
|
||||
|
||||
|
||||
|
||||
{% if entity_slug %}
|
||||
let entitySlug = "{{ view.kwargs.entity_slug }}"
|
||||
|
||||
@ -16,6 +16,7 @@
|
||||
<!-- Year Navigation -->
|
||||
<div class="text-center mb-3">
|
||||
<p class="mb-1">
|
||||
|
||||
<span class="fw-bold">Year: </span>
|
||||
<a href="{{ previous_year_url }}" class="text-decoration-none me-2">
|
||||
<span class="fas fa-chevron-left"> </span>
|
||||
@ -26,6 +27,11 @@
|
||||
<span class="fas fa-chevron-right"> </span>
|
||||
<span class="fas fa-chevron-right"> </span>
|
||||
</a>
|
||||
|
||||
<span class="fw-bold">{% trans 'Year' %}:</span>
|
||||
<a href="{{ previous_year_url }}" class="text-decoration-none me-2"><< {{ previous_year }}</a>
|
||||
<a href="{{ current_year_url }}" class="text-decoration-none me-2">{{ year }}</a>
|
||||
<a href="{{ next_year_url }}" class="text-decoration-none">{{ next_year }} >></a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
@ -72,5 +78,10 @@
|
||||
</div>
|
||||
|
||||
<!-- Date Picker -->
|
||||
|
||||
|
||||
<div class="text-center ">
|
||||
{% date_picker date_navigation_url %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -4,7 +4,9 @@
|
||||
{% load django_ledger %}
|
||||
|
||||
{% block content %}
|
||||
<main class="main" id="top">
|
||||
<style id="apexcharts-css">
|
||||
|
||||
</style>
|
||||
<div class="pb-6">
|
||||
<div class="row align-items-center justify-content-between g-3 mb-6">
|
||||
<div class="col-12 col-md-auto">
|
||||
@ -15,19 +17,19 @@
|
||||
<div class="row justify-content-between">
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-end-xxl-0 border-bottom-xxl-0 border-end border-bottom pb-4 pb-xxl-0 "><i class="fa-solid fa-landmark-dome fs-5 lh-1 text-primary"></i>
|
||||
<h1 class="fs-5 pt-3">{% currency_symbol %}{{ tx_digest.group_balance.GROUP_ASSETS | currency_format }}</h1>
|
||||
<p class="fs-9 mb-0">Assets</p>
|
||||
<p class="fs-9 mb-0">{{ _("Assets") }}</p>
|
||||
</div>
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-end-xxl-0 border-bottom-xxl-0 border-end-md border-bottom pb-4 pb-xxl-0"><i class="fa-solid fa-weight-hanging fs-5 lh-1 text-primary"></i>
|
||||
<h1 class="fs-5 pt-3">{% currency_symbol %}{{ tx_digest.group_balance.GROUP_LIABILITIES | currency_format }}</h1>
|
||||
<p class="fs-9 mb-0">Liabilities</p>
|
||||
<p class="fs-9 mb-0">{{ _("Liabilities") }}</p>
|
||||
</div>
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-bottom-xxl-0 border-bottom border-end border-end-md-0 pb-4 pb-xxl-0 pt-4 pt-md-0"><i class="fa-solid fa-scale-balanced fs-5 lh-1 text-primary"></i>
|
||||
<h1 class="fs-5 pt-3">{% currency_symbol %}{{ tx_digest.group_balance.GROUP_EQUITY | currency_format }}</h1>
|
||||
<p class="fs-9 mb-0">Equity</p>
|
||||
<p class="fs-9 mb-0">{{ _("Equity") }}</p>
|
||||
</div>
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-end-md border-end-xxl-0 border-bottom border-bottom-md-0 pb-4 pb-xxl-0 pt-4 pt-xxl-0"><i class="fa-solid fs-5 lh-1 text-success fa-money-bill"></i>
|
||||
<h1 class="fs-5 pt-3">{% currency_symbol %}{{ tx_digest.role_balance.ASSET_CA_CASH | currency_format }}</h1>
|
||||
<p class="fs-9 mb-0">Cash</p>
|
||||
<p class="fs-9 mb-0">{{ _("Cash") }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -39,15 +41,15 @@
|
||||
<div class="row justify-content-between">
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-end-xxl-0 border-bottom-xxl-0 border-end border-bottom pb-4 pb-xxl-0 "><i class="fa-solid fa-coins fs-5 lh-1 text-primary"></i>
|
||||
<h1 class="fs-5 pt-3">{% currency_symbol %}{{ tx_digest.group_balance.GROUP_INCOME | currency_format }}</h1>
|
||||
<p class="fs-9 mb-0">Revenue</p>
|
||||
<p class="fs-9 mb-0">{{ _("Revenue") }}</p>
|
||||
</div>
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-end-xxl-0 border-bottom-xxl-0 border-end-md border-bottom pb-4 pb-xxl-0"><i class="fa-solid fa-hand-holding-dollar fs-5 lh-1 text-danger"></i>
|
||||
<h1 class="fs-5 pt-3">{% currency_symbol %}{{ tx_digest.group_balance.GROUP_EXPENSES | reverse_sign | currency_format }}</h1>
|
||||
<p class="fs-9 mb-0">Expenses</p>
|
||||
<p class="fs-9 mb-0">{{ _("Expenses") }}</p>
|
||||
</div>
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-bottom-xxl-0 border-bottom border-end border-end-md-0 pb-4 pb-xxl-0 pt-4 pt-md-0"><i class="fa-solid fa-sack-dollar fs-5 lh-1 text-primary"></i>
|
||||
<h1 class="fs-5 pt-3">{% currency_symbol %}{{ tx_digest.group_balance.GROUP_EARNINGS | currency_format }}</h1>
|
||||
<p class="fs-9 mb-0">Earnings (Loss)</p>
|
||||
<p class="fs-9 mb-0">{{ _("Earnings (Loss)")}}</p>
|
||||
</div>
|
||||
<div class="col-6 col-md-4 col-xxl-2 text-center border-translucent border-start-xxl border-end-md border-end-xxl-0 border-bottom border-bottom-md-0 pb-4 pb-xxl-0 pt-4 pt-xxl-0"></div>
|
||||
</div>
|
||||
@ -56,8 +58,8 @@
|
||||
<div class="row gx-6">
|
||||
<div class="col-12 col-md-6 col-lg-12 col-xl-6 mb-5 mb-md-3 mb-lg-5 mb-xl-2 mb-xxl-3">
|
||||
<div class="scrollbar">
|
||||
<h3>Net Receivables</h3>
|
||||
<p class="text-body-tertiary">According to the sales data.</p>
|
||||
<h3>{{ _("Net Receivables")}}</h3>
|
||||
<p class="text-body-tertiary">{{ _("According to the sales data")}}.</p>
|
||||
<div id="net_receivable_chart" class="echart-doughnut-rounded-chart-example" style="min-height:320px"></div>
|
||||
</div>
|
||||
</div>
|
||||
@ -69,18 +71,16 @@
|
||||
<div class="d-flex flex-1 justify-content-center d-sm-block d-md-flex d-lg-block d-xl-flex d-xxl-block gap-3">
|
||||
|
||||
<div class="mb-4 me-6 me-sm-0 me-md-6 me-lg-0 me-xl-6 me-xxl-0">
|
||||
<h3 class="">Financial Analysis</h3>
|
||||
<h4>Solvency:</h4>
|
||||
<h5 class="progress-bar">Current
|
||||
Ratio: {{ tx_digest.ratios.current_ratio | currency_format }}</h5>
|
||||
<h3 class="">{{ _("Financial Analysis")}}</h3>
|
||||
<h4>{{ _("Solvency") }}:</h4>
|
||||
<h5 class="progress-bar">{{ _("Current Ratio")}}: {{ tx_digest.ratios.current_ratio | currency_format }}</h5>
|
||||
<div class="progress" style="height:12px">
|
||||
<progress
|
||||
class="progress-bar {{ tx_digest.ratios.current_ratio | fin_ratio_threshold_class:'current_ratio' }}"
|
||||
value="{{ tx_digest.ratios.current_ratio }}"
|
||||
max="{% fin_ratio_max_value ratio='current_ratio' %}">
|
||||
{{ tx_digest.ratios.current_ratio }}</progress></div>
|
||||
<h5 class="progress-bar">Quick
|
||||
Ratio: {{ tx_digest.ratios.quick_ratio | currency_format }} </h5>
|
||||
<h5 class="progress-bar">{{ _("Quick Ratio")}}: {{ tx_digest.ratios.quick_ratio | currency_format }} </h5>
|
||||
<div class="progress" style="height:12px">
|
||||
<progress
|
||||
class="progress-bar {{ tx_digest.ratios.quick_ratio | fin_ratio_threshold_class:'quick_ratio' }}"
|
||||
@ -88,9 +88,8 @@
|
||||
max="{% fin_ratio_max_value ratio='quick_ratio' %}">
|
||||
{{ tx_digest.ratios.current_ratio }}</progress></div>
|
||||
|
||||
<h4>Leverage:</h4>
|
||||
<h5 class="progress-bar">Debt to
|
||||
Equity: {{ tx_digest.ratios.debt_to_equity | currency_format }} </h5>
|
||||
<h4>{{ _("Leverage") }}:</h4>
|
||||
<h5 class="progress-bar">{{ _("Debt to Equity")}}: {{ tx_digest.ratios.debt_to_equity | currency_format }} </h5>
|
||||
<div class="progress" style="height:12px">
|
||||
<progress
|
||||
class="progress-bar {{ tx_digest.ratios.debt_to_equity | fin_ratio_threshold_class:'debt_to_equity' }}"
|
||||
@ -99,9 +98,8 @@
|
||||
{{ tx_digest.ratios.debt_to_equity }}</progress></div>
|
||||
|
||||
|
||||
<h4>Profitability:</h4>
|
||||
<h5 class="progress-bar">Return on
|
||||
Equity: {{ tx_digest.ratios.return_on_equity | percentage }} </h5>
|
||||
<h4>{{ _("Profitability") }}:</h4>
|
||||
<h5 class="progress-bar">{{ _("Return on Equity")}}: {{ tx_digest.ratios.return_on_equity | percentage }} </h5>
|
||||
<div class="progress" style="height:12px">
|
||||
<progress
|
||||
class="progress-bar bg-info {{ tx_digest.ratios.quick_ratio | fin_ratio_threshold_class:'quick_ratio' }}"
|
||||
@ -109,24 +107,21 @@
|
||||
max="{% fin_ratio_max_value ratio='return_on_equity' %}">
|
||||
{{ tx_digest.ratios.return_on_equity }}</progress></div>
|
||||
|
||||
<h5 class="progress-bar">Return on
|
||||
Assets: {{ tx_digest.ratios.return_on_assets | percentage }} </h5>
|
||||
<h5 class="progress-bar">{{ _("Return on Assets")}}: {{ tx_digest.ratios.return_on_assets | percentage }} </h5>
|
||||
<div class="progress" style="height:12px">
|
||||
<progress
|
||||
class="progress-bar {{ tx_digest.ratios.return_on_assets | fin_ratio_threshold_class:'return_on_assets' }}"
|
||||
value="{{ tx_digest.ratios.return_on_assets }}"
|
||||
max="{% fin_ratio_max_value ratio='return_on_assets' %}">{{ tx_digest.ratios.return_on_assets }}</progress></div>
|
||||
|
||||
<h5 class="progress-bar">Net Profit
|
||||
Margin: {{ tx_digest.ratios.net_profit_margin | percentage }} </h5>
|
||||
<h5 class="progress-bar">{{ _("Net Profit Margin")}}: {{ tx_digest.ratios.net_profit_margin | percentage }} </h5>
|
||||
<div class="progress" style="height:12px">
|
||||
<progress
|
||||
class="progress-bar {{ tx_digest.ratios.net_profit_margin | fin_ratio_threshold_class:'net_profit_margin' }}"
|
||||
value="{{ tx_digest.ratios.net_profit_margin }}"
|
||||
max="{% fin_ratio_max_value ratio='net_profit_margin' %}">{{ tx_digest.ratios.net_profit_margin }}</progress></div>
|
||||
|
||||
<h5 class="progress-bar">Gross Profit
|
||||
Margin: {{ tx_digest.ratios.gross_profit_margin | percentage }} </h5>
|
||||
<h5 class="progress-bar">{{ _("Gross Profit Margin")}}: {{ tx_digest.ratios.gross_profit_margin | percentage }} </h5>
|
||||
<div class="progress" style="height:12px">
|
||||
<progress
|
||||
class="progress-bar {{ tx_digest.ratios.gross_profit_margin | fin_ratio_threshold_class:'gross_profit_margin' }}"
|
||||
@ -143,17 +138,17 @@
|
||||
<div class="col-12 col-md-12">
|
||||
<div class="row justify-content-between mb-4">
|
||||
<div class="col-12">
|
||||
<h3></h3>
|
||||
<h3 id="dataContainer"></h3>
|
||||
<div class="col-6 col-md-3">
|
||||
<div class="">
|
||||
<label class="form-label" for="datepicker">Start Date</label>
|
||||
<input id="startDate" class="form-control datetimepicker flatpickr-input" pattern="[0-9]{4}-[0-9]{2}-[0-9]{2}" type="date" placeholder="dd/mm/yyyy" data-options="{"disableMobile":true,"dateFormat":"Y-m-d"}" readonly="readonly">
|
||||
<label class="form-label" for="datepicker">{{ _("Start Date")}}</label>
|
||||
<input id="startDate" class="form-control datetimepicker flatpickr-input" pattern="[0-9]{4}-[0-9]{2}-[0-9]{2}" type="date" placeholder="dd/mm/yyyy" data-options="{'disableMobile':true,'dateFormat';:'Y-m-d'}" readonly="readonly">
|
||||
</div>
|
||||
<div>
|
||||
<label class="form-label" for="datepicker">End Date</label>
|
||||
<input id="endDate" class="form-control datetimepicker flatpickr-input" pattern="[0-9]{4}-[0-9]{2}-[0-9]{2}" type="date" placeholder="dd/mm/yyyy" data-options="{"disableMobile":true,"dateFormat":"Y-m-d"}" readonly="readonly">
|
||||
<label class="form-label" for="datepicker">{{ _("End Date")}}</label>
|
||||
<input id="endDate" class="form-control datetimepicker flatpickr-input" pattern="[0-9]{4}-[0-9]{2}-[0-9]{2}" type="date" placeholder="dd/mm/yyyy" data-options="{'disableMobile':true,'dateFormat':'Y-m-d'}" readonly="readonly">
|
||||
</div>
|
||||
<button id="apply_filter" class="btn btn-primary mt-3" type="submit">Apply</button>
|
||||
<button id="apply_filter" class="btn btn-primary mt-3" type="submit">{{ _("Apply") }}</button>
|
||||
</div>
|
||||
|
||||
<div id="net_receivable_chart1" class="echart-doughnut-rounded-chart-example col-12" style="min-height:450px"></div>
|
||||
@ -165,217 +160,14 @@
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<footer class="footer position-absolute">
|
||||
<div class="row g-0 justify-content-between align-items-center h-100">
|
||||
<div class="col-12 col-sm-auto text-center">
|
||||
<p class="mb-0 mt-2 mt-sm-0 text-body">Thank you for creating with Phoenix<span class="d-none d-sm-inline-block"></span><span class="d-none d-sm-inline-block mx-1">|</span><br class="d-sm-none" />2024 ©<a class="mx-1" href="https://themewagon.com">Themewagon</a></p>
|
||||
</div>
|
||||
<div class="col-12 col-sm-auto text-center">
|
||||
<p class="mb-0 text-body-tertiary text-opacity-85">v1.20.1</p>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
</div>
|
||||
<div class="modal fade" id="searchBoxModal" tabindex="-1" aria-hidden="true" data-bs-backdrop="true" data-phoenix-modal="data-phoenix-modal" style="--phoenix-backdrop-opacity: 1;">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content mt-15 rounded-pill">
|
||||
<div class="modal-body p-0">
|
||||
<div class="search-box navbar-top-search-box" style="width: auto;">
|
||||
<form class="position-relative" data-bs-toggle="search" data-bs-display="static">
|
||||
<input class="form-control search-input fuzzy-search rounded-pill form-control-lg" type="search" placeholder="Search..." aria-label="Search" />
|
||||
<span class="fas fa-search search-box-icon"></span>
|
||||
|
||||
</form>
|
||||
<div class="btn-close position-absolute end-0 top-50 translate-middle cursor-pointer shadow-none" data-bs-dismiss="search">
|
||||
<button class="btn btn-link p-0" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="dropdown-menu border start-0 py-0 overflow-hidden w-100">
|
||||
<div class="scrollbar-overlay" style="max-height: 30rem;">
|
||||
<div class="list pb-3">
|
||||
<h6 class="dropdown-header text-body-highlight fs-10 py-2">24 <span class="text-body-quaternary">results</span></h6>
|
||||
<hr class="my-0" />
|
||||
<h6 class="dropdown-header text-body-highlight fs-9 border-bottom border-translucent py-2 lh-sm">Recently Searched </h6>
|
||||
<div class="py-2"><a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"><span class="fa-solid fa-clock-rotate-left" data-fa-transform="shrink-2"></span> Store Macbook</div>
|
||||
</div>
|
||||
</a>
|
||||
<a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"> <span class="fa-solid fa-clock-rotate-left" data-fa-transform="shrink-2"></span> MacBook Air - 13″</div>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<hr class="my-0" />
|
||||
<h6 class="dropdown-header text-body-highlight fs-9 border-bottom border-translucent py-2 lh-sm">Products</h6>
|
||||
<div class="py-2"><a class="dropdown-item py-2 d-flex align-items-center" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="file-thumbnail me-2"><img class="h-100 w-100 object-fit-cover rounded-3" src="../../assets/img/products/60x60/3.png" alt="" /></div>
|
||||
<div class="flex-1">
|
||||
<h6 class="mb-0 text-body-highlight title">MacBook Air - 13″</h6>
|
||||
<p class="fs-10 mb-0 d-flex text-body-tertiary"><span class="fw-medium text-body-tertiary text-opactity-85">8GB Memory - 1.6GHz - 128GB Storage</span></p>
|
||||
</div>
|
||||
</a>
|
||||
<a class="dropdown-item py-2 d-flex align-items-center" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="file-thumbnail me-2"><img class="img-fluid" src="../../assets/img/products/60x60/3.png" alt="" /></div>
|
||||
<div class="flex-1">
|
||||
<h6 class="mb-0 text-body-highlight title">MacBook Pro - 13″</h6>
|
||||
<p class="fs-10 mb-0 d-flex text-body-tertiary"><span class="fw-medium text-body-tertiary text-opactity-85">30 Sep at 12:30 PM</span></p>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
</div>
|
||||
<hr class="my-0" />
|
||||
<h6 class="dropdown-header text-body-highlight fs-9 border-bottom border-translucent py-2 lh-sm">Quick Links</h6>
|
||||
<div class="py-2"><a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"><span class="fa-solid fa-link text-body" data-fa-transform="shrink-2"></span> Support MacBook House</div>
|
||||
</div>
|
||||
</a>
|
||||
<a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"> <span class="fa-solid fa-link text-body" data-fa-transform="shrink-2"></span> Store MacBook″</div>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<hr class="my-0" />
|
||||
<h6 class="dropdown-header text-body-highlight fs-9 border-bottom border-translucent py-2 lh-sm">Files</h6>
|
||||
<div class="py-2"><a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"><span class="fa-solid fa-file-zipper text-body" data-fa-transform="shrink-2"></span> Library MacBook folder.rar</div>
|
||||
</div>
|
||||
</a>
|
||||
<a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"> <span class="fa-solid fa-file-lines text-body" data-fa-transform="shrink-2"></span> Feature MacBook extensions.txt</div>
|
||||
</div>
|
||||
</a>
|
||||
<a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"> <span class="fa-solid fa-image text-body" data-fa-transform="shrink-2"></span> MacBook Pro_13.jpg</div>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
</div>
|
||||
<hr class="my-0" />
|
||||
<h6 class="dropdown-header text-body-highlight fs-9 border-bottom border-translucent py-2 lh-sm">Members</h6>
|
||||
<div class="py-2"><a class="dropdown-item py-2 d-flex align-items-center" href="../../pages/members.html">
|
||||
<div class="avatar avatar-l status-online me-2 text-body">
|
||||
<img class="rounded-circle " src="../../assets/img/team/40x40/10.webp" alt="" />
|
||||
|
||||
</div>
|
||||
<div class="flex-1">
|
||||
<h6 class="mb-0 text-body-highlight title">Carry Anna</h6>
|
||||
<p class="fs-10 mb-0 d-flex text-body-tertiary">anna@technext.it</p>
|
||||
</div>
|
||||
</a>
|
||||
<a class="dropdown-item py-2 d-flex align-items-center" href="../../pages/members.html">
|
||||
<div class="avatar avatar-l me-2 text-body">
|
||||
<img class="rounded-circle " src="../../assets/img/team/40x40/12.webp" alt="" />
|
||||
|
||||
</div>
|
||||
<div class="flex-1">
|
||||
<h6 class="mb-0 text-body-highlight title">John Smith</h6>
|
||||
<p class="fs-10 mb-0 d-flex text-body-tertiary">smith@technext.it</p>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
</div>
|
||||
<hr class="my-0" />
|
||||
<h6 class="dropdown-header text-body-highlight fs-9 border-bottom border-translucent py-2 lh-sm">Related Searches</h6>
|
||||
<div class="py-2"><a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"><span class="fa-brands fa-firefox-browser text-body" data-fa-transform="shrink-2"></span> Search in the Web MacBook</div>
|
||||
</div>
|
||||
</a>
|
||||
<a class="dropdown-item" href="../../apps/e-commerce/landing/product-details.html">
|
||||
<div class="d-flex align-items-center">
|
||||
|
||||
<div class="fw-normal text-body-highlight title"> <span class="fa-brands fa-chrome text-body" data-fa-transform="shrink-2"></span> Store MacBook″</div>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="text-center">
|
||||
<p class="fallback fw-bold fs-7 d-none">No Result Found.</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</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-container">
|
||||
<div class="container-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 can’t 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 – we’ll 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>
|
||||
</main>
|
||||
{% endblock %}
|
||||
|
||||
{% block customJS %}
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/echarts/5.6.0/echarts.min.js" integrity="sha512-XSmbX3mhrD2ix5fXPTRQb2FwK22sRMVQTpBP2ac8hX7Dh/605hA2QDegVWiAvZPiXIxOV0CbkmUjGionDpbCmw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
||||
<script type="text/javascript">
|
||||
<script type="text/javascript">
|
||||
let myChart;
|
||||
let myChart1;
|
||||
|
||||
@ -463,7 +255,8 @@
|
||||
|
||||
async function get_data(){
|
||||
const response = await fetch("{% url 'entity-json-net-receivables' request.user.dealer.entity.slug %}");
|
||||
data = await response.json();
|
||||
data = await response.json();
|
||||
console.log(data);
|
||||
const keys = Object.keys(data.results.net_receivable_data);
|
||||
const labels = keys;
|
||||
const values = keys.map(key => data.results.net_receivable_data[key]);
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
{% extends 'base.html' %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block body %}
|
||||
{% block content %}
|
||||
|
||||
<!-- Account Details Section -->
|
||||
<div class="row my-3">
|
||||
|
||||
@ -147,9 +147,22 @@
|
||||
<div class="card shadow-sm">
|
||||
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">{{plan.name }}</h5>
|
||||
<p class="card-text">{{ plan.description }}</p>
|
||||
<p class="h4">{{ plan.price }}</p>
|
||||
<h5 class="card-title fw-bold">{{plan.name }}</h5>
|
||||
<p class="card-text fs-9">{{ plan.description }}</p>
|
||||
{% for plan_pricing in plan.planpricing_set.all %}
|
||||
{% if plan_pricing.visible %}
|
||||
<li class="mb-2">
|
||||
{% if plan_pricing.pricing.url %}<a href="{{ plan_pricing.pricing.url }}" class="info_link pricing text-decoration-none">{% endif %}
|
||||
<span class="plan_pricing_name fw-bold">{{ plan_pricing.pricing.name }}</span>
|
||||
<small class="plan_pricing_period d-block text-muted">({{ plan_pricing.pricing.period }} {% trans "days" %})</small>
|
||||
{% if plan_pricing.pricing.url %}</a>{% endif %}
|
||||
<span class="plan_pricing_price d-block font-weight-bold">{{ plan_pricing.price }} {{ CURRENCY }}</span>
|
||||
{% if plan_pricing.plan == userplan.plan or userplan.is_expired or userplan.plan.is_free %}
|
||||
<a href="{% url 'create_order_plan' pk=plan_pricing.pk %}" class="buy btn btn-sm btn-phoenix-success">{% trans "Buy" %}</a>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
<a href="{% url 'account_signup' %}" class="btn btn-primary mt-3">{% trans 'Get Started' %}</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user