feat(assets): add licence section (vendor, seat count, expiry) to CMDB (PMS-454) #376

Merged
Claude-Run merged 1 commit from feat/PMS-454-asset-license-fields into main 2026-06-26 12:08:16 +02:00
Member

Manual QA expanded the PMS-454 CMDB scope (issue comment) to include a per-asset licence section. The earlier CMDB-expansion work (063, commit 6691ce8) already shipped the other QA-requested fields (assigned user, IP, hostname, MAC, installed date, department, in-transit ticket) and the dependency/impact-map endpoints already satisfy the remaining acceptance criteria; the licence section was the one outstanding item. The warranty-expiry auto-tag is explicitly "filed separately" and the richer CI-type taxonomy lives in a sibling ticket, so both stay out of scope here.

Adds three nullable flat columns on assets (migration 080), mirroring how 063 added the rest of the CMDB fields rather than introducing a side table: license_vendor VARCHAR(150), license_seat_count INTEGER (CHECK >= 0), license_expiry DATE, plus a partial index on (tenant_id, license_expiry) for the "licences lapsing soon" filter. Threads the three fields through AssetResponse, CreateAssetRequest, and UpdateAssetRequest (seat count validated non-negative, vendor capped at 150 chars), the list/get SELECTs, the create INSERT, the update UPDATE (COALESCE so a partial PUT leaves untouched columns alone), and the AssetRow row mapping.

#PMS-454

Manual QA expanded the PMS-454 CMDB scope (issue comment) to include a per-asset licence section. The earlier CMDB-expansion work (063, commit 6691ce8) already shipped the other QA-requested fields (assigned user, IP, hostname, MAC, installed date, department, in-transit ticket) and the dependency/impact-map endpoints already satisfy the remaining acceptance criteria; the licence section was the one outstanding item. The warranty-expiry auto-tag is explicitly "filed separately" and the richer CI-type taxonomy lives in a sibling ticket, so both stay out of scope here. Adds three nullable flat columns on `assets` (migration 080), mirroring how 063 added the rest of the CMDB fields rather than introducing a side table: license_vendor VARCHAR(150), license_seat_count INTEGER (CHECK >= 0), license_expiry DATE, plus a partial index on (tenant_id, license_expiry) for the "licences lapsing soon" filter. Threads the three fields through AssetResponse, CreateAssetRequest, and UpdateAssetRequest (seat count validated non-negative, vendor capped at 150 chars), the list/get SELECTs, the create INSERT, the update UPDATE (COALESCE so a partial PUT leaves untouched columns alone), and the AssetRow row mapping. #PMS-454
feat(assets): add licence section (vendor, seat count, expiry) to CMDB (PMS-454)
All checks were successful
E2E / Playwright against staging (pull_request) Successful in 1m57s
Check / fmt + clippy + build + tests (pull_request) Successful in 2m58s
Integration / integration tests (pull_request) Successful in 9m5s
Create release / Gate (release-branch merges only) (pull_request) Successful in 1s
Create release / Create release from merged PR (pull_request) Has been skipped
c3b4f31294
Manual QA expanded the PMS-454 CMDB scope (issue comment) to include a per-asset licence section. The earlier CMDB-expansion work (063, commit 6691ce8) already shipped the other QA-requested fields (assigned user, IP, hostname, MAC, installed date, department, in-transit ticket) and the dependency/impact-map endpoints already satisfy the remaining acceptance criteria; the licence section was the one outstanding item. The warranty-expiry auto-tag is explicitly "filed separately" and the richer CI-type taxonomy lives in a sibling ticket, so both stay out of scope here.

Adds three nullable flat columns on `assets` (migration 080), mirroring how 063 added the rest of the CMDB fields rather than introducing a side table: license_vendor VARCHAR(150), license_seat_count INTEGER (CHECK >= 0), license_expiry DATE, plus a partial index on (tenant_id, license_expiry) for the "licences lapsing soon" filter. Threads the three fields through AssetResponse, CreateAssetRequest, and UpdateAssetRequest (seat count validated non-negative, vendor capped at 150 chars), the list/get SELECTs, the create INSERT, the update UPDATE (COALESCE so a partial PUT leaves untouched columns alone), and the AssetRow row mapping.

#PMS-454
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
psa-systems/mokosh-server!376
No description provided.