hedera-web/forms/ecomerce/checkout/ui.xml

208 lines
5.4 KiB
XML
Raw Normal View History

2015-03-06 23:33:54 +00:00
<vn>
<vn-group>
2015-07-15 13:39:07 +00:00
<vn-param id="method"/>
2015-07-23 15:58:48 +00:00
<vn-param id="date"/>
2015-07-15 13:39:07 +00:00
<vn-param id="agency"/>
2015-07-23 15:58:48 +00:00
<vn-param id="address" on-changed="onAddressChange"/>
2015-07-15 13:39:07 +00:00
<db-form id="defaults" on-ready="onValuesReady">
2015-11-09 08:14:33 +00:00
<db-model property="model">
<custom>
SELECT delivery_method, agency_id, address_id
FROM basket_defaults
</custom>
</db-model>
</db-form>
2015-07-15 13:39:07 +00:00
<db-form id="order-form" on-ready="onValuesReady">
2015-11-09 08:14:33 +00:00
<db-model property="model">
<custom>
2017-03-17 12:42:10 +00:00
SELECT d.code delivery_method, o.date_send, o.agency_id, o.address_id
2015-11-09 08:14:33 +00:00
FROM basket o
2017-03-17 12:42:10 +00:00
JOIN vn.deliveryMethod d ON d.id = o.delivery_method_id
2015-11-09 08:14:33 +00:00
</custom>
2015-07-03 05:49:45 +00:00
</db-model>
</db-form>
2017-03-17 12:42:10 +00:00
<db-model id="agencies" auto-load="false" on-status-changed="onAgenciesReady">
2015-11-09 08:14:33 +00:00
<custom>
2017-03-17 12:42:10 +00:00
CALL vn.agencyListForMethod(#date, #address, 'AGENCY')
2015-11-09 08:14:33 +00:00
</custom>
2015-07-15 13:39:07 +00:00
<sql-batch property="batch">
2015-11-09 08:14:33 +00:00
<custom>
<item name="address" param="address"/>
<item name="date" param="date"/>
</custom>
2015-07-17 14:34:42 +00:00
</sql-batch>
</db-model>
2017-03-17 12:42:10 +00:00
<db-model id="warehouses" auto-load="false" on-status-changed="onWarehousesReady">
2015-11-09 08:14:33 +00:00
<custom>
2017-03-17 12:42:10 +00:00
CALL vn.agencyListForMethod(#date, #address, 'PICKUP')
2015-11-09 08:14:33 +00:00
</custom>
2015-07-17 14:34:42 +00:00
<sql-batch property="batch">
2015-11-09 08:14:33 +00:00
<custom>
<item name="address" param="address"/>
<item name="date" param="date"/>
</custom>
2015-07-15 13:39:07 +00:00
</sql-batch>
</db-model>
2015-03-06 23:33:54 +00:00
</vn-group>
2017-03-17 12:42:10 +00:00
<h1 id="title">
<t>ConfigureOrder</t>
</h1>
2015-09-16 16:11:15 +00:00
<div id="actions">
2016-09-19 06:40:18 +00:00
<htk-bar-button
icon="close"
2015-09-16 16:11:15 +00:00
tip="_Cancel"
2016-09-19 06:40:18 +00:00
on-click="onCancelClick"/>
</div>
2015-03-06 23:33:54 +00:00
<div id="form" class="checkout">
2016-12-23 08:57:49 +00:00
<div class="card form">
<htk-assistant
id="assistant"
step-count="5"
step-func="stepFunc"
node="assistant-node"/>
<div id="assistant-node">
<div id="method-step">
<h2><t>DeliveryOrPickupQuestion</t></h2>
<div class="answers radio">
<htk-radio-group
id="rg-method"
param="method"
on-changed="onFieldChange"/>
<div>
<htk-radio radio-group="rg-method" value="AGENCY"/>
<label><t>ReceiveThroughtAgency</t></label>
</div>
2016-12-23 08:57:49 +00:00
<div>
<htk-radio radio-group="rg-method" value="DELIVERY"/>
<label><t>ReceiveThroughtRoute</t></label>
</div>
<div>
<htk-radio radio-group="rg-method" value="PICKUP"/>
<label><t>PickupInStore</t></label>
2015-07-10 12:30:08 +00:00
</div>
</div>
2016-12-23 08:57:49 +00:00
</div>
<div id="date-step">
<h2 id="date-question"><t>OrderDateDeliveryQuestion</t></h2>
<div class="answers">
<htk-calendar
id="calendar"
class="thin-calendar"
param="date"
restrict-func="calendarRestrict"
on-changed="onFieldChange"/>
</div>
</div>
<div id="address-step">
<h2><t>AddressQuestion</t></h2>
<db-form id="address-form" model="addresses"/>
<div class="answers target">
<htk-repeater
id="repeater"
form-id="iter"
on-change="onAddressChange"
renderer="addressRenderer">
<db-model property="model" id="addresses">
2015-11-09 08:14:33 +00:00
<custom>
2016-12-23 08:57:49 +00:00
SELECT a.id, a.consignee, p.name province, a.zip_code, a.city, a.name, a.active, c.Pais country
FROM address_view a
LEFT JOIN vn2008.province p ON a.province_id = p.province_id
JOIN vn2008.Paises c ON c.Id = p.Paises_Id
WHERE active != FALSE
2015-11-09 08:14:33 +00:00
</custom>
2016-12-23 08:57:49 +00:00
</db-model>
<custom>
<div class="address" id="address">
<p class="consignee">
<htk-text form="iter" column="consignee"/>
</p>
<p>
<htk-text form="iter" column="name"/>
</p>
</div>
</custom>
</htk-repeater>
</div>
2016-12-23 08:57:49 +00:00
</div>
<div id="agency-step">
<h2><t>AgencyQuestion</t></h2>
<div class="answers target">
<htk-combo
id="agency-combo"
param="agency"
on-changed="onFieldChange"
model="agencies"/>
</div>
2016-12-23 08:57:49 +00:00
</div>
<div id="pickup-step">
<h2><t>PickupWarehouseQuestion</t></h2>
<div class="answers target">
<htk-combo
id="warehouse-combo"
param="agency"
on-changed="onFieldChange"
model="warehouses"/>
2015-07-03 05:49:45 +00:00
</div>
2016-12-23 08:57:49 +00:00
</div>
<div id="confirm-agency-step" class="confirm">
<h2><t>ConfirmToAccessCatalog</t></h2>
<div class="answers target">
<p>
<t>Arrival</t>
<htk-text format="%D" param="date"/>
</p>
<p>
<htk-text form="address-form" column="name"/>
</p>
<p>
<t>Agency</t>
<htk-text form="agency-combo" column="description"/>
</p>
<button id="confirm-agency" class="thin" on-click="onConfirmClick">
<t>Confirm</t>
</button>
<div class="clear"/>
</div>
2016-12-23 08:57:49 +00:00
</div>
<div id="confirm-delivery-step" class="confirm">
<h2><t>ConfirmToAccessCatalog</t></h2>
<div class="answers target">
<p>
<t>Arrival</t>
<htk-text format="%D" param="date"/>
</p>
<p>
<htk-text form="address-form" column="name"/>
</p>
<p>
<t>ReceiveThroughtRoute</t>
</p>
<button id="confirm-delivery" class="thin" on-click="onConfirmClick">
<t>Confirm</t>
</button>
<div class="clear"/>
</div>
2016-12-23 08:57:49 +00:00
</div>
<div id="confirm-pickup-step" class="confirm">
<h2><t>ConfirmToAccessCatalog</t></h2>
<div class="answers target">
<p>
<t>Pickup</t>
<htk-text format="%D" param="date"/>
</p>
<p>
<t>Warehouse</t>
<htk-text form="warehouse-combo" column="description"/>
</p>
<button id="confirm-pickup" class="thin" on-click="onConfirmClick">
<t>Confirm</t>
</button>
<div class="clear"/>
</div>
</div>
2015-03-06 23:33:54 +00:00
</div>
2016-12-23 08:57:49 +00:00
<htk-assistant-bar assistant="assistant"/>
2015-03-06 23:33:54 +00:00
</div>
</div>
</vn>