diff --git a/.DS_Store b/.DS_Store index 8640cae4..848cd14e 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/api/migrations/0001_initial.py b/api/migrations/0001_initial.py index c6f663da..e24aeb44 100644 --- a/api/migrations/0001_initial.py +++ b/api/migrations/0001_initial.py @@ -1,4 +1,4 @@ -# Generated by Django 5.1.5 on 2025-01-30 11:28 +# Generated by Django 5.1.7 on 2025-05-04 16:07 from django.db import migrations, models diff --git a/generate.py b/generate.py index f9cc4445..b06c6c2d 100644 --- a/generate.py +++ b/generate.py @@ -31,71 +31,7 @@ def run(): "LGJE1EE0XSM333551", "LGJE1EE02SM333561", "LGJE1EE0XSM333565", - "LGJE1EE01SM333549", - "LGJE1EE06SM333563", - "LGJE1EE04SM333562", - "LGJE1EE08SM333564", - "LFB1E6078P1Y01338", - "LGJE5EE02PM046815", - "LFB1E6074P1Y01742", - "LGJE5EE07PM132850", - "LGJE1EE08SM311094", - "LFPH4ACP4P2A00123", - "LFB1E6075R1Y00117", - "ZAMPP56F0J1282425", - "LGJE1EE06RM292314", - "LGJE1EE00NM013594", - "LFB1E6075M1Y00272", - "LFB1E6670P1Y00224", - "LFB1E6079N1Y00275", - "LGJE3FE00MM804819", - "LGJE3FE0XMM804844", - "LGJE1EE01RM200767", - "LGJE1EE08RM200703", - "ZAMXS57F7L1341373", - "LGJE5EE06SM330781", - "LFB1E6077P1Y02643", - "LFB1E6074M1Y00151", - "LGJE1EE07RM292323", - "LGJE1EE01RM200171", - "LGJE1EE04SM311545", - "LGJE1EE04RM292859", - "LGJE1EE02RM292861", - "LFB1E607XP1Y01454", - "LFB1E6073P1Y00081", - "LGJE1EE03PM129391", - "LGJE1EE03RM200639", - "LGJE1EE02PM128393", - "LGJE1EE03NM964436", - "LGJE1EE06RM211599", - "LGJE1EE06NM014104", - "LGJE1EE05NM014272", - "LGJE5EE06SM331641", - "LGJE1EE09NM013528", - "LGJE5EE0XPM048196", - "LGJE1EE01RM212935", - "LGJE1EE05RM200433", - "LGJE1EE05SM311909", - "LGJE5EE02SM346914", - "LGJE1EE08SM306753", - "LGJE1EE02SM312001", - "LFPH4ACP6R2A02586", - "LGJE1EE00PM048445", - "LGJE1EE02SM311902", - "LGJE1EE03SM312573", - "LGJE1EE00SM306813", - "LFB1E6674N1Y00577", - "LGJE1EE00SM306875", - "LGJE1EE04SM306863", - "LFB1E6079P1Y00389", - "LGJE1EE04SM311562", - "LGJE1EE01SM312006", - "LGJE1EE08SM312486", - "LFB1E6676P1Y00941", - "LFPH4ACP1M1B00116", - "LGJE1EE02SM312564", - "LFPH4BCPXS2L00051", - "LGJE1EE06SM306864", + ] for vin in vin_list: try: diff --git a/haikalbot/migrations/0001_initial.py b/haikalbot/migrations/0001_initial.py index 33a3c349..a801e7ea 100644 --- a/haikalbot/migrations/0001_initial.py +++ b/haikalbot/migrations/0001_initial.py @@ -1,6 +1,5 @@ -# Generated by Django 5.1.7 on 2025-04-28 12:45 +# Generated by Django 5.1.7 on 2025-05-04 16:07 -import django.db.models.deletion from django.db import migrations, models @@ -9,7 +8,6 @@ class Migration(migrations.Migration): initial = True dependencies = [ - ('inventory', '0006_alter_email_object_id_alter_notes_object_id'), ] operations = [ @@ -20,7 +18,6 @@ class Migration(migrations.Migration): ('user_message', models.TextField()), ('chatbot_response', models.TextField()), ('timestamp', models.DateTimeField(auto_now_add=True)), - ('dealer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='chatlogs', to='inventory.dealer')), ], ), ] diff --git a/haikalbot/migrations/0002_initial.py b/haikalbot/migrations/0002_initial.py new file mode 100644 index 00000000..67dffe26 --- /dev/null +++ b/haikalbot/migrations/0002_initial.py @@ -0,0 +1,22 @@ +# Generated by Django 5.1.7 on 2025-05-04 16:07 + +import django.db.models.deletion +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('haikalbot', '0001_initial'), + ('inventory', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='chatlog', + name='dealer', + field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='chatlogs', to='inventory.dealer'), + ), + ] diff --git a/inventory/migrations/0001_initial.py b/inventory/migrations/0001_initial.py index 97404722..7d9299f2 100644 --- a/inventory/migrations/0001_initial.py +++ b/inventory/migrations/0001_initial.py @@ -1,4 +1,4 @@ -# Generated by Django 5.1.7 on 2025-05-04 10:42 +# Generated by Django 5.1.7 on 2025-05-04 16:07 import datetime import django.core.validators @@ -17,11 +17,17 @@ class Migration(migrations.Migration): initial = True dependencies = [ - ('appointment', '0001_initial'), + ('appointment', '0002_alter_workinghours_options'), ('auth', '0012_alter_user_first_name_max_length'), ('contenttypes', '0002_remove_content_type_name'), - ('django_ledger', '0021_alter_bankaccountmodel_account_model_and_more'), migrations.swappable_dependency(settings.AUTH_USER_MODEL), + migrations.swappable_dependency(settings.DJANGO_LEDGER_ACCOUNT_MODEL), + migrations.swappable_dependency(settings.DJANGO_LEDGER_CUSTOMER_MODEL), + migrations.swappable_dependency(settings.DJANGO_LEDGER_ENTITY_MODEL), + migrations.swappable_dependency(settings.DJANGO_LEDGER_ESTIMATE_MODEL), + migrations.swappable_dependency(settings.DJANGO_LEDGER_INVOICE_MODEL), + migrations.swappable_dependency(settings.DJANGO_LEDGER_ITEM_MODEL), + migrations.swappable_dependency(settings.DJANGO_LEDGER_VENDOR_MODEL), ] operations = [ @@ -114,7 +120,7 @@ class Migration(migrations.Migration): ('price', models.DecimalField(decimal_places=2, max_digits=14, verbose_name='Price')), ('taxable', models.BooleanField(default=False, verbose_name='taxable')), ('uom', models.CharField(choices=[('EA', 'Each'), ('PR', 'Pair'), ('SET', 'Set'), ('GAL', 'Gallon'), ('L', 'Liter'), ('M', 'Meter'), ('KG', 'Kilogram'), ('HR', 'Hour'), ('BX', 'Box'), ('RL', 'Roll'), ('PKG', 'Package'), ('DZ', 'Dozen'), ('SQ_M', 'Square Meter'), ('PC', 'Piece'), ('BDL', 'Bundle')], max_length=10, verbose_name='Unit of Measurement')), - ('item', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='django_ledger.itemmodel', verbose_name='Item')), + ('item', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.DJANGO_LEDGER_ITEM_MODEL, verbose_name='Item')), ], options={ 'verbose_name': 'Additional Services', @@ -134,7 +140,7 @@ class Migration(migrations.Migration): ('mileage', models.IntegerField(blank=True, null=True, verbose_name='Mileage')), ('receiving_date', models.DateTimeField(verbose_name='Receiving Date')), ('hash', models.CharField(blank=True, max_length=64, null=True, verbose_name='Hash')), - ('vendor', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, related_name='cars', to='django_ledger.vendormodel', verbose_name='Vendor')), + ('vendor', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, related_name='cars', to=settings.DJANGO_LEDGER_VENDOR_MODEL, verbose_name='Vendor')), ('id_car_make', models.ForeignKey(blank=True, db_column='id_car_make', null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='inventory.carmake', verbose_name='Make')), ], options={ @@ -316,7 +322,7 @@ class Migration(migrations.Migration): ('logo', models.ImageField(blank=True, null=True, upload_to='logos/users', verbose_name='Logo')), ('joined_at', models.DateTimeField(auto_now_add=True, verbose_name='Joined At')), ('updated_at', models.DateTimeField(auto_now=True, verbose_name='Updated At')), - ('entity', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='django_ledger.entitymodel')), + ('entity', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to=settings.DJANGO_LEDGER_ENTITY_MODEL)), ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='dealer', to=settings.AUTH_USER_MODEL)), ], options={ @@ -431,13 +437,13 @@ class Migration(migrations.Migration): fields=[ ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('additional_info', models.JSONField(blank=True, default=dict, null=True)), - ('bill_cash_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='bill_cash', to='django_ledger.accountmodel')), - ('bill_prepaid_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='bill_prepaid', to='django_ledger.accountmodel')), - ('bill_unearned_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='bill_unearned', to='django_ledger.accountmodel')), + ('bill_cash_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='bill_cash', to=settings.DJANGO_LEDGER_ACCOUNT_MODEL)), + ('bill_prepaid_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='bill_prepaid', to=settings.DJANGO_LEDGER_ACCOUNT_MODEL)), + ('bill_unearned_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='bill_unearned', to=settings.DJANGO_LEDGER_ACCOUNT_MODEL)), ('dealer', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='settings', to='inventory.dealer')), - ('invoice_cash_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='invoice_cash', to='django_ledger.accountmodel')), - ('invoice_prepaid_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='invoice_prepaid', to='django_ledger.accountmodel')), - ('invoice_unearned_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='invoice_unearned', to='django_ledger.accountmodel')), + ('invoice_cash_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='invoice_cash', to=settings.DJANGO_LEDGER_ACCOUNT_MODEL)), + ('invoice_prepaid_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='invoice_prepaid', to=settings.DJANGO_LEDGER_ACCOUNT_MODEL)), + ('invoice_unearned_account', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='invoice_unearned', to=settings.DJANGO_LEDGER_ACCOUNT_MODEL)), ], ), migrations.CreateModel( @@ -479,7 +485,7 @@ class Migration(migrations.Migration): ('status', models.CharField(choices=[('new', 'New'), ('pending', 'Pending'), ('in_progress', 'In Progress'), ('qualified', 'Qualified'), ('contacted', 'Contacted'), ('converted', 'Converted'), ('canceled', 'Canceled')], db_index=True, default='new', max_length=50, verbose_name='Status')), ('created', models.DateTimeField(auto_now_add=True, db_index=True, verbose_name='Created')), ('updated', models.DateTimeField(auto_now=True, verbose_name='Updated')), - ('customer', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='leads', to='django_ledger.customermodel')), + ('customer', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='leads', to=settings.DJANGO_LEDGER_CUSTOMER_MODEL)), ('dealer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='leads', to='inventory.dealer')), ('id_car_make', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='inventory.carmake', verbose_name='Make')), ('id_car_model', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='inventory.carmodel', verbose_name='Model')), @@ -582,8 +588,8 @@ class Migration(migrations.Migration): ('comments', models.TextField(blank=True, null=True)), ('formatted_order_id', models.CharField(editable=False, max_length=10, unique=True)), ('created', models.DateTimeField(auto_now_add=True)), - ('estimate', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sale_orders', to='django_ledger.estimatemodel', verbose_name='Estimate')), - ('invoice', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='sale_orders', to='django_ledger.invoicemodel', verbose_name='Invoice')), + ('estimate', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sale_orders', to=settings.DJANGO_LEDGER_ESTIMATE_MODEL, verbose_name='Estimate')), + ('invoice', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='sale_orders', to=settings.DJANGO_LEDGER_INVOICE_MODEL, verbose_name='Invoice')), ], options={ 'ordering': ['-created'], @@ -601,7 +607,7 @@ class Migration(migrations.Migration): ('status', models.CharField(choices=[('Scheduled', 'Scheduled'), ('Completed', 'Completed'), ('Canceled', 'Canceled')], default='Scheduled', max_length=200)), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), - ('customer', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='schedules', to='django_ledger.customermodel')), + ('customer', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='schedules', to=settings.DJANGO_LEDGER_CUSTOMER_MODEL)), ('lead', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='schedules', to='inventory.lead')), ('scheduled_by', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], @@ -644,9 +650,9 @@ class Migration(migrations.Migration): ('updated', models.DateTimeField(auto_now=True, verbose_name='Updated')), ('closed', models.BooleanField(default=False, verbose_name='Closed')), ('car', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='inventory.car', verbose_name='Car')), - ('customer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='opportunities', to='django_ledger.customermodel')), + ('customer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='opportunities', to=settings.DJANGO_LEDGER_CUSTOMER_MODEL)), ('dealer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='opportunities', to='inventory.dealer')), - ('estimate', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='opportunity', to='django_ledger.estimatemodel')), + ('estimate', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='opportunity', to=settings.DJANGO_LEDGER_ESTIMATE_MODEL)), ('lead', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='opportunity', to='inventory.lead')), ('staff', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='owner', to='inventory.staff', verbose_name='Owner')), ], diff --git a/inventory/models.py b/inventory/models.py index 3f7eb340..2b730e92 100644 --- a/inventory/models.py +++ b/inventory/models.py @@ -935,17 +935,6 @@ class Dealer(models.Model, LocalizedNameMixin): if staff_count >= quota: return True return False - # - # @property - # def get_plan(self): - # active_plan = self.get_active_plan - # if active_plan: - # subscription_plan = SubscriptionPlan.objects.filter( - # pk=active_plan.pk - # ).first() - # if subscription_plan: - # return subscription_plan - # return None class Meta: verbose_name = _("Dealer") @@ -971,17 +960,6 @@ class Dealer(models.Model, LocalizedNameMixin): # return self.parent_dealer if self.parent_dealer else self -class DealersMake(models.Model): - dealer = models.ForeignKey(Dealer, on_delete=models.CASCADE, related_name="dealer_makes") - car_make = models.ForeignKey(CarMake, on_delete=models.CASCADE, related_name="car_dealers") - added_at = models.DateTimeField(auto_now_add=True) - - class Meta: - unique_together = ("dealer", "car_make") # Prevents duplicate entries - - def __str__(self): - return f"{self.dealer.name} - {self.car_make.name}" - ############################## # Additional staff types for later diff --git a/inventory/views.py b/inventory/views.py index fe6b9528..25d538ef 100644 --- a/inventory/views.py +++ b/inventory/views.py @@ -7649,7 +7649,7 @@ def ledger_unpost_all_journals(request, entity_slug, pk): def pricing_page(request): plan_list = PlanPricing.objects.all() form = forms.PaymentPlanForm() - return render(request, "pricing_page.html", {"plan_list": plan_list, "CURRENCY": "$","form":form}) + return render(request, "pricing_page.html", {"plan_list": plan_list, "form":form}) # @require_POST def submit_plan(request): @@ -7661,7 +7661,7 @@ def submit_plan(request): plan=pp.plan, pricing=pp.pricing, amount=pp.price, - currency="SAR", + currency=settings.DEFAULT_CURRENCY, tax=15, status=AbstractOrder.STATUS.NEW ) @@ -7669,20 +7669,21 @@ def submit_plan(request): return redirect(transaction_url) def payment_callback(request): + dealer = get_user_type(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=request.user,status=AbstractOrder.STATUS.NEW).first() + order = Order.objects.filter(user=dealer,status=AbstractOrder.STATUS.NEW).first() if payment_status == "paid": billing_info,created = BillingInfo.objects.get_or_create( - user=request.user, - tax_number='123456789', - name='', - street='', - zipcode='12345', - city='Riyadh', - country='KSA', + user=dealer.user, + tax_number=dealer.vrn, + name=dealer.arabic_name, + street=dealer.entity.address, + zipcode=dealer.entity.zip_code, + city=dealer.entity.city, + country=dealer.entity.country, ) if created: userplan =UserPlan.objects.create( diff --git a/static/images/.DS_Store b/static/images/.DS_Store index cd0ed73a..962d4c37 100644 Binary files a/static/images/.DS_Store and b/static/images/.DS_Store differ diff --git a/static/images/logos/users/marwan-company_bpjODUu.png b/static/images/logos/users/marwan-company_bpjODUu.png new file mode 100644 index 00000000..b8addbe8 Binary files /dev/null and b/static/images/logos/users/marwan-company_bpjODUu.png differ diff --git a/templates/plans/invoices/layout.html b/templates/plans/invoices/layout.html index 0e370d08..b07d1752 100644 --- a/templates/plans/invoices/layout.html +++ b/templates/plans/invoices/layout.html @@ -5,22 +5,26 @@ Company Logo {% endif %}
-
+

- {% if invoice.type == invoice.INVOICE_TYPES.INVOICE %}Invoice{% endif %} - {% if invoice.type == invoice.INVOICE_TYPES.PROFORMA %}Order Confirmation{% endif %} - {% if invoice.type == invoice.INVOICE_TYPES.DUPLICATE %}Invoice (Duplicate){% endif %} + {% if invoice.type == invoice.INVOICE_TYPES.INVOICE %}{{ _("Invoice") }}{% endif %} + {% if invoice.type == invoice.INVOICE_TYPES.PROFORMA %}{{ _("Order Confirmation")}}{% endif %} + {% if invoice.type == invoice.INVOICE_TYPES.DUPLICATE %}{{ _("Invoice (Duplicate)")}}{% endif %}
{{ invoice.full_number }}

- {{ copy|yesno:"COPY,ORIGINAL" }} + {% if copy %} + {{ _("COPY") }} +{% else %} + {{ _("ORIGINAL") }} +{% endif %}
-
Issued: {{ invoice.issued|date:"F j, Y" }}
+
{{ _("Issued") }}: {{ invoice.issued|date:"F j, Y" }}
{% if invoice.type != invoice.INVOICE_TYPES.PROFORMA %} -
Order Date: {{ invoice.selling_date|date:"F j, Y" }}
+
{{ _("Order Date")}}: {{ invoice.selling_date|date:"F j, Y" }}
{% endif %}
@@ -31,8 +35,8 @@
-
-
Seller
+
+
{{ _("Seller") }}
@@ -40,7 +44,7 @@ {{ invoice.issuer_street }}
{{ invoice.issuer_zipcode }} {{ invoice.issuer_city }}
{{ invoice.issuer_country.name }}
- VAT ID: {{ invoice.issuer_tax_number }} + {{ _("VAT ID")}}: {{ invoice.issuer_tax_number }}
@@ -48,8 +52,8 @@
-
-
Buyer
+
+
{{ _("Buyer") }}
@@ -58,7 +62,7 @@ {{ invoice.buyer_zipcode }} {{ invoice.buyer_city }}
{{ invoice.buyer_country.name }}
{% if invoice.buyer_tax_number %} - VAT ID: {{ invoice.buyer_tax_number }} + {{ _("VAT ID")}}: {{ invoice.buyer_tax_number }} {% endif %}
@@ -69,8 +73,8 @@ {% if invoice.shipping_name %}
-
-
Shipping Address
+
+
{{ _("Shipping Address")}}
@@ -85,52 +89,52 @@
-
-
Invoice Items
+
+
{{ _("Invoice Items")}}
- + - - - - - + + + + + {% if invoice.rebate %} - + {% endif %} - - - - + + + + - + - + - + {% if invoice.rebate %} {% endif %} - - - - + + + + - + - - - - - + + + + +
#DescriptionUnit PriceQty.Unit#{{ _("Description") }}{{ _("Unit Price")}}{{ _("Quantity") }}{{ _("Unit") }}Rebate{{ _("Rebate") }}SubtotalVATVAT AmountTotal{{ _("Subtotal") }}{{ _("VAT") }}{{ _("VAT Amount")}}{{ _("Total") }}
11 {{ invoice.item_description }}{{ invoice.unit_price_net|floatformat:2 }} {{ invoice.currency }}{{ invoice.unit_price_net|floatformat:2 }} {{ CURRENCY }} {{ invoice.quantity }}units{{ _("units") }}{{ invoice.rebate|floatformat:2 }}%{{ invoice.total_net|floatformat:2 }} {{ invoice.currency }}{% if invoice.tax != None %}{{ invoice.tax|floatformat:2 }}%{% else %}n/a{% endif %}{% if invoice.tax_total != None %}{{ invoice.tax_total|floatformat:2 }} {{ invoice.currency }}{% else %}n/a{% endif %}{{ invoice.total|floatformat:2 }} {{ invoice.currency }}{{ invoice.total_net|floatformat:2 }} {{ CURRENCY }}{% if invoice.tax != None %}{{ invoice.tax|floatformat }}%{% else %}n/a{% endif %}{% if invoice.tax_total != None %}{{ invoice.tax_total|floatformat:2 }} {{ CURRENCY }}{% else %}{{ _("n/a")}}{% endif %}{{ invoice.total|floatformat:2 }} {{ CURRENCY }}
Total{{ invoice.total_net|floatformat:2 }} {{ invoice.currency }}{% if invoice.tax != None %}{{ invoice.tax|floatformat:2 }}%{% else %}n/a{% endif %}{% if invoice.tax_total != None %}{{ invoice.tax_total|floatformat:2 }} {{ invoice.currency }}{% else %}n/a{% endif %}{{ invoice.total|floatformat:2 }} {{ invoice.currency }}{{ _("Total") }}{{ invoice.total_net|floatformat:2 }} {{ CURRENCY }}{% if invoice.tax != None %}{{ invoice.tax|floatformat }}%{% else %}{{ _("n/a")}}{% endif %}{% if invoice.tax_total != None %}{{ invoice.tax_total|floatformat:2 }} {{ CURRENCY }}{% else %}{{ _("n/a")}}{% endif %}{{ invoice.total|floatformat:2 }} {{ CURRENCY }}
@@ -143,23 +147,23 @@
-
-
Payment Information
+
+
{{ _("Payment Information")}}
{% if invoice.type != invoice.INVOICE_TYPES.PROFORMA %}
- Method: - Electronic Payment + {{ _("Method") }}: + {{ _("Electronic Payment")}}
{% endif %}
- Due Date: + {{ _("Due Date")}}: {{ invoice.payment_date|date:"F j, Y" }}
{% if invoice.type != invoice.INVOICE_TYPES.PROFORMA %}
- Payment Received + {{ _("Payment Received")}}
{% endif %}
@@ -167,18 +171,18 @@
-
-
Notes
+
+
{{ _("Notes") }}
{% if invoice.type == invoice.INVOICE_TYPES.PROFORMA %}
- This document is not an invoice. + {{ _("This document is not an invoice")}}
{% endif %} {% if invoice.tax == None and invoice.is_UE_customer %}
- Reverse charge applied. + {{ _("Reverse charge applied")}}
{% endif %}
@@ -188,8 +192,8 @@
-

Thank you for your business!

-

If you have any questions about this invoice, please contact us.

+

{{ _("Thank you for your business")}}!

+

{{ _("If you have any questions about this invoice, please contact us")}}.

diff --git a/templates/pricing_page.html b/templates/pricing_page.html index 5d97b860..a579106d 100644 --- a/templates/pricing_page.html +++ b/templates/pricing_page.html @@ -59,7 +59,7 @@
-

1. Select a Plan

+

1. {{ _("Select a Plan")}}

{% for pp in plan_list %}
@@ -69,7 +69,7 @@

{{ pp.plan.name }}

-
{{ pp.price }} {{ CURRENCY }}/ {{ _("Per month") }}
+
{{ pp.price }} {{ CURRENCY }}/ {{ pp.pricing.period }} {% trans "days" %}
{{ _("Included") }}
    {% if pp.plan.description %} @@ -91,38 +91,38 @@
    -

    2. Enter Your Information

    +

    2. {{ _("Enter Your Information")}}

    - +
    - +
    - +
    - +
    - +
    @@ -133,10 +133,10 @@
    -

    3. Payment Information

    +

    3. {{ _("Payment Information")}}

    - +