refactor(timereg): stop writing per-site GpsEnabled (now global-only)#1021
Merged
Conversation
GpsEnabled (and SnapshotEnabled) are served from the TimePlanning global settings, so the device-user flow no longer writes a per-site GpsEnabled on AssignedSite. Removes the writes in UpdateDeviceUser (existing-row update + new-assignment initializer) and the now-unused global GPS-setting fetch. UseOneMinuteIntervals (a real per-site flag) is unchanged. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
This PR updates the BackendConfiguration plugin’s device-user update flow to align with the refactor that makes GPS (and Snapshot) settings global-only (served from TimePlanning global settings), by removing now-redundant per-site GpsEnabled writes.
Changes:
- Removed the
TimePlanningBaseSettings:GpsEnabledglobal-setting fetch that was only used to drive per-site writes. - Removed per-site
AssignedSite.GpsEnabledupdates for both existing assignment updates and new assignment creation. - Kept
UseOneMinuteIntervals = true(a legitimate per-site flag) unchanged for newly createdAssignedSiterecords.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of making GPS/Snapshot global-only settings (served from TimePlanning global settings). This removes the now-pointless per-site
GpsEnabledwrites in the device-user flow:UpdateDeviceUserexisting-row update: droppedassignment.GpsEnabled = …UpdateDeviceUsernew-AssignedSiteinitializer: droppedGpsEnabled = …(keptUseOneMinuteIntervals = true)SnapshotEnabledwas never written here.UseOneMinuteIntervals(a legitimate per-site flag) is unchanged.🤖 Generated with Claude Code