salix/modules/order/front/prices-popover/index.html

98 lines
4.5 KiB
HTML

<vn-popover vn-id="popover" on-close="$ctrl.clear()">
<div class="vn-descriptor">
<div class="header">
<a translate-attr="{title: 'Return to module index'}" ui-sref="item.index">
<vn-icon icon="chevron_left"></vn-icon>
</a>
<vn-icon icon="inbox"></vn-icon>
<a translate-attr="{title: 'Preview'}" ui-sref="item.card.summary({id: $ctrl.item.id})">
<vn-icon icon="desktop_windows"></vn-icon>
</a>
</div>
<div pad-medium>
<vn-horizontal>
<h5>{{$ctrl.item.id}}</h5>
</vn-horizontal>
<vn-horizontal>
<vn-vertical class="data">
<vn-auto>
<vn-label-value label="Name"
value="{{$ctrl.item.name}}">
</vn-label-value>
<vn-label-value label="Buyer"
value="{{$ctrl.item.firstName}} {{$ctrl.item.lastName}}">
</vn-label-value>
<vn-label-value
ng-repeat="tag in $ctrl.tags"
label="{{::tag.tag.name}}"
value="{{::tag.value}}">
</vn-label-value>
</vn-auto>
<vn-icon-button
class="button"
label="Save"
ng-click="$ctrl.saveQuantity($ctrl.prices)"></vn-icon-button>
</vn-vertical>
<vn-vertical class="prices">
<form name="form">
<vn-horizontal
ng-repeat="price in $ctrl.prices">
<vn-one class="ellipsize text" title="{{::price.warehouse}}">{{::price.warehouse}}</vn-one>
<vn-one class="number text">
<span orange ng-click="$ctrl.addQuantity(price)" class="link unselectable">{{::price.grouping}}</span><span> x {{::price.price | currency: 'EUR': 2}}</span>
</vn-one>
<vn-one>
<vn-input-number
name="quantity"
label="Qty."
model="price.quantity"
min="0"
step="price.grouping"
on-change="$ctrl.validate()">
</vn-input-number>
</vn-one>
</vn-horizontal>
</form>
<vn-one class="error">
<span translate>Wrong quantity</span>
</vn-one>
</vn-vertical>
</vn-horizontal>
<vn-horizontal class="buttons-bar">
<div class="quicklinks" vn-one>
<a ng-if="$ctrl.quicklinks.btnOne"
vn-tooltip="{{::$ctrl.quicklinks.btnOne.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnOne.state}}" target="_blank">
<vn-icon
class="mdl-button mdl-js-button mdl-button--colored"
icon="{{::$ctrl.quicklinks.btnOne.icon}}">
</vn-icon>
</a>
<a ng-if="$ctrl.quicklinks.btnTwo"
vn-tooltip="{{::$ctrl.quicklinks.btnTwo.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnTwo.state}}" target="_blank">
<vn-icon
class="mdl-button mdl-js-button mdl-button--colored"
icon="{{::$ctrl.quicklinks.btnTwo.icon}}">
</vn-icon>
</a>
<a ng-if="$ctrl.quicklinks.btnThree"
vn-tooltip="{{::$ctrl.quicklinks.btnThree.tooltip}}"
ui-sref="{{::$ctrl.quicklinks.btnThree.state}}" target="_blank">
<vn-icon
class="mdl-button mdl-js-button mdl-button--colored"
icon="{{::$ctrl.quicklinks.btnThree.icon}}">
</vn-icon>
</a>
</div>
<vn-one>
<vn-submit
label="Save"
ng-click="$ctrl.submit()">
</vn-submit>
</vn-one>
</vn-horizontal>
</div>
</div>
</vn-popover>