salix/modules/item/front/index/index.html

197 lines
8.0 KiB
HTML
Raw Normal View History

2019-11-10 10:08:44 +00:00
<vn-auto-search
2020-03-13 19:33:12 +00:00
model="model">
2019-11-10 10:08:44 +00:00
</vn-auto-search>
2021-11-08 13:46:23 +00:00
<vn-card>
<smart-table
model="model"
view-config-id="itemsIndex"
options="$ctrl.smartTableOptions"
expr-builder="$ctrl.exprBuilder(param, value)">
<slot-table>
<table>
2021-11-08 13:46:23 +00:00
<thead>
<tr>
<th shrink></th>
<th field="id">
<span translate>Identifier</span>
2021-11-08 13:46:23 +00:00
</th>
<th field="grouping">
2021-11-08 13:46:23 +00:00
<span translate>Grouping</span>
</th>
<th field="packing">
2021-11-08 13:46:23 +00:00
<span translate>Packing</span>
</th>
<th field="name">
<span translate>Description</span>
</th>
<th field="stems">
2021-11-08 13:46:23 +00:00
<span translate>Stems</span>
</th>
<th field="size">
2021-11-08 13:46:23 +00:00
<span translate>Size</span>
</th>
<th field="typeFk">
2021-11-08 13:46:23 +00:00
<span translate>Type</span>
</th>
<th field="category">
2021-11-08 13:46:23 +00:00
<span translate>Category</span>
</th>
<th field="intrastat">
2021-11-08 13:46:23 +00:00
<span translate>Intrastat</span>
</th>
<th field="origin">
2021-11-08 13:46:23 +00:00
<span translate>Origin</span>
</th>
<th field="buyerFk">
2021-11-08 13:46:23 +00:00
<span translate>Buyer</span>
</th>
<th field="density">
2021-11-08 13:46:23 +00:00
<span translate>Density</span>
</th>
<th field="stemMultiplier">
2021-11-08 13:46:23 +00:00
<span translate>Multiplier</span>
</th>
<th field="active">
2021-11-08 13:46:23 +00:00
<span translate>Active</span>
</th>
2022-02-01 08:37:11 +00:00
<th field="producer">
<span translate>Producer</span>
</th>
<th field="landed">
2021-11-08 13:46:23 +00:00
<span translate>Landed</span>
</th>
<th></th>
</tr>
</thead>
<tbody>
<tr ng-repeat="item in model.data"
vn-anchor="::{
state: 'item.card.summary',
params: {id: item.id}
}">
<td>
2021-11-08 13:46:23 +00:00
<img
ng-src="{{::$root.imagePath('catalog', '50x50', item.id)}}"
zoom-image="{{::$root.imagePath('catalog', '1600x900', item.id)}}"
vn-click-stop
on-error-src/>
</td>
<td>
2021-11-08 13:46:23 +00:00
<span
vn-click-stop="itemDescriptor.show($event, item.id)"
class="link">
{{::item.id}}
</span>
</td>
<td>{{::item.grouping | dashIfEmpty}}</td>
<td>{{::item.packing | dashIfEmpty}}</td>
2021-11-08 13:46:23 +00:00
<td vn-fetched-tags>
<div>
<vn-one title="{{::item.name}}">{{::item.name}}</vn-one>
<vn-one ng-if="::item.subName">
<h3 title="{{::item.subName}}">{{::item.subName}}</h3>
</vn-one>
</div>
<vn-fetched-tags
max-length="6"
item="item"
tabindex="-1">
</vn-fetched-tags>
</td>
<td>{{::item.stems}}</td>
<td>{{::item.size}}</td>
<td title="{{::item.typeName}}">
2021-11-08 13:46:23 +00:00
{{::item.typeName}}
</td>
<td title="{{::item.category}}">
2021-11-08 13:46:23 +00:00
{{::item.category}}
</td>
<td title="{{::item.intrastat}}">
2021-11-08 13:46:23 +00:00
{{::item.intrastat}}
</td>
<td>{{::item.origin}}</td>
<td title="{{::item.userName}}">
2021-11-08 13:46:23 +00:00
<span
class="link"
vn-click-stop="workerDescriptor.show($event, item.buyerFk)">
{{::item.userName}}
</span>
</td>
<td>{{::item.density}}</td>
<td>{{::item.stemMultiplier}}</td>
<td>
2021-11-08 13:46:23 +00:00
<vn-check
disabled="true"
ng-model="::item.isActive">
</vn-check>
</td>
<td>{{::item.producer | dashIfEmpty}}</td>
2021-11-08 13:46:23 +00:00
<td shrink-date>{{::item.landed | date:'dd/MM/yyyy'}}</td>
<td>
2021-11-08 13:46:23 +00:00
<vn-horizontal class="buttons">
<vn-icon-button
vn-click-stop="clone.show(item.id)"
vn-tooltip="Clone"
icon="icon-clone">
</vn-icon-button>
<vn-icon-button
vn-click-stop="$ctrl.preview(item)"
vn-tooltip="Preview"
icon="preview">
</vn-icon-button>
</vn-horizontal>
</td>
</tr>
</tbody>
</table>
</slot-table>
</smart-table>
</vn-card>
2018-07-25 13:14:03 +00:00
<a ui-sref="item.create" vn-tooltip="New item" vn-bind="+" fixed-bottom-right>
2018-03-01 20:18:43 +00:00
<vn-float-button icon="add"></vn-float-button>
</a>
2020-04-25 09:50:04 +00:00
<vn-item-descriptor-popover
vn-id="item-descriptor"
warehouse-fk="$ctrl.vnConfig.warehouseFk">
2020-04-25 09:50:04 +00:00
</vn-item-descriptor-popover>
<vn-worker-descriptor-popover
vn-id="worker-descriptor">
2020-04-25 09:50:04 +00:00
</vn-worker-descriptor-popover>
2018-03-01 20:18:43 +00:00
<vn-confirm
vn-id="clone"
2020-04-25 09:50:04 +00:00
on-accept="$ctrl.onCloneAccept($data)"
2018-03-01 20:18:43 +00:00
question="Do you want to clone this item?"
message="All it's properties will be copied">
</vn-confirm>
2020-04-25 09:50:04 +00:00
<vn-popup vn-id="preview">
<vn-item-summary
item="$ctrl.itemSelected">
</vn-item-summary>
</vn-popup>
2021-02-24 13:49:58 +00:00
<vn-contextmenu
vn-id="contextmenu"
2021-11-08 13:46:23 +00:00
targets="['smart-table']"
2021-02-24 13:49:58 +00:00
model="model"
expr-builder="$ctrl.exprBuilder(param, value)">
2021-02-24 13:49:58 +00:00
<slot-menu>
<vn-item translate
ng-if="contextmenu.isFilterAllowed()"
ng-click="contextmenu.filterBySelection()">
Filter by selection
</vn-item>
<vn-item translate
ng-if="contextmenu.isFilterAllowed()"
ng-click="contextmenu.excludeSelection()">
Exclude selection
</vn-item>
<vn-item translate
ng-if="contextmenu.isFilterAllowed()"
ng-click="contextmenu.removeFilter()">
Remove filter
</vn-item>
<vn-item translate
ng-click="contextmenu.removeAllFilters()">
Remove all filters
</vn-item>
</slot-menu>
</vn-contextmenu>