Skip to content

Commit

Permalink
Merge pull request #556 from webitel/feature/cc-queues-timeout-switcher
Browse files Browse the repository at this point in the history
Feature/cc queues timeout switcher
  • Loading branch information
dlohvinov authored Nov 20, 2023
2 parents b105931 + bab46a8 commit 69782c5
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/app/locale/en/en.js
Original file line number Diff line number Diff line change
Expand Up @@ -817,6 +817,7 @@ export default {
statisticTime: 'Recalculation interval',
communications: 'Communication type',
manualDistribution: 'Manual distribution',
timeoutFromTheLastMessage: 'Timeout from the last message',
processing: {
processing: 'Processing',
enabled: 'Waiting for call result',
Expand Down
1 change: 1 addition & 0 deletions src/app/locale/ru/ru.js
Original file line number Diff line number Diff line change
Expand Up @@ -816,6 +816,7 @@ export default {
statisticTime: 'Интервал пересчета',
communications: 'Тип связи',
manualDistribution: 'Ручное распределение',
timeoutFromTheLastMessage: 'Время ожидания от последнего сообщения',
processing: {
processing: 'Обработка',
enabled: 'Ожидание результата задачи',
Expand Down
1 change: 1 addition & 0 deletions src/app/locale/ua/ua.js
Original file line number Diff line number Diff line change
Expand Up @@ -817,6 +817,7 @@ export default {
statisticTime: 'Інтервал перерахунку',
communications: 'Тип зв\'язку',
manualDistribution: 'Ручне розподілення',
timeoutFromTheLastMessage: 'Час очікування від останнього повідомлення',
processing: {
processing: 'Обробка',
enabled: 'Очікування результату задачі',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,13 @@
:value="itemInstance.payload.manualDistribution"
@change="setItemPayloadProp({ prop: 'manualDistribution', value: $event })"
></wt-switcher>
<wt-switcher
v-if="specificControls.timeoutFromTheLastMessage"
:disabled="disableUserInput"
:label="$t('objects.ccenter.queues.timeoutFromTheLastMessage')"
:value="itemInstance.payload.timeoutFromTheLastMessage"
@change="setItemPayloadProp({ prop: 'timeoutFromTheLastMessage', value: $event })"
></wt-switcher>
</div>
</section>
</template>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ const QueueTypeProperties = Object.freeze({
'stickyAgentSec',
'minOnlineAgents',
'manualDistribution',
'timeoutFromTheLastMessage',

// processing specific
'taskProcessing.enabled',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { QueueType } from 'webitel-sdk/esm2015/enums';
import queue from './defaults/defaultQueue';
import { Strategy } from '../enums/Strategy.enum';
import { TimeBaseScore } from '../enums/TimeBaseScore.enum';
import queue from './defaults/defaultQueue';
import processing from './defaults/processing';

const chatInboundQueue = () => ({
Expand All @@ -23,6 +23,7 @@ const chatInboundQueue = () => ({
maxWaitingSize: 0,
minOnlineAgents: 0,
manualDistribution: false,
timeoutFromTheLastMessage: false,
},
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import { mount } from '@vue/test-utils';
import { reactive } from 'vue';
import { shallowMount } from '@vue/test-utils';
import TheTriggers from '../the-triggers.vue';
import tableComponentComputedMock
from '../../../../../../../tests/unit/mocks/tableComponentComputed.mock';
import { useDummy } from '../../../../../../app/composables/useDummy';
import TheTriggers from '../the-triggers.vue';

jest.mock('../../../../../../app/composables/useDummy');
useDummy.mockImplementation(() => ({ store: reactive({}) }));

describe('TheTriggers', () => {
it('renders a component', () => {
const wrapper = shallowMount(TheTriggers, { computed: tableComponentComputedMock() });
const wrapper = mount(TheTriggers, { computed: tableComponentComputedMock() });
expect(wrapper.exists()).toBe(true);
});
});

0 comments on commit 69782c5

Please sign in to comment.