descriptor can now have 4 quicklinks
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
3284ef5b55
commit
663b5fb9aa
|
@ -94,7 +94,8 @@ ngModule.vnComponent('vnDescriptor', {
|
|||
transclude: {
|
||||
btnOne: '?btnOne',
|
||||
btnTwo: '?btnTwo',
|
||||
btnThree: '?btnThree'
|
||||
btnThree: '?btnThree',
|
||||
btnFour: '?btnFour'
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -88,7 +88,7 @@ vn-descriptor-content {
|
|||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 0 $spacing-md;
|
||||
padding: 10px 5px;
|
||||
margin: 0 $spacing-sm;
|
||||
|
||||
& > vn-icon {
|
||||
|
|
|
@ -146,6 +146,20 @@
|
|||
</vn-quick-link>
|
||||
</div>
|
||||
<div ng-transclude="btnTwo">
|
||||
<vn-quick-link
|
||||
tooltip="Client ticket list"
|
||||
state="['ticket.index', {q: $ctrl.filter}]"
|
||||
icon="icon-ticket">
|
||||
</vn-quick-link>
|
||||
</div>
|
||||
<div ng-transclude="btnThree">
|
||||
<vn-quick-link
|
||||
tooltip="New order"
|
||||
state="['order.create', {clientFk: $ctrl.ticket.clientFk}]"
|
||||
icon="icon-basketadd">
|
||||
</vn-quick-link>
|
||||
</div>
|
||||
<div ng-transclude="btnFour">
|
||||
<vn-quick-link
|
||||
ng-if="$ctrl.ticket.stowaway"
|
||||
tooltip="Ship stowaways"
|
||||
|
@ -153,7 +167,7 @@
|
|||
icon="icon-stowaway">
|
||||
</vn-quick-link>
|
||||
</div>
|
||||
<div ng-transclude="btnThree">
|
||||
<div ng-transclude="btnFour">
|
||||
<vn-quick-link
|
||||
ng-if="$ctrl.ticket.ship"
|
||||
tooltip="Stowaway"
|
||||
|
|
|
@ -38,6 +38,12 @@ class Controller extends Descriptor {
|
|||
return this.ticket.stowaway || this.ticket.ship;
|
||||
}
|
||||
|
||||
get filter() {
|
||||
if (this.ticket)
|
||||
return JSON.stringify({clientFk: this.ticket.clientFk});
|
||||
return null;
|
||||
}
|
||||
|
||||
isTicketEditable() {
|
||||
this.$http.get(`Tickets/${this.$state.params.id}/isEditable`).then(res => {
|
||||
this.isEditable = res.data;
|
||||
|
|
Loading…
Reference in New Issue