This commit is contained in:
parent
ca4009088d
commit
b64a6fd05c
|
@ -84,7 +84,7 @@
|
|||
"url" : "/index",
|
||||
"state": "claim.card.dms.index",
|
||||
"component": "vn-claim-dms-index",
|
||||
"description": "Pictures",
|
||||
"description": "Photos",
|
||||
"params": {
|
||||
"claim": "$ctrl.claim"
|
||||
}
|
||||
|
|
|
@ -1,3 +1,9 @@
|
|||
<vn-crud-model
|
||||
url="/api/ClaimDms"
|
||||
where="{claimFk: $ctrl.$stateParams.id}"
|
||||
data="photos"
|
||||
auto-load="true">
|
||||
</vn-crud-model>
|
||||
<vn-card class="summary">
|
||||
<h5>{{$ctrl.summary.claim.id}} - {{$ctrl.summary.claim.client.name}}</h5>
|
||||
<vn-horizontal>
|
||||
|
@ -73,6 +79,18 @@
|
|||
</vn-tbody>
|
||||
</vn-table>
|
||||
</vn-auto>
|
||||
<vn-auto ng-if="photos.length > 0">
|
||||
<h4 translate>Photos</h4>
|
||||
<vn-horizontal class="photo-list">
|
||||
<section class="photo" ng-repeat="photo in photos">
|
||||
<section class="image">
|
||||
<img alt="" on-error-src
|
||||
ng-src="/api/dms/{{::photo.dmsFk}}/downloadFile?access_token={{::$ctrl.accessToken}}"
|
||||
zoom-image="/api/dms/{{::photo.dmsFk}}/downloadFile?access_token={{::$ctrl.accessToken}}">
|
||||
</section>
|
||||
</section>
|
||||
</vn-horizontal>
|
||||
</vn-auto>
|
||||
<vn-auto>
|
||||
<h4 translate>Development</h4>
|
||||
<vn-table model="model">
|
||||
|
|
|
@ -1,9 +1,12 @@
|
|||
import ngModule from '../module';
|
||||
import './style.scss';
|
||||
|
||||
class Controller {
|
||||
constructor($scope, $http) {
|
||||
constructor($scope, $http, $stateParams, vnToken) {
|
||||
this.$http = $http;
|
||||
this.$ = $scope;
|
||||
this.$stateParams = $stateParams;
|
||||
this.accessToken = vnToken.token;
|
||||
}
|
||||
|
||||
getSummary() {
|
||||
|
@ -36,7 +39,7 @@ class Controller {
|
|||
}
|
||||
}
|
||||
|
||||
Controller.$inject = ['$scope', '$http'];
|
||||
Controller.$inject = ['$scope', '$http', '$stateParams', 'vnToken'];
|
||||
|
||||
ngModule.component('vnClaimSummary', {
|
||||
template: require('./index.html'),
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
@import "./variables";
|
||||
|
||||
.photo-list {
|
||||
align-items: flex-start;
|
||||
flex-wrap: wrap;
|
||||
|
||||
.photo {
|
||||
box-sizing: border-box;
|
||||
padding: $pad-small;
|
||||
width: 33%;
|
||||
|
||||
.image {
|
||||
border: 2px solid $color-main;
|
||||
border-radius: 0.5em;
|
||||
overflow: hidden;
|
||||
|
||||
img {
|
||||
max-width: 100%
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -77,5 +77,5 @@ Tracking: Estados
|
|||
Sale checked: Control clientes
|
||||
Components: Componentes
|
||||
Sale tracking: Líneas preparadas
|
||||
Pictures: Fotos
|
||||
Photos: Fotos
|
||||
Log: Historial
|
Loading…
Reference in New Issue