2015-03-06 23:33:54 +00:00
|
|
|
<vn>
|
|
|
|
<vn-group>
|
2016-05-04 14:36:51 +00:00
|
|
|
<vn-param id="card-item"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
<vn-param id="realm" on-changed="onRealmChange"/>
|
2015-11-09 08:14:33 +00:00
|
|
|
<vn-param id="type" on-changed="onTypeChange"/>
|
2016-01-10 13:10:51 +00:00
|
|
|
<vn-param id="search" on-changed="onFilterChange"/>
|
|
|
|
<vn-param id="color" on-changed="onFilterChange"/>
|
|
|
|
<vn-param id="origin" on-changed="onFilterChange"/>
|
|
|
|
<vn-param id="category" on-changed="onFilterChange"/>
|
|
|
|
<vn-param id="producer" on-changed="onFilterChange"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
<vn-hash-param key="realm" param="realm"/>
|
|
|
|
<vn-hash-param key="type" param="type"/>
|
2015-03-06 23:33:54 +00:00
|
|
|
<sql-filter type="AND" id="filter">
|
2015-11-19 13:57:23 +00:00
|
|
|
<sql-filter-item type="EQUAL" primary="false" id="op-realm">
|
2018-03-26 16:35:02 +00:00
|
|
|
<sql-field target="t" name="categoryFk"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
<sql-value id="realm-value"/>
|
2015-03-06 23:33:54 +00:00
|
|
|
</sql-filter-item>
|
2016-01-07 12:58:29 +00:00
|
|
|
<sql-filter-item type="EQUAL" id="op-type">
|
2018-03-26 16:35:02 +00:00
|
|
|
<sql-field target="i" name="typeFk"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
<sql-value id="type-value"/>
|
2015-11-19 13:57:23 +00:00
|
|
|
</sql-filter-item>
|
2015-11-17 10:34:33 +00:00
|
|
|
<sql-filter-item type="LIKE" id="op-name">
|
2018-07-20 14:30:29 +00:00
|
|
|
<sql-field target="i" name="longName"/>
|
2015-03-06 23:33:54 +00:00
|
|
|
<sql-search-tags param="search"/>
|
|
|
|
</sql-filter-item>
|
2015-11-17 10:34:33 +00:00
|
|
|
<sql-filter-item type="EQUAL" id="op-color">
|
2018-03-26 16:35:02 +00:00
|
|
|
<sql-field target="i" name="inkFk"/>
|
2015-11-17 10:34:33 +00:00
|
|
|
<sql-value param="color"/>
|
|
|
|
</sql-filter-item>
|
|
|
|
<sql-filter-item type="EQUAL" id="op-origin">
|
2018-03-26 16:35:02 +00:00
|
|
|
<sql-field target="i" name="originFk"/>
|
2015-11-17 10:34:33 +00:00
|
|
|
<sql-value param="origin"/>
|
|
|
|
</sql-filter-item>
|
|
|
|
<sql-filter-item type="EQUAL" id="op-category">
|
2018-03-26 16:35:02 +00:00
|
|
|
<sql-field target="i" name="category"/>
|
2015-11-17 10:34:33 +00:00
|
|
|
<sql-value param="category"/>
|
|
|
|
</sql-filter-item>
|
|
|
|
<sql-filter-item type="EQUAL" id="op-producer">
|
2018-03-26 16:35:02 +00:00
|
|
|
<sql-field target="i" name="producerFk"/>
|
2015-11-17 10:34:33 +00:00
|
|
|
<sql-value param="producer"/>
|
|
|
|
</sql-filter-item>
|
2015-03-06 23:33:54 +00:00
|
|
|
</sql-filter>
|
2016-05-04 14:36:51 +00:00
|
|
|
<db-form id="basket" on-ready="onBasketReady">
|
|
|
|
<db-model property="model">
|
2018-03-26 16:35:02 +00:00
|
|
|
SELECT b.id, b.sent, a.description agency, m.code method
|
|
|
|
FROM myBasket b
|
|
|
|
JOIN vn.agencyMode a ON a.id = b.agencyModeFk
|
|
|
|
JOIN vn.deliveryMethod m ON m.id = b.deliveryMethodFk
|
2016-05-04 14:36:51 +00:00
|
|
|
</db-model>
|
|
|
|
</db-form>
|
|
|
|
<db-model
|
|
|
|
id="items-model"
|
|
|
|
result-index="2"
|
|
|
|
on-status-changed="onItemsChange">
|
2019-06-05 07:05:54 +00:00
|
|
|
CREATE TEMPORARY TABLE tmp.item
|
|
|
|
(INDEX (itemFk))
|
2018-03-27 14:35:53 +00:00
|
|
|
ENGINE = MEMORY
|
2019-06-05 07:05:54 +00:00
|
|
|
SELECT i.id itemFk
|
2018-03-27 14:35:53 +00:00
|
|
|
FROM vn.item i
|
|
|
|
JOIN vn.itemType t ON t.id = i.typeFk
|
|
|
|
WHERE #filter;
|
2019-06-05 07:05:54 +00:00
|
|
|
CALL myBasket_calcCatalogFull;
|
2020-08-13 08:21:59 +00:00
|
|
|
SELECT i.id, i.description, i.longName item, i.subName,
|
|
|
|
i.tag5, i.value5, i.tag6, i.value6, i.tag7, i.value7,
|
|
|
|
i.relevancy, i.size, i.category,
|
|
|
|
k.name ink, p.name producer, o.name origin,
|
2022-04-13 11:31:52 +00:00
|
|
|
b.available, b.price, b.`grouping`,
|
|
|
|
i.image, im.updated
|
2019-06-05 07:05:54 +00:00
|
|
|
FROM tmp.ticketCalculateItem b
|
|
|
|
JOIN vn.item i ON i.id = b.itemFk
|
2020-08-13 08:21:59 +00:00
|
|
|
LEFT JOIN vn.ink k ON k.id = i.inkFk
|
|
|
|
LEFT JOIN vn.producer p ON p.id = i.producerFk
|
|
|
|
LEFT JOIN vn.origin o ON o.id = i.originFk
|
2019-05-27 13:38:06 +00:00
|
|
|
LEFT JOIN image im
|
|
|
|
ON im.collectionFk = 'catalog'
|
|
|
|
AND im.name = i.image
|
2018-03-26 16:35:02 +00:00
|
|
|
WHERE b.available > 0
|
|
|
|
ORDER BY i.relevancy DESC, i.name, i.size
|
2020-09-26 11:34:05 +00:00
|
|
|
LIMIT 5000;
|
2015-11-19 13:57:23 +00:00
|
|
|
<sql-batch property="batch" id="filter-batch">
|
|
|
|
<custom>
|
|
|
|
<item name="filter" object="filter"/>
|
|
|
|
</custom>
|
2015-07-07 15:27:47 +00:00
|
|
|
</sql-batch>
|
|
|
|
</db-model>
|
2016-05-04 14:36:51 +00:00
|
|
|
<db-form id="card" model="items-model"/>
|
|
|
|
<sql-batch id="card-batch">
|
|
|
|
<custom>
|
|
|
|
<item name="item" param="card-item"/>
|
|
|
|
</custom>
|
|
|
|
</sql-batch>
|
2015-03-06 23:33:54 +00:00
|
|
|
</vn-group>
|
2015-09-11 09:37:16 +00:00
|
|
|
<div id="title">
|
|
|
|
<h1 id="title-text"><t>Catalog</t></h1>
|
|
|
|
</div>
|
2015-09-16 16:11:15 +00:00
|
|
|
<div id="actions" class="catalog-actions">
|
2016-01-07 12:58:29 +00:00
|
|
|
<button class="menu" on-click="onShowMenuClick">
|
2016-09-19 06:40:18 +00:00
|
|
|
<img src="image/icon/dark/menu.svg" alt="_Menu"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
</button>
|
2016-09-19 06:40:18 +00:00
|
|
|
<htk-bar-button
|
|
|
|
icon="basket"
|
2015-09-16 16:11:15 +00:00
|
|
|
tip="_ShoppingBasket"
|
2016-09-19 06:40:18 +00:00
|
|
|
on-click="onBasketClick"/>
|
|
|
|
<htk-bar-button
|
2016-01-07 12:58:29 +00:00
|
|
|
id="view-button"
|
|
|
|
tip="_Switch view"
|
2016-09-19 06:40:18 +00:00
|
|
|
on-click="onSwitchViewClick"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
<htk-search-entry
|
|
|
|
param="search"/>
|
2015-09-11 09:37:16 +00:00
|
|
|
</div>
|
2015-03-06 23:33:54 +00:00
|
|
|
<div id="form" class="catalog">
|
2016-01-08 21:00:02 +00:00
|
|
|
<div id="main" class="main">
|
|
|
|
<htk-repeater
|
|
|
|
id="grid-view"
|
|
|
|
empty-message="_Choose filter from right menu"
|
|
|
|
form-id="item"
|
2022-04-13 11:31:52 +00:00
|
|
|
model="items-model"
|
|
|
|
renderer="repeaterFunc">
|
2016-01-08 21:00:02 +00:00
|
|
|
<custom>
|
2022-04-13 11:31:52 +00:00
|
|
|
<div
|
|
|
|
id="item-box"
|
|
|
|
class="box item-box"
|
|
|
|
title="_AddToBasket">
|
2016-05-02 13:05:49 +00:00
|
|
|
<htk-image
|
|
|
|
directory="catalog"
|
|
|
|
subdir="200x200"
|
|
|
|
form="item"
|
2018-03-26 16:35:02 +00:00
|
|
|
column="image"
|
2019-05-27 13:38:06 +00:00
|
|
|
stamp-column="updated"
|
2018-07-20 14:30:29 +00:00
|
|
|
full-dir="1600x900"/>
|
2016-01-08 21:00:02 +00:00
|
|
|
<div class="item-info">
|
|
|
|
<h2>
|
2018-03-26 16:35:02 +00:00
|
|
|
<htk-text form="item" column="item"/>
|
2016-01-08 21:00:02 +00:00
|
|
|
</h2>
|
2018-07-20 14:30:29 +00:00
|
|
|
<p class="sub-name">
|
|
|
|
<htk-text form="item" column="subName"/>
|
2016-01-08 21:00:02 +00:00
|
|
|
</p>
|
2019-04-16 13:54:55 +00:00
|
|
|
<table class="tags">
|
|
|
|
<tr>
|
|
|
|
<td><htk-text form="item" column="tag5"/></td>
|
|
|
|
<td><htk-text form="item" column="value5"/></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td><htk-text form="item" column="tag6"/></td>
|
|
|
|
<td><htk-text form="item" column="value6"/></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td><htk-text form="item" column="tag7"/></td>
|
|
|
|
<td><htk-text form="item" column="value7"/></td>
|
|
|
|
</tr>
|
|
|
|
</table>
|
2022-04-13 13:17:43 +00:00
|
|
|
<div class="available-price">
|
|
|
|
<span class="grouping" title="_MinimalGrouping">
|
|
|
|
<htk-text form="item" column="grouping" format="x%.0d"/>
|
|
|
|
</span>
|
|
|
|
<span class="available" title="_Available">
|
|
|
|
<htk-text form="item" column="available"/>
|
|
|
|
</span>
|
|
|
|
<span class="price" title="_GroupingPrice">
|
|
|
|
<htk-text form="item" column="price" format="%.2d€"/>
|
|
|
|
</span>
|
|
|
|
</div>
|
2016-01-08 21:00:02 +00:00
|
|
|
</div>
|
2015-03-06 23:33:54 +00:00
|
|
|
</div>
|
2016-01-08 21:00:02 +00:00
|
|
|
</custom>
|
|
|
|
</htk-repeater>
|
2015-03-06 23:33:54 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
2015-09-16 16:11:15 +00:00
|
|
|
<div id="right-panel" class="right-panel" on-click="onRightPanelClick">
|
2016-01-07 12:58:29 +00:00
|
|
|
<div class="basket-info">
|
2015-03-27 19:10:49 +00:00
|
|
|
<p>
|
2018-03-26 16:35:02 +00:00
|
|
|
<htk-text form="basket" column="sent" format="%D"/>
|
2015-03-27 19:10:49 +00:00
|
|
|
</p>
|
|
|
|
<p>
|
2015-12-10 13:48:43 +00:00
|
|
|
<span id="method"/>
|
|
|
|
<htk-text form="basket" column="agency"/>
|
2015-03-27 19:10:49 +00:00
|
|
|
</p>
|
2015-12-10 13:48:43 +00:00
|
|
|
<button class="thin" on-click="onConfigureClick">
|
2015-12-10 23:24:14 +00:00
|
|
|
<t>Change</t>
|
2015-12-10 13:48:43 +00:00
|
|
|
</button>
|
|
|
|
</div>
|
2016-01-07 12:58:29 +00:00
|
|
|
<div class="filter">
|
|
|
|
<div class="categories">
|
|
|
|
<div class="realms">
|
|
|
|
<htk-repeater
|
|
|
|
model="realms-model"
|
|
|
|
form-id="realm-form"
|
|
|
|
renderer="realmRenderer"
|
|
|
|
class="realms-box">
|
|
|
|
<db-model
|
|
|
|
id="realms-model"
|
|
|
|
property="model"
|
|
|
|
on-status-changed="refreshTitleColor">
|
2021-11-17 07:36:38 +00:00
|
|
|
SELECT c.id, l.name, c.color, c.code
|
2018-03-26 16:35:02 +00:00
|
|
|
FROM vn.itemCategory c
|
|
|
|
JOIN vn.itemCategoryL10n l ON l.id = c.id
|
|
|
|
WHERE c.display
|
2019-02-12 15:40:17 +00:00
|
|
|
ORDER BY display
|
2016-01-07 12:58:29 +00:00
|
|
|
</db-model>
|
|
|
|
<custom>
|
|
|
|
<a id="link">
|
|
|
|
<img id="image"/>
|
|
|
|
</a>
|
|
|
|
</custom>
|
|
|
|
</htk-repeater>
|
|
|
|
<div class="clear"/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="realm-msg" class="realm-msg">
|
|
|
|
<h1><t>Choose a realm</t></h1>
|
|
|
|
</div>
|
|
|
|
<div id="filters" class="filters">
|
|
|
|
<h2><t>Filter by</t></h2>
|
|
|
|
<vn-filter
|
|
|
|
placeholder="_Family"
|
|
|
|
param="type">
|
|
|
|
<db-model
|
|
|
|
id="types-model"
|
|
|
|
property="model"
|
|
|
|
conn="conn"
|
|
|
|
result-index="1"
|
|
|
|
on-status-changed="refreshTitle">
|
2019-06-05 07:05:54 +00:00
|
|
|
CALL myBasket_getAvailable;
|
2018-03-26 16:35:02 +00:00
|
|
|
SELECT DISTINCT t.id, l.name
|
|
|
|
FROM vn.item i
|
|
|
|
JOIN vn.itemType t ON t.id = i.typeFk
|
2018-05-18 11:52:05 +00:00
|
|
|
JOIN tmp.itemAvailable a ON a.id = i.id
|
2018-03-26 16:35:02 +00:00
|
|
|
JOIN vn.itemTypeL10n l ON l.id = t.id
|
2019-04-16 14:39:35 +00:00
|
|
|
WHERE t.`order` >= 0 AND #filter
|
2019-04-16 13:54:55 +00:00
|
|
|
ORDER BY t.`order`, l.name
|
2016-01-07 12:58:29 +00:00
|
|
|
</db-model>
|
|
|
|
<sql-filter property="filter" type="AND">
|
|
|
|
<sql-filter-item type="EQUAL">
|
2018-03-26 16:35:02 +00:00
|
|
|
<sql-field name="categoryFk" target="t"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
<sql-value param="realm"/>
|
|
|
|
</sql-filter-item>
|
|
|
|
</sql-filter>
|
|
|
|
</vn-filter>
|
|
|
|
<vn-filter
|
|
|
|
placeholder="_Color"
|
|
|
|
param="color">
|
|
|
|
<db-model property="model" auto-load="false" result-index="1">
|
2019-06-05 07:05:54 +00:00
|
|
|
CALL myBasket_getAvailable;
|
2018-03-27 14:35:53 +00:00
|
|
|
SELECT DISTINCT l.id, l.name
|
2018-03-26 16:35:02 +00:00
|
|
|
FROM vn.item i
|
|
|
|
JOIN vn.itemType t ON t.id = i.typeFk
|
2018-05-18 11:52:05 +00:00
|
|
|
JOIN tmp.itemAvailable a ON a.id = i.id
|
2018-03-27 14:35:53 +00:00
|
|
|
JOIN vn.inkL10n l ON l.id = i.inkFk
|
2018-03-26 16:35:02 +00:00
|
|
|
WHERE #filter
|
|
|
|
ORDER BY name
|
2016-01-07 12:58:29 +00:00
|
|
|
</db-model>
|
|
|
|
<sql-filter property="filter" always-ready="true" type="AND">
|
|
|
|
<pointer object="op-realm"/>
|
|
|
|
<pointer object="op-type"/>
|
|
|
|
<pointer object="op-name"/>
|
|
|
|
<pointer object="op-origin"/>
|
|
|
|
<pointer object="op-category"/>
|
|
|
|
<pointer object="op-producer"/>
|
|
|
|
</sql-filter>
|
|
|
|
</vn-filter>
|
|
|
|
<vn-filter
|
|
|
|
placeholder="_Producer"
|
|
|
|
param="producer">
|
|
|
|
<db-model property="model" auto-load="false" result-index="1">
|
2019-06-05 07:05:54 +00:00
|
|
|
CALL myBasket_getAvailable;
|
2018-03-26 16:35:02 +00:00
|
|
|
SELECT DISTINCT p.id, p.name
|
|
|
|
FROM vn.item i
|
|
|
|
JOIN vn.itemType t ON t.id = i.typeFk
|
2018-05-18 11:52:05 +00:00
|
|
|
JOIN tmp.itemAvailable a ON a.id = i.id
|
2018-03-26 16:35:02 +00:00
|
|
|
JOIN vn.producer p ON p.id = i.producerFk
|
|
|
|
WHERE #filter
|
|
|
|
ORDER BY name
|
2016-01-07 12:58:29 +00:00
|
|
|
</db-model>
|
|
|
|
<sql-filter property="filter" always-ready="true" type="AND">
|
|
|
|
<pointer object="op-realm"/>
|
|
|
|
<pointer object="op-type"/>
|
|
|
|
<pointer object="op-name"/>
|
|
|
|
<pointer object="op-origin"/>
|
|
|
|
<pointer object="op-color"/>
|
|
|
|
<pointer object="op-category"/>
|
|
|
|
</sql-filter>
|
|
|
|
</vn-filter>
|
|
|
|
<vn-filter
|
|
|
|
placeholder="_Origin"
|
|
|
|
param="origin">
|
|
|
|
<db-model property="model" auto-load="false" result-index="1">
|
2019-06-05 07:05:54 +00:00
|
|
|
CALL myBasket_getAvailable;
|
2018-03-26 16:35:02 +00:00
|
|
|
SELECT DISTINCT o.id, l.name, o.code
|
|
|
|
FROM vn.item i
|
|
|
|
JOIN vn.itemType t ON t.id = i.typeFk
|
2018-05-18 11:52:05 +00:00
|
|
|
JOIN tmp.itemAvailable a ON a.id = i.id
|
2018-03-26 16:35:02 +00:00
|
|
|
JOIN vn.origin o ON o.id = i.originFk
|
|
|
|
JOIN vn.originL10n l ON l.id = o.id
|
|
|
|
WHERE #filter
|
|
|
|
ORDER BY name
|
2016-01-07 12:58:29 +00:00
|
|
|
</db-model>
|
|
|
|
<sql-filter property="filter" always-ready="true" type="AND">
|
|
|
|
<pointer object="op-realm"/>
|
|
|
|
<pointer object="op-type"/>
|
|
|
|
<pointer object="op-name"/>
|
|
|
|
<pointer object="op-color"/>
|
|
|
|
<pointer object="op-category"/>
|
|
|
|
<pointer object="op-producer"/>
|
|
|
|
</sql-filter>
|
|
|
|
</vn-filter>
|
|
|
|
<vn-filter
|
|
|
|
placeholder="_Category"
|
|
|
|
param="category">
|
|
|
|
<db-model property="model" auto-load="false" result-index="1">
|
2019-06-05 07:05:54 +00:00
|
|
|
CALL myBasket_getAvailable;
|
2018-03-26 16:35:02 +00:00
|
|
|
SELECT DISTINCT i.category, i.category
|
|
|
|
FROM vn.item i
|
|
|
|
JOIN vn.itemType t ON t.id = i.typeFk
|
2018-05-18 11:52:05 +00:00
|
|
|
JOIN tmp.itemAvailable a ON a.id = i.id
|
2018-03-26 16:35:02 +00:00
|
|
|
WHERE #filter
|
|
|
|
ORDER BY category
|
2016-01-07 12:58:29 +00:00
|
|
|
</db-model>
|
|
|
|
<sql-filter property="filter" always-ready="true" type="AND">
|
|
|
|
<pointer object="op-realm"/>
|
|
|
|
<pointer object="op-type"/>
|
|
|
|
<pointer object="op-name"/>
|
|
|
|
<pointer object="op-color"/>
|
|
|
|
<pointer object="op-origin"/>
|
|
|
|
<pointer object="op-producer"/>
|
|
|
|
</sql-filter>
|
|
|
|
</vn-filter>
|
|
|
|
</div>
|
|
|
|
<div id="order" class="order">
|
|
|
|
<h2><t>Order by</t></h2>
|
|
|
|
<select on-change="onOrderChange">
|
2017-06-07 14:46:58 +00:00
|
|
|
<option value="D|relevancy" selected="true">
|
2017-06-07 12:19:20 +00:00
|
|
|
<t>Relevancy</t>
|
|
|
|
</option>
|
2018-03-26 16:35:02 +00:00
|
|
|
<option value="A|item">
|
2016-01-07 12:58:29 +00:00
|
|
|
<t>Name</t>
|
|
|
|
</option>
|
|
|
|
<option value="A|price">
|
|
|
|
<t>Lower price</t>
|
|
|
|
</option>
|
|
|
|
<option value="D|price">
|
|
|
|
<t>Higher price</t>
|
|
|
|
</option>
|
|
|
|
<option value="A|available">
|
|
|
|
<t>Available</t>
|
|
|
|
</option>
|
2018-03-26 16:35:02 +00:00
|
|
|
<option value="A|size">
|
2016-01-07 12:58:29 +00:00
|
|
|
<t>Lower size</t>
|
|
|
|
</option>
|
2018-03-26 16:35:02 +00:00
|
|
|
<option value="D|size">
|
2016-01-07 12:58:29 +00:00
|
|
|
<t>Higher size</t>
|
|
|
|
</option>
|
2020-08-13 08:21:59 +00:00
|
|
|
<option value="A|ink">
|
2016-01-07 12:58:29 +00:00
|
|
|
<t>Color</t>
|
|
|
|
</option>
|
|
|
|
<option value="A|producer">
|
|
|
|
<t>Producer</t>
|
|
|
|
</option>
|
2018-03-26 16:35:02 +00:00
|
|
|
<option value="A|origin">
|
2016-01-07 12:58:29 +00:00
|
|
|
<t>Origin</t>
|
|
|
|
</option>
|
2018-03-26 16:35:02 +00:00
|
|
|
<option value="A|category">
|
2016-01-07 12:58:29 +00:00
|
|
|
<t>Category</t>
|
|
|
|
</option>
|
|
|
|
</select>
|
|
|
|
</div>
|
2015-10-14 11:51:43 +00:00
|
|
|
</div>
|
2015-03-06 23:33:54 +00:00
|
|
|
</div>
|
2016-01-07 12:58:29 +00:00
|
|
|
<htk-popup id="desc-popup">
|
|
|
|
<div
|
|
|
|
property="child-node"
|
|
|
|
class="desc-popup"
|
|
|
|
id="description"/>
|
|
|
|
</htk-popup>
|
2016-05-04 14:36:51 +00:00
|
|
|
<htk-popup
|
|
|
|
id="card-popup"
|
|
|
|
class="card-popup"
|
|
|
|
modal="true"
|
|
|
|
on-closed="onPopupClose">
|
|
|
|
<div property="child-node" class="item-card">
|
2018-03-26 16:35:02 +00:00
|
|
|
<db-form id="card-extend">
|
|
|
|
<db-model
|
|
|
|
property="model"
|
|
|
|
batch="card-batch"
|
|
|
|
on-status-changed-after="onCardLoad">
|
|
|
|
SELECT i.description, o.name origin
|
|
|
|
FROM vn.item i
|
|
|
|
LEFT JOIN vn.originL10n o ON o.id = i.originFk
|
|
|
|
WHERE i.id = #item
|
|
|
|
</db-model>
|
|
|
|
</db-form>
|
2016-05-04 14:36:51 +00:00
|
|
|
<div class="top">
|
|
|
|
<htk-image
|
|
|
|
directory="catalog"
|
|
|
|
subdir="200x200"
|
|
|
|
form="card"
|
2018-03-26 16:35:02 +00:00
|
|
|
column="image"
|
2019-05-27 13:38:06 +00:00
|
|
|
stamp-column="updated"
|
2018-07-20 14:30:29 +00:00
|
|
|
full-dir="1600x900"
|
2016-10-11 14:45:10 +00:00
|
|
|
conn="conn"
|
2016-05-04 14:36:51 +00:00
|
|
|
editable="true"/>
|
|
|
|
<div class="item-info">
|
|
|
|
<h2>
|
2018-03-26 16:35:02 +00:00
|
|
|
<htk-text form="card" column="item"/>
|
2016-05-04 14:36:51 +00:00
|
|
|
</h2>
|
2018-07-20 14:30:29 +00:00
|
|
|
<p class="sub-name">
|
|
|
|
<htk-text form="card" column="subName"/>
|
2016-05-04 14:36:51 +00:00
|
|
|
</p>
|
2017-11-26 14:16:56 +00:00
|
|
|
<p>
|
2018-04-09 12:43:21 +00:00
|
|
|
@<htk-text form="card" column="id"/>
|
2017-11-26 14:16:56 +00:00
|
|
|
</p>
|
2016-05-04 14:36:51 +00:00
|
|
|
<p>
|
2018-03-27 14:35:53 +00:00
|
|
|
<htk-text form="card" column="stems" format="_%.0d Units"/>
|
2016-05-04 14:36:51 +00:00
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
<p class="desc">
|
|
|
|
<htk-text form="card-extend" column="description" id="desc"/>
|
|
|
|
</p>
|
2018-03-27 14:35:53 +00:00
|
|
|
<htk-repeater show-status="false" form-id="tag" class="tags">
|
|
|
|
<db-model
|
|
|
|
property="model"
|
|
|
|
batch="card-batch"
|
|
|
|
on-status-changed-after="onCardLoad">
|
|
|
|
SELECT l.name, it.value
|
|
|
|
FROM vn.itemTag it
|
|
|
|
JOIN vn.tag t ON t.id = it.tagFk
|
|
|
|
JOIN vn.tagL10n l ON l.id = t.id
|
|
|
|
WHERE it.itemFk = #item
|
2018-07-20 14:30:29 +00:00
|
|
|
AND priority >= 0
|
2018-06-20 11:45:55 +00:00
|
|
|
ORDER BY it.priority
|
2018-03-27 14:35:53 +00:00
|
|
|
</db-model>
|
|
|
|
<custom>
|
2018-07-20 14:30:29 +00:00
|
|
|
<tr>
|
|
|
|
<td><htk-text form="tag" column="name"/></td>
|
|
|
|
<td><htk-text form="tag" column="value"/></td>
|
|
|
|
</tr>
|
2018-03-27 14:35:53 +00:00
|
|
|
</custom>
|
|
|
|
</htk-repeater>
|
2016-05-04 14:36:51 +00:00
|
|
|
</div>
|
2018-03-26 16:35:02 +00:00
|
|
|
<htk-grid class="lots-grid" show-header="false">
|
|
|
|
<db-model
|
|
|
|
id="item-lots"
|
|
|
|
property="model"
|
|
|
|
result-index="1"
|
|
|
|
on-status-changed-after="onCardLoad"
|
|
|
|
batch="card-batch">
|
2019-06-05 07:05:54 +00:00
|
|
|
CALL myBasket_calcCatalogFromItem(#item);
|
2019-09-16 08:09:41 +00:00
|
|
|
SELECT l.warehouseFk, w.name warehouse, p.`grouping`,
|
|
|
|
p.price, p.priceKg, p.rate, l.available
|
2019-06-05 07:05:54 +00:00
|
|
|
FROM tmp.ticketLot l
|
|
|
|
JOIN tmp.ticketComponentPrice p ON p.warehouseFk = l.warehouseFk
|
|
|
|
JOIN vn.warehouse w ON w.id = p.warehouseFk
|
2019-03-01 14:17:50 +00:00
|
|
|
ORDER BY warehouseFk, `grouping`;
|
2018-03-26 16:35:02 +00:00
|
|
|
</db-model>
|
2019-09-16 08:09:41 +00:00
|
|
|
<htk-column-spin column="price" unit="€" digits="2"/>
|
|
|
|
<htk-column-spin column="priceKg" unit="€/kg" digits="3" class="price-kg"/>
|
|
|
|
<htk-column-text column="grouping" format="x%.0d"/>
|
2016-01-07 12:58:29 +00:00
|
|
|
<htk-column-button
|
|
|
|
column="id"
|
2016-09-26 09:28:47 +00:00
|
|
|
icon="add"
|
2016-01-07 12:58:29 +00:00
|
|
|
tip="_Add"
|
|
|
|
on-clicked="onAddLotClick"/>
|
|
|
|
</htk-grid>
|
2016-01-15 12:31:08 +00:00
|
|
|
<div class="footer">
|
2016-01-07 12:58:29 +00:00
|
|
|
<button on-click="onEraseClick" title="_Erase" class="erase">
|
2016-09-26 09:28:47 +00:00
|
|
|
<htk-icon
|
|
|
|
icon="delete"
|
|
|
|
theme="dark"
|
2016-01-07 12:58:29 +00:00
|
|
|
alt="_Erase"/>
|
|
|
|
</button>
|
|
|
|
<htk-text id="amount"/>
|
|
|
|
<button on-click="onConfirmClick" title="_Confirm" class="confirm">
|
2016-09-26 09:28:47 +00:00
|
|
|
<htk-icon
|
|
|
|
icon="ok"
|
|
|
|
theme="dark"
|
2016-01-07 12:58:29 +00:00
|
|
|
alt="_Confirm"/>
|
|
|
|
</button>
|
|
|
|
<div class="clear"/>
|
|
|
|
</div>
|
2015-03-27 19:10:49 +00:00
|
|
|
</div>
|
2016-01-07 12:58:29 +00:00
|
|
|
</htk-popup>
|
2015-03-06 23:33:54 +00:00
|
|
|
</vn>
|