1 <md-dialog class="disposition-dialog" aria-label="disposition">
2 <form name="transferForm" class="md-inline-form" novalidate>
3 <md-toolbar class="md-background-bg">
5 class="md-toolbar-tools"
7 layout-align="space-between center"
9 <span class="title" translate="DASHBOARDS.TRANSFER"></span>
10 <md-button class="md-icon-button" ng-click="vm.closeDialog(false)">
12 md-font-icon="icon-close"
13 aria-label="Close dialog"
19 <md-dialog-content ms-scroll>
20 <div class="error-list">
22 ng-repeat="error in vm.errors"
25 layout-align="space-between center"
28 <span class="message">{{error.message}}</span>
29 <span class="type">({{error.type}})</span>
31 <md-button class="md-icon-button">
33 md-font-icon="icon-alert-box"
34 aria-label="alert error"
41 <md-input-container class="md-block">
42 <label translate="DASHBOARDS.TYPE">Type</label>
43 <md-select name="type" ng-model="vm.transfer.type" required>
44 <md-option ng-value="'queue'" ng-if="vm.account.queueTransfer"
47 <md-option ng-value="'agent'" ng-if="vm.account.agentTransfer"
52 ng-messages="transferForm.type.$error"
53 ng-show="transferForm.type.$touched"
56 <div ng-message="required">
57 <span translate="DASHBOARDS.ERRORS.TYPE_REQUIRED"
58 >Type field is required</span
64 <md-input-container class="md-block" ng-if="vm.transfer.type === 'queue'">
65 <label translate="DASHBOARDS.QUEUES">Queues</label>
66 <md-select name="queue" ng-model="vm.transfer.id" required>
67 <md-option ng-value="queue.id" ng-repeat="queue in vm.queues.rows"
68 >{{ queue.name }}</md-option
72 ng-messages="transferForm.queue.$error"
73 ng-show="transferForm.queue.$touched"
76 <div ng-message="required">
77 <span translate="DASHBOARDS.ERRORS.QUEUE_REQUIRED"
78 >Queue field is required</span
84 <md-input-container class="md-block" ng-if="vm.transfer.type === 'agent'">
85 <label translate="DASHBOARDS.AGENTS">Agents</label>
86 <md-select name="agent" ng-model="vm.transfer.id" required>
89 ng-repeat="agent in vm.agents.rows"
90 ng-if="vm.currentUser.id != agent.id"
91 >{{ agent.name }}</md-option
95 ng-messages="transferForm.agent.$error"
96 ng-show="transferForm.agent.$touched"
99 <div ng-message="required">
100 <span translate="DASHBOARDS.ERRORS.AGENT_REQUIRED"
101 >Agent field is required</span
105 </md-input-container>
107 <div class="error-list">
109 ng-repeat="error in vm.errors"
112 layout-align="space-between center"
115 <span class="message">{{error.message}}</span>
116 <span class="type">({{error.type}})</span>
118 <md-button class="md-icon-button">
120 md-font-icon="icon-alert-box"
121 aria-label="alert error"
129 <!-- <md-dialog-actions ng-if="!vm.interaction.closed || !vm.interaction.disposition" layout="row" layout-align="space-between center"> -->
130 <md-dialog-actions layout="row" layout-align="space-between center">
131 <div layout="row" layout-align="start center">
134 ng-click="vm.onTransfer(true)"
135 ng-disabled="transferForm.$pristine"
136 class="send-button md-accent md-raised"
137 aria-label="DASHBOARDS.TRANSFER"
138 translate="DASHBOARDS.TRANSFER"
139 translate-attr-aria-label="DASHBOARDS.TRANSFER"