From 0509e123e7e72aae5f6277edfee896e9039bf5c6 Mon Sep 17 00:00:00 2001 From: John Pinkyfloyd Date: Mon, 9 Feb 2026 11:25:22 -0800 Subject: [PATCH] Add BeaconMinor support to servicepoints API Allow setting/reading BeaconMinor on service points for beacon sharding table assignment. Also fixes bug where save.cfm referenced qOut.ServicePointID instead of qOut.ID. Co-Authored-By: Claude Opus 4.5 --- api/servicepoints/list.cfm | 6 ++++-- api/servicepoints/save.cfm | 16 ++++++++++++---- 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/api/servicepoints/list.cfm b/api/servicepoints/list.cfm index 094940f..752c0e2 100644 --- a/api/servicepoints/list.cfm +++ b/api/servicepoints/list.cfm @@ -58,7 +58,8 @@ if (structKeyExists(data, "onlyActive")) { Code, Description, SortOrder, - IsActive + IsActive, + BeaconMinor FROM ServicePoints WHERE BusinessID = @@ -76,7 +77,8 @@ if (structKeyExists(data, "onlyActive")) { "Code" = q.Code, "Description" = q.Description, "SortOrder" = q.SortOrder, - "IsActive" = q.IsActive + "IsActive" = q.IsActive, + "BeaconMinor" = val(q.BeaconMinor) })> diff --git a/api/servicepoints/save.cfm b/api/servicepoints/save.cfm index 4a49ce2..e23fdc1 100644 --- a/api/servicepoints/save.cfm +++ b/api/servicepoints/save.cfm @@ -47,6 +47,7 @@ spName = normStr(data.Name); spCode = structKeyExists(data, "Code") ? normStr(data.Code) : ""; spTypeID = structKeyExists(data, "TypeID") && isNumeric(data.TypeID) ? int(data.TypeID) : 1; sortOrder = structKeyExists(data, "SortOrder") && isNumeric(data.SortOrder) ? int(data.SortOrder) : 0; +beaconMinor = structKeyExists(data, "BeaconMinor") && isNumeric(data.BeaconMinor) ? int(data.BeaconMinor) : -1; isActive = 1; if (structKeyExists(data, "IsActive")) { @@ -65,7 +66,10 @@ if (structKeyExists(data, "IsActive")) { Code = , TypeID = , IsActive = , - SortOrder = + SortOrder = + + , BeaconMinor = + WHERE ID = AND BusinessID = @@ -94,6 +98,7 @@ if (structKeyExists(data, "IsActive")) { TypeID, IsActive, SortOrder + , BeaconMinor ) VALUES ( , , @@ -101,6 +106,7 @@ if (structKeyExists(data, "IsActive")) { , , + , ) @@ -119,7 +125,8 @@ if (structKeyExists(data, "IsActive")) { Code, TypeID, IsActive, - SortOrder + SortOrder, + BeaconMinor FROM ServicePoints WHERE ID = AND BusinessID = @@ -127,13 +134,14 @@ if (structKeyExists(data, "IsActive")) { #serializeJSON({ OK=true, ERROR="", SERVICEPOINT=servicePoint })#