@openinc/parse-server-opendash 4.0.5 → 4.0.8

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/README.md CHANGED
@@ -29,6 +29,3 @@ For a full list of options see the file at [CONFIG.md](https://github.com/open-i
29
29
  ## Development
30
30
 
31
31
  See the file at [DEVELOPMENT.md](https://github.com/open-inc/node-parse-server-opendash/blob/master/DEVELOPMENT.md)
32
-
33
-
34
- ##
@@ -71,6 +71,7 @@ async function init() {
71
71
  title: step.get("title"),
72
72
  fields: step.get("fields"),
73
73
  order: step.get("order"),
74
+ step: step,
74
75
  });
75
76
  const mediarelation = executionstep.relation("media");
76
77
  if (media !== undefined) {
@@ -1,6 +1,10 @@
1
1
  "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
2
5
  Object.defineProperty(exports, "__esModule", { value: true });
3
6
  exports.init = init;
7
+ const node_1 = __importDefault(require("parse/node"));
4
8
  const index_js_1 = require("../features/schema/index.js");
5
9
  const index_js_2 = require("../types/index.js");
6
10
  async function init() {
@@ -8,10 +12,15 @@ async function init() {
8
12
  const { object, original, user } = request;
9
13
  await (0, index_js_1.defaultHandler)(request);
10
14
  await (0, index_js_1.defaultAclHandler)(request);
11
- // TODO
15
+ if (object.get("order") === undefined || object.get("order") === null) {
16
+ const lastStep = await new node_1.default.Query(index_js_2.Maintenance_Schedule_Step)
17
+ .descending("order")
18
+ .first({ useMasterKey: true });
19
+ const lastOrder = lastStep ? lastStep.get("order") : 0;
20
+ object.set("order", lastOrder + 1);
21
+ }
12
22
  });
13
23
  (0, index_js_1.afterSaveHook)(index_js_2.Maintenance_Schedule_Step, async (request) => {
14
24
  const { object, original, user } = request;
15
- // TODO
16
25
  });
17
26
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openinc/parse-server-opendash",
3
- "version": "4.0.5",
3
+ "version": "4.0.8",
4
4
  "description": "Parse Server Cloud Code for open.INC Stack.",
5
5
  "packageManager": "pnpm@10.32.1",
6
6
  "keywords": [
@@ -71,11 +71,11 @@
71
71
  "cron": "^4.4.0",
72
72
  "dayjs": "^1.11.20",
73
73
  "fast-equals": "^6.0.0",
74
- "i18next": "^25.8.20",
74
+ "i18next": "^25.10.9",
75
75
  "i18next-fs-backend": "^2.6.1",
76
76
  "jsonwebtoken": "^9.0.3",
77
77
  "jwks-rsa": "^4.0.1",
78
- "nodemailer": "^8.0.3",
78
+ "nodemailer": "^8.0.4",
79
79
  "nunjucks": "^3.2.4",
80
80
  "parse": "^8.5.0",
81
81
  "parse-server": "9.6.1",
@@ -103,7 +103,7 @@
103
103
  "concurrently": "^9.2.1",
104
104
  "semantic-release-export-data": "^1.2.0",
105
105
  "ts-node": "^10.9.2",
106
- "typedoc": "^0.28.17",
106
+ "typedoc": "^0.28.18",
107
107
  "typedoc-plugin-markdown": "^4.11.0",
108
108
  "typescript": "^5.9.3"
109
109
  }