@statezero/core 0.2.51 → 0.2.52
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/adaptors/vue/components/StateZeroDebugPanel.js +495 -476
- package/dist/adaptors/vue/reactivity.d.ts +1 -0
- package/dist/adaptors/vue/reactivity.js +17 -5
- package/dist/cli/commands/syncActions.js +33 -1
- package/dist/cli/commands/syncModels.js +44 -3
- package/dist/filtering/localFiltering.js +3 -2
- package/dist/flavours/django/errors.d.ts +12 -0
- package/dist/flavours/django/errors.js +20 -0
- package/dist/flavours/django/f.js +16 -15
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -2
- package/dist/models/backend1/django_app/author.d.ts +284 -0
- package/dist/models/backend1/django_app/author.js +69 -0
- package/dist/models/backend1/django_app/author.schema.json +281 -0
- package/dist/models/backend1/django_app/book.d.ts +262 -0
- package/dist/models/backend1/django_app/book.js +71 -0
- package/dist/models/backend1/django_app/book.schema.json +254 -0
- package/dist/models/backend1/django_app/composeditem.d.ts +140 -0
- package/dist/models/backend1/django_app/composeditem.js +69 -0
- package/dist/models/backend1/django_app/composeditem.schema.json +122 -0
- package/dist/models/backend1/django_app/comprehensivemodel.schema.json +3 -3
- package/dist/models/backend1/django_app/dailyrate.schema.json +7 -7
- package/dist/models/backend1/django_app/deepmodellevel1.schema.json +1 -1
- package/dist/models/backend1/django_app/dummymodel.schema.json +3 -3
- package/dist/models/backend1/django_app/errortestcompoundunique.d.ts +124 -0
- package/dist/models/backend1/django_app/errortestcompoundunique.js +69 -0
- package/dist/models/backend1/django_app/errortestcompoundunique.schema.json +106 -0
- package/dist/models/backend1/django_app/errortestonetoonemodel.d.ts +118 -0
- package/dist/models/backend1/django_app/errortestonetoonemodel.js +71 -0
- package/dist/models/backend1/django_app/errortestonetoonemodel.schema.json +90 -0
- package/dist/models/backend1/django_app/errortestparent.d.ts +92 -0
- package/dist/models/backend1/django_app/errortestparent.js +69 -0
- package/dist/models/backend1/django_app/errortestparent.schema.json +70 -0
- package/dist/models/backend1/django_app/errortestprotectedchild.d.ts +118 -0
- package/dist/models/backend1/django_app/errortestprotectedchild.js +71 -0
- package/dist/models/backend1/django_app/errortestprotectedchild.schema.json +94 -0
- package/dist/models/backend1/django_app/errortestuniquemodel.d.ts +108 -0
- package/dist/models/backend1/django_app/errortestuniquemodel.js +69 -0
- package/dist/models/backend1/django_app/errortestuniquemodel.schema.json +88 -0
- package/dist/models/backend1/django_app/excludeditem.d.ts +124 -0
- package/dist/models/backend1/django_app/excludeditem.js +69 -0
- package/dist/models/backend1/django_app/excludeditem.schema.json +105 -0
- package/dist/models/backend1/django_app/hfchild.d.ts +118 -0
- package/dist/models/backend1/django_app/hfchild.js +71 -0
- package/dist/models/backend1/django_app/hfchild.schema.json +94 -0
- package/dist/models/backend1/django_app/hfparent.d.ts +124 -0
- package/dist/models/backend1/django_app/hfparent.js +69 -0
- package/dist/models/backend1/django_app/hfparent.schema.json +105 -0
- package/dist/models/backend1/django_app/index.js +19 -0
- package/dist/models/backend1/django_app/m2mdepthtestlevel1.schema.json +3 -3
- package/dist/models/backend1/django_app/m2mdepthtestlevel2.schema.json +3 -3
- package/dist/models/backend1/django_app/m2mdepthtestlevel3.schema.json +5 -5
- package/dist/models/backend1/django_app/modelwithrestrictedfields.schema.json +2 -2
- package/dist/models/backend1/django_app/nodeleteitem.d.ts +124 -0
- package/dist/models/backend1/django_app/nodeleteitem.js +69 -0
- package/dist/models/backend1/django_app/nodeleteitem.schema.json +105 -0
- package/dist/models/backend1/django_app/objectlevelitem.d.ts +124 -0
- package/dist/models/backend1/django_app/objectlevelitem.js +69 -0
- package/dist/models/backend1/django_app/objectlevelitem.schema.json +105 -0
- package/dist/models/backend1/django_app/order.schema.json +7 -7
- package/dist/models/backend1/django_app/orderitem.schema.json +5 -5
- package/dist/models/backend1/django_app/product.schema.json +11 -11
- package/dist/models/backend1/django_app/productcategory.schema.json +2 -2
- package/dist/models/backend1/django_app/rateplan.schema.json +2 -2
- package/dist/models/backend1/django_app/readonlyitem.d.ts +124 -0
- package/dist/models/backend1/django_app/readonlyitem.js +69 -0
- package/dist/models/backend1/django_app/readonlyitem.schema.json +105 -0
- package/dist/models/backend1/django_app/restrictedcreateitem.d.ts +124 -0
- package/dist/models/backend1/django_app/restrictedcreateitem.js +69 -0
- package/dist/models/backend1/django_app/restrictedcreateitem.schema.json +105 -0
- package/dist/models/backend1/django_app/restrictededititem.d.ts +124 -0
- package/dist/models/backend1/django_app/restrictededititem.js +69 -0
- package/dist/models/backend1/django_app/restrictededititem.schema.json +105 -0
- package/dist/models/backend1/django_app/restrictedfieldrelatedmodel.schema.json +1 -1
- package/dist/models/backend1/django_app/rowfiltereditem.d.ts +124 -0
- package/dist/models/backend1/django_app/rowfiltereditem.js +69 -0
- package/dist/models/backend1/django_app/rowfiltereditem.schema.json +105 -0
- package/dist/models/backend1/django_app/tag.d.ts +554 -0
- package/dist/models/backend1/django_app/tag.js +71 -0
- package/dist/models/backend1/django_app/tag.schema.json +541 -0
- package/dist/models/backend1/django_app/updateonlyitem.d.ts +108 -0
- package/dist/models/backend1/django_app/updateonlyitem.js +69 -0
- package/dist/models/backend1/django_app/updateonlyitem.schema.json +88 -0
- package/dist/models/default/django_app/author.d.ts +284 -0
- package/dist/models/default/django_app/author.js +69 -0
- package/dist/models/default/django_app/author.schema.json +281 -0
- package/dist/models/default/django_app/book.d.ts +262 -0
- package/dist/models/default/django_app/book.js +71 -0
- package/dist/models/default/django_app/book.schema.json +254 -0
- package/dist/models/default/django_app/composeditem.d.ts +140 -0
- package/dist/models/default/django_app/composeditem.js +69 -0
- package/dist/models/default/django_app/composeditem.schema.json +122 -0
- package/dist/models/default/django_app/comprehensivemodel.schema.json +3 -3
- package/dist/models/default/django_app/dailyrate.schema.json +7 -7
- package/dist/models/default/django_app/deepmodellevel1.d.ts +1 -13
- package/dist/models/default/django_app/deepmodellevel1.schema.json +2 -14
- package/dist/models/default/django_app/deepmodellevel2.d.ts +1 -13
- package/dist/models/default/django_app/deepmodellevel2.schema.json +1 -13
- package/dist/models/default/django_app/deepmodellevel3.d.ts +1 -13
- package/dist/models/default/django_app/deepmodellevel3.schema.json +1 -13
- package/dist/models/default/django_app/dummymodel.d.ts +1 -13
- package/dist/models/default/django_app/dummymodel.schema.json +4 -16
- package/dist/models/default/django_app/dummyrelatedmodel.d.ts +1 -13
- package/dist/models/default/django_app/dummyrelatedmodel.schema.json +1 -13
- package/dist/models/default/django_app/errortestcompoundunique.d.ts +124 -0
- package/dist/models/default/django_app/errortestcompoundunique.js +69 -0
- package/dist/models/default/django_app/errortestcompoundunique.schema.json +106 -0
- package/dist/models/default/django_app/errortestonetoonemodel.d.ts +118 -0
- package/dist/models/default/django_app/errortestonetoonemodel.js +71 -0
- package/dist/models/default/django_app/errortestonetoonemodel.schema.json +90 -0
- package/dist/models/default/django_app/errortestparent.d.ts +92 -0
- package/dist/models/default/django_app/errortestparent.js +69 -0
- package/dist/models/default/django_app/errortestparent.schema.json +70 -0
- package/dist/models/default/django_app/errortestprotectedchild.d.ts +118 -0
- package/dist/models/default/django_app/errortestprotectedchild.js +71 -0
- package/dist/models/default/django_app/errortestprotectedchild.schema.json +94 -0
- package/dist/models/default/django_app/errortestuniquemodel.d.ts +108 -0
- package/dist/models/default/django_app/errortestuniquemodel.js +69 -0
- package/dist/models/default/django_app/errortestuniquemodel.schema.json +88 -0
- package/dist/models/default/django_app/excludeditem.d.ts +124 -0
- package/dist/models/default/django_app/excludeditem.js +69 -0
- package/dist/models/default/django_app/excludeditem.schema.json +105 -0
- package/dist/models/default/django_app/filetest.d.ts +1 -13
- package/dist/models/default/django_app/filetest.schema.json +1 -13
- package/dist/models/default/django_app/hfchild.d.ts +118 -0
- package/dist/models/default/django_app/hfchild.js +71 -0
- package/dist/models/default/django_app/hfchild.schema.json +94 -0
- package/dist/models/default/django_app/hfparent.d.ts +124 -0
- package/dist/models/default/django_app/hfparent.js +69 -0
- package/dist/models/default/django_app/hfparent.schema.json +105 -0
- package/dist/models/default/django_app/index.js +19 -0
- package/dist/models/default/django_app/m2mdepthtestlevel1.schema.json +3 -3
- package/dist/models/default/django_app/m2mdepthtestlevel2.schema.json +3 -3
- package/dist/models/default/django_app/m2mdepthtestlevel3.schema.json +5 -5
- package/dist/models/default/django_app/modelwithrestrictedfields.schema.json +2 -2
- package/dist/models/default/django_app/nodeleteitem.d.ts +124 -0
- package/dist/models/default/django_app/nodeleteitem.js +69 -0
- package/dist/models/default/django_app/nodeleteitem.schema.json +105 -0
- package/dist/models/default/django_app/objectlevelitem.d.ts +124 -0
- package/dist/models/default/django_app/objectlevelitem.js +69 -0
- package/dist/models/default/django_app/objectlevelitem.schema.json +105 -0
- package/dist/models/default/django_app/order.schema.json +7 -7
- package/dist/models/default/django_app/orderitem.schema.json +5 -5
- package/dist/models/default/django_app/product.schema.json +11 -11
- package/dist/models/default/django_app/productcategory.schema.json +2 -2
- package/dist/models/default/django_app/rateplan.schema.json +2 -2
- package/dist/models/default/django_app/readonlyitem.d.ts +124 -0
- package/dist/models/default/django_app/readonlyitem.js +69 -0
- package/dist/models/default/django_app/readonlyitem.schema.json +105 -0
- package/dist/models/default/django_app/restrictedcreateitem.d.ts +124 -0
- package/dist/models/default/django_app/restrictedcreateitem.js +69 -0
- package/dist/models/default/django_app/restrictedcreateitem.schema.json +105 -0
- package/dist/models/default/django_app/restrictededititem.d.ts +124 -0
- package/dist/models/default/django_app/restrictededititem.js +69 -0
- package/dist/models/default/django_app/restrictededititem.schema.json +105 -0
- package/dist/models/default/django_app/restrictedfieldrelatedmodel.schema.json +1 -1
- package/dist/models/default/django_app/rowfiltereditem.d.ts +124 -0
- package/dist/models/default/django_app/rowfiltereditem.js +69 -0
- package/dist/models/default/django_app/rowfiltereditem.schema.json +105 -0
- package/dist/models/default/django_app/tag.d.ts +554 -0
- package/dist/models/default/django_app/tag.js +71 -0
- package/dist/models/default/django_app/tag.schema.json +541 -0
- package/dist/models/default/django_app/updateonlyitem.d.ts +108 -0
- package/dist/models/default/django_app/updateonlyitem.js +69 -0
- package/dist/models/default/django_app/updateonlyitem.schema.json +88 -0
- package/dist/schemaIntegrity.d.ts +14 -0
- package/dist/schemaIntegrity.js +29 -0
- package/dist/setup.js +6 -0
- package/dist/syncEngine/stores/operationEventHandlers.js +10 -8
- package/dist/syncEngine/stores/querysetStore.js +9 -0
- package/package.json +1 -1
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Model-specific QuerySet implementation
|
|
3
|
+
*/
|
|
4
|
+
export class ComposedItemQuerySet {
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Model-specific Manager implementation
|
|
8
|
+
*/
|
|
9
|
+
export class ComposedItemManager {
|
|
10
|
+
constructor(ModelClass: any);
|
|
11
|
+
newQuerySet(): ComposedItemQuerySet;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Implementation of the ComposedItem model
|
|
15
|
+
*/
|
|
16
|
+
export class ComposedItem {
|
|
17
|
+
static configKey: string;
|
|
18
|
+
static modelName: string;
|
|
19
|
+
static primaryKeyField: string;
|
|
20
|
+
static objects: ComposedItemManager;
|
|
21
|
+
static fields: string[];
|
|
22
|
+
static schema: {
|
|
23
|
+
model_name: string;
|
|
24
|
+
title: string;
|
|
25
|
+
class_name: string;
|
|
26
|
+
plural_title: string;
|
|
27
|
+
primary_key_field: string;
|
|
28
|
+
filterable_fields: string[];
|
|
29
|
+
searchable_fields: string[];
|
|
30
|
+
ordering_fields: string[];
|
|
31
|
+
properties: {
|
|
32
|
+
id: {
|
|
33
|
+
type: string;
|
|
34
|
+
title: string;
|
|
35
|
+
required: boolean;
|
|
36
|
+
description: null;
|
|
37
|
+
nullable: boolean;
|
|
38
|
+
format: string;
|
|
39
|
+
max_length: null;
|
|
40
|
+
choices: null;
|
|
41
|
+
default: null;
|
|
42
|
+
validators: never[];
|
|
43
|
+
max_digits: null;
|
|
44
|
+
decimal_places: null;
|
|
45
|
+
read_only: boolean;
|
|
46
|
+
ref: null;
|
|
47
|
+
};
|
|
48
|
+
name: {
|
|
49
|
+
type: string;
|
|
50
|
+
title: string;
|
|
51
|
+
required: boolean;
|
|
52
|
+
description: null;
|
|
53
|
+
nullable: boolean;
|
|
54
|
+
format: null;
|
|
55
|
+
max_length: number;
|
|
56
|
+
choices: null;
|
|
57
|
+
default: null;
|
|
58
|
+
validators: never[];
|
|
59
|
+
max_digits: null;
|
|
60
|
+
decimal_places: null;
|
|
61
|
+
read_only: boolean;
|
|
62
|
+
ref: null;
|
|
63
|
+
};
|
|
64
|
+
value: {
|
|
65
|
+
type: string;
|
|
66
|
+
title: string;
|
|
67
|
+
required: boolean;
|
|
68
|
+
description: null;
|
|
69
|
+
nullable: boolean;
|
|
70
|
+
format: null;
|
|
71
|
+
max_length: null;
|
|
72
|
+
choices: null;
|
|
73
|
+
default: number;
|
|
74
|
+
validators: never[];
|
|
75
|
+
max_digits: null;
|
|
76
|
+
decimal_places: null;
|
|
77
|
+
read_only: boolean;
|
|
78
|
+
ref: null;
|
|
79
|
+
};
|
|
80
|
+
secret: {
|
|
81
|
+
type: string;
|
|
82
|
+
title: string;
|
|
83
|
+
required: boolean;
|
|
84
|
+
description: null;
|
|
85
|
+
nullable: boolean;
|
|
86
|
+
format: null;
|
|
87
|
+
max_length: number;
|
|
88
|
+
choices: null;
|
|
89
|
+
default: string;
|
|
90
|
+
validators: never[];
|
|
91
|
+
max_digits: null;
|
|
92
|
+
decimal_places: null;
|
|
93
|
+
read_only: boolean;
|
|
94
|
+
ref: null;
|
|
95
|
+
};
|
|
96
|
+
owner: {
|
|
97
|
+
type: string;
|
|
98
|
+
title: string;
|
|
99
|
+
required: boolean;
|
|
100
|
+
description: null;
|
|
101
|
+
nullable: boolean;
|
|
102
|
+
format: null;
|
|
103
|
+
max_length: number;
|
|
104
|
+
choices: null;
|
|
105
|
+
default: string;
|
|
106
|
+
validators: never[];
|
|
107
|
+
max_digits: null;
|
|
108
|
+
decimal_places: null;
|
|
109
|
+
read_only: boolean;
|
|
110
|
+
ref: null;
|
|
111
|
+
};
|
|
112
|
+
};
|
|
113
|
+
relationships: {};
|
|
114
|
+
default_ordering: null;
|
|
115
|
+
definitions: {
|
|
116
|
+
MoneyField: {
|
|
117
|
+
type: string;
|
|
118
|
+
properties: {
|
|
119
|
+
amount: {
|
|
120
|
+
type: string;
|
|
121
|
+
};
|
|
122
|
+
currency: {
|
|
123
|
+
type: string;
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
};
|
|
127
|
+
};
|
|
128
|
+
datetime_format: string;
|
|
129
|
+
date_format: string;
|
|
130
|
+
time_format: string;
|
|
131
|
+
display: null;
|
|
132
|
+
};
|
|
133
|
+
static relationshipFields: Map<any, any>;
|
|
134
|
+
constructor(data: any);
|
|
135
|
+
/**
|
|
136
|
+
* Define property getters and setters for all model fields
|
|
137
|
+
* @private
|
|
138
|
+
*/
|
|
139
|
+
private _defineProperties;
|
|
140
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated. Do not make direct changes to the file.
|
|
3
|
+
*/
|
|
4
|
+
import { Model, Manager, QuerySet, getModelClass } from '../../../../src';
|
|
5
|
+
import { wrapReactiveModel } from '../../../../src';
|
|
6
|
+
import schemaData from './composeditem.schema.json';
|
|
7
|
+
/**
|
|
8
|
+
* Model-specific QuerySet implementation
|
|
9
|
+
*/
|
|
10
|
+
export class ComposedItemQuerySet extends QuerySet {
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Model-specific Manager implementation
|
|
14
|
+
*/
|
|
15
|
+
export class ComposedItemManager extends Manager {
|
|
16
|
+
constructor(ModelClass) {
|
|
17
|
+
super(ModelClass, ComposedItemQuerySet);
|
|
18
|
+
}
|
|
19
|
+
newQuerySet() {
|
|
20
|
+
return new ComposedItemQuerySet(this.ModelClass);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Implementation of the ComposedItem model
|
|
25
|
+
*/
|
|
26
|
+
export class ComposedItem extends Model {
|
|
27
|
+
constructor(data) {
|
|
28
|
+
ComposedItem.validateFields(data);
|
|
29
|
+
super(data);
|
|
30
|
+
// Define getters and setters for all fields
|
|
31
|
+
this._defineProperties();
|
|
32
|
+
return wrapReactiveModel(this);
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Define property getters and setters for all model fields
|
|
36
|
+
* @private
|
|
37
|
+
*/
|
|
38
|
+
_defineProperties() {
|
|
39
|
+
// For each field, define a property that gets/sets from internal storage
|
|
40
|
+
ComposedItem.fields.forEach(field => {
|
|
41
|
+
Object.defineProperty(this, field, {
|
|
42
|
+
get: function () {
|
|
43
|
+
return this.getField(field);
|
|
44
|
+
},
|
|
45
|
+
set: function (value) {
|
|
46
|
+
this.setField(field, value);
|
|
47
|
+
},
|
|
48
|
+
enumerable: true, // Make sure fields are enumerable for serialization
|
|
49
|
+
configurable: true
|
|
50
|
+
});
|
|
51
|
+
});
|
|
52
|
+
// Add a special read-only getter for the repr field
|
|
53
|
+
Object.defineProperty(this, 'repr', {
|
|
54
|
+
get: function () {
|
|
55
|
+
return this.getField('repr');
|
|
56
|
+
},
|
|
57
|
+
enumerable: true, // Make sure repr is enumerable
|
|
58
|
+
configurable: true
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
// Bind this model to its backend
|
|
63
|
+
ComposedItem.configKey = 'backend1';
|
|
64
|
+
ComposedItem.modelName = 'django_app.composeditem';
|
|
65
|
+
ComposedItem.primaryKeyField = 'id';
|
|
66
|
+
ComposedItem.objects = new ComposedItemManager(ComposedItem);
|
|
67
|
+
ComposedItem.fields = ['id', 'name', 'value', 'secret', 'owner'];
|
|
68
|
+
ComposedItem.schema = schemaData;
|
|
69
|
+
ComposedItem.relationshipFields = new Map([]);
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
{
|
|
2
|
+
"model_name": "django_app.composeditem",
|
|
3
|
+
"title": "Composed Item",
|
|
4
|
+
"class_name": "ComposedItem",
|
|
5
|
+
"plural_title": "Composed Items",
|
|
6
|
+
"primary_key_field": "id",
|
|
7
|
+
"filterable_fields": [
|
|
8
|
+
"secret",
|
|
9
|
+
"name",
|
|
10
|
+
"value",
|
|
11
|
+
"owner",
|
|
12
|
+
"id"
|
|
13
|
+
],
|
|
14
|
+
"searchable_fields": [
|
|
15
|
+
"name"
|
|
16
|
+
],
|
|
17
|
+
"ordering_fields": [
|
|
18
|
+
"value",
|
|
19
|
+
"name"
|
|
20
|
+
],
|
|
21
|
+
"properties": {
|
|
22
|
+
"id": {
|
|
23
|
+
"type": "integer",
|
|
24
|
+
"title": "Id",
|
|
25
|
+
"required": true,
|
|
26
|
+
"description": null,
|
|
27
|
+
"nullable": false,
|
|
28
|
+
"format": "id",
|
|
29
|
+
"max_length": null,
|
|
30
|
+
"choices": null,
|
|
31
|
+
"default": null,
|
|
32
|
+
"validators": [],
|
|
33
|
+
"max_digits": null,
|
|
34
|
+
"decimal_places": null,
|
|
35
|
+
"read_only": true,
|
|
36
|
+
"ref": null
|
|
37
|
+
},
|
|
38
|
+
"name": {
|
|
39
|
+
"type": "string",
|
|
40
|
+
"title": "Name",
|
|
41
|
+
"required": true,
|
|
42
|
+
"description": null,
|
|
43
|
+
"nullable": false,
|
|
44
|
+
"format": null,
|
|
45
|
+
"max_length": 100,
|
|
46
|
+
"choices": null,
|
|
47
|
+
"default": null,
|
|
48
|
+
"validators": [],
|
|
49
|
+
"max_digits": null,
|
|
50
|
+
"decimal_places": null,
|
|
51
|
+
"read_only": false,
|
|
52
|
+
"ref": null
|
|
53
|
+
},
|
|
54
|
+
"value": {
|
|
55
|
+
"type": "integer",
|
|
56
|
+
"title": "Value",
|
|
57
|
+
"required": false,
|
|
58
|
+
"description": null,
|
|
59
|
+
"nullable": false,
|
|
60
|
+
"format": null,
|
|
61
|
+
"max_length": null,
|
|
62
|
+
"choices": null,
|
|
63
|
+
"default": 0,
|
|
64
|
+
"validators": [],
|
|
65
|
+
"max_digits": null,
|
|
66
|
+
"decimal_places": null,
|
|
67
|
+
"read_only": false,
|
|
68
|
+
"ref": null
|
|
69
|
+
},
|
|
70
|
+
"secret": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"title": "Secret",
|
|
73
|
+
"required": false,
|
|
74
|
+
"description": null,
|
|
75
|
+
"nullable": false,
|
|
76
|
+
"format": null,
|
|
77
|
+
"max_length": 100,
|
|
78
|
+
"choices": null,
|
|
79
|
+
"default": "",
|
|
80
|
+
"validators": [],
|
|
81
|
+
"max_digits": null,
|
|
82
|
+
"decimal_places": null,
|
|
83
|
+
"read_only": false,
|
|
84
|
+
"ref": null
|
|
85
|
+
},
|
|
86
|
+
"owner": {
|
|
87
|
+
"type": "string",
|
|
88
|
+
"title": "Owner",
|
|
89
|
+
"required": false,
|
|
90
|
+
"description": null,
|
|
91
|
+
"nullable": false,
|
|
92
|
+
"format": null,
|
|
93
|
+
"max_length": 100,
|
|
94
|
+
"choices": null,
|
|
95
|
+
"default": "",
|
|
96
|
+
"validators": [],
|
|
97
|
+
"max_digits": null,
|
|
98
|
+
"decimal_places": null,
|
|
99
|
+
"read_only": false,
|
|
100
|
+
"ref": null
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
"relationships": {},
|
|
104
|
+
"default_ordering": null,
|
|
105
|
+
"definitions": {
|
|
106
|
+
"MoneyField": {
|
|
107
|
+
"type": "object",
|
|
108
|
+
"properties": {
|
|
109
|
+
"amount": {
|
|
110
|
+
"type": "number"
|
|
111
|
+
},
|
|
112
|
+
"currency": {
|
|
113
|
+
"type": "string"
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
"datetime_format": "iso-8601",
|
|
119
|
+
"date_format": "iso-8601",
|
|
120
|
+
"time_format": "iso-8601",
|
|
121
|
+
"display": null
|
|
122
|
+
}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
"plural_title": "Comprehensive Models",
|
|
6
6
|
"primary_key_field": "id",
|
|
7
7
|
"filterable_fields": [
|
|
8
|
-
"
|
|
9
|
-
"
|
|
8
|
+
"int_field",
|
|
9
|
+
"char_field"
|
|
10
10
|
],
|
|
11
11
|
"searchable_fields": [
|
|
12
12
|
"char_field",
|
|
@@ -105,7 +105,7 @@
|
|
|
105
105
|
"format": "date-time",
|
|
106
106
|
"max_length": null,
|
|
107
107
|
"choices": null,
|
|
108
|
-
"default": "2026-02-
|
|
108
|
+
"default": "2026-02-23T18:47:00.073642+00:00",
|
|
109
109
|
"validators": [],
|
|
110
110
|
"max_digits": null,
|
|
111
111
|
"decimal_places": null,
|
|
@@ -5,16 +5,16 @@
|
|
|
5
5
|
"plural_title": "Daily Rates",
|
|
6
6
|
"primary_key_field": "id",
|
|
7
7
|
"filterable_fields": [
|
|
8
|
+
"min_stay_arrival",
|
|
8
9
|
"price",
|
|
9
|
-
"id",
|
|
10
10
|
"rate_plan",
|
|
11
|
-
"date",
|
|
12
|
-
"max_stay",
|
|
13
|
-
"closed_to_departure",
|
|
14
|
-
"min_stay_arrival",
|
|
15
|
-
"closed_to_arrival",
|
|
16
11
|
"min_stay_through",
|
|
17
|
-
"stop_sell"
|
|
12
|
+
"stop_sell",
|
|
13
|
+
"closed_to_arrival",
|
|
14
|
+
"max_stay",
|
|
15
|
+
"date",
|
|
16
|
+
"id",
|
|
17
|
+
"closed_to_departure"
|
|
18
18
|
],
|
|
19
19
|
"searchable_fields": [],
|
|
20
20
|
"ordering_fields": [
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
"plural_title": "Dummy Models",
|
|
6
6
|
"primary_key_field": "id",
|
|
7
7
|
"filterable_fields": [
|
|
8
|
-
"
|
|
9
|
-
"
|
|
8
|
+
"value",
|
|
9
|
+
"name"
|
|
10
10
|
],
|
|
11
11
|
"searchable_fields": [
|
|
12
12
|
"name"
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"title": "Value",
|
|
53
53
|
"required": false,
|
|
54
54
|
"description": null,
|
|
55
|
-
"nullable":
|
|
55
|
+
"nullable": true,
|
|
56
56
|
"format": null,
|
|
57
57
|
"max_length": null,
|
|
58
58
|
"choices": null,
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Model-specific QuerySet implementation
|
|
3
|
+
*/
|
|
4
|
+
export class ErrorTestCompoundUniqueQuerySet {
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Model-specific Manager implementation
|
|
8
|
+
*/
|
|
9
|
+
export class ErrorTestCompoundUniqueManager {
|
|
10
|
+
constructor(ModelClass: any);
|
|
11
|
+
newQuerySet(): ErrorTestCompoundUniqueQuerySet;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Implementation of the ErrorTestCompoundUnique model
|
|
15
|
+
*/
|
|
16
|
+
export class ErrorTestCompoundUnique {
|
|
17
|
+
static configKey: string;
|
|
18
|
+
static modelName: string;
|
|
19
|
+
static primaryKeyField: string;
|
|
20
|
+
static objects: ErrorTestCompoundUniqueManager;
|
|
21
|
+
static fields: string[];
|
|
22
|
+
static schema: {
|
|
23
|
+
model_name: string;
|
|
24
|
+
title: string;
|
|
25
|
+
class_name: string;
|
|
26
|
+
plural_title: string;
|
|
27
|
+
primary_key_field: string;
|
|
28
|
+
filterable_fields: string[];
|
|
29
|
+
searchable_fields: string[];
|
|
30
|
+
ordering_fields: string[];
|
|
31
|
+
properties: {
|
|
32
|
+
id: {
|
|
33
|
+
type: string;
|
|
34
|
+
title: string;
|
|
35
|
+
required: boolean;
|
|
36
|
+
description: null;
|
|
37
|
+
nullable: boolean;
|
|
38
|
+
format: string;
|
|
39
|
+
max_length: null;
|
|
40
|
+
choices: null;
|
|
41
|
+
default: null;
|
|
42
|
+
validators: never[];
|
|
43
|
+
max_digits: null;
|
|
44
|
+
decimal_places: null;
|
|
45
|
+
read_only: boolean;
|
|
46
|
+
ref: null;
|
|
47
|
+
};
|
|
48
|
+
group: {
|
|
49
|
+
type: string;
|
|
50
|
+
title: string;
|
|
51
|
+
required: boolean;
|
|
52
|
+
description: null;
|
|
53
|
+
nullable: boolean;
|
|
54
|
+
format: null;
|
|
55
|
+
max_length: number;
|
|
56
|
+
choices: null;
|
|
57
|
+
default: null;
|
|
58
|
+
validators: never[];
|
|
59
|
+
max_digits: null;
|
|
60
|
+
decimal_places: null;
|
|
61
|
+
read_only: boolean;
|
|
62
|
+
ref: null;
|
|
63
|
+
};
|
|
64
|
+
rank: {
|
|
65
|
+
type: string;
|
|
66
|
+
title: string;
|
|
67
|
+
required: boolean;
|
|
68
|
+
description: null;
|
|
69
|
+
nullable: boolean;
|
|
70
|
+
format: null;
|
|
71
|
+
max_length: null;
|
|
72
|
+
choices: null;
|
|
73
|
+
default: null;
|
|
74
|
+
validators: never[];
|
|
75
|
+
max_digits: null;
|
|
76
|
+
decimal_places: null;
|
|
77
|
+
read_only: boolean;
|
|
78
|
+
ref: null;
|
|
79
|
+
};
|
|
80
|
+
label: {
|
|
81
|
+
type: string;
|
|
82
|
+
title: string;
|
|
83
|
+
required: boolean;
|
|
84
|
+
description: null;
|
|
85
|
+
nullable: boolean;
|
|
86
|
+
format: null;
|
|
87
|
+
max_length: number;
|
|
88
|
+
choices: null;
|
|
89
|
+
default: string;
|
|
90
|
+
validators: never[];
|
|
91
|
+
max_digits: null;
|
|
92
|
+
decimal_places: null;
|
|
93
|
+
read_only: boolean;
|
|
94
|
+
ref: null;
|
|
95
|
+
};
|
|
96
|
+
};
|
|
97
|
+
relationships: {};
|
|
98
|
+
default_ordering: null;
|
|
99
|
+
definitions: {
|
|
100
|
+
MoneyField: {
|
|
101
|
+
type: string;
|
|
102
|
+
properties: {
|
|
103
|
+
amount: {
|
|
104
|
+
type: string;
|
|
105
|
+
};
|
|
106
|
+
currency: {
|
|
107
|
+
type: string;
|
|
108
|
+
};
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
};
|
|
112
|
+
datetime_format: string;
|
|
113
|
+
date_format: string;
|
|
114
|
+
time_format: string;
|
|
115
|
+
display: null;
|
|
116
|
+
};
|
|
117
|
+
static relationshipFields: Map<any, any>;
|
|
118
|
+
constructor(data: any);
|
|
119
|
+
/**
|
|
120
|
+
* Define property getters and setters for all model fields
|
|
121
|
+
* @private
|
|
122
|
+
*/
|
|
123
|
+
private _defineProperties;
|
|
124
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated. Do not make direct changes to the file.
|
|
3
|
+
*/
|
|
4
|
+
import { Model, Manager, QuerySet, getModelClass } from '../../../../src';
|
|
5
|
+
import { wrapReactiveModel } from '../../../../src';
|
|
6
|
+
import schemaData from './errortestcompoundunique.schema.json';
|
|
7
|
+
/**
|
|
8
|
+
* Model-specific QuerySet implementation
|
|
9
|
+
*/
|
|
10
|
+
export class ErrorTestCompoundUniqueQuerySet extends QuerySet {
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Model-specific Manager implementation
|
|
14
|
+
*/
|
|
15
|
+
export class ErrorTestCompoundUniqueManager extends Manager {
|
|
16
|
+
constructor(ModelClass) {
|
|
17
|
+
super(ModelClass, ErrorTestCompoundUniqueQuerySet);
|
|
18
|
+
}
|
|
19
|
+
newQuerySet() {
|
|
20
|
+
return new ErrorTestCompoundUniqueQuerySet(this.ModelClass);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Implementation of the ErrorTestCompoundUnique model
|
|
25
|
+
*/
|
|
26
|
+
export class ErrorTestCompoundUnique extends Model {
|
|
27
|
+
constructor(data) {
|
|
28
|
+
ErrorTestCompoundUnique.validateFields(data);
|
|
29
|
+
super(data);
|
|
30
|
+
// Define getters and setters for all fields
|
|
31
|
+
this._defineProperties();
|
|
32
|
+
return wrapReactiveModel(this);
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Define property getters and setters for all model fields
|
|
36
|
+
* @private
|
|
37
|
+
*/
|
|
38
|
+
_defineProperties() {
|
|
39
|
+
// For each field, define a property that gets/sets from internal storage
|
|
40
|
+
ErrorTestCompoundUnique.fields.forEach(field => {
|
|
41
|
+
Object.defineProperty(this, field, {
|
|
42
|
+
get: function () {
|
|
43
|
+
return this.getField(field);
|
|
44
|
+
},
|
|
45
|
+
set: function (value) {
|
|
46
|
+
this.setField(field, value);
|
|
47
|
+
},
|
|
48
|
+
enumerable: true, // Make sure fields are enumerable for serialization
|
|
49
|
+
configurable: true
|
|
50
|
+
});
|
|
51
|
+
});
|
|
52
|
+
// Add a special read-only getter for the repr field
|
|
53
|
+
Object.defineProperty(this, 'repr', {
|
|
54
|
+
get: function () {
|
|
55
|
+
return this.getField('repr');
|
|
56
|
+
},
|
|
57
|
+
enumerable: true, // Make sure repr is enumerable
|
|
58
|
+
configurable: true
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
// Bind this model to its backend
|
|
63
|
+
ErrorTestCompoundUnique.configKey = 'backend1';
|
|
64
|
+
ErrorTestCompoundUnique.modelName = 'django_app.errortestcompoundunique';
|
|
65
|
+
ErrorTestCompoundUnique.primaryKeyField = 'id';
|
|
66
|
+
ErrorTestCompoundUnique.objects = new ErrorTestCompoundUniqueManager(ErrorTestCompoundUnique);
|
|
67
|
+
ErrorTestCompoundUnique.fields = ['id', 'group', 'rank', 'label'];
|
|
68
|
+
ErrorTestCompoundUnique.schema = schemaData;
|
|
69
|
+
ErrorTestCompoundUnique.relationshipFields = new Map([]);
|