@fctc/edu-logic-lib 1.0.2 → 1.0.4
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/dist/{store.d.ts → index.d.mts} +574 -3
- package/dist/{store.d.mts → index.d.ts} +574 -3
- package/dist/index.js +4709 -0
- package/dist/index.mjs +4596 -0
- package/package.json +1 -1
- package/dist/base-model-type-DvO53Lwi.d.mts +0 -7
- package/dist/base-model-type-DvO53Lwi.d.ts +0 -7
- package/dist/chunk-6BLY7NZ6.mjs +0 -124
- package/dist/chunk-6QXB3XX7.mjs +0 -258
- package/dist/chunk-ELARQVCE.mjs +0 -2364
- package/dist/chunk-FVGPSTJ7.js +0 -124
- package/dist/chunk-GGOFXFSX.js +0 -2364
- package/dist/chunk-IXDDYGKE.js +0 -61
- package/dist/chunk-MJLXGYQ4.mjs +0 -102
- package/dist/chunk-MLJQPO4Q.mjs +0 -61
- package/dist/chunk-QLUONJPQ.mjs +0 -604
- package/dist/chunk-RZBHZYXG.js +0 -604
- package/dist/chunk-S7B3VKMJ.mjs +0 -95
- package/dist/chunk-S7YF2I23.js +0 -95
- package/dist/chunk-U4CC2BBB.js +0 -1074
- package/dist/chunk-UY6GNZNB.js +0 -258
- package/dist/chunk-W4W2L2NA.js +0 -102
- package/dist/chunk-WYXAE5LI.mjs +0 -1074
- package/dist/config.d.mts +0 -15
- package/dist/config.d.ts +0 -15
- package/dist/config.js +0 -7
- package/dist/config.mjs +0 -7
- package/dist/constants.d.mts +0 -120
- package/dist/constants.d.ts +0 -120
- package/dist/constants.js +0 -30
- package/dist/constants.mjs +0 -30
- package/dist/context-type-D5XefoL-.d.mts +0 -8
- package/dist/context-type-D5XefoL-.d.ts +0 -8
- package/dist/environment.d.mts +0 -37
- package/dist/environment.d.ts +0 -37
- package/dist/environment.js +0 -15
- package/dist/environment.mjs +0 -15
- package/dist/hooks.d.mts +0 -216
- package/dist/hooks.d.ts +0 -216
- package/dist/hooks.js +0 -776
- package/dist/hooks.mjs +0 -776
- package/dist/index-C_nK1Mii.d.mts +0 -19
- package/dist/index-C_nK1Mii.d.ts +0 -19
- package/dist/models.d.mts +0 -35
- package/dist/models.d.ts +0 -35
- package/dist/models.js +0 -43
- package/dist/models.mjs +0 -43
- package/dist/provider.d.mts +0 -16
- package/dist/provider.d.ts +0 -16
- package/dist/provider.js +0 -86
- package/dist/provider.mjs +0 -86
- package/dist/services.d.mts +0 -160
- package/dist/services.d.ts +0 -160
- package/dist/services.js +0 -26
- package/dist/services.mjs +0 -26
- package/dist/store.js +0 -128
- package/dist/store.mjs +0 -128
- package/dist/types.d.mts +0 -12
- package/dist/types.d.ts +0 -12
- package/dist/types.js +0 -1
- package/dist/types.mjs +0 -0
- package/dist/use-get-selection-DFh6sc49.d.mts +0 -26
- package/dist/use-get-selection-DFh6sc49.d.ts +0 -26
- package/dist/utils.d.mts +0 -52
- package/dist/utils.d.ts +0 -52
- package/dist/utils.js +0 -34
- package/dist/utils.mjs +0 -34
- package/dist/view-type-BTzRpkT7.d.mts +0 -106
- package/dist/view-type-BTzRpkT7.d.ts +0 -106
|
@@ -1,10 +1,490 @@
|
|
|
1
|
-
import { TypedUseSelectorHook } from 'react-redux';
|
|
2
1
|
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
3
|
-
import { PayloadAction } from '@reduxjs/toolkit';
|
|
2
|
+
import { EnhancedStore, PayloadAction } from '@reduxjs/toolkit';
|
|
3
|
+
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
4
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
|
+
import { ReactNode } from 'react';
|
|
6
|
+
import { TypedUseSelectorHook } from 'react-redux';
|
|
4
7
|
import * as redux_thunk from 'redux-thunk';
|
|
5
8
|
import * as redux from 'redux';
|
|
6
9
|
import * as immer from 'immer';
|
|
7
10
|
|
|
11
|
+
declare enum KeyConstants {
|
|
12
|
+
PROFILE = "userinfo",
|
|
13
|
+
CURRENT_COMPANY = "current_company",
|
|
14
|
+
LIST_COMPANY = "list_company",
|
|
15
|
+
COMPANY_INFO = "company_info",
|
|
16
|
+
MENU = "menus",
|
|
17
|
+
GET_VIEW_BY_ACTION = "get_view_by_action",
|
|
18
|
+
ACTION_DETAIL = "action_detail",
|
|
19
|
+
GET_DATA_SELECTION = "get_data_select",
|
|
20
|
+
WEB_SAVE = "web_save",
|
|
21
|
+
WEB_READ = "web_read",
|
|
22
|
+
GET_PROVIDER = "get_provider"
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
declare enum MethodConstants {
|
|
26
|
+
WEB_SEARCH_READ = "web_search_read",
|
|
27
|
+
WEB_READ_GROUP = "web_read_group",
|
|
28
|
+
WEB_READ = "web_read",
|
|
29
|
+
WEB_SAVE = "web_save",
|
|
30
|
+
UNLINK = "unlink",
|
|
31
|
+
ONCHANGE = "onchange",
|
|
32
|
+
GET_ONCHANGE_FIELDS = "get_fields_onchange",
|
|
33
|
+
GET_FIELD_VIEW = "get_fields_view_v2"
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
declare enum UriConstants {
|
|
37
|
+
AUTH_TOKEN_PATH = "/authentication/oauth2/token",
|
|
38
|
+
GENTOKEN_SOCIAL = "/token/generate",
|
|
39
|
+
CALL_PATH = "/call",
|
|
40
|
+
COMPANY_PATH = "/company",
|
|
41
|
+
PROFILE_PATH = "/userinfo",
|
|
42
|
+
RESET_PASSWORD_PATH = "/reset_password",
|
|
43
|
+
CHANGE_PASSWORD_PATH = "/change_password",
|
|
44
|
+
UPDATE_PASSWORD_PATH = "/change_password_parent",
|
|
45
|
+
LOAD_ACTION = "/load_action",
|
|
46
|
+
REPORT_PATH = "/report",
|
|
47
|
+
RUN_ACTION_PATH = "/run_action",
|
|
48
|
+
UPLOAD_FILE_PATH = "/upload/file",
|
|
49
|
+
GET_MESSAGE = "/chatter/thread/messages",
|
|
50
|
+
SENT_MESSAGE = "/chatter/message/post",
|
|
51
|
+
UPLOAD_IMAGE = "/mail/attachment/upload",
|
|
52
|
+
DELETE_MESSAGE = "/chatter/message/update_content",
|
|
53
|
+
IMAGE_PATH = "/web/image",
|
|
54
|
+
LOAD_MESSAGE = "/load_message_failures",
|
|
55
|
+
TOKEN = "/check_token",
|
|
56
|
+
CREATE_UPDATE_PATH = "/create_update",
|
|
57
|
+
TWOFA_METHOD_PATH = "/id/api/v2/call",
|
|
58
|
+
SIGNIN_SSO = "/signin-sso/oauth"
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
declare enum FieldTypeConstants {
|
|
62
|
+
CHAR = "char",
|
|
63
|
+
TEXT = "text",
|
|
64
|
+
INTEGER = "integer",
|
|
65
|
+
FLOAT = "float",
|
|
66
|
+
BOOLEAN = "boolean",
|
|
67
|
+
DATE = "date",
|
|
68
|
+
DATETIME = "datetime",
|
|
69
|
+
BINARY = "binary",
|
|
70
|
+
SELECTION = "selection",
|
|
71
|
+
HTML = "html",
|
|
72
|
+
MANY2ONE = "many2one",
|
|
73
|
+
ONE2MANY = "one2many",
|
|
74
|
+
MANY2MANY = "many2many",
|
|
75
|
+
MONETARY = "monetary",
|
|
76
|
+
REFERENCE = "reference",
|
|
77
|
+
FUNCTION = "function",
|
|
78
|
+
PROPERTY = "property"
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
declare enum MethodType {
|
|
82
|
+
CREATE = 0,
|
|
83
|
+
UPDATE = 1,
|
|
84
|
+
DELETE = 2,
|
|
85
|
+
UNLINK = 3,
|
|
86
|
+
NO_CHANGE = 4
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
declare enum ModelConstants {
|
|
90
|
+
MENU = "ir.ui.menu",
|
|
91
|
+
USER = "res.users",
|
|
92
|
+
COMPANY = "res.company",
|
|
93
|
+
WINDOW_ACTION = "ir.actions.act_window",
|
|
94
|
+
BASE_IMPORT = "base_import.import",
|
|
95
|
+
GET_IMPORT = "get_import_templates"
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
declare enum ComponentType {
|
|
99
|
+
TREE = "tree",
|
|
100
|
+
GROUP = "group",
|
|
101
|
+
LIST = "list",
|
|
102
|
+
FORM = "form",
|
|
103
|
+
FIELD = "field",
|
|
104
|
+
DIV = "div",
|
|
105
|
+
SPAN = "span"
|
|
106
|
+
}
|
|
107
|
+
declare const SearchType: {
|
|
108
|
+
FILTER: string;
|
|
109
|
+
SEARCH: string;
|
|
110
|
+
GROUP: string;
|
|
111
|
+
};
|
|
112
|
+
|
|
113
|
+
declare enum WIDGETAVATAR {
|
|
114
|
+
many2one_avatar_user = "many2one_avatar_user",
|
|
115
|
+
many2many_avatar_user = "many2many_avatar_user"
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
declare enum WIDGETCOLOR {
|
|
119
|
+
many2many_tags = "many2many_tags",
|
|
120
|
+
helpdesk_sla_many2many_tags = "helpdesk_sla_many2many_tags"
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
declare enum WIDGETSTATUS {
|
|
124
|
+
sla_status_ids = "sla_status_ids"
|
|
125
|
+
}
|
|
126
|
+
declare enum WIDGETNOSTRING {
|
|
127
|
+
sla_status_ids = "sla_status_ids"
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
declare global {
|
|
131
|
+
interface Global {
|
|
132
|
+
envStore?: EnvStore;
|
|
133
|
+
}
|
|
134
|
+
interface Window {
|
|
135
|
+
envStore?: EnvStore;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
declare class EnvStore {
|
|
139
|
+
envStore: EnhancedStore | any;
|
|
140
|
+
baseUrl?: string;
|
|
141
|
+
requests?: any;
|
|
142
|
+
context?: any;
|
|
143
|
+
defaultCompany?: any;
|
|
144
|
+
config?: any;
|
|
145
|
+
companies?: any[];
|
|
146
|
+
user?: any;
|
|
147
|
+
db?: string;
|
|
148
|
+
localStorageUtils?: any;
|
|
149
|
+
sessionStorageUtils?: any;
|
|
150
|
+
constructor(envStore: EnhancedStore, localStorageUtils?: any, sessionStorageUtils?: any);
|
|
151
|
+
setup(): void;
|
|
152
|
+
setupEnv(envConfig: EnvStore): void;
|
|
153
|
+
setUid(uid: number): void;
|
|
154
|
+
setLang(lang: string): void;
|
|
155
|
+
setAllowCompanies(allowCompanies: number[]): void;
|
|
156
|
+
setCompanies(companies: any[]): void;
|
|
157
|
+
setDefaultCompany(company: any): void;
|
|
158
|
+
setUserInfo(userInfo: any): void;
|
|
159
|
+
}
|
|
160
|
+
declare let env: EnvStore | null;
|
|
161
|
+
declare function initEnv({}: {}): EnvStore;
|
|
162
|
+
declare function getEnv(): EnvStore;
|
|
163
|
+
|
|
164
|
+
declare const useForgotPassword: () => _tanstack_react_query.UseMutationResult<any, Error, string, unknown>;
|
|
165
|
+
|
|
166
|
+
interface Specification {
|
|
167
|
+
[key: string]: any;
|
|
168
|
+
}
|
|
169
|
+
interface ContextApi {
|
|
170
|
+
[key: string]: any;
|
|
171
|
+
}
|
|
172
|
+
interface GetAllParams {
|
|
173
|
+
model?: string;
|
|
174
|
+
ids?: number[];
|
|
175
|
+
specification: Specification;
|
|
176
|
+
domain?: any[];
|
|
177
|
+
offset?: number;
|
|
178
|
+
sort: any;
|
|
179
|
+
fields: any;
|
|
180
|
+
groupby: any;
|
|
181
|
+
context?: ContextApi;
|
|
182
|
+
limit?: number;
|
|
183
|
+
}
|
|
184
|
+
interface GetListParams {
|
|
185
|
+
model: string;
|
|
186
|
+
ids?: number[];
|
|
187
|
+
specification?: Specification;
|
|
188
|
+
domain?: any[];
|
|
189
|
+
offset?: number;
|
|
190
|
+
order?: string;
|
|
191
|
+
context?: ContextApi;
|
|
192
|
+
limit?: number;
|
|
193
|
+
}
|
|
194
|
+
interface GetDetailParams {
|
|
195
|
+
ids?: number[];
|
|
196
|
+
model?: string;
|
|
197
|
+
specification?: Specification;
|
|
198
|
+
context?: ContextApi;
|
|
199
|
+
}
|
|
200
|
+
interface SaveParams {
|
|
201
|
+
model: string;
|
|
202
|
+
ids?: number[] | [];
|
|
203
|
+
data?: Record<string, any>;
|
|
204
|
+
specification?: Specification;
|
|
205
|
+
context?: ContextApi;
|
|
206
|
+
}
|
|
207
|
+
interface DeleteParams {
|
|
208
|
+
ids?: number[];
|
|
209
|
+
model: string;
|
|
210
|
+
}
|
|
211
|
+
interface OnChangeParams {
|
|
212
|
+
ids?: number[];
|
|
213
|
+
model: string;
|
|
214
|
+
object?: Record<string, any>;
|
|
215
|
+
specification: Specification;
|
|
216
|
+
context?: ContextApi;
|
|
217
|
+
fieldChange?: string[];
|
|
218
|
+
}
|
|
219
|
+
interface ViewData {
|
|
220
|
+
models?: {
|
|
221
|
+
[key: string]: {
|
|
222
|
+
[key: string]: {
|
|
223
|
+
type: string;
|
|
224
|
+
relation?: string;
|
|
225
|
+
};
|
|
226
|
+
};
|
|
227
|
+
};
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
interface LoginCredentialBody {
|
|
231
|
+
email: string;
|
|
232
|
+
password: string;
|
|
233
|
+
path?: string;
|
|
234
|
+
}
|
|
235
|
+
interface ResetPasswordRequest {
|
|
236
|
+
password: string;
|
|
237
|
+
confirmPassword: string;
|
|
238
|
+
}
|
|
239
|
+
interface UpdatePasswordRequest {
|
|
240
|
+
newPassword: string;
|
|
241
|
+
oldPassword: string;
|
|
242
|
+
}
|
|
243
|
+
interface ForgotPasswordBody {
|
|
244
|
+
data: ResetPasswordRequest;
|
|
245
|
+
token: string | null;
|
|
246
|
+
}
|
|
247
|
+
interface updatePasswordBody {
|
|
248
|
+
data: UpdatePasswordRequest;
|
|
249
|
+
token: string | null;
|
|
250
|
+
}
|
|
251
|
+
interface SocialTokenBody {
|
|
252
|
+
state: object;
|
|
253
|
+
access_token: string;
|
|
254
|
+
db: string;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
interface BaseModelInit$1 {
|
|
258
|
+
name: string;
|
|
259
|
+
view: Record<string, any>;
|
|
260
|
+
actContext?: Record<string, any>;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
interface Config {
|
|
264
|
+
baseUrl: string;
|
|
265
|
+
grantType: string;
|
|
266
|
+
clientId: string;
|
|
267
|
+
clientSecret: string;
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
interface Context {
|
|
271
|
+
uid: number;
|
|
272
|
+
lang: string;
|
|
273
|
+
allowCompanys: number[];
|
|
274
|
+
[key: string]: any;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
type View = [number | boolean, string];
|
|
278
|
+
type Option = {
|
|
279
|
+
action_id?: number;
|
|
280
|
+
load_filters?: boolean;
|
|
281
|
+
toolbar?: boolean;
|
|
282
|
+
};
|
|
283
|
+
interface GetViewParams {
|
|
284
|
+
model?: string;
|
|
285
|
+
views?: View[];
|
|
286
|
+
context?: Record<string, any>;
|
|
287
|
+
options?: Option;
|
|
288
|
+
aid?: number | string | null | boolean;
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
type TFormView = {
|
|
292
|
+
model: string;
|
|
293
|
+
id?: number | null;
|
|
294
|
+
context?: any;
|
|
295
|
+
};
|
|
296
|
+
|
|
297
|
+
interface BaseModelInit {
|
|
298
|
+
name: string;
|
|
299
|
+
view: Record<string, any>;
|
|
300
|
+
actContext?: Record<string, any>;
|
|
301
|
+
fields?: any;
|
|
302
|
+
}
|
|
303
|
+
declare class BaseModel {
|
|
304
|
+
name: string;
|
|
305
|
+
view: Record<string, any>;
|
|
306
|
+
actContext?: Record<string, any>;
|
|
307
|
+
fields?: any;
|
|
308
|
+
constructor(init: BaseModelInit);
|
|
309
|
+
private getSpecificationByFields;
|
|
310
|
+
getTreeProps(): Record<string, any>;
|
|
311
|
+
getTreeFields(): Record<string, any>[];
|
|
312
|
+
getSpecification(): Record<string, any>;
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
type GetSelectionType = {
|
|
316
|
+
domain: any;
|
|
317
|
+
context: any;
|
|
318
|
+
model: string;
|
|
319
|
+
specification?: any;
|
|
320
|
+
};
|
|
321
|
+
|
|
322
|
+
declare const MainProvider: ({ children }: {
|
|
323
|
+
children: ReactNode;
|
|
324
|
+
}) => react_jsx_runtime.JSX.Element;
|
|
325
|
+
|
|
326
|
+
declare const ReactQueryProvider: ({ children }: {
|
|
327
|
+
children: ReactNode;
|
|
328
|
+
}) => react_jsx_runtime.JSX.Element;
|
|
329
|
+
|
|
330
|
+
declare const VersionGate: ({ children }: {
|
|
331
|
+
children: ReactNode;
|
|
332
|
+
}) => react_jsx_runtime.JSX.Element | null;
|
|
333
|
+
|
|
334
|
+
declare const ActionService: {
|
|
335
|
+
loadAction({ idAction, context, }: {
|
|
336
|
+
idAction: number;
|
|
337
|
+
context: ContextApi;
|
|
338
|
+
}): Promise<any>;
|
|
339
|
+
callButton({ model, ids, context, method, }: {
|
|
340
|
+
model: string;
|
|
341
|
+
ids: Record<string, any>[] | any;
|
|
342
|
+
context: ContextApi;
|
|
343
|
+
method: any;
|
|
344
|
+
}): Promise<any>;
|
|
345
|
+
removeRows({ model, ids, context, }: {
|
|
346
|
+
model: string;
|
|
347
|
+
ids: Record<string, any>[] | any;
|
|
348
|
+
context: ContextApi;
|
|
349
|
+
}): Promise<any>;
|
|
350
|
+
duplicateRecord({ model, id, context, }: {
|
|
351
|
+
model: string;
|
|
352
|
+
id: any;
|
|
353
|
+
context: ContextApi;
|
|
354
|
+
}): Promise<any>;
|
|
355
|
+
print({ id, report, db }: {
|
|
356
|
+
id: number;
|
|
357
|
+
report: any;
|
|
358
|
+
db: any;
|
|
359
|
+
}): Promise<any>;
|
|
360
|
+
runAction({ idAction, context, }: {
|
|
361
|
+
idAction: number;
|
|
362
|
+
context: ContextApi;
|
|
363
|
+
}): Promise<any>;
|
|
364
|
+
};
|
|
365
|
+
|
|
366
|
+
declare const AuthService: {
|
|
367
|
+
login(body: LoginCredentialBody): Promise<any>;
|
|
368
|
+
forgotPassword(email: string): Promise<any>;
|
|
369
|
+
resetPassword(data: ResetPasswordRequest, token: string | null): Promise<any>;
|
|
370
|
+
updatePassword(data: UpdatePasswordRequest, token: string | null): Promise<any>;
|
|
371
|
+
isValidToken(token: string | null): Promise<any>;
|
|
372
|
+
loginSocial({ state, access_token, }: {
|
|
373
|
+
state: object;
|
|
374
|
+
access_token: string;
|
|
375
|
+
}): Promise<any>;
|
|
376
|
+
getProviders(db?: string): Promise<any>;
|
|
377
|
+
};
|
|
378
|
+
|
|
379
|
+
declare const CompanyService: {
|
|
380
|
+
getCurrentCompany(): Promise<any>;
|
|
381
|
+
getInfoCompany(id: number): Promise<any>;
|
|
382
|
+
};
|
|
383
|
+
|
|
384
|
+
declare const ExcelService: {
|
|
385
|
+
uploadFile({ formData }: {
|
|
386
|
+
formData: any;
|
|
387
|
+
}): Promise<any>;
|
|
388
|
+
uploadIdFile({ formData }: {
|
|
389
|
+
formData: any;
|
|
390
|
+
}): Promise<any>;
|
|
391
|
+
parsePreview({ id, selectedSheet, isHeader, context, }: {
|
|
392
|
+
id: any;
|
|
393
|
+
selectedSheet: any;
|
|
394
|
+
isHeader: boolean;
|
|
395
|
+
context: any;
|
|
396
|
+
}): Promise<any>;
|
|
397
|
+
executeImport({ columns, fields, idFile, options, dryrun, context, }: {
|
|
398
|
+
columns: any;
|
|
399
|
+
fields: any;
|
|
400
|
+
idFile: any;
|
|
401
|
+
options: any;
|
|
402
|
+
dryrun: any;
|
|
403
|
+
context: any;
|
|
404
|
+
}): Promise<any>;
|
|
405
|
+
getFileExcel({ model, context }: {
|
|
406
|
+
model: string;
|
|
407
|
+
context: any;
|
|
408
|
+
}): Promise<any>;
|
|
409
|
+
getFieldExport({ ids, model, isShow, parentField, fieldType, parentName, prefix, name, context, importCompat, }: {
|
|
410
|
+
ids: any;
|
|
411
|
+
model: string;
|
|
412
|
+
isShow?: boolean;
|
|
413
|
+
parentField?: any;
|
|
414
|
+
fieldType?: any;
|
|
415
|
+
parentName?: any;
|
|
416
|
+
prefix?: any;
|
|
417
|
+
name?: any;
|
|
418
|
+
context: any;
|
|
419
|
+
importCompat?: any;
|
|
420
|
+
}): Promise<any>;
|
|
421
|
+
exportExcel({ model, domain, ids, fields, type, importCompat, context, groupby, }: {
|
|
422
|
+
model: string;
|
|
423
|
+
domain: any;
|
|
424
|
+
ids: any;
|
|
425
|
+
fields: any;
|
|
426
|
+
type: any;
|
|
427
|
+
importCompat: any;
|
|
428
|
+
context: any;
|
|
429
|
+
groupby: any;
|
|
430
|
+
}): Promise<any>;
|
|
431
|
+
};
|
|
432
|
+
|
|
433
|
+
declare const FormService: {
|
|
434
|
+
getComment({ data }: {
|
|
435
|
+
data: any;
|
|
436
|
+
}): Promise<any>;
|
|
437
|
+
sentComment({ data }: any): Promise<any>;
|
|
438
|
+
deleteComment({ data }: {
|
|
439
|
+
data: any;
|
|
440
|
+
}): Promise<any>;
|
|
441
|
+
getImage({ data }: {
|
|
442
|
+
data: any;
|
|
443
|
+
}): Promise<any>;
|
|
444
|
+
uploadImage({ data }: {
|
|
445
|
+
data: any;
|
|
446
|
+
}): Promise<any>;
|
|
447
|
+
getFormView({ data }: {
|
|
448
|
+
data: TFormView;
|
|
449
|
+
}): Promise<any>;
|
|
450
|
+
changeStatus({ data }: any): Promise<any>;
|
|
451
|
+
};
|
|
452
|
+
|
|
453
|
+
declare const ModelService: {
|
|
454
|
+
getAll({ data }: {
|
|
455
|
+
data: any;
|
|
456
|
+
}): Promise<any>;
|
|
457
|
+
getList({ model, ids, specification, domain, offset, order, context, limit, }: GetListParams): Promise<any>;
|
|
458
|
+
getDetail({ ids, model, specification, context, }: GetDetailParams): Promise<any>;
|
|
459
|
+
save({ model, ids, data, specification, context, }: SaveParams): Promise<any>;
|
|
460
|
+
delete({ ids, model }: DeleteParams): Promise<any>;
|
|
461
|
+
onChange({ ids, model, object, specification, context, fieldChange, }: OnChangeParams): Promise<any>;
|
|
462
|
+
getListFieldsOnchange({ model }: {
|
|
463
|
+
model: string;
|
|
464
|
+
}): Promise<any>;
|
|
465
|
+
parseORMOdoo(data: Record<string, any>): Record<string, any>;
|
|
466
|
+
toDataJS(data: Record<string, any>, viewData?: ViewData, model?: string): Record<string, any>;
|
|
467
|
+
};
|
|
468
|
+
|
|
469
|
+
declare const UserService: {
|
|
470
|
+
getProfile(): Promise<any>;
|
|
471
|
+
getUser({ context, id }: {
|
|
472
|
+
context: any;
|
|
473
|
+
id: any;
|
|
474
|
+
}): Promise<any>;
|
|
475
|
+
switchUserLocale: ({ id, values }: any) => Promise<any>;
|
|
476
|
+
};
|
|
477
|
+
|
|
478
|
+
declare const ViewService: {
|
|
479
|
+
getView({ model, views, context, options, aid, }: GetViewParams): Promise<any>;
|
|
480
|
+
getMenu(context: Context): Promise<any>;
|
|
481
|
+
getSelectionItem({ data }: {
|
|
482
|
+
data: GetSelectionType;
|
|
483
|
+
}): Promise<any>;
|
|
484
|
+
loadMessages(): Promise<any>;
|
|
485
|
+
getVersion(): Promise<any>;
|
|
486
|
+
};
|
|
487
|
+
|
|
8
488
|
interface UserInfor {
|
|
9
489
|
address?: {
|
|
10
490
|
country?: boolean;
|
|
@@ -502,4 +982,95 @@ type AppDispatch = typeof envStore.dispatch;
|
|
|
502
982
|
declare const useAppDispatch: () => AppDispatch;
|
|
503
983
|
declare const useAppSelector: TypedUseSelectorHook<RootState>;
|
|
504
984
|
|
|
505
|
-
|
|
985
|
+
type AST = {
|
|
986
|
+
type: number;
|
|
987
|
+
value: any;
|
|
988
|
+
};
|
|
989
|
+
type Condition = [string | 0 | 1, string, any];
|
|
990
|
+
type DomainListRepr = ('&' | '|' | '!' | Condition)[];
|
|
991
|
+
type DomainRepr = DomainListRepr | string | Domain;
|
|
992
|
+
declare class Domain {
|
|
993
|
+
ast: AST;
|
|
994
|
+
static TRUE: Domain;
|
|
995
|
+
static FALSE: Domain;
|
|
996
|
+
static combine(domains: DomainRepr[], operator: 'AND' | 'OR'): Domain;
|
|
997
|
+
static and(domains: DomainRepr[]): Domain;
|
|
998
|
+
static or(domains: DomainRepr[]): Domain;
|
|
999
|
+
static not(domain: DomainRepr): Domain;
|
|
1000
|
+
static removeDomainLeaves(domain: DomainRepr, keysToRemove: string[]): Domain;
|
|
1001
|
+
constructor(descr?: DomainRepr);
|
|
1002
|
+
contains(record: any): boolean;
|
|
1003
|
+
toString(): string;
|
|
1004
|
+
toList(context: Record<string, any>): DomainListRepr;
|
|
1005
|
+
toJson(): DomainListRepr | string;
|
|
1006
|
+
}
|
|
1007
|
+
|
|
1008
|
+
declare const evalJSONContext: (_context: any, context?: {}) => Context | null;
|
|
1009
|
+
declare const evalJSONDomain: (domain: any, context: any) => any;
|
|
1010
|
+
declare const formatSortingString: (input: string | null | undefined) => string | null;
|
|
1011
|
+
declare const domainHelper: {
|
|
1012
|
+
checkDomain: (context: any, domain: any) => boolean;
|
|
1013
|
+
matchDomains: (context: any, domains: any) => boolean;
|
|
1014
|
+
Domain: typeof Domain;
|
|
1015
|
+
};
|
|
1016
|
+
declare const toQueryString: (params: Record<string, string | number | boolean>) => string;
|
|
1017
|
+
declare const stringToColor: (name: string, id: number) => string;
|
|
1018
|
+
declare const getFieldsOnChange: (fields: any) => any;
|
|
1019
|
+
declare const formatUrlPath: ({ viewType, aid, model, id, actionPath, }: {
|
|
1020
|
+
viewType: "list" | "form" | "kanban" | any;
|
|
1021
|
+
actionPath: string;
|
|
1022
|
+
aid: string | number;
|
|
1023
|
+
model: string;
|
|
1024
|
+
id?: string | number;
|
|
1025
|
+
}) => string;
|
|
1026
|
+
declare const removeUndefinedFields: <T extends Record<string, any>>(obj: T) => Partial<T>;
|
|
1027
|
+
declare const useTabModel: (viewData: any, onchangeData: any) => any;
|
|
1028
|
+
declare const isBase64File: (str: any) => boolean;
|
|
1029
|
+
declare const isBase64Image: (str: any) => boolean;
|
|
1030
|
+
declare const checkIsImageLink: (url: any) => boolean;
|
|
1031
|
+
declare const formatFileSize: (size: any) => string;
|
|
1032
|
+
declare const getSubdomain: (url?: string) => string | null;
|
|
1033
|
+
|
|
1034
|
+
interface CompanyData {
|
|
1035
|
+
id?: number;
|
|
1036
|
+
name?: string;
|
|
1037
|
+
[key: string]: any;
|
|
1038
|
+
}
|
|
1039
|
+
interface CompanyResponse {
|
|
1040
|
+
data: CompanyData;
|
|
1041
|
+
status: number;
|
|
1042
|
+
[key: string]: any;
|
|
1043
|
+
}
|
|
1044
|
+
declare class CompanyModel extends BaseModel {
|
|
1045
|
+
constructor(init: BaseModelInit$1);
|
|
1046
|
+
getCurrentCompany(): Promise<CompanyResponse>;
|
|
1047
|
+
getUserCompany(id: number): Promise<CompanyResponse>;
|
|
1048
|
+
}
|
|
1049
|
+
|
|
1050
|
+
interface UserData {
|
|
1051
|
+
id?: number;
|
|
1052
|
+
name?: string;
|
|
1053
|
+
[key: string]: any;
|
|
1054
|
+
}
|
|
1055
|
+
interface UserResponse {
|
|
1056
|
+
data: UserData;
|
|
1057
|
+
status: number;
|
|
1058
|
+
[key: string]: any;
|
|
1059
|
+
}
|
|
1060
|
+
declare class UserModel extends BaseModel {
|
|
1061
|
+
constructor(init: BaseModelInit$1);
|
|
1062
|
+
getProfile(): Promise<UserResponse>;
|
|
1063
|
+
}
|
|
1064
|
+
|
|
1065
|
+
declare const axiosClient: {
|
|
1066
|
+
init(config: EnvStore): {
|
|
1067
|
+
get: (url: string, headers: any) => Promise<any>;
|
|
1068
|
+
post: (url: string, body: any, headers: any) => Promise<any>;
|
|
1069
|
+
post_excel: (url: string, body: any, headers: any) => Promise<any>;
|
|
1070
|
+
put: (url: string, body: any, headers: any) => Promise<any>;
|
|
1071
|
+
patch: (url: string, body: any) => Promise<any>;
|
|
1072
|
+
delete: (url: string, body: any) => Promise<any>;
|
|
1073
|
+
};
|
|
1074
|
+
};
|
|
1075
|
+
|
|
1076
|
+
export { ActionService, type AppDispatch, AuthService, BaseModel, type BaseModelInit$1 as BaseModelInit, CompanyModel, CompanyService, ComponentType, type Config, type Context, type ContextApi, type DeleteParams, EnvStore, ExcelService, FieldTypeConstants, type ForgotPasswordBody, FormService, type GetAllParams, type GetDetailParams, type GetListParams, type GetViewParams, KeyConstants, type LoginCredentialBody, MainProvider, MethodConstants, MethodType, ModelConstants, ModelService, type OnChangeParams, ReactQueryProvider, type ResetPasswordRequest, type RootState, type SaveParams, SearchType, type SocialTokenBody, type Specification, type UpdatePasswordRequest, UriConstants, UserModel, UserService, VersionGate, type View, type ViewData, ViewService, WIDGETAVATAR, WIDGETCOLOR, WIDGETNOSTRING, WIDGETSTATUS, axiosClient, checkIsImageLink, clearSearchMap, domainHelper, env, envSlice, envStore, evalJSONContext, evalJSONDomain, excelSlice, formSlice, formatFileSize, formatSortingString, formatUrlPath, getEnv, getFieldsOnChange, getSubdomain, initEnv, isBase64File, isBase64Image, listSlice, navbarSlice, profileSlice, removeKeyFromSearchMap, removeUndefinedFields, searchSlice, selectEnv, selectExcel, selectForm, selectList, selectNavbar, selectProfile, selectSearch, selectSearchMap, setAllowCompanies, setCompanies, setDataParse, setDataUser, setDefaultCompany, setDomainTable, setEnv, setEnvFile, setErrorData, setFieldTranslate, setFields, setFilterBy, setFirstDomain, setFormSubmitComponent, setGroupBy, setGroupByDomain, setHoveredIndexSearchList, setIdFile, setIndexRowTableModal, setIsFileLoaded, setIsShowModalTranslate, setIsShowingModalDetail, setLang, setListSubject, setLoadingImport, setMenuList, setModelSearch, setOrder, setPage, setPageLimit, setProfile, setSearchMap, setSearchString, setSelectedFile, setSelectedRowKeys, setSelectedTags, setTableHead, setTypeFieldsSearch, setUid, setUser, setViewDataStore, stringToColor, toQueryString, type updatePasswordBody, updateSearchMap, useAppDispatch, useAppSelector, useForgotPassword, useTabModel };
|