cxtms 1.9.40 → 1.9.42
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/package.json
CHANGED
|
@@ -49,6 +49,10 @@ Use `--feature <feature_name>` with `cx-cli create` to automatically place files
|
|
|
49
49
|
!cat skills/cxtms-developer/ref-entity-shared.md
|
|
50
50
|
!cat skills/cxtms-developer/ref-entity-geography.md
|
|
51
51
|
|
|
52
|
+
### Equipment & Fleet
|
|
53
|
+
|
|
54
|
+
!cat skills/cxtms-developer/ref-entity-equipment.md
|
|
55
|
+
|
|
52
56
|
### Warehouse & Inventory
|
|
53
57
|
|
|
54
58
|
!cat skills/cxtms-developer/ref-entity-warehouse.md
|
|
@@ -65,6 +69,7 @@ Use `--feature <feature_name>` with `cx-cli create` to automatically place files
|
|
|
65
69
|
| **Pricing** | Rate, Lane, Discount, AccountingItem, AccountingAccount, PaymentTerm | ref-entity-rate.md |
|
|
66
70
|
| **Shared** | Tag, Attachment, Division, EquipmentType, PackageType, Note/NoteThread | ref-entity-shared.md |
|
|
67
71
|
| **Geography** | Country, State, City, Port, Vessel, CustomCode, ModeOfTransportation | ref-entity-geography.md |
|
|
72
|
+
| **Equipment** | Equipment, EquipmentStatus | ref-entity-equipment.md |
|
|
68
73
|
| **Warehouse** | InventoryItem, WarehouseLocation, CargoMovement (Order variant) | ref-entity-warehouse.md |
|
|
69
74
|
| **Notification** | Notification, UserNotification | ref-entity-notification.md |
|
|
70
75
|
|
|
@@ -87,7 +92,9 @@ Most entities have `customValues` — a `Dictionary<string, object?>` stored as
|
|
|
87
92
|
|
|
88
93
|
**Lookup entities**: Job, JobStatus, Tag, Attachment, EventDefinition, Rate, Lane, Discount, AccountingItem, Port, Country, State, City, ModeOfTransportation
|
|
89
94
|
|
|
90
|
-
**
|
|
95
|
+
**Fleet**: Equipment (replace semantics — null clears, non-null full-replaces)
|
|
96
|
+
|
|
97
|
+
**Without customValues**: Division, EquipmentType, EquipmentStatus, PackageType, Vessel, CustomCode, AccountingAccount, PaymentTerm, WarehouseLocation, JobOrder
|
|
91
98
|
|
|
92
99
|
### Audit Fields (AuditableEntity)
|
|
93
100
|
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# Equipment Entity Reference
|
|
2
|
+
|
|
3
|
+
## Contents
|
|
4
|
+
- Equipment
|
|
5
|
+
- EquipmentStatus
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Equipment
|
|
10
|
+
|
|
11
|
+
Physical equipment/fleet units (trucks, trailers, etc.).
|
|
12
|
+
|
|
13
|
+
| Field | Type | Notes |
|
|
14
|
+
|-------|------|-------|
|
|
15
|
+
| `equipmentId` | `int` | PK |
|
|
16
|
+
| `organizationId` | `int` | |
|
|
17
|
+
| `unitNumber` | `string` | Max 50 chars |
|
|
18
|
+
| `equipmentTypeId` | `int` | FK to EquipmentType |
|
|
19
|
+
| `equipmentStatusId` | `int` | FK to EquipmentStatus |
|
|
20
|
+
| `notes` | `string?` | Max 700 chars |
|
|
21
|
+
| `customValues` | `Dictionary?` | jsonb — replace semantics (null clears, otherwise full-replace) |
|
|
22
|
+
| `isDeleted` | `bool` | Soft delete |
|
|
23
|
+
|
|
24
|
+
**Navigation:** `organization`, `equipmentType`, `equipmentStatus`
|
|
25
|
+
|
|
26
|
+
**Audit fields:** `created`, `createdBy`, `lastModified`, `lastModifiedBy`, `createdUser`, `updatedUser`
|
|
27
|
+
|
|
28
|
+
### customValues Behavior
|
|
29
|
+
|
|
30
|
+
Equipment uses **replace semantics** (not merge). Sending `null` clears the dictionary entirely; sending a non-null dictionary replaces it completely. This differs from most other entities that use merge semantics.
|
|
31
|
+
|
|
32
|
+
### GraphQL
|
|
33
|
+
|
|
34
|
+
- `equipmentId`, `unitNumber`, `equipmentTypeId`, `equipmentStatusId`, `notes`, `customValues`, `isDeleted`
|
|
35
|
+
- `equipmentType` — expanded `EquipmentType` object
|
|
36
|
+
- `equipmentStatus` — expanded `EquipmentStatus` object
|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
## EquipmentStatus
|
|
41
|
+
|
|
42
|
+
Configurable statuses for equipment units.
|
|
43
|
+
|
|
44
|
+
| Field | Type | Notes |
|
|
45
|
+
|-------|------|-------|
|
|
46
|
+
| `equipmentStatusId` | `int` | PK |
|
|
47
|
+
| `organizationId` | `int` | |
|
|
48
|
+
| `statusName` | `string` | Max 50 chars |
|
|
49
|
+
| `statusDescription` | `string?` | Max 255 chars |
|
|
50
|
+
| `statusStage` | `EquipmentStatusStage` enum | Lifecycle stage |
|
|
51
|
+
| `priority` | `int` | Sort order |
|
|
52
|
+
| `color` | `string?` | Hex color code, max 32 chars |
|
|
53
|
+
|
|
54
|
+
**Audit fields:** `created`, `createdBy`, `lastModified`, `lastModifiedBy`, `createdUser`, `updatedUser`
|
|
55
|
+
|
|
56
|
+
No customValues.
|
|
57
|
+
|
|
58
|
+
### EquipmentStatusStage Enum
|
|
59
|
+
|
|
60
|
+
`EquipmentStatusStage` — represents the lifecycle stage of an equipment status. Values defined in `TMS.Domain.Enums`.
|
|
61
|
+
|
|
62
|
+
### GraphQL
|
|
63
|
+
|
|
64
|
+
- `equipmentStatusId`, `statusName`, `statusDescription`, `statusStage`, `priority`, `color`
|
|
@@ -101,7 +101,8 @@ Functions use two iterator variable names:
|
|
|
101
101
|
| `now('yyyy-MM-dd', 'en-US')` | Formatted current time as string |
|
|
102
102
|
| `addDays([date], 30)` | Add days (decimal, can be negative). Accepts DateTime, DateTimeOffset, string |
|
|
103
103
|
| `addHours([date], 2)` | Add hours (decimal, can be negative). Same type handling |
|
|
104
|
-
| `formatDate([date], 'dd/MM/yyyy'
|
|
104
|
+
| `formatDate([date], 'dd/MM/yyyy')` | Format date using InvariantCulture (culture optional). Returns `null` for null or unparseable input. Accepts `DateTime`, `DateTimeOffset`, or string (including `DateTimeOffset`-shaped strings from `toLocalTime`) |
|
|
105
|
+
| `formatDate([date], 'dd/MM/yyyy', 'en-US')` | Format date with explicit culture |
|
|
105
106
|
| `dateFromUnix([unixTime])` | Unix timestamp (seconds) -> `DateTimeOffset`. Accepts int, long, decimal, string |
|
|
106
107
|
| `dateToUtc([date])` or `dateToUtc([date], 'en-US')` | Convert to UTC. Optional culture for string parsing |
|
|
107
108
|
| `toLocalTime([date], 'America/Chicago')` | Convert UTC datetime to local time in IANA timezone. Returns `null` if date or timezone is invalid |
|