Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fiscalisation : gestion de la TVA sur le tunnel de vente #1355

Closed
Tracked by #1339
agallou opened this issue Nov 19, 2023 · 0 comments · Fixed by #1383
Closed
Tracked by #1339

Fiscalisation : gestion de la TVA sur le tunnel de vente #1355

agallou opened this issue Nov 19, 2023 · 0 comments · Fixed by #1383

Comments

@agallou
Copy link
Member

agallou commented Nov 19, 2023

Sur le tunnel de vente

  • ajouter les 10% de TVA sur les prix affichés
  • ajouter le 10% de TVA sur le prix affiché dans le fieldset
  • afficher "TTC" sur les radios des prix
  • en bas de la page, ajouter un header sur le total avec le prix unitaire HT, quantité, prix HT.
  • en bas de la page, ajouter une colonne avec le prix TTC
  • faire en sorte que le paiement se fasses sur le prix TTC
  • faire en sorte que ces changements soient appliqués au premier janvier 2024 (en se basant sur ma méthode statique)
diff --git a/app/Resources/views/event/ticket/ticket.html.twig b/app/Resources/views/event/ticket/ticket.html.twig
index 0ab90f48..e3545c41 100644
--- a/app/Resources/views/event/ticket/ticket.html.twig
+++ b/app/Resources/views/event/ticket/ticket.html.twig
@@ -138,8 +138,9 @@
                                             {% if type.vars.attr['data-price'] == 0 %}
                                                 OFFERT
                                             {% else %}
-                                                {{ type.vars.attr['data-price'] }}€
+                                                {{ type.vars.attr['data-price'] * 1.1 }}€
                                             {% endif %}
+                                            TTC
                                         </span>
                                         <br />
                                         <span class="tickets--type-details">
@@ -305,4 +306,4 @@
         });
     </script>
     {# Debut block conversion linkedIn Insights #}
-{% endblock %}
\ No newline at end of file
+{% endblock %}
diff --git a/htdocs/js/inscription.js b/htdocs/js/inscription.js
index 8800b8bb..456a5cc9 100644
--- a/htdocs/js/inscription.js
+++ b/htdocs/js/inscription.js
@@ -95,6 +95,30 @@ $(document).ready(function(){
 
         var df = document.createDocumentFragment();
 
+        var trClone = tr.cloneNode();
+        trClone.classList.add('registration')
+        var thClone = th.cloneNode();
+        thClone.appendChild(document.createTextNode("Type"));
+        trClone.appendChild(thClone);
+
+        var tdClone = td.cloneNode();
+        tdClone.appendChild(document.createTextNode("Prix HT Unitaire"));
+        trClone.appendChild(tdClone);
+
+        var tdClone = td.cloneNode();
+        tdClone.appendChild(document.createTextNode("Quantité"));
+        trClone.appendChild(tdClone);
+
+        var tdClone = td.cloneNode();
+        tdClone.appendChild(document.createTextNode("Prix HT"));
+        trClone.appendChild(tdClone);
+
+        var tdClone = td.cloneNode();
+        tdClone.appendChild(document.createTextNode("Prix TTC"));
+        trClone.appendChild(tdClone);
+
+        df.appendChild(trClone);
+
         for (var i in inscriptions) {
             var trClone = tr.cloneNode();
             trClone.classList.add('registration')
@@ -114,6 +138,10 @@ $(document).ready(function(){
             tdClone.appendChild(document.createTextNode(inscriptions[i].subtotal + '€'));
             trClone.appendChild(tdClone);
 
+            var tdClone = td.cloneNode();
+            tdClone.appendChild(document.createTextNode((inscriptions[i].subtotal * 1.1) + '€'));
+            trClone.appendChild(tdClone);
+
             df.appendChild(trClone);
             numberOfTickets += inscriptions[i].quantity;
             total += inscriptions[i].subtotal;
@@ -136,6 +164,10 @@ $(document).ready(function(){
         tdClone.appendChild(document.createTextNode(total + '€'));
         trClone.appendChild(tdClone);
 
+        var tdClone = td.cloneNode();
+        tdClone.appendChild(document.createTextNode((total * 1.1) + '€'));
+        trClone.appendChild(tdClone);
+
         df.appendChild(trClone);
 
         table.appendChild(df);
@@ -162,7 +194,7 @@ $(document).ready(function(){
 		} else {
 			var price = fieldset.find('ul.tickets--type-list input[type=radio]:checked').data('price');
 			if (typeof price !== 'undefined') {
-                $(fieldset).find('legend span.fieldset--legend--price').html(price + '€');
+                $(fieldset).find('legend span.fieldset--legend--price').html((price * 1.1) + '€');
             }
 		}
     }

avant :
Screenshot 2023-11-18 at 18-23-47 Prenez votre place pour le forum

après :
Screenshot 2023-11-18 at 18-33-52 Prenez votre place pour le forum

@agallou agallou changed the title Gestion de la TVA sur le tunnel de vente Fiscalisation : gestion de la TVA sur le tunnel de vente Nov 19, 2023
@github-project-automation github-project-automation bot moved this from Todo to Done in Backlog global Dec 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant