@rentman/rm-core 1.5.1 → 1.5.3
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/changelog.md +375 -368
- package/dist/rm-core.js +68 -76
- package/dist/rm-core.min.js +1 -1
- package/dist/src/classes/CollectionHandler.d.ts +3 -3
- package/dist/src/classes/ColumnExpansion.d.ts +2 -3
- package/dist/src/classes/ColumnSet.d.ts +4 -4
- package/dist/src/classes/ColumnSubsetCache.d.ts +2 -3
- package/dist/src/classes/ColumnUtil.d.ts +20 -13
- package/dist/src/factories/ColumnExpansionFactory.d.ts +2 -3
- package/dist/src/factories/ColumnSubsetCacheFactory.d.ts +2 -3
- package/package.json +1 -1
package/changelog.md
CHANGED
|
@@ -1,368 +1,375 @@
|
|
|
1
|
-
#Changelog
|
|
2
|
-
Contains new features, breaking changes and their reasoning
|
|
3
|
-
|
|
4
|
-
## 1.5.
|
|
5
|
-
-
|
|
6
|
-
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
-
|
|
13
|
-
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
-
|
|
18
|
-
|
|
19
|
-
-
|
|
20
|
-
`
|
|
21
|
-
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
-
|
|
27
|
-
`
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
necessary.
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
- Add
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
## v1.
|
|
72
|
-
-
|
|
73
|
-
>
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
## v1.2.
|
|
79
|
-
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
## v1.2.
|
|
89
|
-
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
- **Breaking:**
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
-
|
|
144
|
-
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
###
|
|
148
|
-
-
|
|
149
|
-
|
|
150
|
-
- `
|
|
151
|
-
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
-
|
|
156
|
-
|
|
157
|
-
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
-
|
|
170
|
-
|
|
171
|
-
##v1.
|
|
172
|
-
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
- `
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
-
|
|
188
|
-
|
|
189
|
-
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
##v.1.
|
|
194
|
-
- Fixed issue
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
##v.1.1.
|
|
227
|
-
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
## v1.1.
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
##v1.0.
|
|
311
|
-
- Fix
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
-
|
|
319
|
-
>
|
|
320
|
-
|
|
321
|
-
##v1.0.
|
|
322
|
-
-
|
|
323
|
-
>
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
##v1.0.
|
|
329
|
-
-
|
|
330
|
-
>
|
|
331
|
-
|
|
332
|
-
##v1.0.
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
##v1.0.
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
-
|
|
346
|
-
>
|
|
347
|
-
|
|
348
|
-
- `
|
|
349
|
-
>
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
>
|
|
362
|
-
|
|
363
|
-
- Remove
|
|
364
|
-
>
|
|
365
|
-
|
|
366
|
-
- Remove `
|
|
367
|
-
> `
|
|
368
|
-
|
|
1
|
+
#Changelog
|
|
2
|
+
Contains new features, breaking changes and their reasoning
|
|
3
|
+
|
|
4
|
+
## 1.5.2
|
|
5
|
+
- Type functions in `ColumnUtil` class.
|
|
6
|
+
- Add `getRequestColumnId` and `containsDerivedColumns` to `ColumnUtil`.
|
|
7
|
+
> `getRequestColumnId` should be used instead of `Util.getFirstProperty` when retrieving a column ID.
|
|
8
|
+
- **Breaking:** Remove `ColumnUtil.isColumnSubset`. Use `ColumnSet.isSuperSetOf` instead.
|
|
9
|
+
- Remove `findColumnObject`. Rename `findColumn` to `findRequestColumn`.
|
|
10
|
+
|
|
11
|
+
## 1.5.1
|
|
12
|
+
- Properly remove item entry stub from (local) cache when request fails.
|
|
13
|
+
- Fix issue where item or collection options could be set to undefined.
|
|
14
|
+
|
|
15
|
+
## 1.5.0
|
|
16
|
+
- Add `SocketMessage` type and add types to `SocketMessageHandler`
|
|
17
|
+
- Expand local items requested using `getItemById` or `getItemsById` in `ItemAdministrator`.
|
|
18
|
+
(`fetchItem` or `fetchItems` in `ItemHandler`.)
|
|
19
|
+
- Implement expanding of local collections. This no longer leads to invalid requests.
|
|
20
|
+
- **Breaking:** The `expand` function in `CollectionEntry` now has an `ItemCache` parameter.
|
|
21
|
+
- **Warning:** This version contains major changes.
|
|
22
|
+
|
|
23
|
+
### Introduce typing of item and collection options
|
|
24
|
+
- **Breaking:** Removed `QueryItemType` collection entry option.
|
|
25
|
+
- **Breaking:** Removed `ItemResourceService`.
|
|
26
|
+
- Removed `processOptions` parameter from `createCollectionResource` (`ItemAdministrator`). It is now equivalent to
|
|
27
|
+
`addCollection`.
|
|
28
|
+
- When creating an item resource using `ItemResourceFactory`, a collection entry using `CollectionResourceFactory` or a
|
|
29
|
+
collection resource using `CollectionResourceFactory` it is no longer necessary to process options beforehand. It is
|
|
30
|
+
still necessary when interacting with `CollectionHandler` or `ItemHandler` directly.
|
|
31
|
+
|
|
32
|
+
## v1.4.0
|
|
33
|
+
- Add `expandProcessLinkedItems` and `expandAddToCollections` to `ItemAdministrator`. These are analogues to
|
|
34
|
+
`processLinkedItems` and `addToCollections`, but also expand the items with (derived) values and columns as necessary.
|
|
35
|
+
They have a slightly different type signature.
|
|
36
|
+
- Whenever a collection is requested, the `CollectionHandler` now makes sure that added local items are expanded as
|
|
37
|
+
necessary.
|
|
38
|
+
- **Breaking:** Last parameter of `ItemHandler.createLocalEntries` is now a callback function.
|
|
39
|
+
- **Breaking:** Rename `TemplateLinkedItemEntryMap` type to `TemplateItemEntryMap`.
|
|
40
|
+
|
|
41
|
+
## v1.3.8
|
|
42
|
+
- Add `isSaving` to `LocalCache`
|
|
43
|
+
> We use this to disable the cancel/save buttons while the localCache is saving in the frontend
|
|
44
|
+
|
|
45
|
+
## v1.3.7
|
|
46
|
+
- Fix issues that generate invalid requests / changes when moving existing item to another collection, then deleting the parent.
|
|
47
|
+
- Remove slip workarounds
|
|
48
|
+
- Add api request types
|
|
49
|
+
- Add types to `ModuleChangesCompilation`
|
|
50
|
+
|
|
51
|
+
## v1.3.6
|
|
52
|
+
- Skip add / remove collection callbacks when calling `revertChanges` (`LocalCache`).
|
|
53
|
+
|
|
54
|
+
## v1.3.5
|
|
55
|
+
- Fix issue where items added to collections when resolving wouldn't be removed in `revertChanges` (`LocalCache`).
|
|
56
|
+
|
|
57
|
+
## v1.3.4
|
|
58
|
+
- Add country to isFilteredColumn in ColumnUtil
|
|
59
|
+
|
|
60
|
+
## v1.3.3
|
|
61
|
+
- Move processLocalConfigColumns and consolidateColumns from ColumnUtil to frontend
|
|
62
|
+
> These functions are specifically used for rendering ui-grid in the frontend, so there's
|
|
63
|
+
no reason to have them in the core
|
|
64
|
+
|
|
65
|
+
## v1.3.2
|
|
66
|
+
- Fix types path in package.json
|
|
67
|
+
|
|
68
|
+
## v1.3.1
|
|
69
|
+
- Fix types path in package.json
|
|
70
|
+
|
|
71
|
+
## v1.3.0
|
|
72
|
+
- Rename PromiseInterface to PromiseLibraryInterface
|
|
73
|
+
> PromiseInterface is now used for the internal promise type
|
|
74
|
+
|
|
75
|
+
- Use PromiseInterface instead of Promise as internal promise type
|
|
76
|
+
> This allows us to overwrite the PromiseInterface definition in the frontend indicate usage of ng.IPromise
|
|
77
|
+
|
|
78
|
+
## v1.2.9
|
|
79
|
+
- Call processOptions in fetchDerivedValuesByColumn
|
|
80
|
+
> Bug was introduced earlier but got enabled in v1.2.7
|
|
81
|
+
|
|
82
|
+
## v1.2.8
|
|
83
|
+
- Add toJSON methods for ItemResources, ItemEntries, and ColumnSets to fix circular dependencies in JSON.stringify
|
|
84
|
+
|
|
85
|
+
## v1.2.7
|
|
86
|
+
- Set itemEntry parent when generating a stub
|
|
87
|
+
|
|
88
|
+
## v1.2.6
|
|
89
|
+
- Fix an issue introduced in v1.2.5.
|
|
90
|
+
|
|
91
|
+
## v1.2.5
|
|
92
|
+
- When a local item cannot by found, return a newly created item in `getItemByState` (`ItemAdministrator`) only. This
|
|
93
|
+
solves an issue with refreshing on a local edit view.
|
|
94
|
+
|
|
95
|
+
## v1.2.4
|
|
96
|
+
- **Breaking:** When a local item cannot by found, instead of a new item being created an error is thrown. This means it
|
|
97
|
+
is no longer possible to create local items using `getItemById` or `getItemsById` in the `ItemAdministrator` class.
|
|
98
|
+
- **Breaking:** Removed `getItemDefinition` and `getItemByDef` in the `ItemAdministrator` class. Added `getItemByState`.
|
|
99
|
+
- Renamed types `TemplateResponseItemEntryMap` to `TemplateItemEntryMap` and `TemplateResponseLinkedItemEntryMap` to
|
|
100
|
+
`TemplateLinkedItemEntryMap`.
|
|
101
|
+
- Removed `getCollectionCacheKey` in `KeyService`. (Legacy code.)
|
|
102
|
+
|
|
103
|
+
## v1.2.3
|
|
104
|
+
- Fixed issue where derived values deeper than one layer couldn't be resolved.
|
|
105
|
+
|
|
106
|
+
## v1.2.2
|
|
107
|
+
- Fixed issue where in derived values weren't set after create request.
|
|
108
|
+
|
|
109
|
+
## v1.2.1
|
|
110
|
+
- **Breaking:** Replaced the `initial` parameter with the `callOnChange` parameter (`true` by default) in the `commit`
|
|
111
|
+
function of the `EditResource` class.
|
|
112
|
+
- Fixed issue in `setLocalFields` (`ItemEntry`) where some values were wrongly assumed to be present in `initialValues`.
|
|
113
|
+
- Optimization: Disabled automatic resolution of derived values in `addItems` (`CollectionEditResource`) when `modInstant` is set to true.
|
|
114
|
+
|
|
115
|
+
## v1.2.0
|
|
116
|
+
- **Breaking:** When calling `addItems` or `addItem` on the `CollectionEditResource` class derived values are now
|
|
117
|
+
resolved automatically. Instead of a compound object like `{fields: {key: 'value'}, derived: {}}` an object like
|
|
118
|
+
`{key: 'value'}` should now be used as argument when calling these functions.
|
|
119
|
+
- **Breaking:** Added `localCache` parameter to `CollectionResource` constructor.
|
|
120
|
+
|
|
121
|
+
## v1.1.20
|
|
122
|
+
- Fixed minor issue where collection wouldn't be deferred properly before expanding.
|
|
123
|
+
- `onChange` is now called automatically when when calling `commit` on an edit resource.
|
|
124
|
+
|
|
125
|
+
## v1.1.19
|
|
126
|
+
- **Breaking:** Renamed `getCurrentChanges` to `getModuleChanges` in the `ItemAdministrator` class. Added optional
|
|
127
|
+
`localCache` parameter.
|
|
128
|
+
|
|
129
|
+
### Local cache callback refactoring
|
|
130
|
+
- Removed `onSaveWithoutClosing` event.
|
|
131
|
+
- Added `condition` parameter to `onBeforeSave` and `onSaveSuccess` (possible values are `always`, `onClose` or
|
|
132
|
+
`skipOnClose`, defaults to `always`). Callbacks registered with `condition: always` will get executed before other
|
|
133
|
+
callbacks.
|
|
134
|
+
- Pass the local cache itself to all registered callback functions. Pass the item ID conversion map as second argument
|
|
135
|
+
to `onSaveSuccess` callback functions.
|
|
136
|
+
|
|
137
|
+
## v1.1.18
|
|
138
|
+
- Calling `expand` on a `CollectionEntry` manually no longer defers the collection entry.
|
|
139
|
+
- The `batchFetch` and `batchExpand` functions in the `CollectionHandler` class now properly defer and resolve the
|
|
140
|
+
collection entries.
|
|
141
|
+
|
|
142
|
+
## v1.1.17
|
|
143
|
+
- Fixed issue where the `getLocalByQuery` function in the `ItemCache` class wouldn't return any items.
|
|
144
|
+
- When batch resolving collection entries, `CollectionHandler` now looks for matching items using `getByQuery` instead
|
|
145
|
+
of `getByParent`.
|
|
146
|
+
|
|
147
|
+
### Cache invalidation
|
|
148
|
+
- Added `queueReload` function to `ItemEntry` class. This will reload the item when the item entry itself or a
|
|
149
|
+
collection entry containing the item is requested.
|
|
150
|
+
- The `queueReload` function in the `CollectionEntry` class no longer directly defers the item.
|
|
151
|
+
- Added `invalidateCache` function to the `ItemAdministrator` class. This will call `queueReload` on all item entries
|
|
152
|
+
and collection entries.
|
|
153
|
+
|
|
154
|
+
### Item entry refactoring
|
|
155
|
+
- Renamed `process` to `setFields`.
|
|
156
|
+
- Replaced `processLocal` with `setLocalFields`. This function no longer has a `modified` parameter.
|
|
157
|
+
- `setModified` now also sets local default values.
|
|
158
|
+
- Removed `setCreator`. This function was called twice in some instances.
|
|
159
|
+
- **Breaking:** Added `derived` parameter to `updateFields`
|
|
160
|
+
|
|
161
|
+
##v1.16
|
|
162
|
+
- Pass `hasChanges` as second argument to `onBeforeSave` callbacks in the `LocalCache` class. This fixes an issue with
|
|
163
|
+
project financial values in the front-end. [RM4-9577]
|
|
164
|
+
- Added `callOnActivate` parameter to `addItems` function in `CollectionEditResource` class. Use this to prevent items
|
|
165
|
+
from being added to the local cache.
|
|
166
|
+
|
|
167
|
+
##v1.15
|
|
168
|
+
- Fix `fetchItemTypesTranslations` function in `ColumnHandler` class.
|
|
169
|
+
- Fix type definition of `PromiseInterface.all`.
|
|
170
|
+
|
|
171
|
+
##v1.14
|
|
172
|
+
- The `ChangesCompiler` now always processes local collections. (Even if they don't have edit resources.) This fixes an
|
|
173
|
+
issue with recurring appointments in the front-end.
|
|
174
|
+
|
|
175
|
+
##v1.13
|
|
176
|
+
- Add option to exclude itemTypes during createLocalEntries.
|
|
177
|
+
|
|
178
|
+
##v1.12
|
|
179
|
+
- **Breaking:** `ItemResource.isNew` returns true *only* if the resource was created using
|
|
180
|
+
`ItemAdministrator.getNewResource` or `ItemAdministrator.getItemByDef`. This fixes an issue where items where removed
|
|
181
|
+
from the local cache inadvertently.
|
|
182
|
+
- The `start`, `commit` and `rollback` functions of `EditResource` now return the resource itself to facilitate chaining.
|
|
183
|
+
- When calling `CollectionEntry.revertChanges`, callbacks like `onAdd` / `onRemove` and `onActivate` / `onDeactivate`
|
|
184
|
+
are now respected. This fixes an issue where items where *not* removed from the local cache.
|
|
185
|
+
- When removing *local* items from collections, they are removed from `initial` as well as `modified`. This fixes an
|
|
186
|
+
issue where changes were being detected continuously.
|
|
187
|
+
- Updated the order of requests in `changesProcessor`. The `update` request is now executed before the `delete` request,
|
|
188
|
+
except when updating documents. This fixes several issues.
|
|
189
|
+
- `CollectionCache` now uses a map instead of an array to store collections. This fixes an issue where the same
|
|
190
|
+
collection was added multiple times.
|
|
191
|
+
- Updated all models to use dependency objects. This increases ease of debugging.
|
|
192
|
+
|
|
193
|
+
##v.1.11
|
|
194
|
+
- Fixed issue that occurs when saving when having an existing item refer to a newly created item.
|
|
195
|
+
- **Breaking:** Removed `ItemResourceService.isNewResource`.
|
|
196
|
+
- **Breaking:** Renamed `ItemResource.isNewResource` to `ItemResource.isNew`. Removed parameter.
|
|
197
|
+
- `ItemResource.isNew` is equivalent to `ItemResource.isLocal`, while `EditResource.isNew` checks also checks for
|
|
198
|
+
completed transactions.
|
|
199
|
+
|
|
200
|
+
##v.1.10
|
|
201
|
+
- Fixed issue where changes on different subtabs were not detected.
|
|
202
|
+
|
|
203
|
+
##v1.1.9
|
|
204
|
+
- Exposed `noop` function on `RmCore` class.
|
|
205
|
+
> This is used in order to check whether a callback has a default value.
|
|
206
|
+
- Added `copyRequestColumns` function to `ColumnUtil` class.
|
|
207
|
+
- Made parameters of `ItemAdministrator.saveCurrentLocalCache` and `LocalCache.save` optional.
|
|
208
|
+
- **Breaking:** Reordered parameters of `ChangesProcessor.execute` to be consistent with
|
|
209
|
+
`ItemAdministrator.saveCurrentLocalCache`. The new order is `singleItems` - `collections` - `parameters` -
|
|
210
|
+
`breakUpByParent` - `onAfterCreateCallback`.
|
|
211
|
+
|
|
212
|
+
##v1.1.8
|
|
213
|
+
- Set default value for `params` to `{filter: false}` in `request` function in `ColumnHandler` class.
|
|
214
|
+
|
|
215
|
+
##v1.1.7
|
|
216
|
+
- Fixed issue where cached item entries or collection entries wouldn't be added to the local cache.
|
|
217
|
+
|
|
218
|
+
##v1.1.6
|
|
219
|
+
- Fixed issue with deferred item entries.
|
|
220
|
+
- Re-enable changes watcher after save.
|
|
221
|
+
- Added optional `id` parameter to `LocalCache` constructor.
|
|
222
|
+
|
|
223
|
+
##v1.1.5
|
|
224
|
+
- Added `clearItem` function to `LocalCache` class.
|
|
225
|
+
|
|
226
|
+
##v.1.1.4
|
|
227
|
+
- Fix issue where items where not added to the local cache automatically when they where added to a collection.
|
|
228
|
+
> This depends on the `callOnActivate` parameter. I've added this mainly because extending collections should *not* add
|
|
229
|
+
the items to the local cache.
|
|
230
|
+
> In other instances this might be debatable because it doesn't do any real harm. *Not*
|
|
231
|
+
doing it however can definitely be harmful.
|
|
232
|
+
|
|
233
|
+
##v.1.1.3
|
|
234
|
+
- Fixed an issue where all collections in a local cache would be cleared.
|
|
235
|
+
- **Breaking:** Renamed `getCacheManager` to `getCurrentLocalCache` and `setCacheManager` to `setCurrentLocalCache` in
|
|
236
|
+
`LocalCacheManagerInterface`.
|
|
237
|
+
|
|
238
|
+
##v1.1.2
|
|
239
|
+
- Fixed an issue concerning derived values.
|
|
240
|
+
|
|
241
|
+
## v1.1.1
|
|
242
|
+
- Fixed an issue where changes wouldn't be detected.
|
|
243
|
+
- **Breaking:** Removed the `_hasChanges` function in the `localCache` class. If you want to force changes detection,
|
|
244
|
+
call `detectChanges` instead. Otherwise, rely on the `hasChanges` variable.
|
|
245
|
+
- **Breaking:** Removed the `enableWatcher` and `disableWatcher` functions. Use `enableChangesWatcher` and
|
|
246
|
+
`disableChangesWatcher` instead.
|
|
247
|
+
|
|
248
|
+
## v1.1.0
|
|
249
|
+
### Development
|
|
250
|
+
|
|
251
|
+
#### Strict TypeScript compilation
|
|
252
|
+
Added the following TypeScript compiler options:
|
|
253
|
+
- noImplicitThis
|
|
254
|
+
- noImplicitReturns
|
|
255
|
+
- strictNullChecks
|
|
256
|
+
- noUnusedLocals
|
|
257
|
+
- noUnusedParameters
|
|
258
|
+
|
|
259
|
+
I would advise enabling these for all TypeScript projects from now on.
|
|
260
|
+
|
|
261
|
+
#### Ordered imports and dependencies
|
|
262
|
+
Imports are now ordered alphabetically and grouped by folder. Added a TSLint option to enforce this.
|
|
263
|
+
Please note that this also applies for imports from the folder the file is currently in.
|
|
264
|
+
For example, in `models/ItemResource.ts`, `itemEntry` should be imported like so:
|
|
265
|
+
`import { ItemEntry } from '../models';`
|
|
266
|
+
|
|
267
|
+
Also, factory and class dependencies should be ordered alphabetically as well. This will make it easier to add and
|
|
268
|
+
remove dependencies in the future.
|
|
269
|
+
|
|
270
|
+
### Breaking changes
|
|
271
|
+
|
|
272
|
+
- Renamed `changesCompiler` to `changesCompilation`, `changesCompilerFactory` to `changesCompilationFactory`,
|
|
273
|
+
`moduleChangesCompiler` to `moduleChangesCompilation` and `moduleChangesCompilerFactory` to
|
|
274
|
+
`moduleChangesCompilationFactory`.
|
|
275
|
+
- Removed the `allLinks` parameter from the `query` function definition in the `ApiRequestServiceInterface`. This is
|
|
276
|
+
no longer supported in the back-end.
|
|
277
|
+
|
|
278
|
+
#### Item and collection entries
|
|
279
|
+
- Moved *all* functions that handle item entries from the `ItemEntryService` to the `ItemEntry` class.
|
|
280
|
+
- Added the following functions to `ItemEntryService`:
|
|
281
|
+
- `createLocalConversionMap`;
|
|
282
|
+
- `expandLocalConversionMap`;
|
|
283
|
+
- `expandConversionMap`;
|
|
284
|
+
- `batchExpandConversionMap`;
|
|
285
|
+
- `batchClone`.
|
|
286
|
+
- Cloning of item entries now works slightly differently. The function will attempt to generate a new
|
|
287
|
+
item ID, and update the conversion map accordingly, but will respect the item ID that is already there.
|
|
288
|
+
|
|
289
|
+
#### Rework item caching
|
|
290
|
+
Newly created item entries and collection entries are no longer added to the global *or* local cache by default.
|
|
291
|
+
All entries are added to the global cache on save. Item entries are added to the local cache when resources are created
|
|
292
|
+
using the item administrator or when resources are created when adding the items to a collection.
|
|
293
|
+
|
|
294
|
+
> This will increase reliability by ensuring the global cache is no longer 'polluted' with local items. Also, this will
|
|
295
|
+
> allow for the creation item and collection entries without caching them directly. This is required for the copying and
|
|
296
|
+
> pasting of items.
|
|
297
|
+
|
|
298
|
+
Other changes:
|
|
299
|
+
|
|
300
|
+
- Moved `saveLocal` to `ItemAdministrator`;
|
|
301
|
+
- `ItemAdministrator.fetchTitle` should now be called instead of `ItemHandler.fetchTitle`;
|
|
302
|
+
- The `ItemAdministrator` collection matching functions (`addToCollections`, `removeFromCollections`) should now be
|
|
303
|
+
called instead of those in the `CollectionHandler`. The `CollectionHandler` should only be used to reflect changes
|
|
304
|
+
already on the backend. (Use `getCollectionMatcher`.)
|
|
305
|
+
|
|
306
|
+
|
|
307
|
+
##v1.0.33
|
|
308
|
+
- Really fix types path
|
|
309
|
+
|
|
310
|
+
##v1.0.33
|
|
311
|
+
- Fix types path
|
|
312
|
+
|
|
313
|
+
##v1.0.32
|
|
314
|
+
- Update `tsconfig.json` to put definitions in the root folder
|
|
315
|
+
> The app had an issue with AOT compilation because of this
|
|
316
|
+
|
|
317
|
+
##v1.0.31
|
|
318
|
+
- Fix `columnHandler.fetchItemTypeTranslations`
|
|
319
|
+
> It incorrectly looped over the response map, it should now work again
|
|
320
|
+
|
|
321
|
+
##v1.0.30
|
|
322
|
+
- Remove `updateTabParams` from LocalCacheManagerInterface
|
|
323
|
+
> The function wasn't used
|
|
324
|
+
|
|
325
|
+
- Reworked class export
|
|
326
|
+
> Imports are now done from @rentman/rm-core, old imports are broken. This is because the old export structure didn't always work
|
|
327
|
+
|
|
328
|
+
##v1.0.29
|
|
329
|
+
- Fix inverted inArray check in CollectionEntry.removeItems
|
|
330
|
+
> A delete message from the socket deleted all BUT the deleted items, this should now be fixed
|
|
331
|
+
|
|
332
|
+
##v1.0.28
|
|
333
|
+
Bug fixes only
|
|
334
|
+
|
|
335
|
+
##v1.0.27
|
|
336
|
+
- `ItemEntry.initial` is now undefined by default
|
|
337
|
+
> In the SocketMessageHandler we use this check to see if an ItemEntry is a stub
|
|
338
|
+
|
|
339
|
+
##v1.0.26
|
|
340
|
+
Bundle both minified and unminified code, include sourcemaps from dev build
|
|
341
|
+
|
|
342
|
+
##v1.0.24, v1.0.25
|
|
343
|
+
! Use version `v1.0.26` !
|
|
344
|
+
|
|
345
|
+
- The core now expects a `promiseInterface` that should implement the provided `promiseInterface`
|
|
346
|
+
> We need to be able to hook into the promises in order to call a digest cycle to update the ui in the frontend
|
|
347
|
+
|
|
348
|
+
- Rename `ItemEntry.entryId` to `ItemEntry.id
|
|
349
|
+
> It used to be called `id`, but it was changed in the seperation of the core.
|
|
350
|
+
> You can use the `id` to uniquely identify an entry, since itemId can be updated (local to saved id)
|
|
351
|
+
|
|
352
|
+
- Rename ItemResource `startTransaction` to `start`
|
|
353
|
+
> Other functions are called `commit` and `rollback` so having 'transaction' only for start doesn't make much sense
|
|
354
|
+
|
|
355
|
+
- `SocketMessageHandler.onMessageReceived` now returns a promise
|
|
356
|
+
> You can now use the updated items or hook into the result to update the ui for example
|
|
357
|
+
|
|
358
|
+
|
|
359
|
+
##v1.0.23
|
|
360
|
+
- Rename ResourceCache to LocalCache
|
|
361
|
+
> LocalCache only caches local items (name better reflects functionality)
|
|
362
|
+
|
|
363
|
+
- Remove getter/setter for hasChanges
|
|
364
|
+
> hasChanges is called in a digest loop in the frontend, so for performance reasons we don't want to recompute the value every time
|
|
365
|
+
|
|
366
|
+
- Remove `_getCollection` from ItemAdministrator
|
|
367
|
+
> `_getCollection` is now named `getCollection` and the old `getCollection` is removed. The query is part of the
|
|
368
|
+
> options and should not be given as a separate argument. This was included to support the frontend
|
|
369
|
+
|
|
370
|
+
- Remove `saveCurrentTab` from ItemAdministrator
|
|
371
|
+
> `saveCurrentTab` makes no sense because the core has no concept of tabs, you should use `saveCurrentLocalCache` instead
|
|
372
|
+
|
|
373
|
+
- Remove `getTabEntry` and `resetTabEntry` from ItemAdministrator
|
|
374
|
+
> `getTabEntry` and `resetTabEntry` make no sense because the core has no concept of tabs, you should use `getLocalCache` and `resetLocalCache` instead
|
|
375
|
+
|