@aiao/rxdb-test 0.0.14 → 0.0.16

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.
Files changed (49) hide show
  1. package/dist/entities/FileLarge.d.ts +339 -0
  2. package/dist/entities/FileLarge.js +77 -0
  3. package/dist/entities/FileNode.d.ts +335 -0
  4. package/dist/entities/FileNode.js +77 -0
  5. package/dist/entities/MenuLarge.d.ts +294 -0
  6. package/dist/entities/MenuLarge.js +41 -0
  7. package/dist/entities/MenuSimple.d.ts +290 -0
  8. package/dist/entities/MenuSimple.js +41 -0
  9. package/dist/entities/Todo.d.ts +165 -0
  10. package/dist/entities/Todo.js +34 -0
  11. package/dist/entities/TypeDemo.d.ts +264 -0
  12. package/dist/entities/TypeDemo.js +101 -0
  13. package/dist/entities/index.d.ts +14 -1664
  14. package/dist/entities/index.js +6 -360
  15. package/dist/graph/index.d.ts +1 -2
  16. package/dist/graph/index.js +1 -1
  17. package/dist/shop/Attribute.d.ts +359 -0
  18. package/dist/shop/Attribute.js +50 -0
  19. package/dist/shop/AttributeValue.d.ts +366 -0
  20. package/dist/shop/AttributeValue.js +51 -0
  21. package/dist/shop/Category.d.ts +280 -0
  22. package/dist/shop/Category.js +41 -0
  23. package/dist/shop/IdCard.d.ts +237 -0
  24. package/dist/shop/IdCard.js +43 -0
  25. package/dist/shop/Order.d.ts +270 -0
  26. package/dist/shop/Order.js +58 -0
  27. package/dist/shop/OrderItem.d.ts +293 -0
  28. package/dist/shop/OrderItem.js +64 -0
  29. package/dist/shop/Product.d.ts +321 -0
  30. package/dist/shop/Product.js +47 -0
  31. package/dist/shop/SKU.d.ts +343 -0
  32. package/dist/shop/SKU.js +63 -0
  33. package/dist/shop/SKUAttributes.d.ts +306 -0
  34. package/dist/shop/SKUAttributes.js +56 -0
  35. package/dist/shop/User.d.ts +269 -0
  36. package/dist/shop/User.js +74 -0
  37. package/dist/shop/index.d.ts +22 -2980
  38. package/dist/shop/index.js +10 -528
  39. package/dist/system/RxDBBranch.d.ts +396 -0
  40. package/dist/system/RxDBBranch.js +106 -0
  41. package/dist/system/RxDBChange.d.ts +361 -0
  42. package/dist/system/RxDBChange.js +123 -0
  43. package/dist/system/RxDBMigration.d.ts +167 -0
  44. package/dist/system/RxDBMigration.js +40 -0
  45. package/dist/system/RxDBSync.d.ts +339 -0
  46. package/dist/system/RxDBSync.js +122 -0
  47. package/dist/system/index.d.ts +9 -1240
  48. package/dist/system/index.js +4 -384
  49. package/package.json +3 -3
@@ -1,458 +1,17 @@
1
- import { BooleanRules, CountOptions, DateRules, ENTITY_STATIC_TYPES, EntityBase, EntityType, FindAllOptions, FindByCursorOptions, FindOneOptions, FindOneOrFailOptions, FindOptions, FindTreeOptions, IEntity, ITreeEntity, KeyValueRules, NumberArrayRules, NumberRules, RelationBooleanRules, RelationDateRules, RelationEntitiesObservable, RelationEntityObservable, RelationExistsRules, RelationNumberRules, RelationStringRules, RelationUUIDRules, RuleGroupBase, StringArrayRules, StringRules, TreeAdjacencyListEntityBase, UUID, UUIDRules } from '@aiao/rxdb';
2
- import { Observable } from 'rxjs';
3
-
4
- /**
5
- * rule
6
- */
7
- declare type TypeDemoRule = UUIDRules<TypeDemo, 'id'>
8
- | DateRules<TypeDemo, 'createdAt'>
9
- | DateRules<TypeDemo, 'updatedAt'>
10
- | StringRules<TypeDemo, 'createdBy'>
11
- | StringRules<TypeDemo, 'updatedBy'>
12
- | StringRules<TypeDemo, 'string'>
13
- | NumberRules<TypeDemo, 'number'>
14
- | NumberRules<TypeDemo, 'integer'>
15
- | BooleanRules<TypeDemo, 'boolean'>
16
- | DateRules<TypeDemo, 'date'>
17
- | StringRules<TypeDemo, 'enum'>
18
- | StringArrayRules<TypeDemo, 'stringArray', string>
19
- | NumberArrayRules<TypeDemo, 'numberArray', number>
20
- | KeyValueRules<TypeDemo, 'keyValue', Partial<TypeDemoKeyValueKeyValue>>
21
- | RelationStringRules<'keyValue.string', string>
22
- | RelationNumberRules<'keyValue.number', number>
23
- | RelationNumberRules<'keyValue.integer', number>
24
- | RelationBooleanRules<'keyValue.boolean', boolean>
25
- | RelationDateRules<'keyValue.date', Date>;
26
-
27
- /**
28
- * RuleGroupBase
29
- */
30
- export declare type TypeDemoRuleGroup = RuleGroupBase<typeof TypeDemo,
31
- |'id'
32
- |'createdAt'
33
- |'updatedAt'
34
- |'createdBy'
35
- |'updatedBy'
36
- |'string'
37
- |'number'
38
- |'integer'
39
- |'boolean'
40
- |'date'
41
- |'enum'
42
- |'stringArray'
43
- |'numberArray'
44
- |'keyValue'
45
- |'keyValue.string'
46
- |'keyValue.number'
47
- |'keyValue.integer'
48
- |'keyValue.boolean'
49
- |'keyValue.date',
50
- TypeDemoRule>;
51
-
52
- /**
53
- * OrderByField
54
- */
55
- declare type TypeDemoOrderByField = "id" | "createdAt" | "updatedAt" | "createdBy" | "updatedBy" | "string" | "number" | "integer" | "boolean" | "date" | "enum" | "stringArray" | "numberArray" | "keyValue" | "json";
56
-
57
- /**
58
- * rule
59
- */
60
- declare type TodoRule = UUIDRules<Todo, 'id'>
61
- | DateRules<Todo, 'createdAt'>
62
- | DateRules<Todo, 'updatedAt'>
63
- | StringRules<Todo, 'createdBy'>
64
- | StringRules<Todo, 'updatedBy'>
65
- | StringRules<Todo, 'title'>
66
- | BooleanRules<Todo, 'completed'>;
67
-
68
- /**
69
- * RuleGroupBase
70
- */
71
- export declare type TodoRuleGroup = RuleGroupBase<typeof Todo,
72
- |'id'
73
- |'createdAt'
74
- |'updatedAt'
75
- |'createdBy'
76
- |'updatedBy'
77
- |'title'
78
- |'completed',
79
- TodoRule>;
80
-
81
- /**
82
- * OrderByField
83
- */
84
- declare type TodoOrderByField = "id" | "createdAt" | "updatedAt" | "createdBy" | "updatedBy" | "title" | "completed";
85
-
86
- /**
87
- * rule
88
- */
89
- declare type MenuSimpleRule = UUIDRules<MenuSimple, 'id'>
90
- | DateRules<MenuSimple, 'createdAt'>
91
- | DateRules<MenuSimple, 'updatedAt'>
92
- | StringRules<MenuSimple, 'createdBy'>
93
- | StringRules<MenuSimple, 'updatedBy'>
94
- | StringRules<MenuSimple, 'title'>
95
- | StringRules<MenuSimple, 'sortOrder'>
96
- | UUIDRules<MenuSimple, 'parentId'>
97
- | RelationExistsRules<'children', MenuSimpleRuleGroup>
98
- | RelationUUIDRules<'children.id', UUID>
99
- | RelationDateRules<'children.createdAt', Date>
100
- | RelationDateRules<'children.updatedAt', Date>
101
- | RelationStringRules<'children.createdBy', string | null>
102
- | RelationStringRules<'children.updatedBy', string | null>
103
- | RelationStringRules<'children.title', string>
104
- | RelationStringRules<'children.sortOrder', string | null>
105
- | RelationExistsRules<'parent', MenuSimpleRuleGroup>
106
- | RelationUUIDRules<'parent.id', UUID>
107
- | RelationDateRules<'parent.createdAt', Date>
108
- | RelationDateRules<'parent.updatedAt', Date>
109
- | RelationStringRules<'parent.createdBy', string | null>
110
- | RelationStringRules<'parent.updatedBy', string | null>
111
- | RelationStringRules<'parent.title', string>
112
- | RelationStringRules<'parent.sortOrder', string | null>;
113
-
114
- /**
115
- * RuleGroupBase
116
- */
117
- export declare type MenuSimpleRuleGroup = RuleGroupBase<typeof MenuSimple,
118
- |'id'
119
- |'createdAt'
120
- |'updatedAt'
121
- |'createdBy'
122
- |'updatedBy'
123
- |'title'
124
- |'sortOrder'
125
- |'parentId'
126
- |'children'
127
- |'children.id'
128
- |'children.createdAt'
129
- |'children.updatedAt'
130
- |'children.createdBy'
131
- |'children.updatedBy'
132
- |'children.title'
133
- |'children.sortOrder'
134
- |'parentId'
135
- |'parent'
136
- |'parent.id'
137
- |'parent.createdAt'
138
- |'parent.updatedAt'
139
- |'parent.createdBy'
140
- |'parent.updatedBy'
141
- |'parent.title'
142
- |'parent.sortOrder'
143
- |'parentId',
144
- MenuSimpleRule>;
145
-
146
- /**
147
- * OrderByField
148
- */
149
- declare type MenuSimpleOrderByField = "id" | "createdAt" | "updatedAt" | "createdBy" | "updatedBy" | "title" | "sortOrder";
150
-
151
- /**
152
- * TreeRule
153
- */
154
- declare type MenuSimpleTreeRule = RelationDateRules<'children.createdAt', Date>
155
- | RelationDateRules<'children.updatedAt', Date>
156
- | RelationStringRules<'children.createdBy', string | null>
157
- | RelationStringRules<'children.updatedBy', string | null>
158
- | RelationStringRules<'children.title', string>
159
- | RelationStringRules<'children.sortOrder', string | null>;
160
-
161
- /**
162
- * TreeRuleGroup
163
- */
164
- export declare type MenuSimpleTreeRuleGroup = RuleGroupBase<typeof MenuSimple, 'children.createdAt' | 'children.updatedAt' | 'children.createdBy' | 'children.updatedBy' | 'children.title' | 'children.sortOrder', MenuSimpleTreeRule>;
165
-
166
- /**
167
- * rule
168
- */
169
- declare type MenuLargeRule = UUIDRules<MenuLarge, 'id'>
170
- | DateRules<MenuLarge, 'createdAt'>
171
- | DateRules<MenuLarge, 'updatedAt'>
172
- | StringRules<MenuLarge, 'createdBy'>
173
- | StringRules<MenuLarge, 'updatedBy'>
174
- | StringRules<MenuLarge, 'title'>
175
- | StringRules<MenuLarge, 'sortOrder'>
176
- | UUIDRules<MenuLarge, 'parentId'>
177
- | RelationExistsRules<'children', MenuLargeRuleGroup>
178
- | RelationUUIDRules<'children.id', UUID>
179
- | RelationDateRules<'children.createdAt', Date>
180
- | RelationDateRules<'children.updatedAt', Date>
181
- | RelationStringRules<'children.createdBy', string | null>
182
- | RelationStringRules<'children.updatedBy', string | null>
183
- | RelationStringRules<'children.title', string>
184
- | RelationStringRules<'children.sortOrder', string | null>
185
- | RelationExistsRules<'parent', MenuLargeRuleGroup>
186
- | RelationUUIDRules<'parent.id', UUID>
187
- | RelationDateRules<'parent.createdAt', Date>
188
- | RelationDateRules<'parent.updatedAt', Date>
189
- | RelationStringRules<'parent.createdBy', string | null>
190
- | RelationStringRules<'parent.updatedBy', string | null>
191
- | RelationStringRules<'parent.title', string>
192
- | RelationStringRules<'parent.sortOrder', string | null>;
193
-
194
- /**
195
- * RuleGroupBase
196
- */
197
- export declare type MenuLargeRuleGroup = RuleGroupBase<typeof MenuLarge,
198
- |'id'
199
- |'createdAt'
200
- |'updatedAt'
201
- |'createdBy'
202
- |'updatedBy'
203
- |'title'
204
- |'sortOrder'
205
- |'parentId'
206
- |'children'
207
- |'children.id'
208
- |'children.createdAt'
209
- |'children.updatedAt'
210
- |'children.createdBy'
211
- |'children.updatedBy'
212
- |'children.title'
213
- |'children.sortOrder'
214
- |'parentId'
215
- |'parent'
216
- |'parent.id'
217
- |'parent.createdAt'
218
- |'parent.updatedAt'
219
- |'parent.createdBy'
220
- |'parent.updatedBy'
221
- |'parent.title'
222
- |'parent.sortOrder'
223
- |'parentId',
224
- MenuLargeRule>;
225
-
226
- /**
227
- * OrderByField
228
- */
229
- declare type MenuLargeOrderByField = "id" | "createdAt" | "updatedAt" | "createdBy" | "updatedBy" | "title" | "sortOrder";
230
-
231
- /**
232
- * TreeRule
233
- */
234
- declare type MenuLargeTreeRule = RelationDateRules<'children.createdAt', Date>
235
- | RelationDateRules<'children.updatedAt', Date>
236
- | RelationStringRules<'children.createdBy', string | null>
237
- | RelationStringRules<'children.updatedBy', string | null>
238
- | RelationStringRules<'children.title', string>
239
- | RelationStringRules<'children.sortOrder', string | null>;
240
-
241
- /**
242
- * TreeRuleGroup
243
- */
244
- export declare type MenuLargeTreeRuleGroup = RuleGroupBase<typeof MenuLarge, 'children.createdAt' | 'children.updatedAt' | 'children.createdBy' | 'children.updatedBy' | 'children.title' | 'children.sortOrder', MenuLargeTreeRule>;
245
-
246
- /**
247
- * rule
248
- */
249
- declare type FileNodeRule = UUIDRules<FileNode, 'id'>
250
- | DateRules<FileNode, 'createdAt'>
251
- | DateRules<FileNode, 'updatedAt'>
252
- | StringRules<FileNode, 'createdBy'>
253
- | StringRules<FileNode, 'updatedBy'>
254
- | StringRules<FileNode, 'name'>
255
- | StringRules<FileNode, 'type'>
256
- | StringRules<FileNode, 'sortOrder'>
257
- | StringRules<FileNode, 'extension'>
258
- | NumberRules<FileNode, 'size'>
259
- | UUIDRules<FileNode, 'parentId'>
260
- | RelationExistsRules<'children', FileNodeRuleGroup>
261
- | RelationUUIDRules<'children.id', UUID>
262
- | RelationDateRules<'children.createdAt', Date>
263
- | RelationDateRules<'children.updatedAt', Date>
264
- | RelationStringRules<'children.createdBy', string | null>
265
- | RelationStringRules<'children.updatedBy', string | null>
266
- | RelationStringRules<'children.name', string>
267
- | RelationStringRules<'children.type', string>
268
- | RelationStringRules<'children.sortOrder', string | null>
269
- | RelationStringRules<'children.extension', string | null>
270
- | RelationNumberRules<'children.size', number | null>
271
- | RelationExistsRules<'parent', FileNodeRuleGroup>
272
- | RelationUUIDRules<'parent.id', UUID>
273
- | RelationDateRules<'parent.createdAt', Date>
274
- | RelationDateRules<'parent.updatedAt', Date>
275
- | RelationStringRules<'parent.createdBy', string | null>
276
- | RelationStringRules<'parent.updatedBy', string | null>
277
- | RelationStringRules<'parent.name', string>
278
- | RelationStringRules<'parent.type', string>
279
- | RelationStringRules<'parent.sortOrder', string | null>
280
- | RelationStringRules<'parent.extension', string | null>
281
- | RelationNumberRules<'parent.size', number | null>;
282
-
283
- /**
284
- * RuleGroupBase
285
- */
286
- export declare type FileNodeRuleGroup = RuleGroupBase<typeof FileNode,
287
- |'id'
288
- |'createdAt'
289
- |'updatedAt'
290
- |'createdBy'
291
- |'updatedBy'
292
- |'name'
293
- |'type'
294
- |'sortOrder'
295
- |'extension'
296
- |'size'
297
- |'parentId'
298
- |'children'
299
- |'children.id'
300
- |'children.createdAt'
301
- |'children.updatedAt'
302
- |'children.createdBy'
303
- |'children.updatedBy'
304
- |'children.name'
305
- |'children.type'
306
- |'children.sortOrder'
307
- |'children.extension'
308
- |'children.size'
309
- |'parentId'
310
- |'parent'
311
- |'parent.id'
312
- |'parent.createdAt'
313
- |'parent.updatedAt'
314
- |'parent.createdBy'
315
- |'parent.updatedBy'
316
- |'parent.name'
317
- |'parent.type'
318
- |'parent.sortOrder'
319
- |'parent.extension'
320
- |'parent.size'
321
- |'parentId',
322
- FileNodeRule>;
323
-
324
- /**
325
- * OrderByField
326
- */
327
- declare type FileNodeOrderByField = "id" | "createdAt" | "updatedAt" | "createdBy" | "updatedBy" | "name" | "type" | "sortOrder" | "extension" | "size";
328
-
329
- /**
330
- * TreeRule
331
- */
332
- declare type FileNodeTreeRule = RelationDateRules<'children.createdAt', Date>
333
- | RelationDateRules<'children.updatedAt', Date>
334
- | RelationStringRules<'children.createdBy', string | null>
335
- | RelationStringRules<'children.updatedBy', string | null>
336
- | RelationStringRules<'children.name', string>
337
- | RelationStringRules<'children.type', string>
338
- | RelationStringRules<'children.sortOrder', string | null>
339
- | RelationStringRules<'children.extension', string | null>
340
- | RelationNumberRules<'children.size', number | null>;
341
-
342
- /**
343
- * TreeRuleGroup
344
- */
345
- export declare type FileNodeTreeRuleGroup = RuleGroupBase<typeof FileNode, 'children.createdAt' | 'children.updatedAt' | 'children.createdBy' | 'children.updatedBy' | 'children.name' | 'children.type' | 'children.sortOrder' | 'children.extension' | 'children.size', FileNodeTreeRule>;
346
-
347
- /**
348
- * rule
349
- */
350
- declare type FileLargeRule = UUIDRules<FileLarge, 'id'>
351
- | DateRules<FileLarge, 'createdAt'>
352
- | DateRules<FileLarge, 'updatedAt'>
353
- | StringRules<FileLarge, 'createdBy'>
354
- | StringRules<FileLarge, 'updatedBy'>
355
- | StringRules<FileLarge, 'name'>
356
- | StringRules<FileLarge, 'type'>
357
- | StringRules<FileLarge, 'sortOrder'>
358
- | StringRules<FileLarge, 'extension'>
359
- | NumberRules<FileLarge, 'size'>
360
- | UUIDRules<FileLarge, 'parentId'>
361
- | RelationExistsRules<'children', FileLargeRuleGroup>
362
- | RelationUUIDRules<'children.id', UUID>
363
- | RelationDateRules<'children.createdAt', Date>
364
- | RelationDateRules<'children.updatedAt', Date>
365
- | RelationStringRules<'children.createdBy', string | null>
366
- | RelationStringRules<'children.updatedBy', string | null>
367
- | RelationStringRules<'children.name', string>
368
- | RelationStringRules<'children.type', string>
369
- | RelationStringRules<'children.sortOrder', string | null>
370
- | RelationStringRules<'children.extension', string | null>
371
- | RelationNumberRules<'children.size', number | null>
372
- | RelationExistsRules<'parent', FileLargeRuleGroup>
373
- | RelationUUIDRules<'parent.id', UUID>
374
- | RelationDateRules<'parent.createdAt', Date>
375
- | RelationDateRules<'parent.updatedAt', Date>
376
- | RelationStringRules<'parent.createdBy', string | null>
377
- | RelationStringRules<'parent.updatedBy', string | null>
378
- | RelationStringRules<'parent.name', string>
379
- | RelationStringRules<'parent.type', string>
380
- | RelationStringRules<'parent.sortOrder', string | null>
381
- | RelationStringRules<'parent.extension', string | null>
382
- | RelationNumberRules<'parent.size', number | null>;
383
-
384
- /**
385
- * RuleGroupBase
386
- */
387
- export declare type FileLargeRuleGroup = RuleGroupBase<typeof FileLarge,
388
- |'id'
389
- |'createdAt'
390
- |'updatedAt'
391
- |'createdBy'
392
- |'updatedBy'
393
- |'name'
394
- |'type'
395
- |'sortOrder'
396
- |'extension'
397
- |'size'
398
- |'parentId'
399
- |'children'
400
- |'children.id'
401
- |'children.createdAt'
402
- |'children.updatedAt'
403
- |'children.createdBy'
404
- |'children.updatedBy'
405
- |'children.name'
406
- |'children.type'
407
- |'children.sortOrder'
408
- |'children.extension'
409
- |'children.size'
410
- |'parentId'
411
- |'parent'
412
- |'parent.id'
413
- |'parent.createdAt'
414
- |'parent.updatedAt'
415
- |'parent.createdBy'
416
- |'parent.updatedBy'
417
- |'parent.name'
418
- |'parent.type'
419
- |'parent.sortOrder'
420
- |'parent.extension'
421
- |'parent.size'
422
- |'parentId',
423
- FileLargeRule>;
424
-
425
- /**
426
- * OrderByField
427
- */
428
- declare type FileLargeOrderByField = "id" | "createdAt" | "updatedAt" | "createdBy" | "updatedBy" | "name" | "type" | "sortOrder" | "extension" | "size";
429
-
430
- /**
431
- * TreeRule
432
- */
433
- declare type FileLargeTreeRule = RelationDateRules<'children.createdAt', Date>
434
- | RelationDateRules<'children.updatedAt', Date>
435
- | RelationStringRules<'children.createdBy', string | null>
436
- | RelationStringRules<'children.updatedBy', string | null>
437
- | RelationStringRules<'children.name', string>
438
- | RelationStringRules<'children.type', string>
439
- | RelationStringRules<'children.sortOrder', string | null>
440
- | RelationStringRules<'children.extension', string | null>
441
- | RelationNumberRules<'children.size', number | null>;
442
-
443
- /**
444
- * TreeRuleGroup
445
- */
446
- export declare type FileLargeTreeRuleGroup = RuleGroupBase<typeof FileLarge, 'children.createdAt' | 'children.updatedAt' | 'children.createdBy' | 'children.updatedBy' | 'children.name' | 'children.type' | 'children.sortOrder' | 'children.extension' | 'children.size', FileLargeTreeRule>;
447
-
448
- /**
449
- * enum 枚举类型
450
- */
451
- export enum TypeDemoEnum {
452
- Active = "active",
453
- Inactive = "inactive",
454
- Pending = "pending"
455
- }
1
+ import { FileLarge } from './FileLarge.js';
2
+ import { FileNode } from './FileNode.js';
3
+ import { MenuLarge } from './MenuLarge.js';
4
+ import { MenuSimple } from './MenuSimple.js';
5
+ import { Todo } from './Todo.js';
6
+ import { TypeDemo } from './TypeDemo.js';
7
+ import { EntityType } from '@aiao/rxdb';
8
+
9
+ export * from './FileLarge.js';
10
+ export * from './FileNode.js';
11
+ export * from './MenuLarge.js';
12
+ export * from './MenuSimple.js';
13
+ export * from './Todo.js';
14
+ export * from './TypeDemo.js';
456
15
 
457
16
  /**
458
17
  * rxdb
@@ -489,1214 +48,5 @@ declare module "@aiao/rxdb" {
489
48
  }
490
49
  }
491
50
 
492
- /**
493
- * 静态类型
494
- */
495
- export interface TypeDemoStaticTypes {
496
- /**
497
- * id 类型
498
- */
499
- idType: UUID;
500
- /**
501
- * 查询选项
502
- */
503
- getOptions: UUID;
504
- /**
505
- * 查询选项
506
- */
507
- findOneOrFailOptions: FindOneOrFailOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>;
508
- /**
509
- * 查询选项
510
- */
511
- findOptions: FindOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>;
512
- /**
513
- * 查询选项
514
- */
515
- findOneOptions: FindOneOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>;
516
- /**
517
- * 查询选项
518
- */
519
- findAllOptions: FindAllOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>;
520
- /**
521
- * 查询选项
522
- */
523
- findByCursorOptions: FindByCursorOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>;
524
- /**
525
- * 查询选项
526
- */
527
- countOptions: CountOptions<typeof TypeDemo,TypeDemoRuleGroup>;
528
- }
529
-
530
- /**
531
- * 初始化数据
532
- */
533
- export interface TypeDemoInitData {
534
- /**
535
- * string
536
- */
537
- string?: string;
538
- /**
539
- * number
540
- */
541
- number?: number;
542
- /**
543
- * integer
544
- */
545
- integer?: number;
546
- /**
547
- * boolean
548
- */
549
- boolean?: boolean;
550
- /**
551
- * date
552
- */
553
- date?: Date;
554
- /**
555
- * enum
556
- */
557
- enum?: TypeDemoEnum | 'active' | 'inactive' | 'pending' | null;
558
- /**
559
- * stringArray
560
- */
561
- stringArray?: string[];
562
- /**
563
- * numberArray
564
- */
565
- numberArray?: number[];
566
- /**
567
- * keyValue
568
- */
569
- keyValue?: TypeDemoKeyValueKeyValue;
570
- /**
571
- * json
572
- */
573
- json?: Record<string, any>;
574
- }
575
-
576
- /**
577
- * keyValue keyValue 类型
578
- */
579
- export interface TypeDemoKeyValueKeyValue {
580
- string: string;
581
- number: number;
582
- integer: number;
583
- boolean: boolean;
584
- date: Date;
585
- }
586
-
587
- /**
588
- * 静态类型
589
- */
590
- export interface TodoStaticTypes {
591
- /**
592
- * id 类型
593
- */
594
- idType: UUID;
595
- /**
596
- * 查询选项
597
- */
598
- getOptions: UUID;
599
- /**
600
- * 查询选项
601
- */
602
- findOneOrFailOptions: FindOneOrFailOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>;
603
- /**
604
- * 查询选项
605
- */
606
- findOptions: FindOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>;
607
- /**
608
- * 查询选项
609
- */
610
- findOneOptions: FindOneOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>;
611
- /**
612
- * 查询选项
613
- */
614
- findAllOptions: FindAllOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>;
615
- /**
616
- * 查询选项
617
- */
618
- findByCursorOptions: FindByCursorOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>;
619
- /**
620
- * 查询选项
621
- */
622
- countOptions: CountOptions<typeof Todo,TodoRuleGroup>;
623
- }
624
-
625
- /**
626
- * 初始化数据
627
- */
628
- export interface TodoInitData {
629
- /**
630
- * title
631
- */
632
- title?: string;
633
- /**
634
- * completed
635
- */
636
- completed?: boolean;
637
- }
638
-
639
- /**
640
- * 静态类型
641
- */
642
- export interface MenuSimpleStaticTypes {
643
- /**
644
- * id 类型
645
- */
646
- idType: UUID;
647
- /**
648
- * 查询选项
649
- */
650
- getOptions: UUID;
651
- /**
652
- * 查询选项
653
- */
654
- findOneOrFailOptions: FindOneOrFailOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>;
655
- /**
656
- * 查询选项
657
- */
658
- findOptions: FindOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>;
659
- /**
660
- * 查询选项
661
- */
662
- findOneOptions: FindOneOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>;
663
- /**
664
- * 查询选项
665
- */
666
- findAllOptions: FindAllOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>;
667
- /**
668
- * 查询选项
669
- */
670
- findByCursorOptions: FindByCursorOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>;
671
- /**
672
- * 查询选项
673
- */
674
- countOptions: CountOptions<typeof MenuSimple,MenuSimpleRuleGroup>;
675
- /**
676
- * 查询的实体
677
- */
678
- entity: MenuSimple;
679
- /**
680
- * 查询选项
681
- */
682
- findDescendantsOptions: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>;
683
- /**
684
- * 查询选项
685
- */
686
- countDescendantsOptions: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>;
687
- /**
688
- * 查询选项
689
- */
690
- findAncestorsOptions: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>;
691
- /**
692
- * 查询选项
693
- */
694
- countAncestorsOptions: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>;
695
- }
696
-
697
- /**
698
- * 初始化数据
699
- */
700
- export interface MenuSimpleInitData {
701
- /**
702
- * title
703
- */
704
- title?: string;
705
- /**
706
- * sortOrder
707
- */
708
- sortOrder?: string | null;
709
- }
710
-
711
- /**
712
- * 静态类型
713
- */
714
- export interface MenuLargeStaticTypes {
715
- /**
716
- * id 类型
717
- */
718
- idType: UUID;
719
- /**
720
- * 查询选项
721
- */
722
- getOptions: UUID;
723
- /**
724
- * 查询选项
725
- */
726
- findOneOrFailOptions: FindOneOrFailOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>;
727
- /**
728
- * 查询选项
729
- */
730
- findOptions: FindOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>;
731
- /**
732
- * 查询选项
733
- */
734
- findOneOptions: FindOneOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>;
735
- /**
736
- * 查询选项
737
- */
738
- findAllOptions: FindAllOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>;
739
- /**
740
- * 查询选项
741
- */
742
- findByCursorOptions: FindByCursorOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>;
743
- /**
744
- * 查询选项
745
- */
746
- countOptions: CountOptions<typeof MenuLarge,MenuLargeRuleGroup>;
747
- /**
748
- * 查询的实体
749
- */
750
- entity: MenuLarge;
751
- /**
752
- * 查询选项
753
- */
754
- findDescendantsOptions: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>;
755
- /**
756
- * 查询选项
757
- */
758
- countDescendantsOptions: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>;
759
- /**
760
- * 查询选项
761
- */
762
- findAncestorsOptions: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>;
763
- /**
764
- * 查询选项
765
- */
766
- countAncestorsOptions: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>;
767
- }
768
-
769
- /**
770
- * 初始化数据
771
- */
772
- export interface MenuLargeInitData {
773
- /**
774
- * title
775
- */
776
- title?: string;
777
- /**
778
- * sortOrder
779
- */
780
- sortOrder?: string | null;
781
- }
782
-
783
- /**
784
- * 静态类型
785
- */
786
- export interface FileNodeStaticTypes {
787
- /**
788
- * id 类型
789
- */
790
- idType: UUID;
791
- /**
792
- * 查询选项
793
- */
794
- getOptions: UUID;
795
- /**
796
- * 查询选项
797
- */
798
- findOneOrFailOptions: FindOneOrFailOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>;
799
- /**
800
- * 查询选项
801
- */
802
- findOptions: FindOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>;
803
- /**
804
- * 查询选项
805
- */
806
- findOneOptions: FindOneOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>;
807
- /**
808
- * 查询选项
809
- */
810
- findAllOptions: FindAllOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>;
811
- /**
812
- * 查询选项
813
- */
814
- findByCursorOptions: FindByCursorOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>;
815
- /**
816
- * 查询选项
817
- */
818
- countOptions: CountOptions<typeof FileNode,FileNodeRuleGroup>;
819
- /**
820
- * 查询的实体
821
- */
822
- entity: FileNode;
823
- /**
824
- * 查询选项
825
- */
826
- findDescendantsOptions: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>;
827
- /**
828
- * 查询选项
829
- */
830
- countDescendantsOptions: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>;
831
- /**
832
- * 查询选项
833
- */
834
- findAncestorsOptions: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>;
835
- /**
836
- * 查询选项
837
- */
838
- countAncestorsOptions: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>;
839
- }
840
-
841
- /**
842
- * 初始化数据
843
- */
844
- export interface FileNodeInitData {
845
- /**
846
- * name
847
- */
848
- name?: string;
849
- /**
850
- * type
851
- */
852
- type?: string;
853
- /**
854
- * sortOrder
855
- */
856
- sortOrder?: string | null;
857
- /**
858
- * extension
859
- */
860
- extension?: string | null;
861
- /**
862
- * size
863
- */
864
- size?: number | null;
865
- }
866
-
867
- /**
868
- * 静态类型
869
- */
870
- export interface FileLargeStaticTypes {
871
- /**
872
- * id 类型
873
- */
874
- idType: UUID;
875
- /**
876
- * 查询选项
877
- */
878
- getOptions: UUID;
879
- /**
880
- * 查询选项
881
- */
882
- findOneOrFailOptions: FindOneOrFailOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>;
883
- /**
884
- * 查询选项
885
- */
886
- findOptions: FindOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>;
887
- /**
888
- * 查询选项
889
- */
890
- findOneOptions: FindOneOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>;
891
- /**
892
- * 查询选项
893
- */
894
- findAllOptions: FindAllOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>;
895
- /**
896
- * 查询选项
897
- */
898
- findByCursorOptions: FindByCursorOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>;
899
- /**
900
- * 查询选项
901
- */
902
- countOptions: CountOptions<typeof FileLarge,FileLargeRuleGroup>;
903
- /**
904
- * 查询的实体
905
- */
906
- entity: FileLarge;
907
- /**
908
- * 查询选项
909
- */
910
- findDescendantsOptions: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>;
911
- /**
912
- * 查询选项
913
- */
914
- countDescendantsOptions: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>;
915
- /**
916
- * 查询选项
917
- */
918
- findAncestorsOptions: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>;
919
- /**
920
- * 查询选项
921
- */
922
- countAncestorsOptions: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>;
923
- }
924
-
925
- /**
926
- * 初始化数据
927
- */
928
- export interface FileLargeInitData {
929
- /**
930
- * name
931
- */
932
- name?: string;
933
- /**
934
- * type
935
- */
936
- type?: string;
937
- /**
938
- * sortOrder
939
- */
940
- sortOrder?: string | null;
941
- /**
942
- * extension
943
- */
944
- extension?: string | null;
945
- /**
946
- * size
947
- */
948
- size?: number | null;
949
- }
950
-
951
- /**
952
- * TypeDemo
953
- */
954
- export declare class TypeDemo extends EntityBase implements IEntity {
955
- static [ENTITY_STATIC_TYPES]: TypeDemoStaticTypes;
956
- /**
957
- * boolean
958
- */
959
- boolean: boolean;
960
- /**
961
- * date
962
- */
963
- date: Date;
964
- /**
965
- * enum
966
- */
967
- enum?: TypeDemoEnum | 'active' | 'inactive' | 'pending' | null;
968
- /**
969
- * integer
970
- */
971
- integer: number;
972
- /**
973
- * json
974
- */
975
- json: Record<string, any>;
976
- /**
977
- * keyValue
978
- */
979
- keyValue: TypeDemoKeyValueKeyValue;
980
- /**
981
- * number
982
- */
983
- number: number;
984
- /**
985
- * numberArray
986
- */
987
- numberArray: number[];
988
- /**
989
- * string
990
- */
991
- string: string;
992
- /**
993
- * stringArray
994
- */
995
- stringArray: string[];
996
- /**
997
- * 初始化数据
998
- * @param initData 初始化数据
999
- */
1000
- constructor(initData?: TypeDemoInitData);
1001
- /**
1002
- * 统计实体数量
1003
- * @param options 查询选项
1004
- * @example
1005
- * TypeDemo.count({ where: { combinator: 'and', rules: [] } }).subscribe(total => console.log(total));
1006
- */
1007
- static count(options: CountOptions<typeof TypeDemo,TypeDemoRuleGroup>): Observable<number>;
1008
- /**
1009
- * 查询多个实体
1010
- * @param options 查询选项
1011
- * @example
1012
- * TypeDemo.find({ where: { combinator: 'and', rules: [] }] }).subscribe(list => console.log(list));
1013
- */
1014
- static find(options: FindOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>): Observable<TypeDemo[]>;
1015
- /**
1016
- * 查询所有实体
1017
- * @param options 查询选项
1018
- * @example
1019
- * TypeDemo.findAll({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1020
- */
1021
- static findAll(options: FindAllOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>): Observable<TypeDemo[]>;
1022
- /**
1023
- * 游标分页查询
1024
- * @param options 查询选项
1025
- * @example
1026
- * TypeDemo.findByCursor({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1027
- */
1028
- static findByCursor(options: FindByCursorOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>): Observable<TypeDemo[]>;
1029
- /**
1030
- * 查询单个实体,未找到时返回 undefined
1031
- * @param options 查询选项
1032
- * @example
1033
- * TypeDemo.findOne({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1034
- */
1035
- static findOne(options: FindOneOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>): Observable<TypeDemo | undefined>;
1036
- /**
1037
- * 查询单个实体,未找到时抛出错误
1038
- * @param options 查询选项
1039
- * @example
1040
- * TypeDemo.findOneOrFail({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1041
- */
1042
- static findOneOrFail(options: FindOneOrFailOptions<typeof TypeDemo,TypeDemoRuleGroup,TypeDemoOrderByField>): Observable<TypeDemo>;
1043
- /**
1044
- * 根据 ID 获取单个实体
1045
- * @param options 查询选项
1046
- * @example
1047
- * TypeDemo.get('123').subscribe(entity => console.log(entity));
1048
- */
1049
- static get(options: UUID): Observable<TypeDemo>;
1050
- /**
1051
- * 删除
1052
- */
1053
- remove(): Promise<TypeDemo>;
1054
- /**
1055
- * 重置数据
1056
- */
1057
- reset(): void;
1058
- /**
1059
- * 保存
1060
- */
1061
- save(): Promise<TypeDemo>;
1062
- }
1063
-
1064
- /**
1065
- * Todo
1066
- */
1067
- export declare class Todo extends EntityBase implements IEntity {
1068
- static [ENTITY_STATIC_TYPES]: TodoStaticTypes;
1069
- /**
1070
- * completed
1071
- */
1072
- completed: boolean;
1073
- /**
1074
- * title
1075
- */
1076
- title: string;
1077
- /**
1078
- * 初始化数据
1079
- * @param initData 初始化数据
1080
- */
1081
- constructor(initData?: TodoInitData);
1082
- /**
1083
- * 统计实体数量
1084
- * @param options 查询选项
1085
- * @example
1086
- * Todo.count({ where: { combinator: 'and', rules: [] } }).subscribe(total => console.log(total));
1087
- */
1088
- static count(options: CountOptions<typeof Todo,TodoRuleGroup>): Observable<number>;
1089
- /**
1090
- * 查询多个实体
1091
- * @param options 查询选项
1092
- * @example
1093
- * Todo.find({ where: { combinator: 'and', rules: [] }] }).subscribe(list => console.log(list));
1094
- */
1095
- static find(options: FindOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>): Observable<Todo[]>;
1096
- /**
1097
- * 查询所有实体
1098
- * @param options 查询选项
1099
- * @example
1100
- * Todo.findAll({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1101
- */
1102
- static findAll(options: FindAllOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>): Observable<Todo[]>;
1103
- /**
1104
- * 游标分页查询
1105
- * @param options 查询选项
1106
- * @example
1107
- * Todo.findByCursor({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1108
- */
1109
- static findByCursor(options: FindByCursorOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>): Observable<Todo[]>;
1110
- /**
1111
- * 查询单个实体,未找到时返回 undefined
1112
- * @param options 查询选项
1113
- * @example
1114
- * Todo.findOne({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1115
- */
1116
- static findOne(options: FindOneOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>): Observable<Todo | undefined>;
1117
- /**
1118
- * 查询单个实体,未找到时抛出错误
1119
- * @param options 查询选项
1120
- * @example
1121
- * Todo.findOneOrFail({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1122
- */
1123
- static findOneOrFail(options: FindOneOrFailOptions<typeof Todo,TodoRuleGroup,TodoOrderByField>): Observable<Todo>;
1124
- /**
1125
- * 根据 ID 获取单个实体
1126
- * @param options 查询选项
1127
- * @example
1128
- * Todo.get('123').subscribe(entity => console.log(entity));
1129
- */
1130
- static get(options: UUID): Observable<Todo>;
1131
- /**
1132
- * 删除
1133
- */
1134
- remove(): Promise<Todo>;
1135
- /**
1136
- * 重置数据
1137
- */
1138
- reset(): void;
1139
- /**
1140
- * 保存
1141
- */
1142
- save(): Promise<Todo>;
1143
- }
1144
-
1145
- /**
1146
- * MenuSimple
1147
- */
1148
- export declare class MenuSimple extends TreeAdjacencyListEntityBase implements ITreeEntity {
1149
- static [ENTITY_STATIC_TYPES]: MenuSimpleStaticTypes;
1150
- /**
1151
- * 子节点
1152
- */
1153
- readonly children$: RelationEntitiesObservable<MenuSimple>;
1154
- /**
1155
- * 父节点
1156
- */
1157
- readonly parent$: RelationEntityObservable<typeof MenuSimple>;
1158
- /**
1159
- * 父节点 id
1160
- */
1161
- parentId?: UUID | null;
1162
- /**
1163
- * sortOrder
1164
- */
1165
- sortOrder?: string | null;
1166
- /**
1167
- * title
1168
- */
1169
- title: string;
1170
- /**
1171
- * 初始化数据
1172
- * @param initData 初始化数据
1173
- */
1174
- constructor(initData?: MenuSimpleInitData);
1175
- /**
1176
- * 统计实体数量
1177
- * @param options 查询选项
1178
- * @example
1179
- * MenuSimple.count({ where: { combinator: 'and', rules: [] } }).subscribe(total => console.log(total));
1180
- */
1181
- static count(options: CountOptions<typeof MenuSimple,MenuSimpleRuleGroup>): Observable<number>;
1182
- /**
1183
- * 统计祖先实体数量(不包含自身)
1184
- * @param options 查询选项
1185
- * @example
1186
- * // 统计某节点的祖先层级深度
1187
- MenuSimple.countAncestors({ entityId: grand.id }).subscribe(depth => console.log(depth));
1188
- */
1189
- static countAncestors(options?: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>): Observable<number>;
1190
- /**
1191
- * 统计子孙实体数量(不包含自身)
1192
- * @param options 查询选项
1193
- * @example
1194
- * // 统计某节点下的后代数量
1195
- MenuSimple.countDescendants({ entityId: root.id }).subscribe(count => console.log(count));
1196
- */
1197
- static countDescendants(options?: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>): Observable<number>;
1198
- /**
1199
- * 查询多个实体
1200
- * @param options 查询选项
1201
- * @example
1202
- * MenuSimple.find({ where: { combinator: 'and', rules: [] }] }).subscribe(list => console.log(list));
1203
- */
1204
- static find(options: FindOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>): Observable<MenuSimple[]>;
1205
- /**
1206
- * 查询所有实体
1207
- * @param options 查询选项
1208
- * @example
1209
- * MenuSimple.findAll({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1210
- */
1211
- static findAll(options: FindAllOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>): Observable<MenuSimple[]>;
1212
- /**
1213
- * 查询祖先实体(包含自身)
1214
- * @param options 查询选项
1215
- * @example
1216
- * // 查询某节点的所有祖先(面包屑导航)
1217
- MenuSimple.findAncestors({ entityId: grand.id }).subscribe(ancestors => console.log(ancestors));
1218
-
1219
- // 仅查询直接父节点(level 1)
1220
- MenuSimple.findAncestors({ entityId: grand.id, level: 1 }).subscribe(parents => console.log(parents));
1221
- */
1222
- static findAncestors(options?: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>): Observable<MenuSimple[]>;
1223
- /**
1224
- * 游标分页查询
1225
- * @param options 查询选项
1226
- * @example
1227
- * MenuSimple.findByCursor({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1228
- */
1229
- static findByCursor(options: FindByCursorOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>): Observable<MenuSimple[]>;
1230
- /**
1231
- * 查询子孙实体(包含自身)
1232
- * @param options 查询选项
1233
- * @example
1234
- * // 查询某节点的所有后代
1235
- MenuSimple.findDescendants({ entityId: root.id }).subscribe(list => console.log(list));
1236
-
1237
- // 仅查询直接子节点(level 1)
1238
- MenuSimple.findDescendants({ entityId: root.id, level: 1 }).subscribe(children => console.log(children));
1239
- */
1240
- static findDescendants(options?: FindTreeOptions<typeof MenuSimple,MenuSimpleTreeRuleGroup>): Observable<MenuSimple[]>;
1241
- /**
1242
- * 查询单个实体,未找到时返回 undefined
1243
- * @param options 查询选项
1244
- * @example
1245
- * MenuSimple.findOne({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1246
- */
1247
- static findOne(options: FindOneOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>): Observable<MenuSimple | undefined>;
1248
- /**
1249
- * 查询单个实体,未找到时抛出错误
1250
- * @param options 查询选项
1251
- * @example
1252
- * MenuSimple.findOneOrFail({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1253
- */
1254
- static findOneOrFail(options: FindOneOrFailOptions<typeof MenuSimple,MenuSimpleRuleGroup,MenuSimpleOrderByField>): Observable<MenuSimple>;
1255
- /**
1256
- * 根据 ID 获取单个实体
1257
- * @param options 查询选项
1258
- * @example
1259
- * MenuSimple.get('123').subscribe(entity => console.log(entity));
1260
- */
1261
- static get(options: UUID): Observable<MenuSimple>;
1262
- /**
1263
- * 删除
1264
- */
1265
- remove(): Promise<MenuSimple>;
1266
- /**
1267
- * 重置数据
1268
- */
1269
- reset(): void;
1270
- /**
1271
- * 保存
1272
- */
1273
- save(): Promise<MenuSimple>;
1274
- }
1275
-
1276
- /**
1277
- * MenuLarge
1278
- */
1279
- export declare class MenuLarge extends TreeAdjacencyListEntityBase implements ITreeEntity {
1280
- static [ENTITY_STATIC_TYPES]: MenuLargeStaticTypes;
1281
- /**
1282
- * 子节点
1283
- */
1284
- readonly children$: RelationEntitiesObservable<MenuLarge>;
1285
- /**
1286
- * 是否有子节点
1287
- */
1288
- readonly hasChildren?: boolean | null;
1289
- /**
1290
- * 父节点
1291
- */
1292
- readonly parent$: RelationEntityObservable<typeof MenuLarge>;
1293
- /**
1294
- * 父节点 id
1295
- */
1296
- parentId?: UUID | null;
1297
- /**
1298
- * sortOrder
1299
- */
1300
- sortOrder?: string | null;
1301
- /**
1302
- * title
1303
- */
1304
- title: string;
1305
- /**
1306
- * 初始化数据
1307
- * @param initData 初始化数据
1308
- */
1309
- constructor(initData?: MenuLargeInitData);
1310
- /**
1311
- * 统计实体数量
1312
- * @param options 查询选项
1313
- * @example
1314
- * MenuLarge.count({ where: { combinator: 'and', rules: [] } }).subscribe(total => console.log(total));
1315
- */
1316
- static count(options: CountOptions<typeof MenuLarge,MenuLargeRuleGroup>): Observable<number>;
1317
- /**
1318
- * 统计祖先实体数量(不包含自身)
1319
- * @param options 查询选项
1320
- * @example
1321
- * // 统计某节点的祖先层级深度
1322
- MenuLarge.countAncestors({ entityId: grand.id }).subscribe(depth => console.log(depth));
1323
- */
1324
- static countAncestors(options?: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>): Observable<number>;
1325
- /**
1326
- * 统计子孙实体数量(不包含自身)
1327
- * @param options 查询选项
1328
- * @example
1329
- * // 统计某节点下的后代数量
1330
- MenuLarge.countDescendants({ entityId: root.id }).subscribe(count => console.log(count));
1331
- */
1332
- static countDescendants(options?: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>): Observable<number>;
1333
- /**
1334
- * 查询多个实体
1335
- * @param options 查询选项
1336
- * @example
1337
- * MenuLarge.find({ where: { combinator: 'and', rules: [] }] }).subscribe(list => console.log(list));
1338
- */
1339
- static find(options: FindOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>): Observable<MenuLarge[]>;
1340
- /**
1341
- * 查询所有实体
1342
- * @param options 查询选项
1343
- * @example
1344
- * MenuLarge.findAll({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1345
- */
1346
- static findAll(options: FindAllOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>): Observable<MenuLarge[]>;
1347
- /**
1348
- * 查询祖先实体(包含自身)
1349
- * @param options 查询选项
1350
- * @example
1351
- * // 查询某节点的所有祖先(面包屑导航)
1352
- MenuLarge.findAncestors({ entityId: grand.id }).subscribe(ancestors => console.log(ancestors));
1353
-
1354
- // 仅查询直接父节点(level 1)
1355
- MenuLarge.findAncestors({ entityId: grand.id, level: 1 }).subscribe(parents => console.log(parents));
1356
- */
1357
- static findAncestors(options?: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>): Observable<MenuLarge[]>;
1358
- /**
1359
- * 游标分页查询
1360
- * @param options 查询选项
1361
- * @example
1362
- * MenuLarge.findByCursor({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1363
- */
1364
- static findByCursor(options: FindByCursorOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>): Observable<MenuLarge[]>;
1365
- /**
1366
- * 查询子孙实体(包含自身)
1367
- * @param options 查询选项
1368
- * @example
1369
- * // 查询某节点的所有后代
1370
- MenuLarge.findDescendants({ entityId: root.id }).subscribe(list => console.log(list));
1371
-
1372
- // 仅查询直接子节点(level 1)
1373
- MenuLarge.findDescendants({ entityId: root.id, level: 1 }).subscribe(children => console.log(children));
1374
- */
1375
- static findDescendants(options?: FindTreeOptions<typeof MenuLarge,MenuLargeTreeRuleGroup>): Observable<MenuLarge[]>;
1376
- /**
1377
- * 查询单个实体,未找到时返回 undefined
1378
- * @param options 查询选项
1379
- * @example
1380
- * MenuLarge.findOne({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1381
- */
1382
- static findOne(options: FindOneOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>): Observable<MenuLarge | undefined>;
1383
- /**
1384
- * 查询单个实体,未找到时抛出错误
1385
- * @param options 查询选项
1386
- * @example
1387
- * MenuLarge.findOneOrFail({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1388
- */
1389
- static findOneOrFail(options: FindOneOrFailOptions<typeof MenuLarge,MenuLargeRuleGroup,MenuLargeOrderByField>): Observable<MenuLarge>;
1390
- /**
1391
- * 根据 ID 获取单个实体
1392
- * @param options 查询选项
1393
- * @example
1394
- * MenuLarge.get('123').subscribe(entity => console.log(entity));
1395
- */
1396
- static get(options: UUID): Observable<MenuLarge>;
1397
- /**
1398
- * 删除
1399
- */
1400
- remove(): Promise<MenuLarge>;
1401
- /**
1402
- * 重置数据
1403
- */
1404
- reset(): void;
1405
- /**
1406
- * 保存
1407
- */
1408
- save(): Promise<MenuLarge>;
1409
- }
1410
-
1411
- /**
1412
- * FileNode
1413
- */
1414
- export declare class FileNode extends TreeAdjacencyListEntityBase implements ITreeEntity {
1415
- static [ENTITY_STATIC_TYPES]: FileNodeStaticTypes;
1416
- /**
1417
- * 子节点
1418
- */
1419
- readonly children$: RelationEntitiesObservable<FileNode>;
1420
- /**
1421
- * 父节点
1422
- */
1423
- readonly parent$: RelationEntityObservable<typeof FileNode>;
1424
- /**
1425
- * extension
1426
- */
1427
- extension?: string | null;
1428
- /**
1429
- * name
1430
- */
1431
- name: string;
1432
- /**
1433
- * 父节点 id
1434
- */
1435
- parentId?: UUID | null;
1436
- /**
1437
- * size
1438
- */
1439
- size?: number | null;
1440
- /**
1441
- * sortOrder
1442
- */
1443
- sortOrder?: string | null;
1444
- /**
1445
- * type
1446
- */
1447
- type: string;
1448
- /**
1449
- * 初始化数据
1450
- * @param initData 初始化数据
1451
- */
1452
- constructor(initData?: FileNodeInitData);
1453
- /**
1454
- * 统计实体数量
1455
- * @param options 查询选项
1456
- * @example
1457
- * FileNode.count({ where: { combinator: 'and', rules: [] } }).subscribe(total => console.log(total));
1458
- */
1459
- static count(options: CountOptions<typeof FileNode,FileNodeRuleGroup>): Observable<number>;
1460
- /**
1461
- * 统计祖先实体数量(不包含自身)
1462
- * @param options 查询选项
1463
- * @example
1464
- * // 统计某节点的祖先层级深度
1465
- FileNode.countAncestors({ entityId: grand.id }).subscribe(depth => console.log(depth));
1466
- */
1467
- static countAncestors(options?: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>): Observable<number>;
1468
- /**
1469
- * 统计子孙实体数量(不包含自身)
1470
- * @param options 查询选项
1471
- * @example
1472
- * // 统计某节点下的后代数量
1473
- FileNode.countDescendants({ entityId: root.id }).subscribe(count => console.log(count));
1474
- */
1475
- static countDescendants(options?: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>): Observable<number>;
1476
- /**
1477
- * 查询多个实体
1478
- * @param options 查询选项
1479
- * @example
1480
- * FileNode.find({ where: { combinator: 'and', rules: [] }] }).subscribe(list => console.log(list));
1481
- */
1482
- static find(options: FindOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>): Observable<FileNode[]>;
1483
- /**
1484
- * 查询所有实体
1485
- * @param options 查询选项
1486
- * @example
1487
- * FileNode.findAll({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1488
- */
1489
- static findAll(options: FindAllOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>): Observable<FileNode[]>;
1490
- /**
1491
- * 查询祖先实体(包含自身)
1492
- * @param options 查询选项
1493
- * @example
1494
- * // 查询某节点的所有祖先(面包屑导航)
1495
- FileNode.findAncestors({ entityId: grand.id }).subscribe(ancestors => console.log(ancestors));
1496
-
1497
- // 仅查询直接父节点(level 1)
1498
- FileNode.findAncestors({ entityId: grand.id, level: 1 }).subscribe(parents => console.log(parents));
1499
- */
1500
- static findAncestors(options?: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>): Observable<FileNode[]>;
1501
- /**
1502
- * 游标分页查询
1503
- * @param options 查询选项
1504
- * @example
1505
- * FileNode.findByCursor({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1506
- */
1507
- static findByCursor(options: FindByCursorOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>): Observable<FileNode[]>;
1508
- /**
1509
- * 查询子孙实体(包含自身)
1510
- * @param options 查询选项
1511
- * @example
1512
- * // 查询某节点的所有后代
1513
- FileNode.findDescendants({ entityId: root.id }).subscribe(list => console.log(list));
1514
-
1515
- // 仅查询直接子节点(level 1)
1516
- FileNode.findDescendants({ entityId: root.id, level: 1 }).subscribe(children => console.log(children));
1517
- */
1518
- static findDescendants(options?: FindTreeOptions<typeof FileNode,FileNodeTreeRuleGroup>): Observable<FileNode[]>;
1519
- /**
1520
- * 查询单个实体,未找到时返回 undefined
1521
- * @param options 查询选项
1522
- * @example
1523
- * FileNode.findOne({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1524
- */
1525
- static findOne(options: FindOneOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>): Observable<FileNode | undefined>;
1526
- /**
1527
- * 查询单个实体,未找到时抛出错误
1528
- * @param options 查询选项
1529
- * @example
1530
- * FileNode.findOneOrFail({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1531
- */
1532
- static findOneOrFail(options: FindOneOrFailOptions<typeof FileNode,FileNodeRuleGroup,FileNodeOrderByField>): Observable<FileNode>;
1533
- /**
1534
- * 根据 ID 获取单个实体
1535
- * @param options 查询选项
1536
- * @example
1537
- * FileNode.get('123').subscribe(entity => console.log(entity));
1538
- */
1539
- static get(options: UUID): Observable<FileNode>;
1540
- /**
1541
- * 删除
1542
- */
1543
- remove(): Promise<FileNode>;
1544
- /**
1545
- * 重置数据
1546
- */
1547
- reset(): void;
1548
- /**
1549
- * 保存
1550
- */
1551
- save(): Promise<FileNode>;
1552
- }
1553
-
1554
- /**
1555
- * FileLarge
1556
- */
1557
- export declare class FileLarge extends TreeAdjacencyListEntityBase implements ITreeEntity {
1558
- static [ENTITY_STATIC_TYPES]: FileLargeStaticTypes;
1559
- /**
1560
- * 子节点
1561
- */
1562
- readonly children$: RelationEntitiesObservable<FileLarge>;
1563
- /**
1564
- * 是否有子节点
1565
- */
1566
- readonly hasChildren?: boolean | null;
1567
- /**
1568
- * 父节点
1569
- */
1570
- readonly parent$: RelationEntityObservable<typeof FileLarge>;
1571
- /**
1572
- * extension
1573
- */
1574
- extension?: string | null;
1575
- /**
1576
- * name
1577
- */
1578
- name: string;
1579
- /**
1580
- * 父节点 id
1581
- */
1582
- parentId?: UUID | null;
1583
- /**
1584
- * size
1585
- */
1586
- size?: number | null;
1587
- /**
1588
- * sortOrder
1589
- */
1590
- sortOrder?: string | null;
1591
- /**
1592
- * type
1593
- */
1594
- type: string;
1595
- /**
1596
- * 初始化数据
1597
- * @param initData 初始化数据
1598
- */
1599
- constructor(initData?: FileLargeInitData);
1600
- /**
1601
- * 统计实体数量
1602
- * @param options 查询选项
1603
- * @example
1604
- * FileLarge.count({ where: { combinator: 'and', rules: [] } }).subscribe(total => console.log(total));
1605
- */
1606
- static count(options: CountOptions<typeof FileLarge,FileLargeRuleGroup>): Observable<number>;
1607
- /**
1608
- * 统计祖先实体数量(不包含自身)
1609
- * @param options 查询选项
1610
- * @example
1611
- * // 统计某节点的祖先层级深度
1612
- FileLarge.countAncestors({ entityId: grand.id }).subscribe(depth => console.log(depth));
1613
- */
1614
- static countAncestors(options?: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>): Observable<number>;
1615
- /**
1616
- * 统计子孙实体数量(不包含自身)
1617
- * @param options 查询选项
1618
- * @example
1619
- * // 统计某节点下的后代数量
1620
- FileLarge.countDescendants({ entityId: root.id }).subscribe(count => console.log(count));
1621
- */
1622
- static countDescendants(options?: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>): Observable<number>;
1623
- /**
1624
- * 查询多个实体
1625
- * @param options 查询选项
1626
- * @example
1627
- * FileLarge.find({ where: { combinator: 'and', rules: [] }] }).subscribe(list => console.log(list));
1628
- */
1629
- static find(options: FindOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>): Observable<FileLarge[]>;
1630
- /**
1631
- * 查询所有实体
1632
- * @param options 查询选项
1633
- * @example
1634
- * FileLarge.findAll({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1635
- */
1636
- static findAll(options: FindAllOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>): Observable<FileLarge[]>;
1637
- /**
1638
- * 查询祖先实体(包含自身)
1639
- * @param options 查询选项
1640
- * @example
1641
- * // 查询某节点的所有祖先(面包屑导航)
1642
- FileLarge.findAncestors({ entityId: grand.id }).subscribe(ancestors => console.log(ancestors));
1643
-
1644
- // 仅查询直接父节点(level 1)
1645
- FileLarge.findAncestors({ entityId: grand.id, level: 1 }).subscribe(parents => console.log(parents));
1646
- */
1647
- static findAncestors(options?: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>): Observable<FileLarge[]>;
1648
- /**
1649
- * 游标分页查询
1650
- * @param options 查询选项
1651
- * @example
1652
- * FileLarge.findByCursor({ where: { combinator: 'and', rules: [] } }).subscribe(list => console.log(list));
1653
- */
1654
- static findByCursor(options: FindByCursorOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>): Observable<FileLarge[]>;
1655
- /**
1656
- * 查询子孙实体(包含自身)
1657
- * @param options 查询选项
1658
- * @example
1659
- * // 查询某节点的所有后代
1660
- FileLarge.findDescendants({ entityId: root.id }).subscribe(list => console.log(list));
1661
-
1662
- // 仅查询直接子节点(level 1)
1663
- FileLarge.findDescendants({ entityId: root.id, level: 1 }).subscribe(children => console.log(children));
1664
- */
1665
- static findDescendants(options?: FindTreeOptions<typeof FileLarge,FileLargeTreeRuleGroup>): Observable<FileLarge[]>;
1666
- /**
1667
- * 查询单个实体,未找到时返回 undefined
1668
- * @param options 查询选项
1669
- * @example
1670
- * FileLarge.findOne({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1671
- */
1672
- static findOne(options: FindOneOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>): Observable<FileLarge | undefined>;
1673
- /**
1674
- * 查询单个实体,未找到时抛出错误
1675
- * @param options 查询选项
1676
- * @example
1677
- * FileLarge.findOneOrFail({ where: { combinator: 'and', rules: [] } }).subscribe(entity => console.log(entity));
1678
- */
1679
- static findOneOrFail(options: FindOneOrFailOptions<typeof FileLarge,FileLargeRuleGroup,FileLargeOrderByField>): Observable<FileLarge>;
1680
- /**
1681
- * 根据 ID 获取单个实体
1682
- * @param options 查询选项
1683
- * @example
1684
- * FileLarge.get('123').subscribe(entity => console.log(entity));
1685
- */
1686
- static get(options: UUID): Observable<FileLarge>;
1687
- /**
1688
- * 删除
1689
- */
1690
- remove(): Promise<FileLarge>;
1691
- /**
1692
- * 重置数据
1693
- */
1694
- reset(): void;
1695
- /**
1696
- * 保存
1697
- */
1698
- save(): Promise<FileLarge>;
1699
- }
1700
-
1701
51
  export declare const ENTITIES: EntityType[];
1702
52