|
|
@ -19,7 +19,11 @@
|
|
|
|
@modelSelectOpened="modelSelectOpened()"
|
|
|
|
@modelSelectOpened="modelSelectOpened()"
|
|
|
|
@save="saveDevice"
|
|
|
|
@save="saveDevice"
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
|
|
|
|
<div
|
|
|
|
|
|
|
|
class="row justify-center"
|
|
|
|
|
|
|
|
>
|
|
|
|
<csc-pbx-model-select
|
|
|
|
<csc-pbx-model-select
|
|
|
|
|
|
|
|
class="col col-md-6 col-sm-12"
|
|
|
|
:erasable="true"
|
|
|
|
:erasable="true"
|
|
|
|
:profiles="profiles"
|
|
|
|
:profiles="profiles"
|
|
|
|
:modelImages="modelImages"
|
|
|
|
:modelImages="modelImages"
|
|
|
@ -28,6 +32,7 @@
|
|
|
|
@select="filterByProfile"
|
|
|
|
@select="filterByProfile"
|
|
|
|
@reseted="resetFilter"
|
|
|
|
@reseted="resetFilter"
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<div
|
|
|
|
<div
|
|
|
|
v-if="devices.length > 0 && !isListRequesting && listLastPage > 1"
|
|
|
|
v-if="devices.length > 0 && !isListRequesting && listLastPage > 1"
|
|
|
|
class="row justify-center"
|
|
|
|
class="row justify-center"
|
|
|
@ -56,11 +61,14 @@
|
|
|
|
:loading="isDeviceLoading(device.id)"
|
|
|
|
:loading="isDeviceLoading(device.id)"
|
|
|
|
:groupsAndSeatsOptions="groupsAndSeatsOptions"
|
|
|
|
:groupsAndSeatsOptions="groupsAndSeatsOptions"
|
|
|
|
:subscribers="getGroupOrSeatById"
|
|
|
|
:subscribers="getGroupOrSeatById"
|
|
|
|
|
|
|
|
:profiles="profiles"
|
|
|
|
|
|
|
|
:modelImages="modelImages"
|
|
|
|
@remove="removeDevice"
|
|
|
|
@remove="removeDevice"
|
|
|
|
@loadGroupsAndSeats="loadGroupsAndSeats()"
|
|
|
|
@loadGroupsAndSeats="loadGroupsAndSeats()"
|
|
|
|
@deviceKeysChanged="deviceKeysChanged"
|
|
|
|
@deviceKeysChanged="deviceKeysChanged"
|
|
|
|
@save-station-name="setStationName"
|
|
|
|
@save-station-name="setStationName"
|
|
|
|
@save-identifier="setIdentifier"
|
|
|
|
@save-identifier="setIdentifier"
|
|
|
|
|
|
|
|
@update-profile="updateProfile"
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</q-list>
|
|
|
|
</q-list>
|
|
|
|
<div
|
|
|
|
<div
|
|
|
@ -211,7 +219,10 @@
|
|
|
|
},
|
|
|
|
},
|
|
|
|
setIdentifier(device) {
|
|
|
|
setIdentifier(device) {
|
|
|
|
this.$store.dispatch('pbxConfig/setIdentifier', device);
|
|
|
|
this.$store.dispatch('pbxConfig/setIdentifier', device);
|
|
|
|
}
|
|
|
|
},
|
|
|
|
|
|
|
|
updateProfile(data) {
|
|
|
|
|
|
|
|
this.$store.dispatch('pbxConfig/setProfile', data);
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
watch: {
|
|
|
|
watch: {
|
|
|
|
deviceRemoved(device) {
|
|
|
|
deviceRemoved(device) {
|
|
|
@ -249,7 +260,12 @@
|
|
|
|
updatedDeviceSucceeded(succeeded) {
|
|
|
|
updatedDeviceSucceeded(succeeded) {
|
|
|
|
if(succeeded === true) {
|
|
|
|
if(succeeded === true) {
|
|
|
|
switch (this.updatedDeviceProperty) {
|
|
|
|
switch (this.updatedDeviceProperty) {
|
|
|
|
case 'staion_name':
|
|
|
|
case 'profile_id':
|
|
|
|
|
|
|
|
showToast(this.$t('pbxConfig.toasts.updatedProfile', {
|
|
|
|
|
|
|
|
name: this.updatedDevice.station_name
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case 'station_name':
|
|
|
|
showToast(this.$t('pbxConfig.toasts.updatedStationName', {
|
|
|
|
showToast(this.$t('pbxConfig.toasts.updatedStationName', {
|
|
|
|
name: this.updatedDevice.station_name
|
|
|
|
name: this.updatedDevice.station_name
|
|
|
|
}));
|
|
|
|
}));
|
|
|
|