Tags disaplayed in tickets and orders
This commit is contained in:
parent
3b14d419d6
commit
0313b8729f
|
@ -20,23 +20,23 @@ Hedera.Basket = new Class
|
||||||
|
|
||||||
,activate: function ()
|
,activate: function ()
|
||||||
{
|
{
|
||||||
this.$('items').setInfo ('i', 'basket_item', 'hedera');
|
this.$('items').setInfo ('bi', 'myBasketItem', 'hedera');
|
||||||
}
|
}
|
||||||
|
|
||||||
,onConfigureClick: function ()
|
,onConfigureClick: function ()
|
||||||
{
|
{
|
||||||
Htk.Toast.showWarning (_('RememberReconfiguringImpact'));
|
Htk.Toast.showWarning (_('RememberReconfiguringImpact'));
|
||||||
this.hash.set ({'form': 'ecomerce/checkout'});
|
this.hash.set ({form: 'ecomerce/checkout'});
|
||||||
}
|
}
|
||||||
|
|
||||||
,onCatalogClick: function ()
|
,onCatalogClick: function ()
|
||||||
{
|
{
|
||||||
this.hash.set ({'form': 'ecomerce/catalog'});
|
this.hash.set ({form: 'ecomerce/catalog'});
|
||||||
}
|
}
|
||||||
|
|
||||||
,onCheckoutClick: function ()
|
,onCheckoutClick: function ()
|
||||||
{
|
{
|
||||||
this.hash.set ({'form': 'ecomerce/confirm'});
|
this.hash.set ({form: 'ecomerce/confirm'});
|
||||||
}
|
}
|
||||||
|
|
||||||
,repeaterFunc: function (res, form)
|
,repeaterFunc: function (res, form)
|
||||||
|
|
|
@ -42,7 +42,7 @@
|
||||||
.basket .line > .delete
|
.basket .line > .delete
|
||||||
{
|
{
|
||||||
margin: -0.5em;
|
margin: -0.5em;
|
||||||
margin-top: .3em;
|
margin-top: 1em;
|
||||||
margin-right: .5em;
|
margin-right: .5em;
|
||||||
float: left;
|
float: left;
|
||||||
}
|
}
|
||||||
|
@ -51,14 +51,28 @@
|
||||||
margin-right: 1em;
|
margin-right: 1em;
|
||||||
float: left;
|
float: left;
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
height: 3.2em;
|
height: 4.25em;
|
||||||
width: 3.2em;
|
width: 4.25em;
|
||||||
}
|
}
|
||||||
.basket .line > p
|
.basket .line > .info
|
||||||
{
|
{
|
||||||
margin: .1em 0;
|
|
||||||
margin-left: 7.5em;
|
margin-left: 7.5em;
|
||||||
}
|
}
|
||||||
|
.basket .line > .info > h2
|
||||||
|
{
|
||||||
|
font-size: 1em;
|
||||||
|
font-weight: normal;
|
||||||
|
padding: 0;
|
||||||
|
padding-bottom: .1em;
|
||||||
|
}
|
||||||
|
.basket .line > .info > p
|
||||||
|
{
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
.basket .line > .info > .tags
|
||||||
|
{
|
||||||
|
color: #777;
|
||||||
|
}
|
||||||
.basket .line .subtotal
|
.basket .line .subtotal
|
||||||
{
|
{
|
||||||
float: right;
|
float: right;
|
||||||
|
|
|
@ -29,42 +29,48 @@
|
||||||
<div class="lines">
|
<div class="lines">
|
||||||
<htk-repeater form-id="iter" renderer="repeaterFunc">
|
<htk-repeater form-id="iter" renderer="repeaterFunc">
|
||||||
<db-model id="items" property="model" updatable="true">
|
<db-model id="items" property="model" updatable="true">
|
||||||
<custom>
|
SELECT bi.id, bi.amount, bi.price, i.name item, i.image
|
||||||
SELECT i.id, i.amount, i.price, a.Article, a.Categoria,
|
t.tag1, t.val1, t.tag2, t.val2, t.tag3, t.val3
|
||||||
a.Medida, a.Tallos, a.Color, o.Abreviatura, a.Foto
|
FROM myBasketItem bi
|
||||||
FROM basket_item i
|
JOIN vn.item i ON i.id = bi.itemFk
|
||||||
JOIN vn2008.Articles a ON a.Id_Article = i.item_id
|
LEFT JOIN vn.itemTagArranged t ON t.itemFk = i.id
|
||||||
LEFT JOIN vn2008.Origen o ON a.id_origen = o.id
|
|
||||||
</custom>
|
|
||||||
</db-model>
|
</db-model>
|
||||||
<custom>
|
<custom>
|
||||||
<div class="line">
|
<div class="line">
|
||||||
<htk-button
|
<htk-button
|
||||||
form="iter"
|
form="iter"
|
||||||
column="ticket_id"
|
column="id"
|
||||||
class="delete"
|
class="delete"
|
||||||
tip="_Remove"
|
tip="_Remove"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
on-click="onDeleteClick"/>
|
on-click="onDeleteClick"/>
|
||||||
<htk-image
|
<htk-image
|
||||||
form="iter"
|
form="iter"
|
||||||
column="Foto"
|
column="image"
|
||||||
class="photo"
|
class="photo"
|
||||||
directory="catalog"
|
directory="catalog"
|
||||||
subdir="200x200"
|
subdir="200x200"
|
||||||
full-dir="900x900"/>
|
full-dir="900x900"/>
|
||||||
<p class="concept">
|
<div class="info">
|
||||||
<htk-text form="iter" column="Article"/>
|
<h2>
|
||||||
<htk-text form="iter" column="Medida"/>
|
<htk-text form="iter" column="item"/>
|
||||||
<htk-text form="iter" column="Categoria"/>
|
</h2>
|
||||||
</p>
|
<p class="tags">
|
||||||
<p class="amount">
|
<htk-text form="iter" column="tag1"/>
|
||||||
<htk-text form="iter" column="amount"/> x
|
<htk-text form="iter" column="val1"/>,
|
||||||
<htk-text form="iter" column="price" format="%.2d€"/>
|
<htk-text form="iter" column="tag2"/>
|
||||||
<span class="subtotal">
|
<htk-text form="iter" column="val2"/>,
|
||||||
<htk-text id="subtotal" format="%.2d€"/>
|
<htk-text form="iter" column="tag3"/>
|
||||||
</span>
|
<htk-text form="iter" column="val3"/>
|
||||||
</p>
|
</p>
|
||||||
|
<p class="amount">
|
||||||
|
<htk-text form="iter" column="amount"/> x
|
||||||
|
<htk-text form="iter" column="price" format="%.2d€"/>
|
||||||
|
<span class="subtotal">
|
||||||
|
<htk-text id="subtotal" format="%.2d€"/>
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
<div class="clear"/>
|
<div class="clear"/>
|
||||||
</div>
|
</div>
|
||||||
</custom>
|
</custom>
|
||||||
|
|
|
@ -50,27 +50,42 @@
|
||||||
|
|
||||||
/* Lines */
|
/* Lines */
|
||||||
|
|
||||||
|
.ticket .line
|
||||||
|
{
|
||||||
|
padding: .5em 0;
|
||||||
|
}
|
||||||
.ticket .line > .photo
|
.ticket .line > .photo
|
||||||
{
|
{
|
||||||
margin-right: 1em;
|
margin-right: 1em;
|
||||||
float: left;
|
float: left;
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
height: 3.2em;
|
height: 4.25em;
|
||||||
width: 3.2em;
|
width: 4.25em;
|
||||||
}
|
}
|
||||||
.ticket .line
|
.ticket .line > .info
|
||||||
{
|
{
|
||||||
padding: .5em 0;
|
margin-left: 5.25em;
|
||||||
}
|
}
|
||||||
.ticket .line p
|
.ticket .line > .info > h2
|
||||||
{
|
{
|
||||||
margin: .1em 0;
|
font-size: 1em;
|
||||||
|
font-weight: normal;
|
||||||
|
padding: 0;
|
||||||
|
padding-bottom: .1em;
|
||||||
}
|
}
|
||||||
.ticket .amount
|
.ticket .line > .info > p
|
||||||
|
{
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
.ticket .line > .info > .tags
|
||||||
|
{
|
||||||
|
color: #777;
|
||||||
|
}
|
||||||
|
.ticket .line > .info > .amount
|
||||||
{
|
{
|
||||||
float: left;
|
float: left;
|
||||||
}
|
}
|
||||||
.ticket .subtotal
|
.ticket .line > .info > .subtotal
|
||||||
{
|
{
|
||||||
float: right;
|
float: right;
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,9 +9,7 @@
|
||||||
</sql-batch>
|
</sql-batch>
|
||||||
<db-form id="ticket" on-ready="onTicketReady">
|
<db-form id="ticket" on-ready="onTicketReady">
|
||||||
<db-model id="ticket-data" property="model" batch="batch">
|
<db-model id="ticket-data" property="model" batch="batch">
|
||||||
<custom>
|
CALL myTicketGet (#ticket)
|
||||||
CALL myTicketGet (#ticket)
|
|
||||||
</custom>
|
|
||||||
</db-model>
|
</db-model>
|
||||||
</db-form>
|
</db-form>
|
||||||
</vn-group>
|
</vn-group>
|
||||||
|
@ -67,9 +65,7 @@
|
||||||
property="model"
|
property="model"
|
||||||
id="movements"
|
id="movements"
|
||||||
batch="batch">
|
batch="batch">
|
||||||
<custom>
|
CALL myTicketGetRows (#ticket)
|
||||||
CALL myTicketGetRows (#ticket)
|
|
||||||
</custom>
|
|
||||||
</db-model>
|
</db-model>
|
||||||
<custom>
|
<custom>
|
||||||
<div class="line">
|
<div class="line">
|
||||||
|
@ -80,18 +76,26 @@
|
||||||
directory="catalog"
|
directory="catalog"
|
||||||
subdir="200x200"
|
subdir="200x200"
|
||||||
full-dir="900x900"/>
|
full-dir="900x900"/>
|
||||||
<p class="concept">
|
<div class="info">
|
||||||
<htk-text form="iter" column="concept"/>
|
<h2>
|
||||||
<htk-text form="iter" column="size"/>
|
<htk-text form="iter" column="concept"/>
|
||||||
<htk-text form="iter" column="category"/>
|
</h2>
|
||||||
</p>
|
<p class="tags">
|
||||||
<p class="amount">
|
<htk-text form="iter" column="tag1"/>
|
||||||
<htk-text form="iter" column="quantity"/> x
|
<htk-text form="iter" column="val1"/>,
|
||||||
<htk-text form="iter" column="price" format="%.2d€"/>
|
<htk-text form="iter" column="tag2"/>
|
||||||
</p>
|
<htk-text form="iter" column="val2"/>,
|
||||||
<p class="subtotal">
|
<htk-text form="iter" column="tag3"/>
|
||||||
<htk-text id="subtotal" format="%.2d€"/>
|
<htk-text form="iter" column="val3"/>
|
||||||
</p>
|
</p>
|
||||||
|
<p class="amount">
|
||||||
|
<htk-text form="iter" column="quantity"/> x
|
||||||
|
<htk-text form="iter" column="price" format="%.2d€"/>
|
||||||
|
</p>
|
||||||
|
<p class="subtotal">
|
||||||
|
<htk-text id="subtotal" format="%.2d€"/>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
<div class="clear"/>
|
<div class="clear"/>
|
||||||
</div>
|
</div>
|
||||||
</custom>
|
</custom>
|
||||||
|
@ -101,9 +105,7 @@
|
||||||
property="model"
|
property="model"
|
||||||
on-status-changed="onPackagesChanged"
|
on-status-changed="onPackagesChanged"
|
||||||
batch="batch">
|
batch="batch">
|
||||||
<custom>
|
CALL myTicketGetPackages (#ticket)
|
||||||
CALL myTicketGetPackages (#ticket)
|
|
||||||
</custom>
|
|
||||||
</db-model>
|
</db-model>
|
||||||
<custom>
|
<custom>
|
||||||
<div class="line">
|
<div class="line">
|
||||||
|
|
|
@ -2,9 +2,7 @@
|
||||||
<vn-group>
|
<vn-group>
|
||||||
<db-form id="ticket" on-ready="onTicketReady">
|
<db-form id="ticket" on-ready="onTicketReady">
|
||||||
<db-model property="model" id="ticket-data" conn="conn" batch="batch">
|
<db-model property="model" id="ticket-data" conn="conn" batch="batch">
|
||||||
<custom>
|
CALL myTicketGet (#ticket)
|
||||||
CALL myTicketGet (#ticket)
|
|
||||||
</custom>
|
|
||||||
</db-model>
|
</db-model>
|
||||||
</db-form>
|
</db-form>
|
||||||
</vn-group>
|
</vn-group>
|
||||||
|
@ -37,9 +35,7 @@
|
||||||
</div>
|
</div>
|
||||||
<htk-grid>
|
<htk-grid>
|
||||||
<db-model property="model" id="movements" conn="conn" batch="batch">
|
<db-model property="model" id="movements" conn="conn" batch="batch">
|
||||||
<custom>
|
CALL myTicketGetRows (#ticket)
|
||||||
CALL myTicketGetRows (#ticket)
|
|
||||||
</custom>
|
|
||||||
</db-model>
|
</db-model>
|
||||||
<htk-column-spin title="_Ref" column="itemFk"/>
|
<htk-column-spin title="_Ref" column="itemFk"/>
|
||||||
<htk-column-spin title="_Amount" column="quantity"/>
|
<htk-column-spin title="_Amount" column="quantity"/>
|
||||||
|
@ -64,9 +60,7 @@
|
||||||
conn="conn"
|
conn="conn"
|
||||||
batch="batch"
|
batch="batch"
|
||||||
on-status-changed="onPackagesChanged">
|
on-status-changed="onPackagesChanged">
|
||||||
<custom>
|
CALL myTicketGetPackages (#ticket)
|
||||||
CALL myTicketGetPackages (#ticket)
|
|
||||||
</custom>
|
|
||||||
</db-model>
|
</db-model>
|
||||||
<htk-column-spin title="_Ref" column="id"/>
|
<htk-column-spin title="_Ref" column="id"/>
|
||||||
<htk-column-spin title="_Amount" column="quantity"/>
|
<htk-column-spin title="_Amount" column="quantity"/>
|
||||||
|
|
Loading…
Reference in New Issue