mirror of
https://github.com/Spythere/station-manager-2.0.git
synced 2026-05-03 13:38:13 +00:00
zmiana endpointów; poprawki designu
This commit is contained in:
+4
-13
@@ -8,11 +8,10 @@
|
||||
import { defineComponent } from 'vue';
|
||||
import PopUpCard from './components/PopUpCard.vue';
|
||||
import { RouterView } from 'vue-router';
|
||||
import { AuthState } from './types/types';
|
||||
import { baseURL, useStore } from './store';
|
||||
import { useStore } from './store';
|
||||
import useLocalStorage from './mixins/useLocalStorage';
|
||||
import axios from 'axios';
|
||||
import { IUser } from './types/types';
|
||||
import client from './common/http';
|
||||
|
||||
export default defineComponent({
|
||||
components: { PopUpCard },
|
||||
@@ -33,14 +32,7 @@ export default defineComponent({
|
||||
try {
|
||||
this.tokenLoading = true;
|
||||
|
||||
const response = await axios.post<IUser>(
|
||||
'/auth/token',
|
||||
{},
|
||||
{
|
||||
baseURL,
|
||||
withCredentials: true,
|
||||
}
|
||||
);
|
||||
const response = await client.post<IUser>('/auth/token');
|
||||
|
||||
this.store.setUserData(response.data);
|
||||
this.$router.push('/');
|
||||
@@ -96,7 +88,7 @@ button {
|
||||
outline: none;
|
||||
border: none;
|
||||
|
||||
background-color: #000000;
|
||||
background-color: #0066ff;
|
||||
color: white;
|
||||
|
||||
padding: 0.5rem 0.75rem;
|
||||
@@ -164,4 +156,3 @@ button {
|
||||
background: #aaa;
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user