You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

67 lines
2.1 KiB

2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
  1. <template>
  2. <div class="done-total-price tw-grid tw-grid-col-1 tw-gap-y-[30px] xl:tw-mt-[60px]">
  3. <div class="tw-p-5 tw-bg-white tw-rounded-xl xl:tw-p-[30px]">
  4. <div class="element tw-flex tw-justify-between tw-items-center tw-flex-nowrap tw-mb-[12px]">
  5. <div class="label tw-body-4 tw-text-black tw-font-bold">
  6. {{ $t("Subtotal")}}
  7. <!-- <span class="tw-text-neutrals-400 tw-font-medium tw-ml-[4px]">{{
  8. $t("(Tax included)")
  9. }}</span> -->
  10. </div>
  11. <div class="content tw-body-4 tw-text-black tw-font-bold">
  12. ${{ subTotal.toLocaleString() }} {{ orderStatus.currency }}
  13. </div>
  14. </div>
  15. <div class="element tw-flex tw-justify-between tw-items-center tw-flex-nowrap tw-mb-[12px]">
  16. <div class="label tw-body-4 tw-text-black tw-font-bold">
  17. {{ $t("Taxes")}}
  18. <!-- <span class="tw-text-neutrals-400 tw-font-medium tw-ml-[4px]">{{
  19. $t("(Tax included)")
  20. }}</span> -->
  21. </div>
  22. <div class="content tw-body-4 tw-text-black tw-font-bold">
  23. ${{ taxes }} {{ orderStatus.currency }}
  24. </div>
  25. </div>
  26. <div
  27. class="element total tw-flex tw-justify-between tw-items-center tw-flex-nowrap tw-pt-[12px] tw-border-0 tw-border-t tw-border-solid tw-border-neutrals-200">
  28. <div class="label tw-body-2 tw-text-black tw-font-bold">
  29. {{ $t("Total Amount") }}
  30. </div>
  31. <div class="content tw-body-2 tw-text-primary-1 tw-font-bold">
  32. ${{ total.toLocaleString() }} {{ orderStatus.currency }}
  33. </div>
  34. </div>
  35. </div>
  36. </div>
  37. </template>
  38. <script>
  39. export default {
  40. name: "TotalPrice",
  41. props: {
  42. subTotal: {
  43. type: Number,
  44. },
  45. total: {
  46. type: Number,
  47. },
  48. orderStatus: {
  49. type: Object
  50. }
  51. },
  52. data() {
  53. return {};
  54. },
  55. computed: {
  56. // total() {
  57. // return parseFloat(this.total).toLocaleString();
  58. // },
  59. taxes() {
  60. return (Math.ceil(this.subTotal*0.05)).toLocaleString();
  61. },
  62. },
  63. };
  64. </script>
  65. <style lang="scss" scoped>
  66. </style>