@abaplint/transpiler 2.12.13 → 2.12.14

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.
@@ -2,27 +2,28 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.HandleEnqu = void 0;
4
4
  const chunk_1 = require("../chunk");
5
- // view, much like the tables
6
5
  class HandleEnqu {
7
6
  runObject(obj, _reg) {
8
7
  const filename = obj.getXMLFile()?.getFilename().replace(".xml", ".mjs").toLowerCase();
9
8
  if (filename === undefined) {
10
9
  return [];
11
10
  }
11
+ const tableName = obj.getPrimaryTable();
12
12
  const chunk = new chunk_1.Chunk().appendString(`// enqueue object
13
13
  abap.FunctionModules["ENQUEUE_${obj.getName().toUpperCase()}"] = async (INPUT) => {
14
14
  const lookup = abap.Classes["KERNEL_LOCK"];
15
15
  if (lookup === undefined) {
16
16
  throw new Error("Lock, kernel class missing");
17
17
  }
18
- await lookup.enqueue(INPUT);
18
+ await lookup.enqueue({TABLE_NAME: "${tableName}", ENQUEUE_NAME: "${obj.getName().toUpperCase()}", ...INPUT});
19
19
  };
20
+
20
21
  abap.FunctionModules["DEQUEUE_${obj.getName().toUpperCase()}"] = async (INPUT) => {
21
22
  const lookup = abap.Classes["KERNEL_LOCK"];
22
23
  if (lookup === undefined) {
23
24
  throw new Error("Lock, kernel class missing");
24
25
  }
25
- await lookup.dequeue(INPUT);
26
+ await lookup.dequeue({TABLE_NAME: "${tableName}", ENQUEUE_NAME: "${obj.getName().toUpperCase()}", ...INPUT});
26
27
  };`);
27
28
  const output = {
28
29
  object: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/transpiler",
3
- "version": "2.12.13",
3
+ "version": "2.12.14",
4
4
  "description": "Transpiler",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/src/index.d.ts",
@@ -29,7 +29,7 @@
29
29
  "author": "abaplint",
30
30
  "license": "MIT",
31
31
  "dependencies": {
32
- "@abaplint/core": "^2.114.4",
32
+ "@abaplint/core": "^2.114.5",
33
33
  "source-map": "^0.7.6"
34
34
  },
35
35
  "devDependencies": {