@erxes/plugin-sdk 0.1.0-v2.11 → 0.1.0-v2.12

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.
Files changed (2) hide show
  1. package/dist/index.d.ts +3 -1
  2. package/package.json +2 -2
package/dist/index.d.ts CHANGED
@@ -32,7 +32,9 @@
32
32
  * Branches and departments (scopes `units:read`, `units:write`; subscribe to `core.unit.*`): core's,
33
33
  * shared by plugins. Keep a read-only copy for your own visibility queries and refresh it whenever
34
34
  * a `core.unit.*` event arrives (the event names the unit in `entityId`); bring your old units in
35
- * once with `units.import`, which keeps their ids and answers where each one went.
35
+ * once with `units.import`, which keeps their ids and answers where each one went. Each unit has a
36
+ * `typeId`, one of the organisation's `unitTypes` of its kind (Branch and Department to start);
37
+ * bring your own types first with `unitTypes.import` and name them on the units you import.
36
38
  *
37
39
  * const { data } = await core.forOrg(orgId).units.list({}); // every unit, parents first, with memberIds
38
40
  * const { ids } = await core.forOrg(orgId).units.import({ units: [{ id, kind: 'branch', name, memberIds }] });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@erxes/plugin-sdk",
3
- "version": "0.1.0-v2.11",
3
+ "version": "0.1.0-v2.12",
4
4
  "private": false,
5
5
  "description": "For erxes plugin servers: a typed core client with automatic plugin tokens, verification of members' plugin session tokens and of core's deliveries, and plugin jobs",
6
6
  "license": "AGPL-3.0-only",
@@ -33,7 +33,7 @@
33
33
  "@orpc/openapi-client": "1.16.2",
34
34
  "jose": "^6.2.17",
35
35
  "zod": "^4.6.7",
36
- "@erxes/core-contract": "0.1.0-v2.12"
36
+ "@erxes/core-contract": "0.1.0-v2.14"
37
37
  },
38
38
  "devDependencies": {
39
39
  "drizzle-orm": "0.45.4"