@webitel/ui-sdk 24.12.102 → 24.12.115
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/{plyr.min-ClXVuhkx.js → plyr.min-BRLz1cd6.js} +1 -1
- package/dist/ui-sdk.css +1 -1
- package/dist/ui-sdk.js +9707 -9471
- package/dist/ui-sdk.umd.cjs +19 -19
- package/package.json +1 -1
- package/src/api/clients/roles/roles.js +1 -1
- package/src/components/wt-tooltip/wt-tooltip.vue +10 -6
- package/src/composables/useAccessControl/v2/createUserAccessControl.ts +16 -6
- package/src/composables/useAccessControl/v2/types/CreateUserAccessControl.d.ts +2 -1
- package/src/composables/useWtTable/useWtTable.js +19 -20
- package/src/css/styleguide/placeholder/_placeholder.scss +0 -2
- package/src/enums/index.js +7 -7
- package/src/locale/en/en.js +80 -0
- package/src/locale/ru/ru.js +97 -0
- package/src/locale/ua/ua.js +97 -0
- package/src/modules/Filters/v2/filters/classes/FiltersManager.ts +3 -3
- package/src/modules/Filters/v2/filters/components/config/dynamic-filter-config-form-label.vue +2 -2
- package/src/modules/Filters/v2/filters/components/config/dynamic-filter-config-form.vue +13 -10
- package/src/modules/Filters/v2/filters/components/dynamic-filter-add-action.vue +17 -8
- package/src/modules/Filters/v2/filters/components/enums/amd-result-options.ts +38 -0
- package/src/modules/Filters/v2/filters/components/enums/boolean-options.ts +16 -0
- package/src/modules/Filters/v2/filters/components/enums/direction-options.ts +20 -0
- package/src/modules/Filters/v2/filters/components/enums/hangup-cause-options.ts +265 -0
- package/src/modules/Filters/v2/filters/components/enums/tag-options.ts +8 -0
- package/src/modules/Filters/v2/filters/components/preview/dynamic-filter-preview-info.vue +14 -27
- package/src/modules/Filters/v2/filters/components/preview/dynamic-filter-preview.vue +15 -6
- package/src/modules/Filters/v2/filters/components/values/_shared/durations/duration-filter-value-field.vue +48 -0
- package/src/modules/Filters/v2/filters/components/values/_shared/has-options/has-option-filter-value-field.vue +29 -0
- package/src/modules/Filters/v2/filters/components/values/agent/agent-filter-value-field.vue +57 -0
- package/src/modules/Filters/v2/filters/components/values/agent/agent-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/agent/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/amd-result/amd-result-filter-value-field.vue +52 -0
- package/src/modules/Filters/v2/filters/components/values/amd-result/amd-result-filter-value-preview.vue +20 -0
- package/src/modules/Filters/v2/filters/components/values/cause/cause-filter-value-field.vue +52 -0
- package/src/modules/Filters/v2/filters/components/values/cause/cause-filter-value-preview.vue +19 -0
- package/src/modules/Filters/v2/filters/components/values/contact/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/contact/contact-filter-value-field.vue +56 -0
- package/src/modules/Filters/v2/filters/components/values/contact/contact-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/created-at-from/created-at-from-filter-value-field.vue +23 -0
- package/src/modules/Filters/v2/filters/components/values/created-at-from/created-at-from-filter-value-preview.vue +15 -0
- package/src/modules/Filters/v2/filters/components/values/created-at-to/created-at-to-filter-value-field.vue +23 -0
- package/src/modules/Filters/v2/filters/components/values/created-at-to/created-at-to-filter-value-preview.vue +15 -0
- package/src/modules/Filters/v2/filters/components/values/direction/direction-filter-value-field.vue +51 -0
- package/src/modules/Filters/v2/filters/components/values/direction/direction-filter-value-preview.vue +17 -0
- package/src/modules/Filters/v2/filters/components/values/gateway/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/gateway/gateway-filter-value-field.vue +56 -0
- package/src/modules/Filters/v2/filters/components/values/gateway/gateway-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/grantee/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/grantee/grantee-filter-value-field.vue +56 -0
- package/src/modules/Filters/v2/filters/components/values/grantee/grantee-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/has-file/has-file-filter-value-field.vue +43 -0
- package/src/modules/Filters/v2/filters/components/values/has-file/has-file-filter-value-preview.vue +22 -0
- package/src/modules/Filters/v2/filters/components/values/has-transcription/has-transcription-filter-value-field.vue +43 -0
- package/src/modules/Filters/v2/filters/components/values/has-transcription/has-transcription-filter-value-preview.vue +22 -0
- package/src/modules/Filters/v2/filters/components/values/index.js +87 -0
- package/src/modules/Filters/v2/filters/components/values/queue/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/queue/queue-filter-value-field.vue +56 -0
- package/src/modules/Filters/v2/filters/components/values/queue/queue-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/rated/rated-filter-value-field.vue +43 -0
- package/src/modules/Filters/v2/filters/components/values/rated/rated-filter-value-preview.vue +22 -0
- package/src/modules/Filters/v2/filters/components/values/rated-by/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/rated-by/rated-by-filter-value-field.vue +56 -0
- package/src/modules/Filters/v2/filters/components/values/rated-by/rated-by-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/score/score-from-to-filter-value-field.vue +99 -0
- package/src/modules/Filters/v2/filters/components/values/score/score-from-to-filter-value-preview.vue +37 -0
- package/src/modules/Filters/v2/filters/components/values/tag/tag-filter-value-field.vue +52 -0
- package/src/modules/Filters/v2/filters/components/values/tag/tag-filter-value-preview.vue +18 -0
- package/src/modules/Filters/v2/filters/components/values/talk-duration/talk-duration-filter-value-field.vue +19 -0
- package/src/modules/Filters/v2/filters/components/values/talk-duration/talk-duration-filter-value-preview.vue +44 -0
- package/src/modules/Filters/v2/filters/components/values/team/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/team/team-filter-value-field.vue +56 -0
- package/src/modules/Filters/v2/filters/components/values/team/team-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/total-duration/total-duration-filter-value-field.vue +19 -0
- package/src/modules/Filters/v2/filters/components/values/total-duration/total-duration-filter-value-preview.vue +44 -0
- package/src/modules/Filters/v2/filters/components/values/user/config.js +4 -0
- package/src/modules/Filters/v2/filters/components/values/user/user-filter-value-field.vue +56 -0
- package/src/modules/Filters/v2/filters/components/values/user/user-filter-value-preview.vue +32 -0
- package/src/modules/Filters/v2/filters/components/values/variable/variable-filter-value-field.vue +51 -0
- package/src/modules/Filters/v2/filters/components/values/variable/variable-filter-value-preview.vue +36 -0
- package/src/modules/Filters/v2/filters/types/Filter.d.ts +5 -0
- package/src/modules/Filters/v2/table/createTableStore.store.ts +12 -1
- package/src/modules/Filters/v2/types/tableStore.types.ts +1 -0
- package/src/modules/Filters/v2/filters/components/values/users/config.js +0 -4
- package/src/modules/Filters/v2/filters/components/values/users/user-filter-value-field.vue +0 -35
- package/src/modules/Filters/v2/filters/components/values/users/user-filter-value-preview.vue +0 -13
package/package.json
CHANGED
|
@@ -27,7 +27,7 @@ const preRequestHandler = (item) => {
|
|
|
27
27
|
};
|
|
28
28
|
|
|
29
29
|
const getRoleList = async (params) => {
|
|
30
|
-
const fieldsToSend = ['page', 'size', 'q', 'sort', 'fields', '
|
|
30
|
+
const fieldsToSend = ['page', 'size', 'q', 'sort', 'fields', 'ids'];
|
|
31
31
|
|
|
32
32
|
const url = applyTransform(params, [
|
|
33
33
|
merge(getDefaultGetParams()),
|
|
@@ -25,7 +25,9 @@
|
|
|
25
25
|
@hide="hideTooltip"
|
|
26
26
|
@show="showTooltip"
|
|
27
27
|
>
|
|
28
|
-
<
|
|
28
|
+
<div ref="floatingChild">
|
|
29
|
+
<slot v-bind="{ hide: hideTooltip }" />
|
|
30
|
+
</div>
|
|
29
31
|
</wt-tooltip-floating>
|
|
30
32
|
</div>
|
|
31
33
|
</template>
|
|
@@ -39,9 +41,8 @@ import {
|
|
|
39
41
|
shift,
|
|
40
42
|
useFloating,
|
|
41
43
|
} from '@floating-ui/vue';
|
|
42
|
-
import { onBeforeUnmount, onMounted, ref, watch } from 'vue';
|
|
44
|
+
import { onBeforeUnmount, onMounted, ref, useTemplateRef, watch } from 'vue';
|
|
43
45
|
|
|
44
|
-
import debounce from '../../scripts/debounce.js';
|
|
45
46
|
import { useTooltipTriggerSubscriptions } from './_internals/useTooltipTriggerSubscriptions.js';
|
|
46
47
|
import WtTooltipFloating from './_internals/wt-tooltip-floating.vue';
|
|
47
48
|
|
|
@@ -74,8 +75,9 @@ const props = defineProps({
|
|
|
74
75
|
|
|
75
76
|
const emit = defineEmits(['update:visible']);
|
|
76
77
|
|
|
77
|
-
const activator =
|
|
78
|
-
const floating =
|
|
78
|
+
const activator = useTemplateRef('activator');
|
|
79
|
+
const floating = useTemplateRef('floating');
|
|
80
|
+
const floatingChild = useTemplateRef('floatingChild');
|
|
79
81
|
const isVisible = ref(props.visible);
|
|
80
82
|
|
|
81
83
|
const emitVisibilityChange = () => {
|
|
@@ -91,7 +93,9 @@ const showTooltip = (event = {}) => {
|
|
|
91
93
|
};
|
|
92
94
|
|
|
93
95
|
const hideTooltip = (event = {}) => {
|
|
94
|
-
|
|
96
|
+
const contains = floatingChild.value?.contains(event.target);
|
|
97
|
+
if (!isVisible.value || event.usedByTooltip || contains) return;
|
|
98
|
+
|
|
95
99
|
isVisible.value = false;
|
|
96
100
|
emitVisibilityChange();
|
|
97
101
|
removeScrollListener();
|
|
@@ -4,16 +4,18 @@ import { useRoute } from 'vue-router';
|
|
|
4
4
|
import { _wtUiLog } from '../../../scripts/logger';
|
|
5
5
|
import type {
|
|
6
6
|
CreateUserAccessControlComposableParams,
|
|
7
|
-
UseAccessControlReturn,
|
|
7
|
+
UseAccessControlReturn, UseUserAccessControlComposableOptions,
|
|
8
8
|
} from './types/CreateUserAccessControl';
|
|
9
9
|
|
|
10
10
|
export const createUserAccessControlComposable = (
|
|
11
11
|
useUserinfoStore: CreateUserAccessControlComposableParams,
|
|
12
12
|
) => {
|
|
13
13
|
const useUserAccessControl = (
|
|
14
|
-
|
|
15
|
-
// options: UseUserAccessControlComposableOptions = {},
|
|
14
|
+
options?: UseUserAccessControlComposableOptions,
|
|
16
15
|
): UseAccessControlReturn => {
|
|
16
|
+
const resource = typeof options === 'string' ? options: options?.resource;
|
|
17
|
+
const useUpdateAccessAsAllMutableChecksSource = options?.useUpdateAccessAsAllMutableChecksSource;
|
|
18
|
+
|
|
17
19
|
const route = useRoute();
|
|
18
20
|
const object = resource || route?.meta?.WtObject;
|
|
19
21
|
|
|
@@ -31,22 +33,30 @@ export const createUserAccessControlComposable = (
|
|
|
31
33
|
const hasReadAccess = computed(() => {
|
|
32
34
|
return userinfoStore.hasReadAccess(object);
|
|
33
35
|
});
|
|
34
|
-
const hasCreateAccess = computed(() => {
|
|
35
|
-
return userinfoStore.hasCreateAccess(object);
|
|
36
|
-
});
|
|
37
36
|
const hasUpdateAccess = computed(() => {
|
|
38
37
|
return userinfoStore.hasUpdateAccess(object);
|
|
39
38
|
});
|
|
39
|
+
const hasCreateAccess = computed(() => {
|
|
40
|
+
if (useUpdateAccessAsAllMutableChecksSource) return hasUpdateAccess.value;
|
|
41
|
+
|
|
42
|
+
return userinfoStore.hasCreateAccess(object);
|
|
43
|
+
});
|
|
40
44
|
const hasDeleteAccess = computed(() => {
|
|
45
|
+
if (useUpdateAccessAsAllMutableChecksSource) return hasUpdateAccess.value;
|
|
46
|
+
|
|
41
47
|
return userinfoStore.hasDeleteAccess(object);
|
|
42
48
|
});
|
|
43
49
|
|
|
44
50
|
const hasSaveActionAccess = computed(() => {
|
|
51
|
+
if (useUpdateAccessAsAllMutableChecksSource) return hasUpdateAccess.value;
|
|
52
|
+
|
|
45
53
|
if (route.params.id === 'new') return hasCreateAccess.value;
|
|
46
54
|
return hasUpdateAccess.value;
|
|
47
55
|
});
|
|
48
56
|
|
|
49
57
|
const disableUserInput = computed(() => {
|
|
58
|
+
if (useUpdateAccessAsAllMutableChecksSource) return !hasUpdateAccess.value;
|
|
59
|
+
|
|
50
60
|
if (route.params.id === 'new') return !hasCreateAccess.value;
|
|
51
61
|
return !hasUpdateAccess.value;
|
|
52
62
|
});
|
|
@@ -6,8 +6,9 @@ import type { createUserAccessStore } from '../../../../modules/Userinfo/v2/stor
|
|
|
6
6
|
export type CreateUserAccessControlComposableParams =
|
|
7
7
|
ReturnType<createUserAccessStore>;
|
|
8
8
|
|
|
9
|
-
export type UseUserAccessControlComposableOptions = {
|
|
9
|
+
export type UseUserAccessControlComposableOptions = WtObject | {
|
|
10
10
|
resource?: WtObject;
|
|
11
|
+
useUpdateAccessAsAllMutableChecksSource?: boolean;
|
|
11
12
|
};
|
|
12
13
|
|
|
13
14
|
export interface UseAccessControlReturn {
|
|
@@ -1,24 +1,23 @@
|
|
|
1
1
|
import { computed } from 'vue';
|
|
2
2
|
import { useI18n } from 'vue-i18n';
|
|
3
3
|
export const useWtTable = ({ headers }) => {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
};
|
|
4
|
+
const { t } = useI18n();
|
|
5
|
+
const tableHeaders = computed(() => {
|
|
6
|
+
return headers
|
|
7
|
+
.filter((header) => header.show === undefined || header.show)
|
|
8
|
+
.map((header) => {
|
|
9
|
+
if (!header.text && header.locale) {
|
|
10
|
+
return {
|
|
11
|
+
...header,
|
|
12
|
+
text: typeof header.locale === 'string'
|
|
13
|
+
? t(header.locale)
|
|
14
|
+
: t(...header.locale),
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
return header;
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
return {
|
|
21
|
+
tableHeaders,
|
|
22
|
+
};
|
|
24
23
|
};
|
|
@@ -24,7 +24,6 @@ $vendors: (':-webkit', '-moz', ':-moz', '-ms');
|
|
|
24
24
|
@mixin wt-placeholder($style: '') {
|
|
25
25
|
@each $vendor in $vendors {
|
|
26
26
|
@include optional-at-root(':#{$vendor}-input-placeholder') {
|
|
27
|
-
font: inherit;
|
|
28
27
|
transition: var(--transition);
|
|
29
28
|
|
|
30
29
|
@if ($style == 'error') {
|
|
@@ -46,7 +45,6 @@ $vendors: (':-webkit', '-moz', ':-moz', '-ms');
|
|
|
46
45
|
*/
|
|
47
46
|
%wt-placeholder {
|
|
48
47
|
transition: var(--transition);
|
|
49
|
-
font: inherit;
|
|
50
48
|
color: var(--wt-text-field-placeholder-color);
|
|
51
49
|
}
|
|
52
50
|
|
package/src/enums/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import AbstractUserStatus from './AbstractUserStatus/AbstractUserStatus.enum';
|
|
2
|
-
import AgentStatus from './AgentStatus/AgentStatus.enum';
|
|
3
|
-
import ChatGatewayProvider from './ChatGatewayProvider/ChatGatewayProvider.enum';
|
|
1
|
+
import AbstractUserStatus from './AbstractUserStatus/AbstractUserStatus.enum.js';
|
|
2
|
+
import AgentStatus from './AgentStatus/AgentStatus.enum.js';
|
|
3
|
+
import ChatGatewayProvider from './ChatGatewayProvider/ChatGatewayProvider.enum.js';
|
|
4
4
|
import { ComponentSize } from './ComponentSize/ComponentSize';
|
|
5
5
|
import { CrudAction } from './CrudAction/CrudAction';
|
|
6
|
-
import IconAction from './IconAction/IconAction.enum';
|
|
7
|
-
import QueueType from './QueueType/QueueType.enum';
|
|
8
|
-
import TypesExportedSettings from './TypesExportedSettings/TypesExportedSettings.enum';
|
|
6
|
+
import IconAction from './IconAction/IconAction.enum.js';
|
|
7
|
+
import QueueType from './QueueType/QueueType.enum.js';
|
|
8
|
+
import TypesExportedSettings from './TypesExportedSettings/TypesExportedSettings.enum.js';
|
|
9
9
|
import { AdminSections } from './WebitelApplications/AdminSections';
|
|
10
10
|
import { AuditorSections } from './WebitelApplications/AuditorSections';
|
|
11
11
|
import { CrmSections } from './WebitelApplications/CrmSections';
|
|
12
12
|
import { SupervisorSections } from './WebitelApplications/SupervisorSections';
|
|
13
|
-
import WebitelApplications from './WebitelApplications/WebitelApplications.enum';
|
|
13
|
+
import WebitelApplications from './WebitelApplications/WebitelApplications.enum.js';
|
|
14
14
|
import { WtApplication } from './WebitelApplications/WtApplication';
|
|
15
15
|
import { WtObject } from './WtObject/WtObject';
|
|
16
16
|
export { AbstractUserStatus, AdminSections, AgentStatus, AuditorSections, ChatGatewayProvider, ComponentSize, CrmSections, CrudAction, IconAction, QueueType, SupervisorSections, TypesExportedSettings, WebitelApplications, WtApplication, WtObject, };
|
package/src/locale/en/en.js
CHANGED
|
@@ -147,7 +147,19 @@ export default {
|
|
|
147
147
|
role: 'Role | Roles',
|
|
148
148
|
user: 'User | Users',
|
|
149
149
|
calendar: 'Calendar | Calendars',
|
|
150
|
+
direction: 'Direction',
|
|
151
|
+
gateway: 'Gateway | Gateways',
|
|
152
|
+
hangupCause: 'Hangup cause',
|
|
153
|
+
hasOption: 'Has option',
|
|
154
|
+
hasRecording: 'Has recording',
|
|
155
|
+
amdResult: 'AMD result',
|
|
156
|
+
evaluation: 'Evaluation',
|
|
157
|
+
ratedBy: 'Rated by',
|
|
158
|
+
talkDuration: 'Talk duration',
|
|
159
|
+
totalDuration: 'Total duration',
|
|
160
|
+
transcription: 'Transcription',
|
|
150
161
|
queue: {
|
|
162
|
+
queue: 'Queue | Queues',
|
|
151
163
|
type: {
|
|
152
164
|
[QueueType.INBOUND_QUEUE]: 'Inbound queue',
|
|
153
165
|
[QueueType.OFFLINE_QUEUE]: 'Offline queue',
|
|
@@ -161,6 +173,7 @@ export default {
|
|
|
161
173
|
},
|
|
162
174
|
},
|
|
163
175
|
agent: {
|
|
176
|
+
agent: 'Agent | Agents',
|
|
164
177
|
status: {
|
|
165
178
|
[AgentStatus.Online]: 'Online',
|
|
166
179
|
[AgentStatus.Pause]: 'Pause',
|
|
@@ -458,9 +471,76 @@ export default {
|
|
|
458
471
|
filterValue: ({ linked }) => {
|
|
459
472
|
return linked('vocabulary.values');
|
|
460
473
|
},
|
|
474
|
+
filterValueFrom: ({ linked }) => {
|
|
475
|
+
const from = linked('reusable.from').toLowerCase();
|
|
476
|
+
return `${linked('vocabulary.values')} ${from}`;
|
|
477
|
+
},
|
|
461
478
|
filterLabel: ({ linked }) => {
|
|
462
479
|
return linked('vocabulary.labels');
|
|
463
480
|
},
|
|
481
|
+
agent: ({ linked }) => {
|
|
482
|
+
return linked('objects.agent.agent');
|
|
483
|
+
},
|
|
484
|
+
amdResult: ({ linked }) => {
|
|
485
|
+
return linked('objects.amdResult');
|
|
486
|
+
},
|
|
487
|
+
contact: ({ linked }) => {
|
|
488
|
+
return linked('vocabulary.contact');
|
|
489
|
+
},
|
|
490
|
+
createdAtFrom: ({ linked }) => {
|
|
491
|
+
return linked('reusable.from');
|
|
492
|
+
},
|
|
493
|
+
createdAtTo: ({ linked }) => {
|
|
494
|
+
return linked('reusable.to');
|
|
495
|
+
},
|
|
496
|
+
direction: ({ linked }) => {
|
|
497
|
+
return linked('objects.direction');
|
|
498
|
+
},
|
|
499
|
+
rated: ({ linked }) => {
|
|
500
|
+
return linked('objects.evaluation');
|
|
501
|
+
},
|
|
502
|
+
gateway: ({ linked }) => {
|
|
503
|
+
return linked('objects.gateway');
|
|
504
|
+
},
|
|
505
|
+
grantee: ({ linked }) => {
|
|
506
|
+
return linked('objects.grantee');
|
|
507
|
+
},
|
|
508
|
+
cause: ({ linked }) => {
|
|
509
|
+
return linked('objects.hangupCause');
|
|
510
|
+
},
|
|
511
|
+
queue: ({ linked }) => {
|
|
512
|
+
return linked('objects.queue.queue');
|
|
513
|
+
},
|
|
514
|
+
ratedBy: ({ linked }) => {
|
|
515
|
+
return linked('objects.ratedBy');
|
|
516
|
+
},
|
|
517
|
+
hasFile: ({ linked }) => {
|
|
518
|
+
return linked('objects.hasRecording');
|
|
519
|
+
},
|
|
520
|
+
score: ({ linked }) => {
|
|
521
|
+
return linked('webitelUI.auditForm.score');
|
|
522
|
+
},
|
|
523
|
+
tags: ({ linked }) => {
|
|
524
|
+
return linked('vocabulary.tag');
|
|
525
|
+
},
|
|
526
|
+
talkSec: ({ linked }) => {
|
|
527
|
+
return linked('objects.talkDuration');
|
|
528
|
+
},
|
|
529
|
+
team: ({ linked }) => {
|
|
530
|
+
return linked('objects.team');
|
|
531
|
+
},
|
|
532
|
+
duration: ({ linked }) => {
|
|
533
|
+
return linked('objects.totalDuration');
|
|
534
|
+
},
|
|
535
|
+
hasTranscription: ({ linked }) => {
|
|
536
|
+
return linked('objects.transcription');
|
|
537
|
+
},
|
|
538
|
+
user: ({ linked }) => {
|
|
539
|
+
return linked('objects.user');
|
|
540
|
+
},
|
|
541
|
+
variable: ({ linked }) => {
|
|
542
|
+
return linked('vocabulary.variables');
|
|
543
|
+
},
|
|
464
544
|
},
|
|
465
545
|
},
|
|
466
546
|
errorNotifications: {
|
package/src/locale/ru/ru.js
CHANGED
|
@@ -145,7 +145,19 @@ export default {
|
|
|
145
145
|
user: 'Пользователь | Пользователи',
|
|
146
146
|
role: 'Роль | Роли',
|
|
147
147
|
calendar: 'Календарь | Календари',
|
|
148
|
+
direction: 'Направление',
|
|
149
|
+
gateway: 'Шлюз | Шлюзы',
|
|
150
|
+
hangupCause: 'Причина окончания',
|
|
151
|
+
hasOption: 'Has option',
|
|
152
|
+
hasRecording: 'Запись разговора',
|
|
153
|
+
amdResult: 'AMD результат',
|
|
154
|
+
evaluation: 'Оценивание',
|
|
155
|
+
ratedBy: 'Оценено кем',
|
|
156
|
+
talkDuration: 'Длительность разговора',
|
|
157
|
+
totalDuration: 'Общая длительность',
|
|
158
|
+
transcription: 'Транскрипция',
|
|
148
159
|
queue: {
|
|
160
|
+
queue: 'Очередь | Очереди',
|
|
149
161
|
type: {
|
|
150
162
|
[QueueType.INBOUND_QUEUE]: 'Входящая очередь',
|
|
151
163
|
[QueueType.OFFLINE_QUEUE]: 'Оффлайн очередь',
|
|
@@ -159,6 +171,7 @@ export default {
|
|
|
159
171
|
},
|
|
160
172
|
},
|
|
161
173
|
agent: {
|
|
174
|
+
agent: 'Оператор | Операторы',
|
|
162
175
|
status: {
|
|
163
176
|
[AgentStatus.Online]: 'Онлайн',
|
|
164
177
|
[AgentStatus.Pause]: 'Пауза',
|
|
@@ -442,6 +455,90 @@ export default {
|
|
|
442
455
|
label: 'Что-то пошло не так. Пожалуйста, попробуйте еще раз',
|
|
443
456
|
exportToJson: 'Экспортировать в JSON',
|
|
444
457
|
},
|
|
458
|
+
filters: {
|
|
459
|
+
addFilter: ({ linked }) => {
|
|
460
|
+
return `${linked('reusable.add')} ${linked(
|
|
461
|
+
'reusable.filter',
|
|
462
|
+
).toLowerCase()}`;
|
|
463
|
+
},
|
|
464
|
+
filterName: ({ linked }) => {
|
|
465
|
+
// because filter select has a 'column' label now
|
|
466
|
+
return linked('vocabulary.column');
|
|
467
|
+
},
|
|
468
|
+
filterValue: ({ linked }) => {
|
|
469
|
+
return linked('vocabulary.values');
|
|
470
|
+
},
|
|
471
|
+
filterValueFrom: ({ linked }) => {
|
|
472
|
+
const from = linked('reusable.from').toLowerCase();
|
|
473
|
+
return `${linked('vocabulary.values')} ${from}`;
|
|
474
|
+
},
|
|
475
|
+
filterLabel: ({ linked }) => {
|
|
476
|
+
return linked('vocabulary.labels');
|
|
477
|
+
},
|
|
478
|
+
agent: ({ linked }) => {
|
|
479
|
+
return linked('objects.agent.agent');
|
|
480
|
+
},
|
|
481
|
+
amdResult: ({ linked }) => {
|
|
482
|
+
return linked('objects.amdResult');
|
|
483
|
+
},
|
|
484
|
+
contact: ({ linked }) => {
|
|
485
|
+
return linked('vocabulary.contact');
|
|
486
|
+
},
|
|
487
|
+
createdAtFrom: ({ linked }) => {
|
|
488
|
+
return linked('reusable.from');
|
|
489
|
+
},
|
|
490
|
+
createdAtTo: ({ linked }) => {
|
|
491
|
+
return linked('reusable.to');
|
|
492
|
+
},
|
|
493
|
+
direction: ({ linked }) => {
|
|
494
|
+
return linked('objects.direction');
|
|
495
|
+
},
|
|
496
|
+
rated: ({ linked }) => {
|
|
497
|
+
return linked('objects.evaluation');
|
|
498
|
+
},
|
|
499
|
+
gateway: ({ linked }) => {
|
|
500
|
+
return linked('objects.gateway');
|
|
501
|
+
},
|
|
502
|
+
grantee: ({ linked }) => {
|
|
503
|
+
return linked('objects.grantee');
|
|
504
|
+
},
|
|
505
|
+
cause: ({ linked }) => {
|
|
506
|
+
return linked('objects.hangupCause');
|
|
507
|
+
},
|
|
508
|
+
hasOption: ({ linked }) => {
|
|
509
|
+
return linked('objects.hasOption'); ////
|
|
510
|
+
},
|
|
511
|
+
queue: ({ linked }) => {
|
|
512
|
+
return linked('objects.queue.queue');
|
|
513
|
+
},
|
|
514
|
+
hasFile: ({ linked }) => {
|
|
515
|
+
return linked('objects.hasRecording');
|
|
516
|
+
},
|
|
517
|
+
score: ({ linked }) => {
|
|
518
|
+
return linked('webitelUI.auditForm.score');
|
|
519
|
+
},
|
|
520
|
+
tags: ({ linked }) => {
|
|
521
|
+
return linked('vocabulary.tag');
|
|
522
|
+
},
|
|
523
|
+
talkSec: ({ linked }) => {
|
|
524
|
+
return linked('objects.talkDuration');
|
|
525
|
+
},
|
|
526
|
+
team: ({ linked }) => {
|
|
527
|
+
return linked('objects.team');
|
|
528
|
+
},
|
|
529
|
+
duration: ({ linked }) => {
|
|
530
|
+
return linked('objects.totalDuration');
|
|
531
|
+
},
|
|
532
|
+
hasTranscription: ({ linked }) => {
|
|
533
|
+
return linked('objects.transcription');
|
|
534
|
+
},
|
|
535
|
+
user: ({ linked }) => {
|
|
536
|
+
return linked('objects.user');
|
|
537
|
+
},
|
|
538
|
+
variable: ({ linked }) => {
|
|
539
|
+
return linked('vocabulary.variables');
|
|
540
|
+
},
|
|
541
|
+
},
|
|
445
542
|
},
|
|
446
543
|
errorNotifications: {
|
|
447
544
|
chatHistoryApi: 'Произошла ошибка загрузки истории чата',
|
package/src/locale/ua/ua.js
CHANGED
|
@@ -145,7 +145,19 @@ export default {
|
|
|
145
145
|
user: 'Користувач | Користувачі',
|
|
146
146
|
role: 'Роль | Ролі',
|
|
147
147
|
calendar: 'Календар | Календарі',
|
|
148
|
+
direction: 'Напрямок',
|
|
149
|
+
gateway: 'Шлюз | Шлюзи',
|
|
150
|
+
hangupCause: 'Причина завершення',
|
|
151
|
+
hasOption: 'Has option',
|
|
152
|
+
hasRecording: 'Запис розмови',
|
|
153
|
+
amdResult: 'AMD результат',
|
|
154
|
+
evaluation: 'Оцінювання',
|
|
155
|
+
ratedBy: 'Оцінено ким',
|
|
156
|
+
talkDuration: 'Тривалість розмови',
|
|
157
|
+
totalDuration: 'Загальна тривалість',
|
|
158
|
+
transcription: 'Транскрипція',
|
|
148
159
|
queue: {
|
|
160
|
+
queue: 'Черга | Черги',
|
|
149
161
|
type: {
|
|
150
162
|
[QueueType.INBOUND_QUEUE]: 'Вхідна черга',
|
|
151
163
|
[QueueType.OFFLINE_QUEUE]: 'Оффлайн черга',
|
|
@@ -159,6 +171,7 @@ export default {
|
|
|
159
171
|
},
|
|
160
172
|
},
|
|
161
173
|
agent: {
|
|
174
|
+
agent: 'Оператор | Оператори',
|
|
162
175
|
status: {
|
|
163
176
|
[AgentStatus.Online]: 'Онлайн',
|
|
164
177
|
[AgentStatus.Pause]: 'Пауза',
|
|
@@ -442,6 +455,90 @@ export default {
|
|
|
442
455
|
label: 'Щось пішло не так. Будь ласка, спробуйте ще раз',
|
|
443
456
|
exportToJson: 'Експортувати в JSON',
|
|
444
457
|
},
|
|
458
|
+
filters: {
|
|
459
|
+
addFilter: ({ linked }) => {
|
|
460
|
+
return `${linked('reusable.add')} ${linked(
|
|
461
|
+
'reusable.filter',
|
|
462
|
+
).toLowerCase()}`;
|
|
463
|
+
},
|
|
464
|
+
filterName: ({ linked }) => {
|
|
465
|
+
// because filter select has a 'column' label now
|
|
466
|
+
return linked('vocabulary.column');
|
|
467
|
+
},
|
|
468
|
+
filterValue: ({ linked }) => {
|
|
469
|
+
return linked('vocabulary.values');
|
|
470
|
+
},
|
|
471
|
+
filterValueFrom: ({ linked }) => {
|
|
472
|
+
const from = linked('reusable.from').toLowerCase();
|
|
473
|
+
return `${linked('vocabulary.values')} ${from}`;
|
|
474
|
+
},
|
|
475
|
+
filterLabel: ({ linked }) => {
|
|
476
|
+
return linked('vocabulary.labels');
|
|
477
|
+
},
|
|
478
|
+
agent: ({ linked }) => {
|
|
479
|
+
return linked('objects.agent.agent');
|
|
480
|
+
},
|
|
481
|
+
amdResult: ({ linked }) => {
|
|
482
|
+
return linked('objects.amdResult');
|
|
483
|
+
},
|
|
484
|
+
contact: ({ linked }) => {
|
|
485
|
+
return linked('vocabulary.contact');
|
|
486
|
+
},
|
|
487
|
+
createdAtFrom: ({ linked }) => {
|
|
488
|
+
return linked('reusable.from');
|
|
489
|
+
},
|
|
490
|
+
createdAtTo: ({ linked }) => {
|
|
491
|
+
return linked('reusable.to');
|
|
492
|
+
},
|
|
493
|
+
direction: ({ linked }) => {
|
|
494
|
+
return linked('objects.direction');
|
|
495
|
+
},
|
|
496
|
+
rated: ({ linked }) => {
|
|
497
|
+
return linked('objects.evaluation');
|
|
498
|
+
},
|
|
499
|
+
gateway: ({ linked }) => {
|
|
500
|
+
return linked('objects.gateway');
|
|
501
|
+
},
|
|
502
|
+
grantee: ({ linked }) => {
|
|
503
|
+
return linked('objects.grantee');
|
|
504
|
+
},
|
|
505
|
+
cause: ({ linked }) => {
|
|
506
|
+
return linked('objects.hangupCause');
|
|
507
|
+
},
|
|
508
|
+
hasOption: ({ linked }) => {
|
|
509
|
+
return linked('objects.hasOption'); ////
|
|
510
|
+
},
|
|
511
|
+
queue: ({ linked }) => {
|
|
512
|
+
return linked('objects.queue.queue');
|
|
513
|
+
},
|
|
514
|
+
hasFile: ({ linked }) => {
|
|
515
|
+
return linked('objects.hasRecording');
|
|
516
|
+
},
|
|
517
|
+
score: ({ linked }) => {
|
|
518
|
+
return linked('webitelUI.auditForm.score');
|
|
519
|
+
},
|
|
520
|
+
tags: ({ linked }) => {
|
|
521
|
+
return linked('vocabulary.tag');
|
|
522
|
+
},
|
|
523
|
+
talkSec: ({ linked }) => {
|
|
524
|
+
return linked('objects.talkDuration');
|
|
525
|
+
},
|
|
526
|
+
team: ({ linked }) => {
|
|
527
|
+
return linked('objects.team');
|
|
528
|
+
},
|
|
529
|
+
duration: ({ linked }) => {
|
|
530
|
+
return linked('objects.totalDuration');
|
|
531
|
+
},
|
|
532
|
+
hasTranscription: ({ linked }) => {
|
|
533
|
+
return linked('objects.transcription');
|
|
534
|
+
},
|
|
535
|
+
user: ({ linked }) => {
|
|
536
|
+
return linked('objects.user');
|
|
537
|
+
},
|
|
538
|
+
variable: ({ linked }) => {
|
|
539
|
+
return linked('vocabulary.variables');
|
|
540
|
+
},
|
|
541
|
+
},
|
|
445
542
|
},
|
|
446
543
|
errorNotifications: {
|
|
447
544
|
chatHistoryApi: 'Сталася помилка завантаження історії чату',
|
|
@@ -128,9 +128,9 @@ class FiltersManager implements IFiltersManager {
|
|
|
128
128
|
include,
|
|
129
129
|
exclude,
|
|
130
130
|
}: {
|
|
131
|
-
include
|
|
132
|
-
exclude
|
|
133
|
-
}): IFilter[] {
|
|
131
|
+
include?: FilterName[];
|
|
132
|
+
exclude?: FilterName[];
|
|
133
|
+
} = {}): IFilter[] {
|
|
134
134
|
const useInclude = !isEmpty(include);
|
|
135
135
|
const useExclude = !isEmpty(exclude) && !useInclude;
|
|
136
136
|
|
package/src/modules/Filters/v2/filters/components/config/dynamic-filter-config-form-label.vue
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<wt-input
|
|
3
3
|
:value="model"
|
|
4
4
|
:label="t('webitelUI.filters.filterLabel')"
|
|
5
|
-
:v="v
|
|
5
|
+
:v="v$.model"
|
|
6
6
|
@input="model = $event"
|
|
7
7
|
/>
|
|
8
8
|
</template>
|
|
@@ -13,7 +13,7 @@ import { maxLength } from '@vuelidate/validators';
|
|
|
13
13
|
import { computed, watch } from 'vue';
|
|
14
14
|
import { useI18n } from 'vue-i18n';
|
|
15
15
|
|
|
16
|
-
import WtInput from '
|
|
16
|
+
import WtInput from '../../../../../../components/wt-input/wt-input.vue';
|
|
17
17
|
|
|
18
18
|
const MAX_STRING_LENGTH = 50;
|
|
19
19
|
|
|
@@ -5,8 +5,10 @@
|
|
|
5
5
|
:label="t('webitelUI.filters.filterName')"
|
|
6
6
|
:options="options"
|
|
7
7
|
:value="filterName"
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
:clearable="false"
|
|
9
|
+
track-by="value"
|
|
10
|
+
use-value-from-options-by-prop="value"
|
|
11
|
+
@input="onFilterNameUpdate($event)"
|
|
10
12
|
/>
|
|
11
13
|
|
|
12
14
|
<slot
|
|
@@ -22,7 +24,7 @@
|
|
|
22
24
|
|
|
23
25
|
<dynamic-filter-config-form-label
|
|
24
26
|
:value="filterLabel"
|
|
25
|
-
@update:value="onLabelValueUpdate"
|
|
27
|
+
@update:model-value="onLabelValueUpdate"
|
|
26
28
|
@update:invalid="(v) => (invalid = v)"
|
|
27
29
|
/>
|
|
28
30
|
|
|
@@ -51,13 +53,9 @@ import deepcopy from 'deep-copy';
|
|
|
51
53
|
import { ref, watch } from 'vue';
|
|
52
54
|
import { useI18n } from 'vue-i18n';
|
|
53
55
|
|
|
54
|
-
import WtButton from '
|
|
55
|
-
import WtSelect from '
|
|
56
|
-
import type {
|
|
57
|
-
FilterInitParams,
|
|
58
|
-
FilterName,
|
|
59
|
-
IFilter,
|
|
60
|
-
} from '../../../types/Filter';
|
|
56
|
+
import WtButton from '../../../../../../components/wt-button/wt-button.vue';
|
|
57
|
+
import WtSelect from '../../../../../../components/wt-select/wt-select.vue';
|
|
58
|
+
import type { FilterInitParams, FilterName, IFilter } from '../../types/Filter';
|
|
61
59
|
import DynamicFilterConfigFormLabel from './dynamic-filter-config-form-label.vue';
|
|
62
60
|
|
|
63
61
|
interface FilterNameSelectRepresentation {
|
|
@@ -100,6 +98,11 @@ const onLabelValueUpdate = (val: string) => {
|
|
|
100
98
|
touchedLabel.value = true;
|
|
101
99
|
};
|
|
102
100
|
|
|
101
|
+
const onFilterNameUpdate = (val: string) => {
|
|
102
|
+
filterName.value = val;
|
|
103
|
+
filterValue.value = null;
|
|
104
|
+
};
|
|
105
|
+
|
|
103
106
|
const submit = () => {
|
|
104
107
|
emit('submit', {
|
|
105
108
|
name: filterName.value,
|