- {{ priorityWaitTime }}
+ {{ getPriorityWaitTime }}
- {{ regularWaitTime }}
+ {{ getRegularWaitTime }}
Days
@@ -106,6 +106,8 @@ import NamexServices from '@/services/namex-services'
export default class Stats extends Vue {
@Getter(useStore) getStats!: StatsI
@Getter(useStore) isMobile!: boolean
+ @Getter(useStore) getRegularWaitTime!: string | number
+ @Getter(useStore) getPriorityWaitTime!: string | number
@Action(useStore) setStats!: ActionBindingIF
@@ -134,43 +136,13 @@ export default class Stats extends Vue {
return (this.getStats?.auto_approved_count ?? '-')
}
- /** The regular wait time, in days. */
- get regularWaitTime (): string | number {
- const flagVal = GetFeatureFlag('hardcoded_regular_wait_time')
-
- if (flagVal > 0) return flagVal
- if (flagVal < 0) return '-'
-
- const statVal = this.getStats?.regular_wait_time
- if (statVal > 0) {
- return statVal
- }
-
- return '-'
- }
-
- /** The priority wait time, in days. */
- get priorityWaitTime (): string | number {
- const flagVal = GetFeatureFlag('hardcoded_priority_wait_time')
-
- if (flagVal > 0) return flagVal
- if (flagVal < 0) return '-'
-
- const statVal = this.getStats?.priority_wait_time
- if (statVal > 0) {
- return statVal
- }
-
- return '-'
- }
-
get showRegularTooltip (): boolean {
- const val = Number(this.regularWaitTime)
+ const val = Number(this.getRegularWaitTime)
return Number.isFinite(val) && val > 0
}
get showPriorityTooltip (): boolean {
- const val = Number(this.priorityWaitTime)
+ const val = Number(this.getPriorityWaitTime)
return Number.isFinite(val) && val > 0
}
}
diff --git a/app/src/store/getters.ts b/app/src/store/getters.ts
index 0d631b929..b1c3eb325 100644
--- a/app/src/store/getters.ts
+++ b/app/src/store/getters.ts
@@ -58,6 +58,7 @@ import {
RequestActions,
XproMapping
} from '@/list-data'
+import { GetFeatureFlag } from '@/plugins/launchDarkly'
export const isMobile = (state: StateIF): boolean => {
// fall back to base window width if no window size changes have occurred
@@ -1318,3 +1319,23 @@ export const getSearchRequest = (state: StateIF): RequestActionsI => {
export const getBusinessAccountId = (state: StateIF): string => {
return state.newRequestModel.businessAccountId
}
+
+export const getPriorityWaitTime = (state: StateIF): string | number => {
+ const flagVal = GetFeatureFlag('hardcoded_priority_wait_time')
+ if (flagVal > 0) return flagVal
+ if (flagVal < 0) return '-'
+
+ const statVal = getStats(state)?.priority_wait_time
+ if (statVal > 0) return statVal
+ return '-'
+}
+
+export const getRegularWaitTime = (state: StateIF): string | number => {
+ const flagVal = GetFeatureFlag('hardcoded_regular_wait_time')
+ if (flagVal > 0) return flagVal
+ if (flagVal < 0) return '-'
+
+ const statVal = getStats(state)?.regular_wait_time
+ if (statVal > 0) return statVal
+ return '-'
+}
From 67dc3226e56ec3d8010b7a3a6e0b6f6ba87a3a01 Mon Sep 17 00:00:00 2001
From: eve-git <54647458+eve-git@users.noreply.github.com>
Date: Tue, 25 Nov 2025 11:09:34 -0800
Subject: [PATCH 2/2] Remove unnecessary newline in stats.vue
---
app/src/components/new-request/stats.vue | 1 -
1 file changed, 1 deletion(-)
diff --git a/app/src/components/new-request/stats.vue b/app/src/components/new-request/stats.vue
index 1e4dd9c7e..90092cffb 100644
--- a/app/src/components/new-request/stats.vue
+++ b/app/src/components/new-request/stats.vue
@@ -145,7 +145,6 @@ export default class Stats extends Vue {
const val = Number(this.getPriorityWaitTime)
return Number.isFinite(val) && val > 0
}
-
}