Descriptor style fixes

This commit is contained in:
Juan Ferrer 2019-01-21 15:21:24 +01:00
parent 6e43b11e16
commit 09811d322a
18 changed files with 375 additions and 343 deletions

View File

@ -2,12 +2,19 @@
import Nightmare from 'nightmare'; import Nightmare from 'nightmare';
export default function createNightmare(width = 1280, height = 720) { export default function createNightmare(width = 1280, height = 720) {
const nightmare = new Nightmare({show: process.env.E2E_SHOW, typeInterval: 10, x: 0, y: 0, waitTimeout: 2000}) const nightmare = new Nightmare({
.viewport(width, height); show: process.env.E2E_SHOW,
typeInterval: 10,
x: 0,
y: 0,
waitTimeout: 2000
}).viewport(width, height);
nightmare.on('console', (type, message) => { nightmare.on('console', (type, message, ...args) => {
if (type === 'error') if (type === 'error')
fail(message); fail(message);
else
console[type](message, ...args);
}); });
nightmare.header('Accept-Language', 'en'); nightmare.header('Accept-Language', 'en');

View File

@ -35,7 +35,7 @@ export default {
cancelButton: `vn-button[href="#!/client/index"]` cancelButton: `vn-button[href="#!/client/index"]`
}, },
clientDescriptor: { clientDescriptor: {
moreMenu: `vn-client-descriptor > vn-card > div vn-icon-menu > div > vn-icon`, moreMenu: `vn-client-descriptor vn-icon-menu > div > vn-icon`,
simpleTicketButton: 'vn-client-descriptor vn-popover > div > div.content > div > div.list > ul > li' simpleTicketButton: 'vn-client-descriptor vn-popover > div > div.content > div > div.list > ul > li'
}, },
clientBasicData: { clientBasicData: {
@ -189,7 +189,7 @@ export default {
cancelButton: `button[ui-sref="item.index"]` cancelButton: `button[ui-sref="item.index"]`
}, },
itemDescriptor: { itemDescriptor: {
moreMenu: `vn-item-descriptor > vn-card > div vn-icon-menu > div > vn-icon`, moreMenu: `vn-item-descriptor vn-icon-menu > div > vn-icon`,
moreMenuRegularizeButton: `vn-item-descriptor vn-icon-menu > div > vn-drop-down > vn-popover ul > li:nth-child(1)`, moreMenuRegularizeButton: `vn-item-descriptor vn-icon-menu > div > vn-drop-down > vn-popover ul > li:nth-child(1)`,
regularizeQuantityInput: `vn-item-descriptor > vn-dialog > div > form > div.body > tpl-body > div > vn-textfield > div > div > div.infix > input`, regularizeQuantityInput: `vn-item-descriptor > vn-dialog > div > form > div.body > tpl-body > div > vn-textfield > div > div > div.infix > input`,
regularizeWarehouseAutocomplete: `#warehouse`, regularizeWarehouseAutocomplete: `#warehouse`,
@ -303,7 +303,7 @@ export default {
createButton: `${components.vnSubmit}` createButton: `${components.vnSubmit}`
}, },
ticketDescriptor: { ticketDescriptor: {
moreMenu: `vn-ticket-descriptor > vn-card > div vn-icon-menu > div > vn-icon`, moreMenu: `vn-ticket-descriptor vn-icon-menu > div > vn-icon`,
moreMenuAddToTurn: `vn-ticket-descriptor vn-icon-menu > div > vn-drop-down > vn-popover ul > li:nth-child(1)`, moreMenuAddToTurn: `vn-ticket-descriptor vn-icon-menu > div > vn-drop-down > vn-popover ul > li:nth-child(1)`,
moreMenuDeleteTicket: `vn-ticket-descriptor vn-icon-menu > div > vn-drop-down > vn-popover ul > li:nth-child(2)`, moreMenuDeleteTicket: `vn-ticket-descriptor vn-icon-menu > div > vn-drop-down > vn-popover ul > li:nth-child(2)`,
acceptDeleteTicketButton: `vn-ticket-descriptor button[response="ACCEPT"]`, acceptDeleteTicketButton: `vn-ticket-descriptor button[response="ACCEPT"]`,
@ -338,7 +338,7 @@ export default {
saleDescriptorPopover: 'vn-ticket-sale vn-item-descriptor-popover > vn-popover', saleDescriptorPopover: 'vn-ticket-sale vn-item-descriptor-popover > vn-popover',
saleDescriptorPopoverSummaryButton: 'vn-item-descriptor-popover a[href="#!/item/1/summary"]', saleDescriptorPopoverSummaryButton: 'vn-item-descriptor-popover a[href="#!/item/1/summary"]',
saleButton: `vn-left-menu a[ui-sref="ticket.card.sale"]`, saleButton: `vn-left-menu a[ui-sref="ticket.card.sale"]`,
descriptorItemDiaryButton: `vn-item-descriptor > vn-card > div > vn-horizontal.quicklinks.ng-scope > vn-horizontal > a > vn-icon > i`, descriptorItemDiaryButton: `vn-item-descriptor .quicklinks.ng-scope > vn-horizontal > a > vn-icon > i`,
newItemButton: 'vn-float-button[icon="add"]', newItemButton: 'vn-float-button[icon="add"]',
firstSaleText: `vn-table div > vn-tbody > vn-tr:nth-child(1)`, firstSaleText: `vn-table div > vn-tbody > vn-tr:nth-child(1)`,
firstSaleThumbnailImage: 'vn-ticket-sale:nth-child(1) vn-td:nth-child(3) > img', firstSaleThumbnailImage: 'vn-ticket-sale:nth-child(1) vn-td:nth-child(3) > img',

View File

@ -154,7 +154,7 @@ export default class ArrayModel extends ModelProxy {
let aType = typeof a; let aType = typeof a;
if (aType === typeof b) if (aType === typeof b) {
switch (aType) { switch (aType) {
case 'string': case 'string':
return a.localeCompare(b); return a.localeCompare(b);
@ -166,6 +166,7 @@ export default class ArrayModel extends ModelProxy {
if (a instanceof Date && b instanceof Date) if (a instanceof Date && b instanceof Date)
return a.getTime() - b.getTime(); return a.getTime() - b.getTime();
} }
}
if (a === undefined) if (a === undefined)
return -1; return -1;
@ -183,11 +184,12 @@ export default class ArrayModel extends ModelProxy {
let mergedWhere = []; let mergedWhere = [];
let wheres = [dst.where, src.where]; let wheres = [dst.where, src.where];
for (let where of wheres) for (let where of wheres) {
if (Array.isArray(where)) if (Array.isArray(where))
mergedWhere = mergedWhere.concat(where); mergedWhere = mergedWhere.concat(where);
else if (where) else if (where)
mergedWhere.push(where); mergedWhere.push(where);
}
switch (mergedWhere.length) { switch (mergedWhere.length) {
case 0: case 0:

View File

@ -1,13 +1,13 @@
<div class="button-menu"> <div class="button-menu">
<button <button
class="mdl-button mdl-js-button mdl-button--raised mdl-button--colored button-menu__button" class="mdl-button mdl-js-button mdl-button--raised mdl-button--colored button-menu__button">
ng-click="$ctrl.onClick($event)">
<vn-label vn-none translate>{{::$ctrl.label}}</vn-label> <vn-label vn-none translate>{{::$ctrl.label}}</vn-label>
<vn-icon vn-none icon="{{::$ctrl.icon}}"></vn-icon> <vn-icon vn-none icon="{{::$ctrl.icon}}"></vn-icon>
<vn-icon vn-none class="button-menu__arrow_down" icon="keyboard_arrow_down"></vn-icon> <vn-icon vn-none class="button-menu__arrow_down" icon="keyboard_arrow_down"></vn-icon>
</button> </button>
<vn-drop-down <vn-drop-down
vn-id="drop-down" vn-id="drop-down"
on-select="$ctrl.onDropDownSelect(value)"> on-select="$ctrl.onDropDownSelect(value)"
ng-click="$ctrl.onDropDownClick($event)">
</vn-drop-down> </vn-drop-down>
</div> </div>

View File

@ -8,6 +8,7 @@ export default class ButtonMenu extends Input {
super($element, $scope); super($element, $scope);
this.$transclude = $transclude; this.$transclude = $transclude;
this.input = this.element.querySelector('.mdl-button'); this.input = this.element.querySelector('.mdl-button');
$element.on('click', e => this.onClick(e));
} }
get model() { get model() {
@ -42,11 +43,16 @@ export default class ButtonMenu extends Input {
} }
onClick(event) { onClick(event) {
if (event.defaultPrevented) return;
event.preventDefault(); event.preventDefault();
this.emit('open'); this.emit('open');
this.showDropDown(); this.showDropDown();
} }
onDropDownClick(event) {
event.preventDefault();
}
onDropDownSelect(value) { onDropDownSelect(value) {
this.field = value; this.field = value;
this.emit('change', {value}); this.emit('change', {value});
@ -70,7 +76,7 @@ export default class ButtonMenu extends Input {
'limit', 'limit',
'searchFunction' 'searchFunction'
]); ]);
this.$.dropDown.show(this.input); this.$.dropDown.show(this.element);
} }
} }
ButtonMenu.$inject = ['$element', '$scope', '$transclude']; ButtonMenu.$inject = ['$element', '$scope', '$transclude'];

View File

@ -1,5 +1,7 @@
vn-button-menu { vn-button-menu {
position: relative; position: relative;
cursor: pointer;
.button-menu__button { .button-menu__button {
padding: 0 10px; padding: 0 10px;
} }

View File

@ -110,8 +110,8 @@ export default class DropDown extends Component {
show(parent, search) { show(parent, search) {
this._activeOption = -1; this._activeOption = -1;
this.search = search; this.search = search;
this.buildList();
this.$.popover.show(parent || this.parent); this.$.popover.show(parent || this.parent);
this.buildList();
} }
/** /**
@ -218,6 +218,7 @@ export default class DropDown extends Component {
} }
onLoadMoreClick(event) { onLoadMoreClick(event) {
if (event.defaultPrevented) return;
event.preventDefault(); event.preventDefault();
this.model.loadMore(); this.model.loadMore();
} }
@ -225,7 +226,10 @@ export default class DropDown extends Component {
onContainerClick(event) { onContainerClick(event) {
if (event.defaultPrevented) return; if (event.defaultPrevented) return;
let index = getPosition(this.ul, event); let index = getPosition(this.ul, event);
if (index != -1) this.selectOption(index); if (index != -1) {
event.preventDefault();
this.selectOption(index);
}
} }
onDocKeyDown(event) { onDocKeyDown(event) {

View File

@ -1,14 +1,11 @@
<div class="icon-menu"> <div class="icon-menu">
<vn-icon <vn-icon
pointer
class="button" class="button"
ng-click="$ctrl.onClick($event)"
vn-none
icon="{{::$ctrl.icon}}"> icon="{{::$ctrl.icon}}">
</vn-icon> </vn-icon>
<vn-drop-down <vn-drop-down
vn-id="drop-down" vn-id="drop-down"
on-select="$ctrl.onDropDownSelect(value)"> on-select="$ctrl.onDropDownSelect(value)"
ng-click="$ctrl.onDropDownClick($event)">
</vn-drop-down> </vn-drop-down>
</div> </div>

View File

@ -1,4 +1,6 @@
vn-icon-menu { vn-icon-menu {
cursor: pointer;
vn-drop-down { vn-drop-down {
font-family: 'vn-font' font-family: 'vn-font'
} }

View File

@ -6,6 +6,7 @@
left: 0; left: 0;
right: 0; right: 0;
bottom: 0; bottom: 0;
color: initial;
opacity: 0; opacity: 0;
transform: translateY(-.6em); transform: translateY(-.6em);

View File

@ -188,63 +188,74 @@ vn-main-block {
} }
.vn-descriptor { .vn-descriptor {
.header { box-shadow: 0 .1em .2em rgba(1, 1, 1, .2);
& > .header {
display: flex;
background: $main-01; background: $main-01;
color: white; color: white;
justify-content: space-between; justify-content: space-between;
align-items: stretch; align-items: stretch;
color: white;
& > vn-icon { & > * {
padding: .1em; min-width: 1.8em;
font-size: 2.5em;
}
& > a , & > vn-icon-menu {
@extend %clickable; @extend %clickable;
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center;
padding: .5em; padding: .5em;
color: white;
text-decoration: none;
& > vn-icon { & > vn-icon {
font-size: 1.8em; font-size: 1.8em;
} }
}
}
& > .body {
@extend .pad-small;
& vn-drop-down{ & > * {
color: initial; @extend .pad-small;
} }
} & > .icons {
} display: flex;
.footer { align-items: center;
text-align: center; justify-content: center;
padding: 0;
& > vn-icon { & > vn-icon {
@extend .pad-small;
color: #666; color: #666;
opacity: .4; opacity: .4;
padding: 0 5% 0 5%;
font-size: 1.5em; font-size: 1.5em;
}
& > vn-icon.bright { &.bright {
color: $main-01; color: $main-01;
opacity: 1; opacity: 1;
} }
} }
}
.quicklinks { & > .quicklinks {
justify-content: center; display: flex;
align-items: center; align-items: center;
justify-content: center;
padding: 0;
& > a { & > a {
@extend .pad-small;
& > vn-icon { & > vn-icon {
font-size: 1.8em; font-size: 1.8em;
padding: 0; padding: 0;
}
& > vn-icon i { & > i {
line-height: 36px line-height: 36px
} }
} }
} }
} }
}
}
.vn-list { .vn-list {
max-width: 36em; max-width: 36em;

View File

@ -49,17 +49,12 @@
vn-label-value > section { vn-label-value > section {
margin-bottom: .3em; margin-bottom: .3em;
& > vn-label { & > vn-label::after {
display: block;
font-size: .9em;
&::after {
content: initial; content: initial;
} }
} }
} }
} }
}
p:after { p:after {
content: ' '; content: ' ';
overflow: hidden; overflow: hidden;

View File

@ -1,4 +1,4 @@
<vn-card class="vn-descriptor"> <div class="vn-descriptor">
<vn-horizontal class="header"> <vn-horizontal class="header">
<a translate-attr="{title: 'Return to module index'}" ui-sref="zone.index"> <a translate-attr="{title: 'Return to module index'}" ui-sref="zone.index">
<vn-icon icon="chevron_left"></vn-icon> <vn-icon icon="chevron_left"></vn-icon>
@ -14,7 +14,7 @@
on-change="$ctrl.onMoreChange(value)"> on-change="$ctrl.onMoreChange(value)">
</vn-icon-menu> </vn-icon-menu>
</vn-horizontal> </vn-horizontal>
<vn-horizontal pad-medium> <div class="body">
<vn-one> <vn-one>
<vn-label-value label="Id" <vn-label-value label="Id"
value="{{::$ctrl.zone.id}}"> value="{{::$ctrl.zone.id}}">
@ -43,9 +43,8 @@
value="{{::$ctrl.zone.price | currency: '€': 2}}"> value="{{::$ctrl.zone.price | currency: '€': 2}}">
</vn-label-value> </vn-label-value>
</vn-one> </vn-one>
</vn-horizontal> </div>
</vn-card> </div>
<vn-confirm <vn-confirm
vn-id="delete-zone" vn-id="delete-zone"
on-response="$ctrl.returnDialog(response)" on-response="$ctrl.returnDialog(response)"

View File

@ -1,15 +1,15 @@
<vn-card class="vn-descriptor"> <div class="vn-descriptor">
<vn-horizontal class="header"> <div class="header">
<a translate-attr="{title: 'Return to module index'}" ui-sref="claim.index"> <a translate-attr="{title: 'Return to module index'}" ui-sref="claim.index">
<vn-icon icon="chevron_left"></vn-icon> <vn-icon icon="chevron_left"></vn-icon>
</a> </a>
<vn-icon icon=""></vn-icon>
<a translate-attr="{title: 'Preview'}" ui-sref="claim.card.summary({id: $ctrl.claim.id})"> <a translate-attr="{title: 'Preview'}" ui-sref="claim.card.summary({id: $ctrl.claim.id})">
<vn-icon icon="desktop_windows"></vn-icon> <vn-icon icon="desktop_windows"></vn-icon>
</a> </a>
</vn-horizontal> <div></div>
<vn-vertical> </div>
<vn-auto pad-medium> <div class="body">
<div class="attributes">
<h5>{{$ctrl.claim.id}}</h5> <h5>{{$ctrl.claim.id}}</h5>
<vn-label-value label="Client" <vn-label-value label="Client"
value="{{::$ctrl.claim.client.name}}"> value="{{::$ctrl.claim.client.name}}">
@ -29,10 +29,9 @@
<vn-label-value label="Ticket" ui-sref="ticket.card.summary({id: $ctrl.claim.ticketFk})" class="link" <vn-label-value label="Ticket" ui-sref="ticket.card.summary({id: $ctrl.claim.ticketFk})" class="link"
value="{{$ctrl.claim.ticketFk}}"> value="{{$ctrl.claim.ticketFk}}">
</vn-label-value> </vn-label-value>
</vn-auto> </div>
</vn-vertical> <div class="quicklinks">
<vn-horizontal pad-small class="quicklinks"> <a ng-if="$ctrl.quicklinks.btnOne"
<a ng-if="$ctrl.quicklinks.btnOne" pad-small-right
vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank">
<vn-icon <vn-icon
@ -40,7 +39,7 @@
icon="{{::$ctrl.quicklinks.btnOne.icon}}"> icon="{{::$ctrl.quicklinks.btnOne.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnTwo" pad-small-right <a ng-if="$ctrl.quicklinks.btnTwo"
vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank">
<vn-icon <vn-icon
@ -48,7 +47,7 @@
icon="{{::$ctrl.quicklinks.btnTwo.icon}}"> icon="{{::$ctrl.quicklinks.btnTwo.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnThree" pad-small-right <a ng-if="$ctrl.quicklinks.btnThree"
vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank">
<vn-icon <vn-icon
@ -56,5 +55,6 @@
icon="{{::$ctrl.quicklinks.btnThree.icon}}"> icon="{{::$ctrl.quicklinks.btnThree.icon}}">
</vn-icon> </vn-icon>
</a> </a>
</vn-horizontal> </div>
</vn-card> </div>
</div>

View File

@ -1,5 +1,5 @@
<vn-card class="vn-descriptor"> <div class="vn-descriptor">
<vn-horizontal class="header"> <div class="header">
<a translate-attr="{title: 'Return to module index'}" ui-sref="client.index"> <a translate-attr="{title: 'Return to module index'}" ui-sref="client.index">
<vn-icon icon="chevron_left"></vn-icon> <vn-icon icon="chevron_left"></vn-icon>
</a> </a>
@ -16,8 +16,9 @@
on-change="$ctrl.onMoreChange(value)" on-change="$ctrl.onMoreChange(value)"
on-open="$ctrl.onMoreOpen()"> on-open="$ctrl.onMoreOpen()">
</vn-icon-menu> </vn-icon-menu>
</vn-horizontal> </div>
<div pad-medium> <div class="body">
<div class="attributes">
<h5>{{$ctrl.client.name}}</h5> <h5>{{$ctrl.client.name}}</h5>
<vn-label-value label="Id" <vn-label-value label="Id"
value="{{$ctrl.client.id}}"> value="{{$ctrl.client.id}}">
@ -35,7 +36,7 @@
value="{{$ctrl.client.salesPerson.firstName}} {{$ctrl.client.salesPerson.name}}"> value="{{$ctrl.client.salesPerson.firstName}} {{$ctrl.client.salesPerson.name}}">
</vn-label-value> </vn-label-value>
</div> </div>
<vn-horizontal pad-medium class="footer"> <div class="icons">
<vn-icon <vn-icon
vn-tooltip="Client inactive" vn-tooltip="Client inactive"
icon="icon-disabled" icon="icon-disabled"
@ -61,9 +62,9 @@
icon="icon-no036" icon="icon-no036"
ng-class="{bright: $ctrl.client.isTaxDataChecked == false}"> ng-class="{bright: $ctrl.client.isTaxDataChecked == false}">
</vn-icon> </vn-icon>
</vn-horizontal> </div>
<vn-horizontal pad-small class="quicklinks"> <div class="quicklinks">
<a ng-if="$ctrl.quicklinks.btnOne" pad-small-right <a ng-if="$ctrl.quicklinks.btnOne"
vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank">
<vn-icon <vn-icon
@ -71,7 +72,7 @@
icon="{{::$ctrl.quicklinks.btnOne.icon}}"> icon="{{::$ctrl.quicklinks.btnOne.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnTwo" pad-small-right <a ng-if="$ctrl.quicklinks.btnTwo"
vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank">
<vn-icon <vn-icon
@ -79,7 +80,7 @@
icon="{{::$ctrl.quicklinks.btnTwo.icon}}"> icon="{{::$ctrl.quicklinks.btnTwo.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnThree" pad-small-right <a ng-if="$ctrl.quicklinks.btnThree"
vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank">
<vn-icon <vn-icon
@ -87,5 +88,6 @@
icon="{{::$ctrl.quicklinks.btnThree.icon}}"> icon="{{::$ctrl.quicklinks.btnThree.icon}}">
</vn-icon> </vn-icon>
</a> </a>
</vn-horizontal> </div>
</vn-card> </div>
</div>

View File

@ -1,5 +1,5 @@
<vn-card class="vn-descriptor"> <div class="vn-descriptor">
<vn-horizontal class="header"> <div class="header">
<a translate-attr="{title: 'Return to module index'}" ui-sref="item.index"> <a translate-attr="{title: 'Return to module index'}" ui-sref="item.index">
<vn-icon icon="chevron_left"></vn-icon> <vn-icon icon="chevron_left"></vn-icon>
</a> </a>
@ -16,9 +16,9 @@
on-change="$ctrl.onMoreChange(value)" on-change="$ctrl.onMoreChange(value)"
on-open="$ctrl.onMoreOpen()"> on-open="$ctrl.onMoreOpen()">
</vn-icon-menu> </vn-icon-menu>
</vn-horizontal> </div>
<vn-vertical> <div>
<vn-auto style="position: relative" text-center> <div style="position: relative" text-center>
<img <img
ng-src="//verdnatura.es/vn-image-data/catalog/200x200/{{$ctrl.item.image}}" ng-src="//verdnatura.es/vn-image-data/catalog/200x200/{{$ctrl.item.image}}"
zoom-image="//verdnatura.es/vn-image-data/catalog/1600x900/{{$ctrl.item.image}}" zoom-image="//verdnatura.es/vn-image-data/catalog/1600x900/{{$ctrl.item.image}}"
@ -30,7 +30,7 @@
vn-visible-by="marketing, buyer"> vn-visible-by="marketing, buyer">
</vn-float-button> </vn-float-button>
</a> </a>
</vn-auto> </div>
<vn-horizontal class="state"> <vn-horizontal class="state">
<vn-one> <vn-one>
<p translate>Visible</p> <p translate>Visible</p>
@ -41,7 +41,9 @@
<p>{{$ctrl.item.available}}</p> <p>{{$ctrl.item.available}}</p>
</vn-one> </vn-one>
</vn-horizontal> </vn-horizontal>
<vn-auto pad-medium> </div>
<div class="body">
<div class="attributes">
<h5>{{$ctrl.item.id}}</h5> <h5>{{$ctrl.item.id}}</h5>
<vn-label-value label="Name" <vn-label-value label="Name"
value="{{::$ctrl.item.name}}"> value="{{::$ctrl.item.name}}">
@ -54,11 +56,9 @@
label="{{tag.tag.name}}" label="{{tag.tag.name}}"
value="{{tag.value}}"> value="{{tag.value}}">
</vn-label-value> </vn-label-value>
</vn-auto> </div>
</vn-vertical> <div class="quicklinks">
<vn-horizontal pad-small class="quicklinks"> <a ng-if="$ctrl.quicklinks.btnOne"
<vn-horizontal pad-small class="quicklinks">
<a ng-if="$ctrl.quicklinks.btnOne" pad-small-right
vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank">
<vn-icon <vn-icon
@ -66,7 +66,7 @@
icon="{{::$ctrl.quicklinks.btnOne.icon}}"> icon="{{::$ctrl.quicklinks.btnOne.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnTwo" pad-small-right <a ng-if="$ctrl.quicklinks.btnTwo"
vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank">
<vn-icon <vn-icon
@ -74,7 +74,7 @@
icon="{{::$ctrl.quicklinks.btnTwo.icon}}"> icon="{{::$ctrl.quicklinks.btnTwo.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnThree" pad-small-right <a ng-if="$ctrl.quicklinks.btnThree"
vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank">
<vn-icon <vn-icon
@ -82,9 +82,9 @@
icon="{{::$ctrl.quicklinks.btnThree.icon}}"> icon="{{::$ctrl.quicklinks.btnThree.icon}}">
</vn-icon> </vn-icon>
</a> </a>
</vn-horizontal> </div>
</vn-card> </div>
</div>
<vn-dialog <vn-dialog
vn-id="regularize" vn-id="regularize"
on-open="$ctrl.clearRegularizeDialog()" on-open="$ctrl.clearRegularizeDialog()"

View File

@ -1,5 +1,5 @@
<vn-card class="vn-descriptor"> <div class="vn-descriptor">
<vn-horizontal class="header"> <div class="header">
<a translate-attr="{title: 'Return to module index'}" ui-sref="ticket.index"> <a translate-attr="{title: 'Return to module index'}" ui-sref="ticket.index">
<vn-icon icon="chevron_left"></vn-icon> <vn-icon icon="chevron_left"></vn-icon>
</a> </a>
@ -16,8 +16,9 @@
on-change="$ctrl.onMoreChange(value)" on-change="$ctrl.onMoreChange(value)"
on-open="$ctrl.onMoreOpen()"> on-open="$ctrl.onMoreOpen()">
</vn-icon-menu> </vn-icon-menu>
</vn-horizontal> </div>
<div pad-medium> <div class="body">
<div class="attributes">
<h5>{{::$ctrl.client.name}}</h5> <h5>{{::$ctrl.client.name}}</h5>
<vn-label-value label="Id" <vn-label-value label="Id"
value="{{$ctrl.ticket.id}}"> value="{{$ctrl.ticket.id}}">
@ -44,7 +45,7 @@
value="{{$ctrl.ticket.nickname}}"> value="{{$ctrl.ticket.nickname}}">
</vn-label-value> </vn-label-value>
</div> </div>
<vn-horizontal pad-medium-bottom class="footer"> <div class="icons">
<vn-icon vn-one <vn-icon vn-one
vn-tooltip="Client inactive" vn-tooltip="Client inactive"
icon="icon-disabled" icon="icon-disabled"
@ -65,9 +66,9 @@
icon="icon-no036" icon="icon-no036"
ng-class="{bright: $ctrl.ticket.client.isTaxDataChecked == false}"> ng-class="{bright: $ctrl.ticket.client.isTaxDataChecked == false}">
</vn-icon> </vn-icon>
</vn-horizontal> </div>
<vn-horizontal pad-small class="quicklinks"> <div class="quicklinks">
<a ng-if="$ctrl.quicklinks.btnOne" pad-small-right <a ng-if="$ctrl.quicklinks.btnOne"
vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank">
<vn-icon <vn-icon
@ -75,7 +76,7 @@
icon="{{::$ctrl.quicklinks.btnOne.icon}}"> icon="{{::$ctrl.quicklinks.btnOne.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnTwo" pad-small-right <a ng-if="$ctrl.quicklinks.btnTwo"
vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank">
<vn-icon <vn-icon
@ -83,7 +84,7 @@
icon="{{::$ctrl.quicklinks.btnTwo.icon}}"> icon="{{::$ctrl.quicklinks.btnTwo.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnThree" pad-small-right <a ng-if="$ctrl.quicklinks.btnThree"
vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank">
<vn-icon <vn-icon
@ -102,8 +103,9 @@
data="$ctrl.ticket.ship" data="$ctrl.ticket.ship"
on-change="$ctrl.goToTicket(value)"> on-change="$ctrl.goToTicket(value)">
</vn-button-menu> </vn-button-menu>
</vn-horizontal> </div>
</vn-card> </div>
</div>
<vn-dialog class="dialog-summary" <vn-dialog class="dialog-summary"
vn-id="addTurn"> vn-id="addTurn">
<tpl-body> <tpl-body>

View File

@ -1,14 +1,15 @@
<vn-card class="vn-descriptor"> <div class="vn-descriptor">
<vn-horizontal class="header"> <div class="header">
<a translate-attr="{title: 'Return to module index'}" ui-sref="order.index"> <a translate-attr="{title: 'Return to module index'}" ui-sref="order.index">
<vn-icon icon="chevron_left"></vn-icon> <vn-icon icon="chevron_left"></vn-icon>
</a> </a>
<vn-icon icon="shopping_cart"></vn-icon>
<a translate-attr="{title: 'Preview'}" ui-sref="order.card.summary"> <a translate-attr="{title: 'Preview'}" ui-sref="order.card.summary">
<vn-icon icon="desktop_windows"></vn-icon> <vn-icon icon="desktop_windows"></vn-icon>
</a> </a>
</vn-horizontal> <div></div>
<div pad-medium> </div>
<div class="body">
<div class="attributes">
<vn-label-value label="ID" <vn-label-value label="ID"
value="{{$ctrl.order.id}}"> value="{{$ctrl.order.id}}">
</vn-label-value> </vn-label-value>
@ -37,8 +38,8 @@
value="{{$ctrl.order.total | currency: ' €': 2}}"> value="{{$ctrl.order.total | currency: ' €': 2}}">
</vn-label-value> </vn-label-value>
</div> </div>
<vn-horizontal pad-small class="quicklinks"> <div class="quicklinks">
<a ng-if="$ctrl.quicklinks.btnOne" pad-small-right <a ng-if="$ctrl.quicklinks.btnOne"
vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank">
<vn-icon <vn-icon
@ -46,7 +47,7 @@
icon="{{::$ctrl.quicklinks.btnOne.icon}}"> icon="{{::$ctrl.quicklinks.btnOne.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnTwo" pad-small-right <a ng-if="$ctrl.quicklinks.btnTwo"
vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank">
<vn-icon <vn-icon
@ -54,7 +55,7 @@
icon="{{::$ctrl.quicklinks.btnTwo.icon}}"> icon="{{::$ctrl.quicklinks.btnTwo.icon}}">
</vn-icon> </vn-icon>
</a> </a>
<a ng-if="$ctrl.quicklinks.btnThree" pad-small-right <a ng-if="$ctrl.quicklinks.btnThree"
vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}" vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank"> ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank">
<vn-icon <vn-icon
@ -62,5 +63,6 @@
icon="{{::$ctrl.quicklinks.btnThree.icon}}"> icon="{{::$ctrl.quicklinks.btnThree.icon}}">
</vn-icon> </vn-icon>
</a> </a>
</vn-horizontal> </div>
</vn-card> </div>
</div>