Client Auth endpoint logic, first run.

This commit is contained in:
Jeremy Zimmerman 2023-02-16 14:53:31 -05:00
parent c38389abd4
commit fcf620eecd
3 changed files with 14 additions and 7 deletions

View file

@ -91,7 +91,7 @@ const endpoints = {
url: "https://maps.googleapis.com/maps/api/js?key={apiKey}&libraries=places" url: "https://maps.googleapis.com/maps/api/js?key={apiKey}&libraries=places"
}, },
ValidateClientTag: { ValidateClientTag: {
url: "/clientauth/api/v1/validateClientTag", url: "/clientauth/api/v1/clientauth/validateClientTag",
method: "GET", method: "GET",
}, },
}; };

View file

@ -4,10 +4,17 @@ export function validateISSClientTag(clientTag) {
const store = useMainStore() const store = useMainStore()
const clientName = store.issConfig.clientName; const clientName = store.issConfig.clientName;
const resp = store.validateClientTag(clientTag); store.validateClientTag(clientTag)
.then(
console.log(resp); (response) => {
// Success
console.log(response);
},
(error) => {
// Error
console.log("error: " + error);
}
);
return true; return true;
}; };

View file

@ -893,10 +893,10 @@ export const useMainStore = defineStore({
}); });
}, },
validateClientTag({ clientTag }) { validateClientTag(clientTag) {
return globalMethods.callHttpClient({ return globalMethods.callHttpClient({
methods: endpoints.ValidateClientTag.method, methods: endpoints.ValidateClientTag.method,
endpoint: `${endpoints.ValidateClientTag.url}/${"asdf"}`, endpoint: `${endpoints.ValidateClientTag.url}/${clientTag}`,
}); });
}, },