Skip to content

Commit 10c2177

Browse files
committed
Merge branch 'develop' of https://github.com/devpalsPlus/frontend into feat/#348
2 parents 74f82c6 + 453a09e commit 10c2177

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+995
-122
lines changed
File renamed without changes.
File renamed without changes.

src/api/admin/tag.api.ts

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
import type { ApiCommonBasicType } from '../../models/apiCommon';
2+
import type { TagFormType } from '../../models/tags';
3+
import { httpClient } from '../http.api';
4+
5+
export const postSkillTag = async (formData: FormData) => {
6+
try {
7+
await httpClient.post<ApiCommonBasicType>(`/skill-tag`, formData);
8+
} catch (e) {
9+
console.error(e);
10+
throw e;
11+
}
12+
};
13+
14+
export const putSkillTag = async ({
15+
formData,
16+
id,
17+
}: {
18+
formData: FormData;
19+
id: number;
20+
}) => {
21+
try {
22+
await httpClient.put<ApiCommonBasicType>(`/skill-tag/${id}`, formData);
23+
} catch (e) {
24+
console.error(e);
25+
throw e;
26+
}
27+
};
28+
29+
export const deleteSkillTag = async (id: number) => {
30+
try {
31+
await httpClient.delete<ApiCommonBasicType>(`/skill-tag/${id}`);
32+
} catch (e) {
33+
console.error(e);
34+
throw e;
35+
}
36+
};
37+
38+
export const postPositionTag = async (name: string) => {
39+
try {
40+
await httpClient.post<ApiCommonBasicType>(`/position-tag`, { name });
41+
} catch (e) {
42+
console.error(e);
43+
throw e;
44+
}
45+
};
46+
47+
export const putPositionTag = async ({
48+
name,
49+
id,
50+
}: {
51+
name: string;
52+
id: number;
53+
}) => {
54+
try {
55+
await httpClient.put<ApiCommonBasicType>(`/position-tag/${id}`, { name });
56+
} catch (e) {
57+
console.error(e);
58+
throw e;
59+
}
60+
};
61+
62+
export const deletePositionTag = async (id: number) => {
63+
try {
64+
await httpClient.delete<ApiCommonBasicType>(`/position-tag/${id}`);
65+
} catch (e) {
66+
console.error(e);
67+
throw e;
68+
}
69+
};
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
import styled from 'styled-components';
2+
import { SendButton } from '../../user/customerService/inquiry/Inquiry.styled';
3+
4+
export const CRUDContainer = styled.form`
5+
width: 100%;
6+
height: 100%;
7+
`;
8+
9+
export const CRUDWrapper = styled.div`
10+
width: 70%;
11+
height: 100%;
12+
display: flex;
13+
gap: 1rem;
14+
font-size: 1.2rem;
15+
justify-content: space-between;
16+
`;
17+
18+
export const InfoContainer = styled.div`
19+
display: flex;
20+
height: 100%;
21+
flex-direction: column;
22+
gap: 1.5rem;
23+
justify-content: center;
24+
/* align-items: center; */
25+
`;
26+
27+
export const CRUDButtonWrapper = styled.div`
28+
display: grid;
29+
gap: 1rem;
30+
`;
31+
32+
export const CRUDButton = styled(SendButton)`
33+
height: 2.3rem;
34+
`;
35+
36+
export const CRUDTitleWrapper = styled.div`
37+
display: flex;
38+
align-items: center;
39+
gap: 1rem;
40+
`;
41+
42+
export const CRUDTitleHead = styled.span``;
43+
44+
export const CRUDTitle = styled.input`
45+
border-bottom: 1px solid ${({ theme }) => theme.color.placeholder};
46+
padding-left: 0.3rem;
47+
font-size: 1rem;
48+
`;
49+
50+
export const CRUDDefaultButton = styled.button`
51+
svg {
52+
width: 1rem;
53+
height: 1rem;
54+
}
55+
`;
56+
57+
export const CRUDImgWrapper = styled.div`
58+
display: flex;
59+
align-items: center;
60+
gap: 1rem;
61+
`;
62+
63+
export const CRUDImgHead = styled.span``;
64+
65+
export const CRUDImg = styled.img`
66+
width: 3rem;
67+
border: 1px solid ${({ theme }) => theme.color.grey};
68+
`;
69+
70+
export const CRUDImgExplore = styled(SendButton)`
71+
cursor: pointer;
72+
border-radius: ${({ theme }) => theme.borderRadius.primary};
73+
padding: 0.4rem 1rem;
74+
`;
75+
76+
export const CRUDImgExplain = styled.span`
77+
max-width: 10rem;
78+
`;
79+
80+
export const CRUDImgInput = styled.input`
81+
visibility: hidden;
82+
width: 0;
83+
height: 0;
84+
`;

0 commit comments

Comments
 (0)