1457 client.sample.index
gitea/salix/dev This commit looks good
Details
gitea/salix/dev This commit looks good
Details
This commit is contained in:
parent
fe250b8269
commit
1769b03846
|
@ -23,8 +23,16 @@
|
||||||
<vn-tbody>
|
<vn-tbody>
|
||||||
<vn-tr ng-repeat="sample in samples">
|
<vn-tr ng-repeat="sample in samples">
|
||||||
<vn-td>{{::sample.created | dateTime:'dd/MM/yyyy HH:mm' }}</vn-td>
|
<vn-td>{{::sample.created | dateTime:'dd/MM/yyyy HH:mm' }}</vn-td>
|
||||||
<vn-td>{{::sample.type.description}}</vn-td>
|
<vn-td
|
||||||
<vn-td>{{::sample.worker.user.nickname}}</vn-td>
|
title="{{::sample.type.description}}">
|
||||||
|
{{::sample.type.description}}
|
||||||
|
</vn-td>
|
||||||
|
<vn-td>
|
||||||
|
<span class="link"
|
||||||
|
ng-click="$ctrl.showWorkerDescriptor($event, sample.worker.id)">
|
||||||
|
{{::sample.worker.user.nickname}}
|
||||||
|
</span>
|
||||||
|
</vn-td>
|
||||||
<vn-td>{{::sample.company.code}}</vn-td>
|
<vn-td>{{::sample.company.code}}</vn-td>
|
||||||
</vn-tr>
|
</vn-tr>
|
||||||
</vn-tbody>
|
</vn-tbody>
|
||||||
|
@ -33,6 +41,10 @@
|
||||||
<vn-pagination model="model"></vn-pagination>
|
<vn-pagination model="model"></vn-pagination>
|
||||||
</vn-card>
|
</vn-card>
|
||||||
</vn-vertical>
|
</vn-vertical>
|
||||||
|
<vn-worker-descriptor-popover
|
||||||
|
vn-id="workerDescriptor"
|
||||||
|
worker-fk="$ctrl.selectedWorker">
|
||||||
|
</vn-worker-descriptor-popover>
|
||||||
<a ui-sref="client.card.sample.create" vn-tooltip="Send sample"
|
<a ui-sref="client.card.sample.create" vn-tooltip="Send sample"
|
||||||
vn-bind="+" fixed-bottom-right>
|
vn-bind="+" fixed-bottom-right>
|
||||||
<vn-float-button icon="add"></vn-float-button>
|
<vn-float-button icon="add"></vn-float-button>
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
import ngModule from '../../module';
|
import ngModule from '../../module';
|
||||||
|
|
||||||
class Controller {
|
class Controller {
|
||||||
constructor($stateParams) {
|
constructor($scope, $stateParams) {
|
||||||
|
this.$ = $scope;
|
||||||
this.$stateParams = $stateParams;
|
this.$stateParams = $stateParams;
|
||||||
this.filter = {
|
this.filter = {
|
||||||
include: [
|
include: [
|
||||||
|
@ -32,9 +33,19 @@ class Controller {
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
showWorkerDescriptor(event, workerFk) {
|
||||||
|
if (event.defaultPrevented) return;
|
||||||
|
|
||||||
|
event.preventDefault();
|
||||||
|
event.stopImmediatePropagation();
|
||||||
|
|
||||||
|
this.selectedWorker = workerFk;
|
||||||
|
this.$.workerDescriptor.parent = event.target;
|
||||||
|
this.$.workerDescriptor.show();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Controller.$inject = ['$stateParams'];
|
Controller.$inject = ['$scope', '$stateParams'];
|
||||||
|
|
||||||
ngModule.component('vnClientSampleIndex', {
|
ngModule.component('vnClientSampleIndex', {
|
||||||
template: require('./index.html'),
|
template: require('./index.html'),
|
||||||
|
|
Loading…
Reference in New Issue