@nocobase/database 1.9.39 → 1.9.40

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.
@@ -61,7 +61,7 @@ const findFilterFieldType = /* @__PURE__ */ __name((ctx) => {
61
61
  }
62
62
  model = modelAssociation.target;
63
63
  }
64
- const collection = db.modelCollection.get(model);
64
+ const collection = db.getCollection(model.name);
65
65
  return collection.getField(fieldName);
66
66
  }, "findFilterFieldType");
67
67
  var empty_default = {
@@ -140,6 +140,7 @@ const _BelongsToManyRepository = class _BelongsToManyRepository extends import_m
140
140
  [import_sequelize.Op.in]: ids
141
141
  }
142
142
  },
143
+ individualHooks: true,
143
144
  transaction: transaction2
144
145
  });
145
146
  return true;
@@ -69,7 +69,7 @@ const _UpdateGuard = class _UpdateGuard {
69
69
  }
70
70
  setAssociationKeysToBeUpdate(associationKeysToBeUpdate) {
71
71
  if (this.action == "create") {
72
- this.associationKeysToBeUpdate = Object.keys(this.model.associations);
72
+ this.associationKeysToBeUpdate = (associationKeysToBeUpdate == null ? void 0 : associationKeysToBeUpdate.length) ? associationKeysToBeUpdate : Object.keys(this.model.associations);
73
73
  } else {
74
74
  this.associationKeysToBeUpdate = associationKeysToBeUpdate;
75
75
  }
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@nocobase/database",
3
- "version": "1.9.39",
3
+ "version": "1.9.40",
4
4
  "description": "",
5
5
  "main": "./lib/index.js",
6
6
  "types": "./lib/index.d.ts",
7
7
  "license": "AGPL-3.0",
8
8
  "dependencies": {
9
- "@nocobase/logger": "1.9.39",
10
- "@nocobase/utils": "1.9.39",
9
+ "@nocobase/logger": "1.9.40",
10
+ "@nocobase/utils": "1.9.40",
11
11
  "async-mutex": "^0.3.2",
12
12
  "chalk": "^4.1.1",
13
13
  "cron-parser": "4.4.0",
@@ -38,5 +38,5 @@
38
38
  "url": "git+https://github.com/nocobase/nocobase.git",
39
39
  "directory": "packages/database"
40
40
  },
41
- "gitHead": "34f2bbc1b54d52c90f7524730c4129efa6fa23cf"
41
+ "gitHead": "853abfb8a77683e1e7afdc80be1d49ae1cb5d769"
42
42
  }