|
@@ -253,6 +253,7 @@ if ($resql) {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
?>
|
|
|
|
|
|
<script>
|
|
@@ -520,20 +521,51 @@ if (getDolGlobalString('TAKEPOS_CUSTOMER_DISPLAY')) {
|
|
|
?>
|
|
|
</script>
|
|
|
|
|
|
+<?php
|
|
|
+$showothercurrency = 0;
|
|
|
+if (isModEnabled('multicurrency') && $_SESSION["takeposcustomercurrency"] != "" && $conf->currency != $_SESSION["takeposcustomercurrency"]) {
|
|
|
+ //Only show customer currency if multicurrency module is enabled, if currency selected and if this currency selected is not the same as main currency
|
|
|
+ $showothercurrency = 1;
|
|
|
+ include_once DOL_DOCUMENT_ROOT . '/multicurrency/class/multicurrency.class.php';
|
|
|
+ $multicurrency = new MultiCurrency($db);
|
|
|
+ $multicurrency->fetch(0, $_SESSION["takeposcustomercurrency"]);
|
|
|
+}
|
|
|
+?>
|
|
|
+
|
|
|
<div style="position:relative; padding-top: 20px; left:5%; height:140px; width:90%;">
|
|
|
<div class="paymentbordline paymentbordlinetotal center">
|
|
|
- <span class="takepospay colorwhite"><?php echo $langs->trans('TotalTTC'); ?>: <span id="totaldisplay" class="colorwhite"><?php echo price($invoice->total_ttc, 1, '', 1, -1, -1, $invoice->multicurrency_code); ?></span></span>
|
|
|
+ <span class="takepospay colorwhite"><?php echo $langs->trans('TotalTTC'); ?>: <span id="totaldisplay" class="colorwhite"><?php
|
|
|
+ echo price($invoice->total_ttc, 1, '', 1, -1, -1, $conf->currency);
|
|
|
+ if ($showothercurrency) {
|
|
|
+ print ' <span id="linecolht-span-total opacitymedium" style="font-size:0.9em; font-style:italic;">(' . price($invoice->total_ht * $multicurrency->rate->rate) . ' ' . $_SESSION["takeposcustomercurrency"] . ')</span>';
|
|
|
+ }
|
|
|
+ ?></span></span>
|
|
|
</div>
|
|
|
<?php if ($remaintopay != $invoice->total_ttc) { ?>
|
|
|
<div class="paymentbordline paymentbordlineremain center">
|
|
|
- <span class="takepospay colorwhite"><?php echo $langs->trans('RemainToPay'); ?>: <span id="remaintopaydisplay" class="colorwhite"><?php echo price($remaintopay, 1, '', 1, -1, -1, $invoice->multicurrency_code); ?></span></span>
|
|
|
+ <span class="takepospay colorwhite"><?php echo $langs->trans('RemainToPay'); ?>: <span id="remaintopaydisplay" class="colorwhite"><?php
|
|
|
+ echo price($remaintopay, 1, '', 1, -1, -1, $invoice->multicurrency_code);
|
|
|
+ if ($showothercurrency) {
|
|
|
+ print ' <span id="linecolht-span-total opacitymedium" style="font-size:0.9em; font-style:italic;">(' . price($remaintopay * $multicurrency->rate->rate) . ' ' . $_SESSION["takeposcustomercurrency"] . ')</span>';
|
|
|
+ }
|
|
|
+ ?></span></span>
|
|
|
</div>
|
|
|
<?php } ?>
|
|
|
<div class="paymentbordline paymentbordlinereceived center">
|
|
|
- <span class="takepospay colorwhite"><?php echo $langs->trans("Received"); ?>: <span class="change1 colorred"><?php echo price(0, 1, '', 1, -1, -1, $invoice->multicurrency_code); ?></span><input type="hidden" id="change1" class="change1" value="0"></span>
|
|
|
+ <span class="takepospay colorwhite"><?php echo $langs->trans("Received"); ?>: <span class="change1 colorred"><?php
|
|
|
+ echo price(0, 1, '', 1, -1, -1, $invoice->multicurrency_code);
|
|
|
+ if ($showothercurrency) {
|
|
|
+ print ' <span id="linecolht-span-total opacitymedium" style="font-size:0.9em; font-style:italic;">(' . price(0 * $multicurrency->rate->rate) . ' ' . $_SESSION["takeposcustomercurrency"] . ')</span>';
|
|
|
+ }
|
|
|
+ ?></span><input type="hidden" id="change1" class="change1" value="0"></span>
|
|
|
</div>
|
|
|
<div class="paymentbordline paymentbordlinechange center">
|
|
|
- <span class="takepospay colorwhite"><?php echo $langs->trans("Change"); ?>: <span class="change2 colorwhite"><?php echo price(0, 1, '', 1, -1, -1, $invoice->multicurrency_code); ?></span><input type="hidden" id="change2" class="change2" value="0"></span>
|
|
|
+ <span class="takepospay colorwhite"><?php echo $langs->trans("Change"); ?>: <span class="change2 colorwhite"><?php
|
|
|
+ echo price(0, 1, '', 1, -1, -1, $invoice->multicurrency_code);
|
|
|
+ if ($showothercurrency) {
|
|
|
+ print ' <span id="linecolht-span-total opacitymedium" style="font-size:0.9em; font-style:italic;">(' . price(0 * $multicurrency->rate->rate) . ' ' . $_SESSION["takeposcustomercurrency"] . ')</span>';
|
|
|
+ }
|
|
|
+ ?></span><input type="hidden" id="change2" class="change2" value="0"></span>
|
|
|
</div>
|
|
|
<?php
|
|
|
if (getDolGlobalString('TAKEPOS_CAN_FORCE_BANK_ACCOUNT_DURING_PAYMENT')) {
|