@snabcentr/vue-ui-lib 3.55.1 → 3.56.0

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.
@@ -14,6 +14,10 @@ declare const _default: import('vue').DefineComponent<{
14
14
  * Признак, что значение времени следует расположить на второй строке.
15
15
  */
16
16
  isTimeOnSecondLine?: boolean;
17
+ /**
18
+ * Признак, что значение времени следует отобразить.
19
+ */
20
+ isShowTime?: boolean;
17
21
  }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{
18
22
  /**
19
23
  * Дата.
@@ -27,5 +31,11 @@ declare const _default: import('vue').DefineComponent<{
27
31
  * Признак, что значение времени следует расположить на второй строке.
28
32
  */
29
33
  isTimeOnSecondLine?: boolean;
30
- }> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLSpanElement>;
34
+ /**
35
+ * Признак, что значение времени следует отобразить.
36
+ */
37
+ isShowTime?: boolean;
38
+ }> & Readonly<{}>, {
39
+ isShowTime: boolean;
40
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLSpanElement>;
31
41
  export default _default;
@@ -0,0 +1,20 @@
1
+ import { IOrderInfo } from '@snabcentr/common-lib';
2
+ import { IOrdersTableFields } from '../../properties/interfaces/i-orders-table-fields';
3
+ /**
4
+ * Компонент контекстного меню заказа.
5
+ */
6
+ declare const _default: import('vue').DefineComponent<Pick<IOrdersTableFields, "orderContextButtonsConfig" | "onOrderContextSelect"> & {
7
+ /**
8
+ * Данные о заказе.
9
+ */
10
+ order: IOrderInfo;
11
+ }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Pick<IOrdersTableFields, "orderContextButtonsConfig" | "onOrderContextSelect"> & {
12
+ /**
13
+ * Данные о заказе.
14
+ */
15
+ order: IOrderInfo;
16
+ }> & Readonly<{}>, {
17
+ orderContextButtonsConfig: (order: IOrderInfo) => Array<import('naive-ui').DropdownOption | import('naive-ui').DropdownGroupOption | import('naive-ui').DropdownDividerOption | import('naive-ui').DropdownRenderOption>;
18
+ onOrderContextSelect: (order: IOrderInfo, key: string | number) => void;
19
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
20
+ export default _default;
@@ -8,6 +8,10 @@ declare const _default: import('vue').DefineComponent<IOrdersTableFields & {
8
8
  * URL страницы заказов. В качестве указания идентификатора заказа необходимо использовать значение `:id`.
9
9
  */
10
10
  orderUrl: string;
11
+ /**
12
+ * Минимальная ширина таблицы (с паддингами помещается в экран 1440px).
13
+ */
14
+ tableMinWidth?: number;
11
15
  /**
12
16
  * Фильтры поиска записей.
13
17
  */
@@ -20,11 +24,21 @@ declare const _default: import('vue').DefineComponent<IOrdersTableFields & {
20
24
  * Параметры пагинации.
21
25
  */
22
26
  pagination?: IPagination;
23
- }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<IOrdersTableFields & {
27
+ /**
28
+ * Признак, определяющий, использовать ли индикацию в стилях ячеек таблицы заказов.
29
+ */
30
+ useCellIndication?: boolean;
31
+ }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
32
+ "click:client-name": (client: import('@snabcentr/common-lib').IClientShortInfo, event: any) => any;
33
+ }, string, import('vue').PublicProps, Readonly<IOrdersTableFields & {
24
34
  /**
25
35
  * URL страницы заказов. В качестве указания идентификатора заказа необходимо использовать значение `:id`.
26
36
  */
27
37
  orderUrl: string;
38
+ /**
39
+ * Минимальная ширина таблицы (с паддингами помещается в экран 1440px).
40
+ */
41
+ tableMinWidth?: number;
28
42
  /**
29
43
  * Фильтры поиска записей.
30
44
  */
@@ -37,5 +51,18 @@ declare const _default: import('vue').DefineComponent<IOrdersTableFields & {
37
51
  * Параметры пагинации.
38
52
  */
39
53
  pagination?: IPagination;
40
- }> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
54
+ /**
55
+ * Признак, определяющий, использовать ли индикацию в стилях ячеек таблицы заказов.
56
+ */
57
+ useCellIndication?: boolean;
58
+ }> & Readonly<{
59
+ "onClick:client-name"?: ((client: import('@snabcentr/common-lib').IClientShortInfo, event: any) => any) | undefined;
60
+ }>, {
61
+ sort: ISortRequestParams;
62
+ filters: IFilterGroup;
63
+ showAttachedUserColumn: boolean;
64
+ tableMinWidth: number;
65
+ pagination: IPagination;
66
+ useCellIndication: boolean;
67
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
41
68
  export default _default;
@@ -10,18 +10,34 @@ export declare enum OrdersTableFields {
10
10
  * Данные о клиенте.
11
11
  */
12
12
  ClientInfo = "client_info",
13
+ /**
14
+ * Данные о клиенте.
15
+ */
16
+ ClientInfoShort = "client_info_short",
13
17
  /**
14
18
  * Дата создания.
15
19
  */
16
20
  CreatedAt = "created_at",
21
+ /**
22
+ * Город клиента.
23
+ */
24
+ ClientCity = "client_city",
17
25
  /**
18
26
  * Данные о доставке.
19
27
  */
20
28
  DeliveryInfo = "delivery_info",
29
+ /**
30
+ * Дата доставки / дата самовывоза.
31
+ */
32
+ DeliveryDate = "delivery_date",
21
33
  /**
22
34
  * Идентификатор заказа.
23
35
  */
24
36
  Id = "id",
37
+ /**
38
+ * Тип оплаты.
39
+ */
40
+ PaymentType = "payment_type",
25
41
  /**
26
42
  * Направление продаж.
27
43
  */
@@ -29,5 +45,9 @@ export declare enum OrdersTableFields {
29
45
  /**
30
46
  * Статус заказа.
31
47
  */
32
- Status = "status"
48
+ Status = "status",
49
+ /**
50
+ * Действия.
51
+ */
52
+ actions = "actions"
33
53
  }
@@ -1,4 +1,6 @@
1
1
  import { OrdersTableFields } from '../../enums/orders-table-fields';
2
+ import { IOrderInfo } from '@snabcentr/common-lib';
3
+ import { DropdownDividerOption, DropdownGroupOption, DropdownOption, DropdownRenderOption } from 'naive-ui';
2
4
  /**
3
5
  * Список полей, которые необходимо отображать в полном представлении таблицы.
4
6
  */
@@ -7,4 +9,17 @@ export interface IOrdersTableFields {
7
9
  * Список полей, которые необходимо отображать в полном представлении таблицы.
8
10
  */
9
11
  fields: OrdersTableFields[];
12
+ /**
13
+ * Показывать столбец «За кем закреплен заказ».
14
+ * Скрыто для операторов; для админов, менеджеров и руководителя МРК — отображать.
15
+ */
16
+ showAttachedUserColumn?: boolean;
17
+ /**
18
+ * Конфигурация пунктов контекстного меню заказа.
19
+ */
20
+ orderContextButtonsConfig?: (order: IOrderInfo) => Array<DropdownOption | DropdownGroupOption | DropdownDividerOption | DropdownRenderOption>;
21
+ /**
22
+ * Обработчик выбора пункта контекстного меню заказа.
23
+ */
24
+ onOrderContextSelect?: (order: IOrderInfo, key: string | number) => void;
10
25
  }
@@ -1,4 +1,4 @@
1
- import { ICityWithRegionAndCountry } from '@snabcentr/common-lib';
1
+ import { ICityWithRegionAndCountry, IClientShortInfo } from '@snabcentr/common-lib';
2
2
  import { SelectOption } from 'naive-ui';
3
3
  /**
4
4
  * Список типов доставки.
@@ -36,6 +36,18 @@ export declare const salesDirectionsReferenceList: import('vue').ComputedRef<imp
36
36
  * Список складов.
37
37
  */
38
38
  export declare const warehousesReferenceList: import('vue').ComputedRef<import('@snabcentr/common-lib').IWarehouse[]>;
39
+ /**
40
+ * Список типов оплаты.
41
+ */
42
+ export declare const paymentTypeReferenceList: import('vue').ComputedRef<import('@snabcentr/common-lib').IPaymentType[]>;
43
+ /**
44
+ * Список статусов заказов.
45
+ */
46
+ export declare const orderStatusReferenceList: import('vue').ComputedRef<import('@snabcentr/common-lib').IOrderStatus[]>;
47
+ /**
48
+ * Список операторов.
49
+ */
50
+ export declare const operatorReferenceList: import('vue').ComputedRef<import('@snabcentr/common-lib').IOperator[]>;
39
51
  /**
40
52
  * Справочник опций направлений продаж.
41
53
  */
@@ -56,3 +68,15 @@ export declare const searchCityReferenceDataHandler: (term: string) => Promise<I
56
68
  * @param items Список данных о городах.
57
69
  */
58
70
  export declare const searchCityReferenceLabelRenderer: (items: ICityWithRegionAndCountry[]) => SelectOption[];
71
+ /**
72
+ * Обработчик события поиска клиента по названию.
73
+ *
74
+ * @param term Терм поиска.
75
+ */
76
+ export declare const searchClientReferenceDataHandler: (term: string) => Promise<IClientShortInfo[]>;
77
+ /**
78
+ * Функция рендеринга представления пункта выпадающего списка с данными о клиенте.
79
+ *
80
+ * @param items Список данных о клиентах.
81
+ */
82
+ export declare const searchClientReferenceLabelRenderer: (items: IClientShortInfo[]) => SelectOption[];
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "keywords": [],
5
5
  "author": "Sergey S. Smirnov <dev@snabcentr.com>",
6
6
  "type": "module",
7
- "version": "3.55.1",
7
+ "version": "3.56.0",
8
8
  "license": "ISC",
9
9
  "scripts": {
10
10
  "dev": "vite",
@@ -45,7 +45,7 @@
45
45
  "@iconify-json/logos": "^1.2.9",
46
46
  "@iconify-json/mdi": "^1.2.3",
47
47
  "@iconify-json/tabler": "^1.2.23",
48
- "@snabcentr/common-lib": "^1.84.0 || ^2.2.1",
48
+ "@snabcentr/common-lib": "^1.86.0 || ^2.2.1",
49
49
  "@tailwindcss/container-queries": "^0.1.1",
50
50
  "date-fns": "^3.6.0",
51
51
  "libphonenumber-js": "^1.12.23",