eservices-core 1.0.444 → 1.0.446
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.
|
@@ -8,6 +8,7 @@ export interface ICustomerContext {
|
|
|
8
8
|
interface IUserInformation {
|
|
9
9
|
id: number;
|
|
10
10
|
}
|
|
11
|
+
export declare type ApplicationType = 'front' | 'back';
|
|
11
12
|
declare class ApplicationManager extends EventEmitter {
|
|
12
13
|
#private;
|
|
13
14
|
static EVENT_CONTEXT_UPDATE: string;
|
|
@@ -21,6 +22,10 @@ declare class ApplicationManager extends EventEmitter {
|
|
|
21
22
|
* @description Current customer id. If Application state is not ready - undefined.
|
|
22
23
|
*/
|
|
23
24
|
contextId?: number;
|
|
25
|
+
set type(type: ApplicationType);
|
|
26
|
+
get type(): ApplicationType;
|
|
27
|
+
get isBack(): boolean;
|
|
28
|
+
get isFront(): boolean;
|
|
24
29
|
/**
|
|
25
30
|
* @description User information. Parent Object.
|
|
26
31
|
*/
|
|
@@ -19,6 +19,9 @@ export declare class List<T> extends EventEmitter {
|
|
|
19
19
|
private array;
|
|
20
20
|
constructor(params: IListParams);
|
|
21
21
|
set wait(v: boolean);
|
|
22
|
+
/**
|
|
23
|
+
* @description Value is true if request is running
|
|
24
|
+
* */
|
|
22
25
|
get wait(): boolean;
|
|
23
26
|
get primaryKeys(): string[];
|
|
24
27
|
/**
|
|
@@ -76,7 +79,13 @@ export declare class List<T> extends EventEmitter {
|
|
|
76
79
|
static GetFieldNames<T extends {
|
|
77
80
|
name?: string | string[];
|
|
78
81
|
}>(config: T[]): string[];
|
|
82
|
+
/**
|
|
83
|
+
* @description Put ROW_KEY to data. Override keu if data include key.
|
|
84
|
+
* */
|
|
79
85
|
static mergeWithKey(data: any, key: number): any;
|
|
86
|
+
/**
|
|
87
|
+
* @description Methods using for get name from cell config.
|
|
88
|
+
* */
|
|
80
89
|
static getCellName<T extends Pick<ListCell, 'name'>>(cell: T): string;
|
|
81
90
|
/**
|
|
82
91
|
* @description Получение стандартной информации из ячейки и значений. {name, value}
|
package/dist/index.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ import { ICustomerContext } from "./classes/ApplicationManager";
|
|
|
13
13
|
import { IActionExecuteResult, IValidationEffect } from "./services/action-service";
|
|
14
14
|
import { INotificationCard } from "./classes/NotificationSystem";
|
|
15
15
|
import { ListCell } from "./classes/List";
|
|
16
|
+
import { ApplicationType } from "./classes/ApplicationManager";
|
|
16
17
|
import { setupSocket, useSocket } from "./socket/use-socket";
|
|
17
18
|
import WidgetBreadcrumbs from "./widgets/breadcrumbs/widget-breadcrumbs.vue";
|
|
18
19
|
import WidgetList from "./widgets/list/widget-list.vue";
|
|
@@ -92,9 +93,9 @@ declare const utils: {
|
|
|
92
93
|
};
|
|
93
94
|
export { utils };
|
|
94
95
|
/**
|
|
95
|
-
* Interfaces
|
|
96
|
+
* Interfaces and Types
|
|
96
97
|
* */
|
|
97
|
-
export { IListCell, IListConfig, IFilterConfig, ISortConfig, ICustomerContext, IActionExecuteResult, IValidationEffect, INotificationCard };
|
|
98
|
+
export { IListCell, IListConfig, IFilterConfig, ISortConfig, ICustomerContext, IActionExecuteResult, IValidationEffect, INotificationCard, ApplicationType };
|
|
98
99
|
declare const _default: {
|
|
99
100
|
widgets: {
|
|
100
101
|
inputs: {
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* eservices-core v1.0.
|
|
2
|
+
* eservices-core v1.0.446
|
|
3
3
|
* (c) 2022 ESERVICES
|
|
4
4
|
*/
|
|
5
5
|
'use strict';
|
|
@@ -2753,6 +2753,9 @@ class List$1 extends EventEmitter {
|
|
|
2753
2753
|
__classPrivateFieldSet(this, _wait, v);
|
|
2754
2754
|
this.emit(jenesiusVueForm.Form.EVENT_WAIT, __classPrivateFieldGet(this, _wait));
|
|
2755
2755
|
}
|
|
2756
|
+
/**
|
|
2757
|
+
* @description Value is true if request is running
|
|
2758
|
+
* */
|
|
2756
2759
|
get wait() {
|
|
2757
2760
|
return __classPrivateFieldGet(this, _wait);
|
|
2758
2761
|
}
|
|
@@ -2876,9 +2879,15 @@ class List$1 extends EventEmitter {
|
|
|
2876
2879
|
return acc;
|
|
2877
2880
|
}, []);
|
|
2878
2881
|
}
|
|
2882
|
+
/**
|
|
2883
|
+
* @description Put ROW_KEY to data. Override keu if data include key.
|
|
2884
|
+
* */
|
|
2879
2885
|
static mergeWithKey(data, key) {
|
|
2880
2886
|
return Object.assign(Object.assign({}, data), { [LIST_ROW_KEY]: key });
|
|
2881
2887
|
}
|
|
2888
|
+
/**
|
|
2889
|
+
* @description Methods using for get name from cell config.
|
|
2890
|
+
* */
|
|
2882
2891
|
static getCellName(cell) {
|
|
2883
2892
|
if (typeof cell.name === "string")
|
|
2884
2893
|
return cell.name;
|
|
@@ -3753,7 +3762,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
3753
3762
|
]))
|
|
3754
3763
|
}
|
|
3755
3764
|
|
|
3756
|
-
var css_248z$9 = "\n.widget-table__head[data-v-2f217eb0]{\r\n text-align: left;\n}\n.widget-table__head-cell[data-v-2f217eb0]{\r\n padding: 18px;\n}\n.widget-table__head-title[data-v-2f217eb0]{\r\n white-space: nowrap;\r\n text-overflow: ellipsis;\r\n overflow: hidden;\r\n font-weight: 600;\r\n font-size: 14px;\r\n line-height: 19px;\r\n margin: 0;\n}\r\n";
|
|
3765
|
+
var css_248z$9 = "\n.widget-table__head[data-v-2f217eb0]{\r\n text-align: left;\r\n position: sticky;\r\n top: -1px;\r\n z-index: 0;\n}\n.widget-table__head-cell[data-v-2f217eb0]{\r\n padding: 18px;\n}\n.widget-table__head-title[data-v-2f217eb0]{\r\n white-space: nowrap;\r\n text-overflow: ellipsis;\r\n overflow: hidden;\r\n font-weight: 600;\r\n font-size: 14px;\r\n line-height: 19px;\r\n margin: 0;\n}\r\n";
|
|
3757
3766
|
styleInject(css_248z$9);
|
|
3758
3767
|
|
|
3759
3768
|
script$d.render = render;
|
|
@@ -4720,10 +4729,14 @@ class clientService {
|
|
|
4720
4729
|
}
|
|
4721
4730
|
}
|
|
4722
4731
|
|
|
4723
|
-
var _ready;
|
|
4732
|
+
var _type, _ready;
|
|
4724
4733
|
class ApplicationManager extends EventEmitter {
|
|
4725
4734
|
constructor() {
|
|
4726
4735
|
super(...arguments);
|
|
4736
|
+
/**
|
|
4737
|
+
* @description Office type. By Default is front
|
|
4738
|
+
* */
|
|
4739
|
+
_type.set(this, 'front');
|
|
4727
4740
|
/**
|
|
4728
4741
|
* @description List of organizations
|
|
4729
4742
|
*/
|
|
@@ -4733,6 +4746,18 @@ class ApplicationManager extends EventEmitter {
|
|
|
4733
4746
|
*/
|
|
4734
4747
|
_ready.set(this, false);
|
|
4735
4748
|
}
|
|
4749
|
+
set type(type) {
|
|
4750
|
+
__classPrivateFieldSet(this, _type, type);
|
|
4751
|
+
}
|
|
4752
|
+
get type() {
|
|
4753
|
+
return __classPrivateFieldGet(this, _type);
|
|
4754
|
+
}
|
|
4755
|
+
get isBack() {
|
|
4756
|
+
return this.type === 'back';
|
|
4757
|
+
}
|
|
4758
|
+
get isFront() {
|
|
4759
|
+
return this.type === 'front';
|
|
4760
|
+
}
|
|
4736
4761
|
set ready(v) {
|
|
4737
4762
|
__classPrivateFieldSet(this, _ready, v);
|
|
4738
4763
|
this.emit(ApplicationManager.EVENT_READY_UPDATE, v);
|
|
@@ -4804,7 +4829,7 @@ class ApplicationManager extends EventEmitter {
|
|
|
4804
4829
|
return !!this.organizations.find(org => org.id === id);
|
|
4805
4830
|
}
|
|
4806
4831
|
}
|
|
4807
|
-
_ready = new WeakMap();
|
|
4832
|
+
_type = new WeakMap(), _ready = new WeakMap();
|
|
4808
4833
|
ApplicationManager.EVENT_CONTEXT_UPDATE = 'event:context-update';
|
|
4809
4834
|
ApplicationManager.EVENT_READY_UPDATE = 'event:ready-update';
|
|
4810
4835
|
ApplicationManager.EVENT_DATA_UPDATE = 'event:data-update';
|