trm-core 9.10.2 → 9.10.3

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/changelog.txt CHANGED
@@ -8,6 +8,11 @@ Legend
8
8
  + : added
9
9
  - : removed
10
10
 
11
+ 2026-07-29 v9.10.3
12
+ -------------------
13
+ * rest refresh transport desc in tms
14
+ * rest read transport status
15
+
11
16
  2026-07-29 v9.10.2
12
17
  -------------------
13
18
  * rest delete from tms
@@ -558,8 +558,10 @@ class RESTClient {
558
558
  }
559
559
  refreshTransportTmsTxt(trkorr) {
560
560
  return __awaiter(this, void 0, void 0, function* () {
561
- yield this._axiosInstance.post('/refresh_tms_transport_txt', {
562
- trkorr
561
+ yield this._axiosInstance.delete('/refresh_tms_transport_txt', {
562
+ data: {
563
+ trkorr
564
+ }
563
565
  });
564
566
  });
565
567
  }
@@ -23,16 +23,17 @@ function fromAbapToDateLegacy(as4date, as4time) {
23
23
  const seconds = parseInt(`${aTime[4]}${aTime[5]}`);
24
24
  return new Date(year, month, day, hour, minutes, seconds);
25
25
  }
26
+ function parseDate(as4date, as4time, ianaZone) {
27
+ const abapDateTime = luxon_1.DateTime.fromFormat(`${as4date} ${as4time}`, "yyyyMMdd HHmmss", { zone: ianaZone });
28
+ if (abapDateTime.isValid) {
29
+ return abapDateTime;
30
+ }
31
+ return luxon_1.DateTime.fromISO(`${as4date}T${as4time}`, { zone: ianaZone });
32
+ }
26
33
  function fromAbapToDate(as4date, as4time) {
27
34
  return __awaiter(this, void 0, void 0, function* () {
28
35
  const ianaZone = yield systemConnector_1.SystemConnector.getTimezone();
29
- const year = Number(as4date.slice(0, 4));
30
- const month = Number(as4date.slice(4, 6));
31
- const day = Number(as4date.slice(6, 8));
32
- const hour = Number(as4time.slice(0, 2));
33
- const minute = Number(as4time.slice(2, 4));
34
- const second = Number(as4time.slice(4, 6));
35
- const dt = luxon_1.DateTime.fromObject({ year, month, day, hour, minute, second }, { zone: ianaZone });
36
+ const dt = parseDate(as4date, as4time, ianaZone);
36
37
  if (!dt.isValid) {
37
38
  return fromAbapToDateLegacy(as4date, as4time);
38
39
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "trm-core",
3
- "version": "9.10.2",
3
+ "version": "9.10.3",
4
4
  "description": "TRM (Transport Request Manager) Core",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",