CASH-2867 add device id for logging
CASH-2867 add device id for logging. If there are errors in the log prior to being assigned a referral sequence number, we have no easy way to tie the error back to a user/session.
This commit is contained in:
parent
bf0e3bd876
commit
6398221d2b
2 changed files with 3 additions and 0 deletions
|
|
@ -7,4 +7,5 @@ export const headerKeys = {
|
|||
EON: "X-Enterprise-Order-Number",
|
||||
LOG_ENABLED: "log-enabled",
|
||||
PAGE_NAME_TO_LOG: "X-Page-Name-To-Log",
|
||||
DEVICE_ID: "X-Device-Id",
|
||||
};
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ import { getSessionKeyValue } from "@/helpers/heritage-integration/cookie-helper
|
|||
import { headerKeys } from "@/constants/header-keys";
|
||||
import axiosResponseInterceptorMessages from "@/constants/axios-response-interceptor-messages.js";
|
||||
import { endpoints } from "@/constants/endpoints";
|
||||
import { getDeviceIdValue } from "@/helpers/heritage-integration/cookie-helper";
|
||||
|
||||
// Add a response interceptor for global axios error handing.
|
||||
axios.interceptors.response.use(
|
||||
|
|
@ -73,6 +74,7 @@ export default {
|
|||
[headerKeys.TRANSACTION_ID]: crypto.randomUUID(),
|
||||
[headerKeys.EON]: order?.eon,
|
||||
[headerKeys.LOG_ENABLED]: store.getters.applicationUser?.loggingOption ?? false,
|
||||
[headerKeys.DEVICE_ID]: getDeviceIdValue(),
|
||||
};
|
||||
|
||||
axios({
|
||||
|
|
|
|||
Loading…
Reference in a new issue