@apia/uploader-controller 4.0.44
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/index.d.ts +495 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +1502 -0
- package/dist/index.js.map +1 -0
- package/package.json +31 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,495 @@
|
|
|
1
|
+
import * as _apia_util from '@apia/util';
|
|
2
|
+
import { EventEmitter, NotificationDefinition, T__LEGACY_SERVER__ApiaLoad, T__LEGACY_SERVER__ApiaFunction } from '@apia/util';
|
|
3
|
+
import * as _apia_api2 from '@apia/api2';
|
|
4
|
+
import { ApiContext } from '@apia/api2';
|
|
5
|
+
|
|
6
|
+
interface UploadContext extends ApiContext {
|
|
7
|
+
currentUserLogin: string;
|
|
8
|
+
docLangs: string;
|
|
9
|
+
everyoneCanUpdate: boolean;
|
|
10
|
+
ownerCanUpdate: boolean;
|
|
11
|
+
readonly: boolean;
|
|
12
|
+
IN_MONITOR: boolean;
|
|
13
|
+
WEBDAV_SERVER: string;
|
|
14
|
+
ITHit: any;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* El comportamiento de esta función se explica por su
|
|
18
|
+
* nombre.
|
|
19
|
+
*/
|
|
20
|
+
declare function returnExactlyTheSame(defaultParameters: Record<string, unknown>): Record<string, unknown>;
|
|
21
|
+
declare const parseFileDefinition: (context: UploadContext, fileDefinition: TFileUploaded | TUploaderFileInfo, isSignRequired: boolean) => TUploaderFileInfo;
|
|
22
|
+
type TOnUploadProgress = (progress: number) => void;
|
|
23
|
+
declare class UploaderApi extends EventEmitter<{
|
|
24
|
+
fileUploaded: null;
|
|
25
|
+
}> {
|
|
26
|
+
props: {
|
|
27
|
+
context: UploadContext;
|
|
28
|
+
id: string;
|
|
29
|
+
type: 'E' | 'P';
|
|
30
|
+
modalConfig: TModalConfig;
|
|
31
|
+
};
|
|
32
|
+
maxFiles: number;
|
|
33
|
+
modalController: UploaderModalController | null;
|
|
34
|
+
allowTranslations: boolean;
|
|
35
|
+
langs: Record<number, string> | undefined;
|
|
36
|
+
currentConfiguration: TUploaderLoadCurrentFunctionMessages | undefined;
|
|
37
|
+
state: UploaderState;
|
|
38
|
+
get filesArray(): TUploaderFileInfo[];
|
|
39
|
+
constructor(props: {
|
|
40
|
+
context: UploadContext;
|
|
41
|
+
id: string;
|
|
42
|
+
type: 'E' | 'P';
|
|
43
|
+
modalConfig: TModalConfig;
|
|
44
|
+
});
|
|
45
|
+
get context(): UploadContext;
|
|
46
|
+
init(): Promise<void>;
|
|
47
|
+
protected buildModalController(conf?: {
|
|
48
|
+
langId?: number;
|
|
49
|
+
translatingFile?: TUploaderFileInfo;
|
|
50
|
+
versionFile?: TUploaderFileInfo;
|
|
51
|
+
}): UploaderModalController;
|
|
52
|
+
onStartUpload(files?: File[]): Promise<void>;
|
|
53
|
+
onTranslateUpload(conf: {
|
|
54
|
+
langId: number;
|
|
55
|
+
translatingFile: TUploaderFileInfo;
|
|
56
|
+
}, files?: File[]): Promise<void>;
|
|
57
|
+
onVersionUpload(file: TUploaderFileInfo, conf?: {
|
|
58
|
+
newFiles?: File[];
|
|
59
|
+
langId?: number;
|
|
60
|
+
translatingFile?: TUploaderFileInfo;
|
|
61
|
+
}): Promise<void>;
|
|
62
|
+
autoLock(): Promise<boolean>;
|
|
63
|
+
notify(notification: NotificationDefinition): void;
|
|
64
|
+
protected getAjaxUrl(): string;
|
|
65
|
+
getDocTypes(): TDocType[];
|
|
66
|
+
getCurrentDocTypeId(): string;
|
|
67
|
+
getCurrentDocType(): TDocType | undefined;
|
|
68
|
+
getInProgressFiles(): File[];
|
|
69
|
+
getHiddenFiles(): File[];
|
|
70
|
+
getExistingFiles(): Record<string, TUploaderFileInfo>;
|
|
71
|
+
getProgress(): number;
|
|
72
|
+
getHasAllDocTypes(): boolean | undefined;
|
|
73
|
+
getDocumentInfo({ docId: apiId, downloadDocId: docId, }: TRequireOnlyOne<{
|
|
74
|
+
docId: string;
|
|
75
|
+
downloadDocId: string;
|
|
76
|
+
}>, newElem?: boolean): Promise<({
|
|
77
|
+
canClose: boolean;
|
|
78
|
+
type: string;
|
|
79
|
+
} & {
|
|
80
|
+
function: {
|
|
81
|
+
name: string;
|
|
82
|
+
} & {
|
|
83
|
+
data: {
|
|
84
|
+
onClose: string;
|
|
85
|
+
general: TApiaDocumentDefinition;
|
|
86
|
+
permissions: {
|
|
87
|
+
pool: TDocumentPermission | TDocumentPermission[];
|
|
88
|
+
user: TDocumentPermission | TDocumentPermission[];
|
|
89
|
+
};
|
|
90
|
+
versions: {
|
|
91
|
+
version: TDocumentVersion | TDocumentVersion[];
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
currentUsrPems: {
|
|
95
|
+
usrCanModify: boolean;
|
|
96
|
+
};
|
|
97
|
+
metadatas: {
|
|
98
|
+
metadata: TDocumentMetadata | TDocumentMetadata[];
|
|
99
|
+
};
|
|
100
|
+
docDownHistory: {
|
|
101
|
+
docHistory: TDocumentDownloadHistory | TDocumentDownloadHistory[];
|
|
102
|
+
};
|
|
103
|
+
};
|
|
104
|
+
} & _apia_util.T__LEGACY_SERVER__MessagesPayload) | null>;
|
|
105
|
+
/**
|
|
106
|
+
* This method searches for the provided id in several places:
|
|
107
|
+
*
|
|
108
|
+
* If it's found in the current files, returns it.
|
|
109
|
+
* If not, it searches the provided docId in the translations map of each uploaded file.
|
|
110
|
+
*/
|
|
111
|
+
getDocument(docId: string): TUploaderFileInfo | undefined;
|
|
112
|
+
protected updateDocument(docId: string, newValue: TUploaderFileInfo): void;
|
|
113
|
+
protected deleteDocument(docId: string): void;
|
|
114
|
+
clearFile(name: string): void;
|
|
115
|
+
clearFiles(): void;
|
|
116
|
+
clearState(): void;
|
|
117
|
+
checkLockDocument(id: string, shouldNotifyUnlocked?: boolean): Promise<string | boolean>;
|
|
118
|
+
setCurrentDocTypeId(docTypeId: string): void;
|
|
119
|
+
ajaxUploadStart(newFiles?: File[]): Promise<boolean | undefined>;
|
|
120
|
+
reloadMetadata(props?: Partial<{
|
|
121
|
+
docId: string;
|
|
122
|
+
docTypeId: number | string;
|
|
123
|
+
}>, additionalProps?: Record<string, unknown>): Promise<void>;
|
|
124
|
+
saveDroppedFiles(unprocessedFiles: File[], conf?: TSaveDroppedFilesConf): Promise<boolean>;
|
|
125
|
+
checkWebDavLock(docId: string): Promise<unknown>;
|
|
126
|
+
checkSignature(file: TUploaderFileInfo): Promise<_apia_api2.TApiaApiAxiosResponse<({
|
|
127
|
+
markedToSign: boolean;
|
|
128
|
+
} & _apia_util.T__LEGACY_SERVER__MessagesPayload) | null> | null>;
|
|
129
|
+
editDocument(id: string): Promise<void>;
|
|
130
|
+
downloadVersion(fileId: string, version?: string): Promise<void>;
|
|
131
|
+
downloadDocument(id: string, version?: string): Promise<void>;
|
|
132
|
+
ajaxDeleteDocument(id: string, langId?: number): Promise<void>;
|
|
133
|
+
version(file: TUploaderFileInfo, conf?: {
|
|
134
|
+
newFiles?: File[];
|
|
135
|
+
langId?: number;
|
|
136
|
+
translatingFile?: TUploaderFileInfo;
|
|
137
|
+
}): Promise<void>;
|
|
138
|
+
versionFileInfo(file: TUploaderFileInfo): Promise<void>;
|
|
139
|
+
pickFileById(id: string): Promise<void>;
|
|
140
|
+
markFileToSign(id: string, langId?: string): Promise<void>;
|
|
141
|
+
/**
|
|
142
|
+
* Por el momento realiza la descarga de todos los archivos
|
|
143
|
+
* que estén subidos.
|
|
144
|
+
*/
|
|
145
|
+
downloadMultipleDocuments(): void;
|
|
146
|
+
confirmDropModal(conf?: {
|
|
147
|
+
langId?: number;
|
|
148
|
+
translatingFile?: TUploaderFileInfo;
|
|
149
|
+
}): Promise<boolean>;
|
|
150
|
+
loadCurrentDocuments(): Promise<void>;
|
|
151
|
+
lockDocument(id: string): Promise<void>;
|
|
152
|
+
protected evaluateDeleteDocumentResult(result: unknown): boolean;
|
|
153
|
+
setTranslationFile(file: TUploaderFileInfo, docId: string, langId: number): void;
|
|
154
|
+
protected getCheckSignatureParameters: typeof returnExactlyTheSame;
|
|
155
|
+
protected getAjaxUploadFileStatusParameters: typeof returnExactlyTheSame;
|
|
156
|
+
protected getAjaxUploadStartParameters: typeof returnExactlyTheSame;
|
|
157
|
+
protected getConfirmDropModalParameters: typeof returnExactlyTheSame;
|
|
158
|
+
protected getCheckLockDocumentParameters: typeof returnExactlyTheSame;
|
|
159
|
+
protected getCheckWebDavLockParameters: typeof returnExactlyTheSame;
|
|
160
|
+
protected getConfirmDropModalPostdata: typeof returnExactlyTheSame;
|
|
161
|
+
protected getConfirmDropModalMetadataString: ({ metadata, }: {
|
|
162
|
+
metadata: TDocumentMetadata[];
|
|
163
|
+
}) => string;
|
|
164
|
+
protected getConfirmDropModalPermissionsString: ({ poolsPermissions, usersPermissions, }: {
|
|
165
|
+
poolsPermissions: IPoolsPermissions[];
|
|
166
|
+
usersPermissions: IUsersPermissions[];
|
|
167
|
+
}) => string;
|
|
168
|
+
protected getConfirmDropModalAdditionalMetadataString: (additionalMetadata: TDocumentMetadata[] | []) => string;
|
|
169
|
+
protected getDeleteDocumentParameters: typeof returnExactlyTheSame;
|
|
170
|
+
protected getClearTempFilesParameters: typeof returnExactlyTheSame;
|
|
171
|
+
protected getDocumentInfoParameters: typeof returnExactlyTheSame;
|
|
172
|
+
protected getDownloadMultipleDocumentsParameters: typeof returnExactlyTheSame;
|
|
173
|
+
protected getEditDocumentParameters: typeof returnExactlyTheSame;
|
|
174
|
+
protected getLockDocumentParameters: typeof returnExactlyTheSame;
|
|
175
|
+
protected getMarkFileToSignParameters: typeof returnExactlyTheSame;
|
|
176
|
+
protected getProcessDroppedFilesParameters: typeof returnExactlyTheSame;
|
|
177
|
+
protected getProcessDroppedFilesPostdata: typeof returnExactlyTheSame;
|
|
178
|
+
protected getReloadMetadataParameters: typeof returnExactlyTheSame;
|
|
179
|
+
protected getSaveDroppedFilesParameters: typeof returnExactlyTheSame;
|
|
180
|
+
protected filterAlreadyUploadedFiles(files: File[], conf?: TSaveDroppedFilesConf): File[];
|
|
181
|
+
protected filterByFilesAmountLimit(files: File[]): File[];
|
|
182
|
+
protected filterAcceptedFiles(files: File[], shouldNotify?: boolean, docTypeId?: string | TDocType): File[];
|
|
183
|
+
protected filterExistingFiles(files: File[], conf?: TSaveDroppedFilesConf): File[];
|
|
184
|
+
protected filterVersioningFiles(files: File[], conf?: {
|
|
185
|
+
langId?: number;
|
|
186
|
+
strictMode?: boolean;
|
|
187
|
+
translatingFile?: TUploaderFileInfo;
|
|
188
|
+
shouldReset?: boolean;
|
|
189
|
+
}): File[];
|
|
190
|
+
parseFileDefinition: (file: TFileUploaded) => TUploaderFileInfo;
|
|
191
|
+
getLoadFileSystemStructureTree(): Record<string, unknown>;
|
|
192
|
+
getLoadFilesForFolderParameters(): Record<string, unknown>;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
declare class UploaderModalController {
|
|
196
|
+
api: UploaderApi;
|
|
197
|
+
modalConfig: TModalConfig;
|
|
198
|
+
conf?: {
|
|
199
|
+
langId?: number;
|
|
200
|
+
translatingFile?: TUploaderFileInfo;
|
|
201
|
+
versionFile?: TUploaderFileInfo;
|
|
202
|
+
} | undefined;
|
|
203
|
+
state: UploaderModalState;
|
|
204
|
+
constructor(api: UploaderApi, modalConfig: TModalConfig, conf?: {
|
|
205
|
+
langId?: number;
|
|
206
|
+
translatingFile?: TUploaderFileInfo;
|
|
207
|
+
versionFile?: TUploaderFileInfo;
|
|
208
|
+
} | undefined);
|
|
209
|
+
get allMetadata(): TDocumentMetadata[];
|
|
210
|
+
get allowAllType(): "" | "M" | "R";
|
|
211
|
+
get description(): string;
|
|
212
|
+
get docFolder(): number | undefined;
|
|
213
|
+
get docExpDate(): string | undefined;
|
|
214
|
+
get docTypes(): TDocType[];
|
|
215
|
+
get freeMetadata(): TDocumentMetadata[];
|
|
216
|
+
get exitingFiles(): Record<string, TUploaderFileInfo>;
|
|
217
|
+
get inProgressFiles(): File[];
|
|
218
|
+
get hiddenFiles(): File[];
|
|
219
|
+
get progress(): number;
|
|
220
|
+
get metadata(): TDocumentMetadata[];
|
|
221
|
+
get selectedDocTypeId(): string;
|
|
222
|
+
get selectedDocType(): TDocType | undefined;
|
|
223
|
+
addMetadata(): void;
|
|
224
|
+
addFiles(files: File[]): void;
|
|
225
|
+
addDirectoryFile(file: TApiaDocumentDefinition): void;
|
|
226
|
+
changeDocType(docTypeId: string): Promise<void>;
|
|
227
|
+
clearDirectoryFile(): void;
|
|
228
|
+
clearFile(name: string): void;
|
|
229
|
+
clearFiles(): void;
|
|
230
|
+
clearState(): void;
|
|
231
|
+
clearPartialState(): void;
|
|
232
|
+
onCloseModal(): void;
|
|
233
|
+
confirm(): Promise<boolean>;
|
|
234
|
+
deleteMetadata(indices: number[]): void;
|
|
235
|
+
deletePermission(item: IPoolsPermissions | IUsersPermissions): void;
|
|
236
|
+
protected onChangeExtension(): void;
|
|
237
|
+
openModal(): Promise<void>;
|
|
238
|
+
setDescription(desc: string): void;
|
|
239
|
+
protected resetMetadata(): Promise<void>;
|
|
240
|
+
validate(): boolean;
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
type TUploadModalOpener = (controller: UploaderModalController) => void;
|
|
244
|
+
type UploaderModalState = {
|
|
245
|
+
fileReqError: boolean;
|
|
246
|
+
metadata: {
|
|
247
|
+
metadataArray: TDocumentMetadata[];
|
|
248
|
+
isFreeMetadata: boolean;
|
|
249
|
+
freeMetadataArray: TDocumentMetadata[];
|
|
250
|
+
};
|
|
251
|
+
fromDirectoryFile: TApiaDocumentDefinition | null;
|
|
252
|
+
docFolder?: number;
|
|
253
|
+
docPath?: string;
|
|
254
|
+
docExpDate?: string;
|
|
255
|
+
description: string;
|
|
256
|
+
isReadonly?: boolean;
|
|
257
|
+
permissions: {
|
|
258
|
+
allowAllType: 'M' | 'R' | '';
|
|
259
|
+
users: IUsersPermissions[];
|
|
260
|
+
pools: IPoolsPermissions[];
|
|
261
|
+
};
|
|
262
|
+
};
|
|
263
|
+
type UploaderState = {
|
|
264
|
+
progress: number;
|
|
265
|
+
allowedTypes: TDocType[];
|
|
266
|
+
selectedDocTypeId: string;
|
|
267
|
+
versioningFile: TUploaderFileInfo | null;
|
|
268
|
+
inProgressFiles: File[];
|
|
269
|
+
hiddenFiles: File[];
|
|
270
|
+
files: Record<string, TUploaderFileInfo>;
|
|
271
|
+
translatedFiles: Map<string, Map<number, TUploaderFileInfo>>;
|
|
272
|
+
hasAllDocTypes?: boolean;
|
|
273
|
+
selectedFiles: string[];
|
|
274
|
+
};
|
|
275
|
+
interface IUsersPermissions {
|
|
276
|
+
userId: string;
|
|
277
|
+
userLogin: string;
|
|
278
|
+
canUpdate: boolean;
|
|
279
|
+
}
|
|
280
|
+
interface IPoolsPermissions {
|
|
281
|
+
poolId: string;
|
|
282
|
+
poolName: string;
|
|
283
|
+
canUpdate: boolean;
|
|
284
|
+
}
|
|
285
|
+
type TUploaderFileInfo = Omit<TFileUploaded, 'locked' | 'userLocking'> & {
|
|
286
|
+
canEdit?: boolean;
|
|
287
|
+
canRead?: boolean;
|
|
288
|
+
isLocked: boolean;
|
|
289
|
+
locked?: boolean;
|
|
290
|
+
isLockedByMe: boolean;
|
|
291
|
+
isVirtual: boolean;
|
|
292
|
+
lockingUser: string;
|
|
293
|
+
};
|
|
294
|
+
type TFileUploaded = {
|
|
295
|
+
canEdit?: boolean;
|
|
296
|
+
canWrite?: boolean;
|
|
297
|
+
canRead?: boolean;
|
|
298
|
+
description?: string;
|
|
299
|
+
docDescription?: string;
|
|
300
|
+
docId: string;
|
|
301
|
+
docLang?: string;
|
|
302
|
+
docLangGroup?: string;
|
|
303
|
+
docName?: string;
|
|
304
|
+
docSize?: string;
|
|
305
|
+
docTypeFreeMetadata?: boolean;
|
|
306
|
+
docTypeId?: string;
|
|
307
|
+
docTypeLabel?: string;
|
|
308
|
+
docTypeTitle: string;
|
|
309
|
+
downloadDocId: string;
|
|
310
|
+
isMarkedToSign: boolean;
|
|
311
|
+
markedToSign: boolean;
|
|
312
|
+
lock?: string | boolean;
|
|
313
|
+
isLocked?: string | boolean;
|
|
314
|
+
lockedBy?: string;
|
|
315
|
+
name?: string;
|
|
316
|
+
onlyInformation: boolean;
|
|
317
|
+
prefix: string;
|
|
318
|
+
preview: string;
|
|
319
|
+
sign?: string | boolean;
|
|
320
|
+
size?: string;
|
|
321
|
+
userLocking: string;
|
|
322
|
+
virtualDoc?: boolean;
|
|
323
|
+
locked?: boolean;
|
|
324
|
+
};
|
|
325
|
+
type TAjaxUploadStart = T__LEGACY_SERVER__ApiaLoad<T__LEGACY_SERVER__ApiaFunction<{
|
|
326
|
+
general: {
|
|
327
|
+
isDocTypeDisabled: boolean;
|
|
328
|
+
useDocTypePermitted: boolean;
|
|
329
|
+
createMode: boolean;
|
|
330
|
+
allowAllTypes: string;
|
|
331
|
+
allDocTypes: boolean;
|
|
332
|
+
};
|
|
333
|
+
docTypes: {
|
|
334
|
+
docType: TDocType | TDocType[];
|
|
335
|
+
};
|
|
336
|
+
metadatas: {
|
|
337
|
+
metadata: TDocumentMetadata | TDocumentMetadata[];
|
|
338
|
+
};
|
|
339
|
+
}, false>>;
|
|
340
|
+
type TDocType = {
|
|
341
|
+
docExts: string;
|
|
342
|
+
maxSize: number;
|
|
343
|
+
id: string;
|
|
344
|
+
title: string;
|
|
345
|
+
free: boolean;
|
|
346
|
+
selected: boolean;
|
|
347
|
+
};
|
|
348
|
+
type TDocumentMetadata = {
|
|
349
|
+
free: string;
|
|
350
|
+
id: string;
|
|
351
|
+
name: string;
|
|
352
|
+
required: 'Y' | 'N';
|
|
353
|
+
title: string;
|
|
354
|
+
type: 'S' | 'N' | 'D';
|
|
355
|
+
value: string;
|
|
356
|
+
errorMessage: string;
|
|
357
|
+
labelErrorMessage: string;
|
|
358
|
+
};
|
|
359
|
+
type TModalConfig = {
|
|
360
|
+
allowDocumentsMonitor: boolean;
|
|
361
|
+
allowPickFromDirectories: boolean;
|
|
362
|
+
collapsePermissions: boolean;
|
|
363
|
+
collapseDirectories: boolean;
|
|
364
|
+
collapseMetadata: boolean;
|
|
365
|
+
defaultDirectory?: number;
|
|
366
|
+
monitorId?: number;
|
|
367
|
+
oneClickUpload: boolean;
|
|
368
|
+
rootFolder?: string;
|
|
369
|
+
showDirectoriesStructure: boolean;
|
|
370
|
+
showExpDate: boolean;
|
|
371
|
+
showPermissions: boolean;
|
|
372
|
+
showMetadata: boolean;
|
|
373
|
+
translationId?: string;
|
|
374
|
+
};
|
|
375
|
+
type TUploaderLoadCurrentFunctionMessages = {
|
|
376
|
+
allowSign: boolean;
|
|
377
|
+
allowLock: boolean;
|
|
378
|
+
allowMultiple: boolean;
|
|
379
|
+
readOnly: boolean;
|
|
380
|
+
};
|
|
381
|
+
type TSaveDroppedFilesConf = {
|
|
382
|
+
langId?: number;
|
|
383
|
+
strictMode?: boolean;
|
|
384
|
+
translatingFile?: TUploaderFileInfo;
|
|
385
|
+
shouldReset?: boolean;
|
|
386
|
+
};
|
|
387
|
+
type TAjaxUploadFileStatus = T__LEGACY_SERVER__ApiaLoad<T__LEGACY_SERVER__ApiaFunction<{
|
|
388
|
+
message: {
|
|
389
|
+
label: string;
|
|
390
|
+
name: string;
|
|
391
|
+
}[];
|
|
392
|
+
}>>;
|
|
393
|
+
type TProcessDroppedFiles = T__LEGACY_SERVER__ApiaLoad<T__LEGACY_SERVER__ApiaFunction<{
|
|
394
|
+
principal: {
|
|
395
|
+
docInfo: TDocInfo | TDocInfo[];
|
|
396
|
+
docTypes: {
|
|
397
|
+
'data-free': boolean;
|
|
398
|
+
docTypeExtensions: string;
|
|
399
|
+
docTypeId: string;
|
|
400
|
+
docTypeMaxSize: number;
|
|
401
|
+
docTypeName: string;
|
|
402
|
+
};
|
|
403
|
+
elemInfo: {
|
|
404
|
+
elemId: string;
|
|
405
|
+
elemType: string;
|
|
406
|
+
};
|
|
407
|
+
};
|
|
408
|
+
}, false>>;
|
|
409
|
+
type TDocInfo = {
|
|
410
|
+
docInfoName: string;
|
|
411
|
+
docInfoSize: string;
|
|
412
|
+
docInfoTmpId: string;
|
|
413
|
+
docInfoType: string;
|
|
414
|
+
};
|
|
415
|
+
type TConfirmDropModal = T__LEGACY_SERVER__ApiaLoad<T__LEGACY_SERVER__ApiaFunction<{
|
|
416
|
+
general: TFileUploaded | TFileUploaded[];
|
|
417
|
+
fromForm: {
|
|
418
|
+
fromForm: {
|
|
419
|
+
fromForm: boolean;
|
|
420
|
+
}[];
|
|
421
|
+
};
|
|
422
|
+
}, false>>;
|
|
423
|
+
type TApiaDocumentDefinition = {
|
|
424
|
+
docDesc: string;
|
|
425
|
+
docTypeLabel: string;
|
|
426
|
+
docId: string;
|
|
427
|
+
prefix: string;
|
|
428
|
+
docSize: string;
|
|
429
|
+
docDate: string;
|
|
430
|
+
docDwnExternal: string;
|
|
431
|
+
docExpDate: string;
|
|
432
|
+
docFolder: string;
|
|
433
|
+
docFolderPath: string;
|
|
434
|
+
docUsu: string;
|
|
435
|
+
docAllPoolPerm: 'M' | 'R' | '';
|
|
436
|
+
docName: string;
|
|
437
|
+
docTypeId: string;
|
|
438
|
+
locked: boolean;
|
|
439
|
+
downloadDocId: string;
|
|
440
|
+
};
|
|
441
|
+
type TUploaderLoadCurrentFunction = {
|
|
442
|
+
general?: TFileUploaded | TFileUploaded[];
|
|
443
|
+
messages: {
|
|
444
|
+
message: {
|
|
445
|
+
name: keyof TUploaderLoadCurrentFunctionMessages;
|
|
446
|
+
label: boolean;
|
|
447
|
+
} | {
|
|
448
|
+
name: keyof TUploaderLoadCurrentFunctionMessages;
|
|
449
|
+
label: boolean;
|
|
450
|
+
}[];
|
|
451
|
+
};
|
|
452
|
+
};
|
|
453
|
+
type TDocumentInformation = T__LEGACY_SERVER__ApiaLoad<T__LEGACY_SERVER__ApiaFunction<{
|
|
454
|
+
data: {
|
|
455
|
+
onClose: string;
|
|
456
|
+
general: TApiaDocumentDefinition;
|
|
457
|
+
permissions: {
|
|
458
|
+
pool: TDocumentPermission | TDocumentPermission[];
|
|
459
|
+
user: TDocumentPermission | TDocumentPermission[];
|
|
460
|
+
};
|
|
461
|
+
versions: {
|
|
462
|
+
version: TDocumentVersion | TDocumentVersion[];
|
|
463
|
+
};
|
|
464
|
+
};
|
|
465
|
+
currentUsrPems: {
|
|
466
|
+
usrCanModify: boolean;
|
|
467
|
+
};
|
|
468
|
+
metadatas: {
|
|
469
|
+
metadata: TDocumentMetadata | TDocumentMetadata[];
|
|
470
|
+
};
|
|
471
|
+
docDownHistory: {
|
|
472
|
+
docHistory: TDocumentDownloadHistory | TDocumentDownloadHistory[];
|
|
473
|
+
};
|
|
474
|
+
}, false>>;
|
|
475
|
+
type TDocumentPermission = {
|
|
476
|
+
id: string;
|
|
477
|
+
name: string;
|
|
478
|
+
permType: 'R' | 'M';
|
|
479
|
+
};
|
|
480
|
+
type TDocumentDownloadHistory = {
|
|
481
|
+
hisDwn: string;
|
|
482
|
+
hisUsr: string;
|
|
483
|
+
hisVer: string;
|
|
484
|
+
};
|
|
485
|
+
type TDocumentVersion = {
|
|
486
|
+
verUser: string;
|
|
487
|
+
verNumber: string;
|
|
488
|
+
verDate: string;
|
|
489
|
+
};
|
|
490
|
+
type TRequireOnlyOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> & {
|
|
491
|
+
[K in Keys]-?: Required<Pick<T, K>> & Partial<Record<Exclude<Keys, K>, undefined>>;
|
|
492
|
+
}[Keys];
|
|
493
|
+
|
|
494
|
+
export { type IPoolsPermissions, type IUsersPermissions, type TAjaxUploadFileStatus, type TAjaxUploadStart, type TApiaDocumentDefinition, type TConfirmDropModal, type TDocInfo, type TDocType, type TDocumentDownloadHistory, type TDocumentInformation, type TDocumentMetadata, type TDocumentPermission, type TDocumentVersion, type TFileUploaded, type TModalConfig, type TOnUploadProgress, type TProcessDroppedFiles, type TRequireOnlyOne, type TSaveDroppedFilesConf, type TUploadModalOpener, type TUploaderFileInfo, type TUploaderLoadCurrentFunction, type TUploaderLoadCurrentFunctionMessages, type UploadContext, UploaderApi, UploaderModalController, type UploaderModalState, type UploaderState, parseFileDefinition, returnExactlyTheSame };
|
|
495
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|