@wix/wix-data-items-common 1.0.88 → 1.0.89
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":[],"sources":["../../../src/api/WixDataPatch.ts"],"sourcesContent":["import { WixDataOptions, WixDataItem, WixDataBulkResult } from './types'\n\nexport interface FieldUpdate {\n fieldPath: string\n action:\n | 'SET_FIELD'\n | 'REMOVE_FIELD'\n | 'INCREMENT_FIELD'\n | 'APPEND_TO_ARRAY'\n | 'REMOVE_FROM_ARRAY'\n actionOptions?: any\n}\n\nexport interface WixDataBulkPatch {\n incrementField(fieldName: string, by: number): WixDataBulkPatch\n setField(fieldName: string, value: any): WixDataBulkPatch\n appendToArray(fieldName: string, value: any): WixDataBulkPatch\n removeFromArray(fieldName: string, value: any): WixDataBulkPatch\n removeField(fieldName: string): WixDataBulkPatch\n\n run(options?: WixDataOptions): Promise<WixDataBulkResult>\n}\n\nexport interface WixDataPatch {\n incrementField(fieldName: string, by: number): WixDataPatch\n setField(fieldName: string, value: any): WixDataPatch\n appendToArray(fieldName: string, value: any): WixDataPatch\n removeFromArray(fieldName: string, value: any): WixDataPatch\n removeField(fieldName: string): WixDataPatch\n\n run(options?: WixDataOptions): Promise<WixDataItem | null>\n}\n"],"mappings":""}
|
|
1
|
+
{"version":3,"names":[],"sources":["../../../src/api/WixDataPatch.ts"],"sourcesContent":["import { WixDataOptions, WixDataItem, WixDataBulkResult } from './types'\n\nexport interface FieldUpdate {\n fieldPath: string\n action:\n | 'SET_FIELD'\n | 'REMOVE_FIELD'\n | 'INCREMENT_FIELD'\n | 'APPEND_TO_ARRAY'\n | 'REMOVE_FROM_ARRAY'\n actionOptions?: any\n}\n\n/**\n * @builder\n */\nexport interface WixDataBulkPatch {\n /**\n * Increments field\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param by - Value to increment by.\n * @requiredField by\n * @returns Updated patch.\n */\n incrementField(fieldName: string, by: number): WixDataBulkPatch\n\n /**\n * Sets field value\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param value - Value to set.\n * @requiredField value\n * @returns Updated patch.\n */\n setField(fieldName: string, value: any): WixDataBulkPatch\n\n /**\n * Appends to array\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param value - Value to append.\n * @requiredField value\n * @returns Updated patch.\n */\n appendToArray(fieldName: string, value: any): WixDataBulkPatch\n\n /**\n * Removes value from array\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param value - Value to append.\n * @requiredField value\n * @returns Updated patch.\n */\n removeFromArray(fieldName: string, value: any): WixDataBulkPatch\n\n /**\n * Removes field\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @returns Updated patch.\n */\n removeField(fieldName: string): WixDataBulkPatch\n\n /**\n * Executes patch\n * @public\n * @documentationMaturity preview\n * @returns Bulk action results.\n */\n run(options?: WixDataOptions): Promise<WixDataBulkResult>\n}\n\n/**\n * @builder\n */\nexport interface WixDataPatch {\n /**\n * Increments field\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param by - Value to increment by.\n * @requiredField by\n * @returns Updated patch.\n */\n incrementField(fieldName: string, by: number): WixDataPatch\n\n /**\n * Sets field value\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param value - Value to set.\n * @requiredField value\n * @returns Updated patch.\n */\n setField(fieldName: string, value: any): WixDataPatch\n\n /**\n * Appends to array\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param value - Value to append.\n * @requiredField value\n * @returns Updated patch.\n */\n appendToArray(fieldName: string, value: any): WixDataPatch\n\n /**\n * Removes value from array\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @param value - Value to append.\n * @requiredField value\n * @returns Updated patch.\n */\n removeFromArray(fieldName: string, value: any): WixDataPatch\n\n /**\n * Removes field\n * @public\n * @documentationMaturity preview\n * @param field - Field whose value is will be modified.\n * @requiredField fieldName\n * @returns Updated patch.\n */\n removeField(fieldName: string): WixDataPatch\n\n /**\n * Executes patch\n * @public\n * @documentationMaturity preview\n * @returns Modified data item.\n */\n\n run(options?: WixDataOptions): Promise<WixDataItem | null>\n}\n"],"mappings":""}
|
|
@@ -4,20 +4,134 @@ export interface FieldUpdate {
|
|
|
4
4
|
action: 'SET_FIELD' | 'REMOVE_FIELD' | 'INCREMENT_FIELD' | 'APPEND_TO_ARRAY' | 'REMOVE_FROM_ARRAY';
|
|
5
5
|
actionOptions?: any;
|
|
6
6
|
}
|
|
7
|
+
/**
|
|
8
|
+
* @builder
|
|
9
|
+
*/
|
|
7
10
|
export interface WixDataBulkPatch {
|
|
11
|
+
/**
|
|
12
|
+
* Increments field
|
|
13
|
+
* @public
|
|
14
|
+
* @documentationMaturity preview
|
|
15
|
+
* @param field - Field whose value is will be modified.
|
|
16
|
+
* @requiredField fieldName
|
|
17
|
+
* @param by - Value to increment by.
|
|
18
|
+
* @requiredField by
|
|
19
|
+
* @returns Updated patch.
|
|
20
|
+
*/
|
|
8
21
|
incrementField(fieldName: string, by: number): WixDataBulkPatch;
|
|
22
|
+
/**
|
|
23
|
+
* Sets field value
|
|
24
|
+
* @public
|
|
25
|
+
* @documentationMaturity preview
|
|
26
|
+
* @param field - Field whose value is will be modified.
|
|
27
|
+
* @requiredField fieldName
|
|
28
|
+
* @param value - Value to set.
|
|
29
|
+
* @requiredField value
|
|
30
|
+
* @returns Updated patch.
|
|
31
|
+
*/
|
|
9
32
|
setField(fieldName: string, value: any): WixDataBulkPatch;
|
|
33
|
+
/**
|
|
34
|
+
* Appends to array
|
|
35
|
+
* @public
|
|
36
|
+
* @documentationMaturity preview
|
|
37
|
+
* @param field - Field whose value is will be modified.
|
|
38
|
+
* @requiredField fieldName
|
|
39
|
+
* @param value - Value to append.
|
|
40
|
+
* @requiredField value
|
|
41
|
+
* @returns Updated patch.
|
|
42
|
+
*/
|
|
10
43
|
appendToArray(fieldName: string, value: any): WixDataBulkPatch;
|
|
44
|
+
/**
|
|
45
|
+
* Removes value from array
|
|
46
|
+
* @public
|
|
47
|
+
* @documentationMaturity preview
|
|
48
|
+
* @param field - Field whose value is will be modified.
|
|
49
|
+
* @requiredField fieldName
|
|
50
|
+
* @param value - Value to append.
|
|
51
|
+
* @requiredField value
|
|
52
|
+
* @returns Updated patch.
|
|
53
|
+
*/
|
|
11
54
|
removeFromArray(fieldName: string, value: any): WixDataBulkPatch;
|
|
55
|
+
/**
|
|
56
|
+
* Removes field
|
|
57
|
+
* @public
|
|
58
|
+
* @documentationMaturity preview
|
|
59
|
+
* @param field - Field whose value is will be modified.
|
|
60
|
+
* @requiredField fieldName
|
|
61
|
+
* @returns Updated patch.
|
|
62
|
+
*/
|
|
12
63
|
removeField(fieldName: string): WixDataBulkPatch;
|
|
64
|
+
/**
|
|
65
|
+
* Executes patch
|
|
66
|
+
* @public
|
|
67
|
+
* @documentationMaturity preview
|
|
68
|
+
* @returns Bulk action results.
|
|
69
|
+
*/
|
|
13
70
|
run(options?: WixDataOptions): Promise<WixDataBulkResult>;
|
|
14
71
|
}
|
|
72
|
+
/**
|
|
73
|
+
* @builder
|
|
74
|
+
*/
|
|
15
75
|
export interface WixDataPatch {
|
|
76
|
+
/**
|
|
77
|
+
* Increments field
|
|
78
|
+
* @public
|
|
79
|
+
* @documentationMaturity preview
|
|
80
|
+
* @param field - Field whose value is will be modified.
|
|
81
|
+
* @requiredField fieldName
|
|
82
|
+
* @param by - Value to increment by.
|
|
83
|
+
* @requiredField by
|
|
84
|
+
* @returns Updated patch.
|
|
85
|
+
*/
|
|
16
86
|
incrementField(fieldName: string, by: number): WixDataPatch;
|
|
87
|
+
/**
|
|
88
|
+
* Sets field value
|
|
89
|
+
* @public
|
|
90
|
+
* @documentationMaturity preview
|
|
91
|
+
* @param field - Field whose value is will be modified.
|
|
92
|
+
* @requiredField fieldName
|
|
93
|
+
* @param value - Value to set.
|
|
94
|
+
* @requiredField value
|
|
95
|
+
* @returns Updated patch.
|
|
96
|
+
*/
|
|
17
97
|
setField(fieldName: string, value: any): WixDataPatch;
|
|
98
|
+
/**
|
|
99
|
+
* Appends to array
|
|
100
|
+
* @public
|
|
101
|
+
* @documentationMaturity preview
|
|
102
|
+
* @param field - Field whose value is will be modified.
|
|
103
|
+
* @requiredField fieldName
|
|
104
|
+
* @param value - Value to append.
|
|
105
|
+
* @requiredField value
|
|
106
|
+
* @returns Updated patch.
|
|
107
|
+
*/
|
|
18
108
|
appendToArray(fieldName: string, value: any): WixDataPatch;
|
|
109
|
+
/**
|
|
110
|
+
* Removes value from array
|
|
111
|
+
* @public
|
|
112
|
+
* @documentationMaturity preview
|
|
113
|
+
* @param field - Field whose value is will be modified.
|
|
114
|
+
* @requiredField fieldName
|
|
115
|
+
* @param value - Value to append.
|
|
116
|
+
* @requiredField value
|
|
117
|
+
* @returns Updated patch.
|
|
118
|
+
*/
|
|
19
119
|
removeFromArray(fieldName: string, value: any): WixDataPatch;
|
|
120
|
+
/**
|
|
121
|
+
* Removes field
|
|
122
|
+
* @public
|
|
123
|
+
* @documentationMaturity preview
|
|
124
|
+
* @param field - Field whose value is will be modified.
|
|
125
|
+
* @requiredField fieldName
|
|
126
|
+
* @returns Updated patch.
|
|
127
|
+
*/
|
|
20
128
|
removeField(fieldName: string): WixDataPatch;
|
|
129
|
+
/**
|
|
130
|
+
* Executes patch
|
|
131
|
+
* @public
|
|
132
|
+
* @documentationMaturity preview
|
|
133
|
+
* @returns Modified data item.
|
|
134
|
+
*/
|
|
21
135
|
run(options?: WixDataOptions): Promise<WixDataItem | null>;
|
|
22
136
|
}
|
|
23
137
|
//# sourceMappingURL=WixDataPatch.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WixDataPatch.d.ts","sourceRoot":"","sources":["../../../src/api/WixDataPatch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAA;AAExE,MAAM,WAAW,WAAW;IAC1B,SAAS,EAAE,MAAM,CAAA;IACjB,MAAM,EACF,WAAW,GACX,cAAc,GACd,iBAAiB,GACjB,iBAAiB,GACjB,mBAAmB,CAAA;IACvB,aAAa,CAAC,EAAE,GAAG,CAAA;CACpB;AAED,MAAM,WAAW,gBAAgB;IAC/B,cAAc,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,gBAAgB,CAAA;
|
|
1
|
+
{"version":3,"file":"WixDataPatch.d.ts","sourceRoot":"","sources":["../../../src/api/WixDataPatch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAA;AAExE,MAAM,WAAW,WAAW;IAC1B,SAAS,EAAE,MAAM,CAAA;IACjB,MAAM,EACF,WAAW,GACX,cAAc,GACd,iBAAiB,GACjB,iBAAiB,GACjB,mBAAmB,CAAA;IACvB,aAAa,CAAC,EAAE,GAAG,CAAA;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;;;;;;;OASG;IACH,cAAc,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,gBAAgB,CAAA;IAE/D;;;;;;;;;OASG;IACH,QAAQ,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,GAAG,gBAAgB,CAAA;IAEzD;;;;;;;;;OASG;IACH,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,GAAG,gBAAgB,CAAA;IAE9D;;;;;;;;;OASG;IACH,eAAe,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,GAAG,gBAAgB,CAAA;IAEhE;;;;;;;OAOG;IACH,WAAW,CAAC,SAAS,EAAE,MAAM,GAAG,gBAAgB,CAAA;IAEhD;;;;;OAKG;IACH,GAAG,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAA;CAC1D;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B;;;;;;;;;OASG;IACH,cAAc,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,YAAY,CAAA;IAE3D;;;;;;;;;OASG;IACH,QAAQ,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,GAAG,YAAY,CAAA;IAErD;;;;;;;;;OASG;IACH,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,GAAG,YAAY,CAAA;IAE1D;;;;;;;;;OASG;IACH,eAAe,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,GAAG,YAAY,CAAA;IAE5D;;;;;;;OAOG;IACH,WAAW,CAAC,SAAS,EAAE,MAAM,GAAG,YAAY,CAAA;IAE5C;;;;;OAKG;IAEH,GAAG,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,OAAO,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;CAC3D"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/wix-data-items-common",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.89",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Rimvydas Gimbutas",
|
|
@@ -85,5 +85,5 @@
|
|
|
85
85
|
"wallaby": {
|
|
86
86
|
"autoDetect": true
|
|
87
87
|
},
|
|
88
|
-
"falconPackageHash": "
|
|
88
|
+
"falconPackageHash": "4bf44eb04766e84a522867b56c2f95d538e66dd0273903b9a942f4a8"
|
|
89
89
|
}
|