♻️ Refactor urls with aliased services
This commit is contained in:
		| @@ -47,7 +47,7 @@ async function submit() { | ||||
|   if (!probe.value || !password.value) return | ||||
|  | ||||
|   emits("update:loading", true) | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/auth/auth`, { | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/id/auth`, { | ||||
|     method: "POST", | ||||
|     headers: { "Content-Type": "application/json" }, | ||||
|     body: JSON.stringify({ username: probe.value, password: password.value }), | ||||
|   | ||||
| @@ -36,7 +36,7 @@ async function load() { | ||||
| onMounted(() => load()) | ||||
|  | ||||
| async function getToken(tk: string) { | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/auth/auth/token`, { | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/id/auth/token`, { | ||||
|     method: "POST", | ||||
|     headers: { "Content-Type": "application/json" }, | ||||
|     body: JSON.stringify({ | ||||
|   | ||||
| @@ -58,7 +58,7 @@ const emits = defineEmits(["swap", "update:ticket", "update:loading"]) | ||||
|  | ||||
| async function submit() { | ||||
|   emits("update:loading", true) | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/auth/auth/mfa`, { | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/id/auth/mfa`, { | ||||
|     method: "POST", | ||||
|     headers: { "Content-Type": "application/json" }, | ||||
|     body: JSON.stringify({ | ||||
|   | ||||
| @@ -44,7 +44,7 @@ const emits = defineEmits(["swap", "update:loading", "update:currentFactor"]) | ||||
|  | ||||
| async function load() { | ||||
|   emits("update:loading", true) | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/auth/auth/factors?ticketId=${props.ticket.id}`) | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/id/auth/factors?ticketId=${props.ticket.id}`) | ||||
|   if (res.status !== 200) { | ||||
|     error.value = await res.text() | ||||
|   } else { | ||||
| @@ -59,7 +59,7 @@ async function submit() { | ||||
|   if (!focus.value) return | ||||
|  | ||||
|   emits("update:loading", true) | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/auth/auth/factors/${focus.value}`, { | ||||
|   const res = await fetch(`${config.public.solarNetworkApi}/cgi/id/auth/factors/${focus.value}`, { | ||||
|     method: "POST", | ||||
|   }) | ||||
|   if (res.status !== 200 && res.status !== 204) { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user