Skip to content

Commit

Permalink
Merge pull request #29 from pknu-wap/develop
Browse files Browse the repository at this point in the history
[release] v0.1.1 배포
  • Loading branch information
wkdghdwns199 authored Sep 13, 2024
2 parents 95a2075 + 12324d3 commit 56a71f0
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 16 deletions.
32 changes: 17 additions & 15 deletions client/src/api/sendToServer.ts
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
import axios, {AxiosResponse} from "axios";
import {studentQr} from "../types/QrType/StudentQr";
import axios, {AxiosResponse} from 'axios';
import {studentQr} from '../types/QrType/StudentQr';

interface ServerResponse {
message: string | null;
message: string | null;
}

export const sendToServer = (data: studentQr): Promise<AxiosResponse<ServerResponse>> => {
return axios
.post("http://34.47.97.81:8080/api/events/check-in",data)
.then((res) => {
console.log(res);
return res;
})
.catch((error) => {
console.log(error);
throw error;
})
}
export const sendToServer = (
data: studentQr,
): Promise<AxiosResponse<ServerResponse>> => {
return axios
.post('https://zepelown.site/api/events/check-in', data)
.then(res => {
console.log(res);
return res;
})
.catch(error => {
console.log(error);
throw error;
});
};
2 changes: 1 addition & 1 deletion client/src/hooks/useCheckInStudent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const useCheckInStudent = (eventId: string) => {

const LoadCheckInStudent = () => {
axios
.get(`http://34.47.97.81:8080/api/events/check-in/${eventId}?filter=ALL`)
.get(`https://zepelown.site/api/events/check-in/${eventId}?filter=ALL`)
.then(res => {
const CleanedData = res.data.data;

Expand Down

0 comments on commit 56a71f0

Please sign in to comment.