@live-change/relations-plugin 0.6.1 → 0.6.4

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/itemOfAny.js CHANGED
@@ -1,5 +1,5 @@
1
1
  const {
2
- defineAnyProperties, defineAnyIndex,
2
+ defineAnyProperties, defineAnyIndexes,
3
3
  processModelsAnyAnnotation
4
4
  } = require('./utilsAny.js')
5
5
 
@@ -18,7 +18,7 @@ module.exports = function(service, app) {
18
18
  context.reverseRelationWord = 'Owned'
19
19
 
20
20
  context.identifiers = defineAnyProperties(context.model, context.otherPropertyNames)
21
- defineAnyIndex(context.model, context.joinedOthersClassName, context.otherPropertyNames)
21
+ defineAnyIndexes(context.model, context.otherPropertyNames)
22
22
 
23
23
  if(config.sortBy) {
24
24
  for(const sortFields of config.sortBy) {
@@ -28,6 +28,7 @@ module.exports = function(service, app) {
28
28
 
29
29
  if(config.readAccess) {
30
30
  defineView(config, context)
31
+ // TODO: multiple views with all properties combinations
31
32
  }
32
33
  /// TODO: multiple views with limited fields
33
34
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@live-change/relations-plugin",
3
- "version": "0.6.1",
3
+ "version": "0.6.4",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -21,8 +21,8 @@
21
21
  "url": "https://www.viamage.com/"
22
22
  },
23
23
  "dependencies": {
24
- "@live-change/framework": "^0.6.1",
24
+ "@live-change/framework": "^0.6.4",
25
25
  "pluralize": "8.0.0"
26
26
  },
27
- "gitHead": "64a9e476bdeec727ff5b8bedbaef65078f1b32f2"
27
+ "gitHead": "7a2db2aaf4b35a65bbbe90a979eb08ae5f216cf8"
28
28
  }
package/propertyEvents.js CHANGED
@@ -45,7 +45,7 @@ function defineTransferredEvent(config, context, generateId) {
45
45
  ...properties.to,
46
46
  id: toId
47
47
  })
48
- await modelRunntime().delete(fromId)
48
+ await modelRuntime().delete(fromId)
49
49
  return toId
50
50
  }
51
51
  })
package/propertyOfAny.js CHANGED
@@ -1,5 +1,5 @@
1
1
  const {
2
- defineAnyProperties, defineAnyIndex, defineAnyIndexes,
2
+ defineAnyProperties, defineAnyIndexes,
3
3
  processModelsAnyAnnotation, generateAnyId
4
4
  } = require('./utilsAny.js')
5
5
 
@@ -27,7 +27,7 @@ function defineObjectView(config, context) {
27
27
  const viewProperties = {}
28
28
  for (let i = 0; i < others.length; i++) {
29
29
  viewProperties[otherPropertyNames[i]] = new PropertyDefinition({
30
- type: others[i],
30
+ type: 'String',
31
31
  validation: ['nonEmpty']
32
32
  })
33
33
  viewProperties[otherPropertyNames[i] + 'Type'] = new PropertyDefinition({
@@ -195,10 +195,10 @@ function defineResetAction(config, context) {
195
195
  service.actions[actionName] = new ActionDefinition({
196
196
  name: actionName,
197
197
  properties: {
198
- [modelPropertyName]: {
198
+ /*[modelPropertyName]: {
199
199
  type: model,
200
200
  validation: ['nonEmpty']
201
- },
201
+ },*/
202
202
  ...identifiers
203
203
  },
204
204
  access: config.resetAccess || config.writeAccess,