0
1
Fork 0
hedera-web-mindshore/forms/ecomerce/confirm/ui.xml

218 lines
5.3 KiB
XML
Raw Normal View History

<vn>
<vn-group>
2015-07-17 14:34:42 +00:00
<db-form id="order-form" on-ready="onOrderReady">
<db-model property="model" result-index="1">
2019-05-21 14:16:27 +00:00
CALL myBasket_getTax;
2018-05-18 11:52:05 +00:00
SELECT o.id, o.sent, o.notes, o.companyFk,
2019-03-13 08:57:18 +00:00
ag.description agency, v.code method,
ad.nickname, ad.postalCode, ad.city, ad.street,
t.*, c.credit, myClientGetDebt(NULL) debt
2018-05-18 11:52:05 +00:00
FROM myBasket o
JOIN vn.agencyMode ag ON ag.id = o.agencyModeFk
LEFT JOIN myAddress ad ON ad.id = o.addressFk
JOIN vn.deliveryMethod v ON v.id = o.deliveryMethodFk
2018-05-17 10:09:29 +00:00
JOIN myClient c
JOIN (
SELECT
2019-03-13 08:57:18 +00:00
IFNULL(SUM(taxableBase), 0) taxableBase,
IFNULL(SUM(tax), 0) tax
FROM tmp.orderAmount
2018-05-17 10:09:29 +00:00
) t;
2019-03-13 08:57:18 +00:00
DROP TEMPORARY TABLE tmp.orderAmount;
2018-05-17 10:09:29 +00:00
DROP TEMPORARY TABLE tmp.orderTax;
</db-model>
</db-form>
2015-07-17 14:34:42 +00:00
<db-query id="confirm-query" on-ready="onConfirm">
2019-05-21 14:16:27 +00:00
CALL myBasket_confirm
2015-07-17 14:34:42 +00:00
</db-query>
</vn-group>
<div id="title">
<h1><t>Order summary</t></h1>
</div>
2015-07-07 15:27:47 +00:00
<div id="form" class="confirm">
<div class="box summary">
<div>
<div class="delivery">
<p>
<t>Delivery at</t>
2018-05-18 11:52:05 +00:00
<htk-text format="%D" form="order-form" column="sent"/>
2015-07-07 15:27:47 +00:00
</p>
<p>
2015-07-17 14:34:42 +00:00
<span id="method"><t>Agency</t></span>
2015-07-07 15:27:47 +00:00
<htk-text form="order-form" column="agency"/>
</p>
</div>
<div id="address" class="address">
<p>
2018-01-22 08:52:43 +00:00
<htk-text form="order-form" column="nickname"/>
2015-07-07 15:27:47 +00:00
</p>
<p>
2018-01-22 08:52:43 +00:00
<htk-text form="order-form" column="street"/>
2015-07-07 15:27:47 +00:00
</p>
<p>
2018-01-22 08:52:43 +00:00
<htk-text form="order-form" column="postalCode"/>,
2015-07-07 15:27:47 +00:00
<htk-text form="order-form" column="city"/>
</p>
</div>
</div>
</div>
<div class="box payment">
<div>
<table class="debt-info">
<tbody>
<tr>
<td>
<t>Previous balance</t>
</td>
<td class="currency">
<htk-text format="%.2d€" id="debt"/>
</td>
</tr>
<tr>
<td>
<t>Order total</t>
</td>
<td class="currency">
2019-03-13 08:57:18 +00:00
<htk-text format="%.2d€" form="order-form" column="taxableBase"/>
</td>
</tr>
<tr>
<td>
<t>Order VAT</t>
</td>
<td class="currency">
2017-12-01 14:38:23 +00:00
<htk-text format="%.2d€" form="order-form" column="tax"/>
</td>
</tr>
<tr class="total-debt sum-total">
<td>
<t>Total debt</t>
</td>
<td class="currency">
<htk-text format="%.2d€" id="total-debt"/>
</td>
</tr>
<tr id="credit-info" class="credit-info">
<td>
<t>Credit</t>
</td>
<td class="currency">
<htk-text format="%.2d€" form="order-form" column="credit"/>
</td>
</tr>
<tr id="exceeded-info" class="exceeded-info sum-total">
<td>
<t>Exceeded credit</t>
</td>
<td class="currency">
<htk-text format="%.2d€" id="credit-excess"/>
</td>
</tr>
</tbody>
</table>
</div>
<div id="amount-selector" class="amount-selector">
<h2>
<t>Amount to pay</t>
</h2>
<div class="radio">
<htk-radio-group
id="pay-amount"/>
<div>
<htk-radio radio-group="pay-amount" value="ALL"/>
<label>
<t>Total debt</t>,
<htk-text format="%.2d€" id="total-amount"/>
</label>
</div>
<div>
<htk-radio radio-group="pay-amount" value="EXCEEDED"/>
<label>
<t>Exceeded credit</t>,
<htk-text format="%.2d€" id="excess-amount"/>
</label>
</div>
2015-07-07 15:27:47 +00:00
</div>
</div>
<div>
<h2>
<t>Pay method</t>
</h2>
2018-05-17 11:22:13 +00:00
<div class="pay-methods">
<htk-radio-group
id="pay-method"
on-changed="onPayMethodChange"/>
<div id="balance-method">
2018-05-17 11:22:13 +00:00
<label>
<htk-radio radio-group="pay-method" value="BALANCE"/>
<t>Use my balance</t>
</label>
<div>
<t>You have a favorable balance.</t>
</div>
</div>
<div id="credit-method">
2018-05-17 11:22:13 +00:00
<label>
<htk-radio radio-group="pay-method" value="CREDIT"/>
<t>Use my credit</t>
</label>
<div>
<t>You have a favorable credit.</t>
</div>
</div>
<div id="card-method">
2018-05-17 11:22:13 +00:00
<label>
<htk-radio radio-group="pay-method" value="CARD"/>
<t>Credit card</t>
</label>
<div>
<t>You will be redirected to the payment.</t>
</div>
</div>
<div id="transfer-method">
2018-05-17 11:22:13 +00:00
<label>
<htk-radio radio-group="pay-method" value="TRANSFER"/>
<t>Bank Transfer</t>
</label>
<div>
<t>Make a transfer to one account.</t>
<htk-repeater form-id="iter">
<db-model property="model">
2018-05-17 10:09:29 +00:00
SELECT name, iban FROM mainAccountBank
</db-model>
<custom>
<div class="transfer-account">
2018-05-17 10:09:29 +00:00
<p><htk-text form="iter" column="name"/></p>
<p><htk-text form="iter" column="iban"/></p>
</div>
</custom>
</htk-repeater>
</div>
</div>
<div id="later-method">
2018-05-17 11:22:13 +00:00
<label>
<htk-radio radio-group="pay-method" value="LATER"/>
<t>Pay later</t>
</label>
</div>
</div>
</div>
<div class="button-bar">
<button on-click="onModifyClick" id="modify" class="thin modify-order">
<t>Modify</t>
</button>
<button on-click="onConfirmClick" id="confirm" class="thin confirm-order">
<t>Confirm</t>
</button>
<div class="clear"/>
</div>
</div>
2015-07-07 15:27:47 +00:00
</div>
<htk-dialog
id="success-dialog"
icon="ok"
message="_Order confirmed successfully"
buttons="ACCEPT"
on-response="onDialogResponse"/>
</vn>