{% extends 'AppBundle:Documents:v2\\standard_layout.html.twig' %} {% import 'AppBundle:Documents:v2\\Import\\vehicle.html.twig' as vehicleF %} {% import 'AppBundle:Documents:v2\\Import\\vehicle_follow.html.twig' as vehicleFollowF %} {% import 'AppBundle:Documents:v2\\Import\\group.html.twig' as groupF %} {% import 'AppBundle:Documents:v2\\Import\\vehicle_purchase.html.twig' as vehiclePurchaseF %} {% import 'AppBundle:Documents:v2\\Import\\contact.html.twig' as contactF %} {% import 'AppBundle:Documents:v2\\Import\\address.html.twig' as addressF %} {% block style %} {{ parent() }} {% endblock style %} {% block main_title %}{% endblock main_title %} {% block header %} {% set editor = {'label': 'user.buyer.title'|trans({}, 'DocumentTrans'), 'contactLabel': 'contact.title'|trans({}, 'DocumentTrans' )}|merge(buyer) %} {% include 'AppBundle:Documents:v2\\Include\\Global\\header.html.twig' with { 'editor': editor } %} {% endblock header %} {% block content %} {% set name = headerData.corporateName %} {% set addressSource = headerData.addressBilling %} {% if (vehicle_selling_point_header or seller_selling_point_header or user_selling_point_header) %} {% set name = headerData.name %} {% set addressSource = headerData.addressSellingPoint %} {% endif %} {% set address = addressSource.address %} {% set address2 = addressSource.address2 %} {% set postalCode = addressSource.postalCode %} {% set city = addressSource.city %}

{{ 'facture_achat.content_block.title'|trans({}, 'DocumentTrans') }}

{{ name }} {{ 'facture_achat.content_block.txt_1'|trans({ '%date%': vehiclePurchase.purchaseFullDate }, 'DocumentTrans') }}

{% include 'AppBundle:Documents:v2\\Include\\Global\\contact_widget.html.twig' with {'contactHistory' : purchase.newSupplier} %}

{{ 'facture_achat.content_block.txt_2'|trans({}, 'DocumentTrans') }}

{% include 'AppBundle:Documents:v2\\Include\\Global\\array_content.html.twig' with { 'rowList' : [ { 'widthCells' : [1,2,3,4], 'cellTdClass' : 'l-light-grey tab-light-grey', 'items' : [ {'label' : 'vehicle.type'|trans({}, 'DocumentTrans'), 'value' : vehicleData.voVnType}, {'label' : 'vehicle.brand'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getBrand(vehicle, {'truncate': 40})}, {'label' : 'vehicle.model'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getModel(vehicle, {'truncate': 40})}, {'label' : 'vehicle.version'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getVersion(vehicle, {'truncate': 40})}, ] }, { 'widthCells' : [1,2,3,4], 'items' : [ {'label' : 'vehicle.gender'|trans({}, 'DocumentTrans'), 'value' : vehicleData.vehicleType}, {'label' : 'vehicle.energy'|trans({}, 'DocumentTrans'), 'value' : vehicleData.energy}, {'label' : 'vehicle.tax_horsepower_complet'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getTaxHorsePower(vehicle, {})}, {'label' : 'vehicle.serial_number_complet'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getVin(vehicle, {'truncate': 40})}, ] }, { 'widthCells' : [2,2,2,4], 'items' : [ {'label' : 'vehicle.date_distribution'|trans({}, 'DocumentTrans'), 'value' : vehicleData.dateOfDistribution|date('d/m/Y')}, {'label' : 'vehicle.color'|trans({}, 'DocumentTrans'), 'value' : vehicleData.color}, {'label' : 'vehicle.license_number_complete'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getLicenseNumber(vehicle, {"afterValue": ""})}, {'label' : 'vehicle.mileage_not_guaranted'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getDistanceTraveled(vehicle, {"afterValue": "Km"})}, ] }, { 'widthCells' : [2,2,3,3], 'items' : [ {'label' : 'vehicle.horsepower_complet'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getHorsePower(vehicle, {})}, {'label' : 'vehicle.provenance'|trans({}, 'DocumentTrans'), 'value' : vehicleFollowF.getOrigin(vehicle.follow, {'truncate': 40})}, {'label' : 'vehicle.origine'|trans({}, 'DocumentTrans'), 'value' : vehicleF.getCountry(vehicle, {'truncate': 40, 'countries': countries})}, {'label' : 'CO2', 'value' : vehicleF.getExtraUrbanKmConsumption(vehicle, {})}, ] }, ] } %} {% include 'AppBundle:Documents:v2\\Include\\Global\\title_content.html.twig' with {'title' : 'Montant'} %}
{% include 'AppBundle:Documents:v2\\Include\\Global\\array_content.html.twig' with { 'rowList' : [ { 'widthCells' : [4,2,4], 'cellTdClass' : 'l-light-grey tab-light-grey', 'items' : [ {'label' : 'payment.transaction_amount_DF'|trans({}, 'DocumentTrans'), 'value' : vehiclePurchase.price ~ ' ' ~ currencySymbol}, {'label' : vehiclePurchaseF.getTax(vehicle.purchase, {}), 'value' : vehiclePurchase.taxValue}, {'label' : 'payment.transaction_amount_VAT'|trans({}, 'DocumentTrans'), 'value' : vehiclePurchase.priceTtc ~ ' ' ~ currencySymbol}, ] } ] } %} {% include 'AppBundle:Documents:v2\\Include\\Global\\title_content.html.twig' with {'title' : 'user.buyer.title'|trans({}, 'DocumentTrans')} %}

{{ name }}

{{ address }}
{{ address2 }}
{{ postalCode }}
{{ city }}

{{ 'facture_achat.content_block.txt_3'|trans({}, 'DocumentTrans') }}

{% block payment %} {% include 'AppBundle:Documents:v2\\Include\\Global\\title_content.html.twig' with {'title' : 'payment.title'|trans({}, 'DocumentTrans')} %}

{{ 'administrative.purchase_order_number'|trans({}, 'DocumentTrans') }}

{{ vehiclePurchase.purchaseOrderNumber }}

{{ 'administrative.invoice_number'|trans({}, 'DocumentTrans') }}

{{ vehiclePurchase.paymentInvoiceNumber }}

{{ 'payment.paid_vehicle'|trans({}, 'DocumentTrans') }}

{{ vehiclePurchase.paymentSettled }}

{{ 'payment.paid_amount'|trans({}, 'DocumentTrans') }}

{{ vehiclePurchase.paymentAmount }} {{ currencySymbol }}

{{ 'payment.bill_date'|trans({}, 'DocumentTrans') }}

{{ vehiclePurchase.paymentDate }}

{{ 'payment.deadline'|trans({}, 'DocumentTrans') }}

{{ vehiclePurchase.paymentDueDate }}

{{ 'payment.type'|trans({}, 'DocumentTrans') }}

{{ vehiclePurchase.paymentType }}
{% endblock payment %} {% include 'AppBundle:Documents:v2\\Include\\Global\\title_content.html.twig' with {'title' : 'title_content.title_remark'|trans({}, 'DocumentTrans')} %} {% block notes %}

{{ vehiclePurchase.paymentNote }}

{% endblock notes %} {% endblock content %} {% block signature %}{% endblock signature %}