@daeryun/dr_components 0.2.99 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/banner/TopBanner.jsx +14 -11
- package/dist/components/banner/TopBanner.tsx +15 -12
- package/dist/components/myCase/MyCase.d.ts +5 -0
- package/dist/components/myCase/MyCase.jsx +27 -0
- package/dist/components/myCase/MyCase.tsx +48 -0
- package/dist/components/page/MyCase/MyCase.stories.d.ts +6 -0
- package/dist/components/page/MyCase/MyCase.stories.jsx +17 -0
- package/dist/components/page/MyCase/MyCase.stories.tsx +25 -0
- package/dist/components/page/MyCase/MyCaseApp.d.ts +2 -0
- package/dist/components/page/MyCase/MyCaseApp.jsx +19 -0
- package/dist/components/page/MyCase/MyCaseApp.tsx +32 -0
- package/dist/components/page/MyCase/MyCasePage.d.ts +3 -0
- package/dist/components/page/MyCase/MyCasePage.jsx +21 -0
- package/dist/components/page/MyCase/MyCasePage.tsx +32 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetail.stories.d.ts +6 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetail.stories.jsx +17 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetail.stories.tsx +25 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetailApp.d.ts +3 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetailApp.jsx +66 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetailApp.tsx +159 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetailPage.d.ts +3 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetailPage.jsx +65 -0
- package/dist/components/page/MyCase/[id]/MyCaseDetailPage.tsx +157 -0
- package/dist/components/page/MyCase/[id]/_component/ContactInfo.d.ts +2 -0
- package/dist/components/page/MyCase/[id]/_component/ContactInfo.jsx +79 -0
- package/dist/components/page/MyCase/[id]/_component/ContactInfo.tsx +102 -0
- package/dist/components/page/MyCase/[id]/_component/DetailInfo.d.ts +6 -0
- package/dist/components/page/MyCase/[id]/_component/DetailInfo.jsx +44 -0
- package/dist/components/page/MyCase/[id]/_component/DetailInfo.tsx +94 -0
- package/dist/components/page/MyCase/[id]/_component/TimeLine.d.ts +6 -0
- package/dist/components/page/MyCase/[id]/_component/TimeLine.jsx +46 -0
- package/dist/components/page/MyCase/[id]/_component/TimeLine.tsx +72 -0
- package/dist/components/page/MyCase/[id]/_component/_caseInquiry/CaseInquiry.d.ts +11 -0
- package/dist/components/page/MyCase/[id]/_component/_caseInquiry/CaseInquiry.jsx +80 -0
- package/dist/components/page/MyCase/[id]/_component/_caseInquiry/CaseInquiry.tsx +188 -0
- package/dist/components/page/MyCase/[id]/_component/_document/Document.d.ts +6 -0
- package/dist/components/page/MyCase/[id]/_component/_document/Document.jsx +35 -0
- package/dist/components/page/MyCase/[id]/_component/_document/Document.tsx +59 -0
- package/dist/components/page/MyCase/[id]/_component/_document/DocumentLine.d.ts +6 -0
- package/dist/components/page/MyCase/[id]/_component/_document/DocumentLine.jsx +76 -0
- package/dist/components/page/MyCase/[id]/_component/_document/DocumentLine.tsx +94 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryAddModal.d.ts +7 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryAddModal.jsx +107 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryAddModal.tsx +150 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryConfirmModal.d.ts +7 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryConfirmModal.jsx +25 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryConfirmModal.tsx +55 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/ModalCotainer.d.ts +7 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/ModalCotainer.jsx +26 -0
- package/dist/components/page/MyCase/[id]/_component/_modal/ModalCotainer.tsx +39 -0
- package/dist/components/page/MyCase/[id]/_component/_textarea/TextArea.d.ts +7 -0
- package/dist/components/page/MyCase/[id]/_component/_textarea/TextArea.jsx +4 -0
- package/dist/components/page/MyCase/[id]/_component/_textarea/TextArea.tsx +24 -0
- package/dist/components/page/MyCase/_actions/action.d.ts +35 -0
- package/dist/components/page/MyCase/_actions/action.js +145 -0
- package/dist/components/page/MyCase/_actions/action.ts +165 -0
- package/dist/components/page/MyCase/_component/CaseAppContainer.d.ts +2 -0
- package/dist/components/page/MyCase/_component/CaseAppContainer.jsx +117 -0
- package/dist/components/page/MyCase/_component/CaseAppContainer.tsx +255 -0
- package/dist/components/page/MyCase/_component/CasePageContainer.d.ts +2 -0
- package/dist/components/page/MyCase/_component/CasePageContainer.jsx +106 -0
- package/dist/components/page/MyCase/_component/CasePageContainer.tsx +244 -0
- package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenuApp.d.ts +7 -0
- package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenuApp.jsx +47 -0
- package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenuApp.tsx +77 -0
- package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenuPage.d.ts +8 -0
- package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenuPage.jsx +47 -0
- package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenuPage.tsx +77 -0
- package/dist/components/page/MyCase/_component/_button/Badge.d.ts +14 -0
- package/dist/components/page/MyCase/_component/_button/Badge.jsx +16 -0
- package/dist/components/page/MyCase/_component/_button/Badge.tsx +22 -0
- package/dist/components/page/MyCase/_component/_button/SubColor1Button.d.ts +7 -0
- package/dist/components/page/MyCase/_component/_button/SubColor1Button.jsx +9 -0
- package/dist/components/page/MyCase/_component/_button/SubColor1Button.tsx +33 -0
- package/dist/components/page/MyCase/_component/_button/SubMenuButton.d.ts +7 -0
- package/dist/components/page/MyCase/_component/_button/SubMenuButton.jsx +9 -0
- package/dist/components/page/MyCase/_component/_button/SubMenuButton.tsx +31 -0
- package/dist/components/page/MyCase/_component/_empty/EmptyTable.d.ts +6 -0
- package/dist/components/page/MyCase/_component/_empty/EmptyTable.jsx +75 -0
- package/dist/components/page/MyCase/_component/_empty/EmptyTable.tsx +85 -0
- package/dist/components/page/MyCase/_component/_layout/CaseLayout.d.ts +7 -0
- package/dist/components/page/MyCase/_component/_layout/CaseLayout.jsx +11 -0
- package/dist/components/page/MyCase/_component/_layout/CaseLayout.tsx +29 -0
- package/dist/components/page/MyCase/_component/_layout/CaseWrapper.d.ts +12 -0
- package/dist/components/page/MyCase/_component/_layout/CaseWrapper.jsx +25 -0
- package/dist/components/page/MyCase/_component/_layout/CaseWrapper.tsx +41 -0
- package/dist/components/page/MyCase/_component/_layout/HeaderLayout.d.ts +4 -0
- package/dist/components/page/MyCase/_component/_layout/HeaderLayout.jsx +4 -0
- package/dist/components/page/MyCase/_component/_layout/HeaderLayout.tsx +5 -0
- package/dist/components/page/MyCase/_component/_layout/IntroAppWrapper.d.ts +10 -0
- package/dist/components/page/MyCase/_component/_layout/IntroAppWrapper.jsx +29 -0
- package/dist/components/page/MyCase/_component/_layout/IntroAppWrapper.tsx +80 -0
- package/dist/components/page/MyCase/_component/_layout/IntroPageWrapper.d.ts +10 -0
- package/dist/components/page/MyCase/_component/_layout/IntroPageWrapper.jsx +31 -0
- package/dist/components/page/MyCase/_component/_layout/IntroPageWrapper.tsx +81 -0
- package/dist/components/page/MyCase/_component/_loading/Loading.d.ts +2 -0
- package/dist/components/page/MyCase/_component/_loading/Loading.jsx +89 -0
- package/dist/components/page/MyCase/_component/_loading/Loading.tsx +92 -0
- package/dist/components/page/MyCase/_component/_pagination/PaginationComponentApp.d.ts +10 -0
- package/dist/components/page/MyCase/_component/_pagination/PaginationComponentApp.jsx +82 -0
- package/dist/components/page/MyCase/_component/_pagination/PaginationComponentApp.tsx +137 -0
- package/dist/components/page/MyCase/_component/_pagination/PaginationComponentPage.d.ts +10 -0
- package/dist/components/page/MyCase/_component/_pagination/PaginationComponentPage.jsx +81 -0
- package/dist/components/page/MyCase/_component/_pagination/PaginationComponentPage.tsx +135 -0
- package/dist/components/page/MyCase/_component/_table/CaseTabSwiper.d.ts +9 -0
- package/dist/components/page/MyCase/_component/_table/CaseTabSwiper.jsx +65 -0
- package/dist/components/page/MyCase/_component/_table/CaseTabSwiper.tsx +79 -0
- package/dist/components/page/MyCase/_component/_table/CaseTable.d.ts +9 -0
- package/dist/components/page/MyCase/_component/_table/CaseTable.jsx +63 -0
- package/dist/components/page/MyCase/_component/_table/CaseTable.tsx +94 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMo.d.ts +9 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMo.jsx +11 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMo.tsx +28 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMoBox.d.ts +5 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMoBox.jsx +35 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMoBox.tsx +43 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMoPage.d.ts +9 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMoPage.jsx +11 -0
- package/dist/components/page/MyCase/_component/_table/CaseTableMoPage.tsx +28 -0
- package/dist/components/page/MyCase/_fetchers/addMyCaseQuestion.d.ts +6 -0
- package/dist/components/page/MyCase/_fetchers/addMyCaseQuestion.js +31 -0
- package/dist/components/page/MyCase/_fetchers/addMyCaseQuestion.ts +22 -0
- package/dist/components/page/MyCase/_fetchers/getCase.d.ts +5 -0
- package/dist/components/page/MyCase/_fetchers/getCase.js +30 -0
- package/dist/components/page/MyCase/_fetchers/getCase.ts +21 -0
- package/dist/components/page/MyCase/_fetchers/getCaseList.d.ts +7 -0
- package/dist/components/page/MyCase/_fetchers/getCaseList.js +30 -0
- package/dist/components/page/MyCase/_fetchers/getCaseList.ts +24 -0
- package/dist/components/page/MyCase/_fetchers/getCourtFileList.d.ts +5 -0
- package/dist/components/page/MyCase/_fetchers/getCourtFileList.js +30 -0
- package/dist/components/page/MyCase/_fetchers/getCourtFileList.ts +21 -0
- package/dist/components/page/MyCase/_fetchers/getMyCaseQuestion.d.ts +7 -0
- package/dist/components/page/MyCase/_fetchers/getMyCaseQuestion.js +30 -0
- package/dist/components/page/MyCase/_fetchers/getMyCaseQuestion.ts +24 -0
- package/dist/components/page/MyCase/_fetchers/getMyFileList.d.ts +5 -0
- package/dist/components/page/MyCase/_fetchers/getMyFileList.js +30 -0
- package/dist/components/page/MyCase/_fetchers/getMyFileList.ts +21 -0
- package/dist/components/page/MyCase/_fetchers/getTimeLine.d.ts +5 -0
- package/dist/components/page/MyCase/_fetchers/getTimeLine.js +30 -0
- package/dist/components/page/MyCase/_fetchers/getTimeLine.ts +21 -0
- package/dist/components/page/MyCase/_lib/catagoryMenuName.d.ts +8 -0
- package/dist/components/page/MyCase/_lib/catagoryMenuName.js +8 -0
- package/dist/components/page/MyCase/_lib/catagoryMenuName.ts +11 -0
- package/dist/components/page/MyCase/_lib/catagoryMenuNameApp.d.ts +7 -0
- package/dist/components/page/MyCase/_lib/catagoryMenuNameApp.js +8 -0
- package/dist/components/page/MyCase/_lib/catagoryMenuNameApp.ts +11 -0
- package/dist/components/page/MyCase/_lib/pagination/locale/ko_KR.d.ts +15 -0
- package/dist/components/page/MyCase/_lib/pagination/locale/ko_KR.js +21 -0
- package/dist/components/page/MyCase/_type/type.d.ts +73 -0
- package/dist/components/page/MyCase/_type/type.js +1 -0
- package/dist/components/page/MyCase/_type/type.ts +81 -0
- package/dist/components/page/index.d.ts +4 -0
- package/dist/components/page/index.js +4 -0
- package/dist/components/page/index.ts +4 -0
- package/dist/styles/globals.css +2080 -118
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,255 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { useEffect, useState } from 'react';
|
|
4
|
+
import CaseLayout from './_layout/CaseLayout';
|
|
5
|
+
import SubColor1Button from './_button/SubColor1Button';
|
|
6
|
+
import CaseTable from './_table/CaseTable';
|
|
7
|
+
import EmptyTable from './_empty/EmptyTable';
|
|
8
|
+
import { useRouter } from 'next/router';
|
|
9
|
+
import Loading from './_loading/Loading';
|
|
10
|
+
import { useGetCaseList } from '../_actions/action';
|
|
11
|
+
import CaseTabSwiper from './_table/CaseTabSwiper';
|
|
12
|
+
|
|
13
|
+
import CaseTableMoPage from './_table/CaseTableMoPage';
|
|
14
|
+
// import { useCompatibleRouter } from '../../../lib/router/useCompatibleRouter';
|
|
15
|
+
|
|
16
|
+
const CaseTap = ({
|
|
17
|
+
title,
|
|
18
|
+
type,
|
|
19
|
+
tap,
|
|
20
|
+
setTap
|
|
21
|
+
}: {
|
|
22
|
+
title: string;
|
|
23
|
+
type: string;
|
|
24
|
+
tap: string;
|
|
25
|
+
setTap: (tap: string) => void;
|
|
26
|
+
}) => {
|
|
27
|
+
return (
|
|
28
|
+
<button
|
|
29
|
+
onClick={() => {
|
|
30
|
+
if (setTap) {
|
|
31
|
+
setTap(type);
|
|
32
|
+
}
|
|
33
|
+
}}
|
|
34
|
+
className={`items-top sm-top:h-[40px] flex h-[29px] w-full justify-center border-b-[2px] border-solid transition-colors duration-300 lg:h-[45px] ${
|
|
35
|
+
tap === type ? 'border-black text-black' : 'border-grayScale4 text-grayScale4'
|
|
36
|
+
}`}
|
|
37
|
+
>
|
|
38
|
+
<p className={'body_large1_mo sm-top:body_large1_tb lg:body_large1'}>{title}</p>
|
|
39
|
+
</button>
|
|
40
|
+
);
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
const CaseContainer = () => {
|
|
44
|
+
// const { router, searchParams } = useCompatibleRouter();
|
|
45
|
+
const router = useRouter();
|
|
46
|
+
const { page, tap, subTap } = router.query;
|
|
47
|
+
// const searchParams = useSearchParams();
|
|
48
|
+
// const searchParams = useSearchParams();
|
|
49
|
+
// const { page, tap, subTap } = searchParams ? Object.fromEntries(searchParams.entries()) : {};
|
|
50
|
+
const tapState = tap ? (tap as string) : 'ongoing';
|
|
51
|
+
const subTapState = subTap ? (subTap as string) : tap ? (tap as string) : 'ongoing';
|
|
52
|
+
const [pageSize, setPageSize] = useState(6);
|
|
53
|
+
|
|
54
|
+
// const [isLoading, setIsLoading] = useState(true);
|
|
55
|
+
const pageNumber = page ? Number(page) : 1;
|
|
56
|
+
|
|
57
|
+
const handleOnChange = (pageNum: number) => {
|
|
58
|
+
router.push({
|
|
59
|
+
pathname: '/mycase',
|
|
60
|
+
query: { page: pageNum, tap, subTap }
|
|
61
|
+
});
|
|
62
|
+
};
|
|
63
|
+
const handleOnTap = (tap: string) => {
|
|
64
|
+
router.push({
|
|
65
|
+
pathname: '/mycase',
|
|
66
|
+
query: { page, tap, subTap: tap === 'ongoing' ? 'ongoing' : 'closed' }
|
|
67
|
+
});
|
|
68
|
+
};
|
|
69
|
+
const handleOnSubTap = (subTap: string) => {
|
|
70
|
+
router.push({
|
|
71
|
+
pathname: '/mycase',
|
|
72
|
+
query: { page: 1, tap, subTap }
|
|
73
|
+
});
|
|
74
|
+
};
|
|
75
|
+
|
|
76
|
+
const { data, isLoading } = useGetCaseList({
|
|
77
|
+
tapState,
|
|
78
|
+
subTapState,
|
|
79
|
+
pageNumber,
|
|
80
|
+
pageSize
|
|
81
|
+
});
|
|
82
|
+
useEffect(() => {
|
|
83
|
+
const handleResize = () => {
|
|
84
|
+
setPageSize(window.innerWidth < 721 ? 3 : 6);
|
|
85
|
+
}; // 300ms 딜레이
|
|
86
|
+
|
|
87
|
+
window.addEventListener('resize', handleResize);
|
|
88
|
+
return () => window.removeEventListener('resize', handleResize);
|
|
89
|
+
}, []);
|
|
90
|
+
|
|
91
|
+
return (
|
|
92
|
+
<CaseLayout
|
|
93
|
+
outerClassName="mt-[230px] sm-top:mt-[310px] lg:mt-[294px] "
|
|
94
|
+
innerClassName={'py-[40px] sm-top:py-[52px] lg:py-[60px]'}
|
|
95
|
+
isMobilePadding={false}
|
|
96
|
+
>
|
|
97
|
+
<div className={''}>
|
|
98
|
+
<div className="sm-top:px-[50px] flex flex-row items-center px-[20px] 2sm:px-[40px] lg:px-[60px]">
|
|
99
|
+
<CaseTap title="진행중인 사건" type="ongoing" tap={tapState} setTap={handleOnTap} />
|
|
100
|
+
<CaseTap title="종결된 사건" type="closed" tap={tapState} setTap={handleOnTap} />
|
|
101
|
+
</div>
|
|
102
|
+
<div className={'sm-top:px-[50px] sm-top:py-[16px] py-[22px] lg:my-[20px] lg:px-[60px]'}>
|
|
103
|
+
{tapState === 'ongoing' ? (
|
|
104
|
+
<>
|
|
105
|
+
<div className="max-sm-top:hidden sm-top:gap-[12px] flex flex-row md2:gap-[20px] lg:gap-[28px] ">
|
|
106
|
+
<SubColor1Button
|
|
107
|
+
title="전체"
|
|
108
|
+
onClick={() => handleOnSubTap('ongoing')}
|
|
109
|
+
isSelected={subTapState === 'ongoing'}
|
|
110
|
+
/>
|
|
111
|
+
|
|
112
|
+
<SubColor1Button
|
|
113
|
+
title="사건접수"
|
|
114
|
+
onClick={() => handleOnSubTap('사건접수')}
|
|
115
|
+
isSelected={subTapState === '사건접수'}
|
|
116
|
+
/>
|
|
117
|
+
<SubColor1Button
|
|
118
|
+
title="사건검토"
|
|
119
|
+
onClick={() => handleOnSubTap('사건검토')}
|
|
120
|
+
isSelected={subTapState === '사건검토'}
|
|
121
|
+
/>
|
|
122
|
+
<SubColor1Button
|
|
123
|
+
title="변호사상담"
|
|
124
|
+
onClick={() => handleOnSubTap('변호사상담')}
|
|
125
|
+
isSelected={subTapState === '변호사상담'}
|
|
126
|
+
/>
|
|
127
|
+
|
|
128
|
+
<SubColor1Button
|
|
129
|
+
title="소송준비"
|
|
130
|
+
onClick={() => handleOnSubTap('소송준비')}
|
|
131
|
+
isSelected={subTapState === '소송준비'}
|
|
132
|
+
/>
|
|
133
|
+
<SubColor1Button
|
|
134
|
+
title="소송진행"
|
|
135
|
+
onClick={() => handleOnSubTap('소송진행')}
|
|
136
|
+
isSelected={subTapState === '소송진행'}
|
|
137
|
+
/>
|
|
138
|
+
</div>
|
|
139
|
+
<div className="sm-top:hidden">
|
|
140
|
+
<CaseTabSwiper
|
|
141
|
+
id="case-tab-swiper"
|
|
142
|
+
scrollClassName="max-[585px]:!block"
|
|
143
|
+
// handleOnSubTap={handleOnSubTap}
|
|
144
|
+
// subTapState={subTapState}
|
|
145
|
+
>
|
|
146
|
+
<SubColor1Button
|
|
147
|
+
title="전체"
|
|
148
|
+
onClick={() => handleOnSubTap('ongoing')}
|
|
149
|
+
isSelected={subTapState === 'ongoing'}
|
|
150
|
+
outerClassName="ml-[20px] 2sm:ml-[40px]"
|
|
151
|
+
/>
|
|
152
|
+
|
|
153
|
+
<SubColor1Button
|
|
154
|
+
title="사건접수"
|
|
155
|
+
onClick={() => handleOnSubTap('사건접수')}
|
|
156
|
+
isSelected={subTapState === '사건접수'}
|
|
157
|
+
/>
|
|
158
|
+
<SubColor1Button
|
|
159
|
+
title="사건검토"
|
|
160
|
+
onClick={() => handleOnSubTap('사건검토')}
|
|
161
|
+
isSelected={subTapState === '사건검토'}
|
|
162
|
+
/>
|
|
163
|
+
<SubColor1Button
|
|
164
|
+
title="변호사상담"
|
|
165
|
+
onClick={() => handleOnSubTap('변호사상담')}
|
|
166
|
+
isSelected={subTapState === '변호사상담'}
|
|
167
|
+
/>
|
|
168
|
+
|
|
169
|
+
<SubColor1Button
|
|
170
|
+
title="소송준비"
|
|
171
|
+
onClick={() => handleOnSubTap('소송준비')}
|
|
172
|
+
isSelected={subTapState === '소송준비'}
|
|
173
|
+
/>
|
|
174
|
+
<SubColor1Button
|
|
175
|
+
title="소송진행"
|
|
176
|
+
onClick={() => handleOnSubTap('소송진행')}
|
|
177
|
+
isSelected={subTapState === '소송진행'}
|
|
178
|
+
/>
|
|
179
|
+
</CaseTabSwiper>
|
|
180
|
+
</div>
|
|
181
|
+
</>
|
|
182
|
+
) : (
|
|
183
|
+
<>
|
|
184
|
+
<div className="max-sm-top:hidden sm-top:gap-[12px] flex flex-row md2:gap-[20px] lg:gap-[28px] ">
|
|
185
|
+
<SubColor1Button
|
|
186
|
+
title="전체"
|
|
187
|
+
onClick={() => handleOnSubTap('closed')}
|
|
188
|
+
isSelected={subTapState === 'closed'}
|
|
189
|
+
/>
|
|
190
|
+
<SubColor1Button
|
|
191
|
+
title="사건종결"
|
|
192
|
+
onClick={() => handleOnSubTap('사건종결')}
|
|
193
|
+
isSelected={subTapState === '사건종결'}
|
|
194
|
+
/>
|
|
195
|
+
<SubColor1Button
|
|
196
|
+
title="환불"
|
|
197
|
+
onClick={() => handleOnSubTap('환불')}
|
|
198
|
+
isSelected={subTapState === '환불'}
|
|
199
|
+
/>
|
|
200
|
+
</div>
|
|
201
|
+
<div className="sm-top:hidden">
|
|
202
|
+
<CaseTabSwiper
|
|
203
|
+
id="case-tab-swiper"
|
|
204
|
+
// handleOnSubTap={handleOnSubTap}
|
|
205
|
+
// subTapState={subTapState}
|
|
206
|
+
>
|
|
207
|
+
<SubColor1Button
|
|
208
|
+
title="전체"
|
|
209
|
+
onClick={() => handleOnSubTap('closed')}
|
|
210
|
+
isSelected={subTapState === 'closed'}
|
|
211
|
+
outerClassName="ml-[20px] 2sm:ml-[40px]"
|
|
212
|
+
/>
|
|
213
|
+
<SubColor1Button
|
|
214
|
+
title="사건종결"
|
|
215
|
+
onClick={() => handleOnSubTap('사건종결')}
|
|
216
|
+
isSelected={subTapState === '사건종결'}
|
|
217
|
+
/>
|
|
218
|
+
<SubColor1Button
|
|
219
|
+
title="환불"
|
|
220
|
+
onClick={() => handleOnSubTap('환불')}
|
|
221
|
+
isSelected={subTapState === '환불'}
|
|
222
|
+
/>
|
|
223
|
+
</CaseTabSwiper>
|
|
224
|
+
</div>
|
|
225
|
+
</>
|
|
226
|
+
)}
|
|
227
|
+
</div>
|
|
228
|
+
{isLoading ? (
|
|
229
|
+
<Loading />
|
|
230
|
+
) : data?.list.length > 0 ? (
|
|
231
|
+
<>
|
|
232
|
+
<CaseTable
|
|
233
|
+
list={data?.list}
|
|
234
|
+
totalLength={data?.totalLength}
|
|
235
|
+
pageSize={pageSize}
|
|
236
|
+
pageNumber={pageNumber}
|
|
237
|
+
onChange={handleOnChange}
|
|
238
|
+
/>
|
|
239
|
+
<CaseTableMoPage
|
|
240
|
+
list={data?.list}
|
|
241
|
+
totalLength={data?.totalLength}
|
|
242
|
+
pageSize={pageSize}
|
|
243
|
+
pageNumber={pageNumber}
|
|
244
|
+
onChange={handleOnChange}
|
|
245
|
+
/>
|
|
246
|
+
</>
|
|
247
|
+
) : (
|
|
248
|
+
<EmptyTable tap={tapState} subTap={subTapState === 'ongoing' || subTapState === 'closed' ? 0 : 1} />
|
|
249
|
+
)}
|
|
250
|
+
</div>
|
|
251
|
+
</CaseLayout>
|
|
252
|
+
);
|
|
253
|
+
};
|
|
254
|
+
|
|
255
|
+
export default CaseContainer;
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { useEffect, useState } from 'react';
|
|
2
|
+
import CaseLayout from './_layout/CaseLayout';
|
|
3
|
+
import SubColor1Button from './_button/SubColor1Button';
|
|
4
|
+
import CaseTable from './_table/CaseTable';
|
|
5
|
+
import EmptyTable from './_empty/EmptyTable';
|
|
6
|
+
import { useRouter, useSearchParams } from 'next/navigation';
|
|
7
|
+
import Loading from './_loading/Loading';
|
|
8
|
+
import { useGetCaseList } from '../_actions/action';
|
|
9
|
+
import CaseTabSwiper from './_table/CaseTabSwiper';
|
|
10
|
+
import CaseTableMo from './_table/CaseTableMo';
|
|
11
|
+
const CaseTap = ({ title, type, tap, setTap }) => {
|
|
12
|
+
return (<button onClick={() => {
|
|
13
|
+
if (setTap) {
|
|
14
|
+
setTap(type);
|
|
15
|
+
}
|
|
16
|
+
}} className={`items-top sm-top:h-[40px] flex h-[29px] w-full justify-center border-b-[2px] border-solid transition-colors duration-300 lg:h-[45px] ${tap === type ? 'border-black text-black' : 'border-grayScale4 text-grayScale4'}`}>
|
|
17
|
+
<p className={'body_large1_mo sm-top:body_large1_tb lg:body_large1'}>{title}</p>
|
|
18
|
+
</button>);
|
|
19
|
+
};
|
|
20
|
+
const CaseContainer = () => {
|
|
21
|
+
var _a, _b, _c, _d, _e;
|
|
22
|
+
const router = useRouter();
|
|
23
|
+
const searchParams = useSearchParams();
|
|
24
|
+
const { page, tap, subTap } = searchParams ? Object.fromEntries(searchParams.entries()) : {};
|
|
25
|
+
const tapState = tap ? tap : 'ongoing';
|
|
26
|
+
const subTapState = subTap ? subTap : tap ? tap : 'ongoing';
|
|
27
|
+
const [pageSize, setPageSize] = useState(6);
|
|
28
|
+
const [caseList, setCaseList] = useState([]);
|
|
29
|
+
const [totalLength, setTotalLength] = useState(0);
|
|
30
|
+
// const [isLoading, setIsLoading] = useState(true);
|
|
31
|
+
const pageNumber = page ? Number(page) : 1;
|
|
32
|
+
const handleOnChange = (pageNum) => {
|
|
33
|
+
router.push(`/mycase?page=${pageNum}&tap=${tap}&subTap=${subTap}`);
|
|
34
|
+
};
|
|
35
|
+
const handleOnTap = (tap) => {
|
|
36
|
+
router.push(`/mycase?page=${page}&tap=${tap}&subTap=${tap === 'ongoing' ? 'ongoing' : 'closed'}`);
|
|
37
|
+
};
|
|
38
|
+
const handleOnSubTap = (subTap) => {
|
|
39
|
+
router.push(`/mycase?page=1&tap=${tap}&subTap=${subTap}`);
|
|
40
|
+
};
|
|
41
|
+
const { data, isLoading } = useGetCaseList({
|
|
42
|
+
tapState,
|
|
43
|
+
subTapState,
|
|
44
|
+
pageNumber,
|
|
45
|
+
pageSize
|
|
46
|
+
});
|
|
47
|
+
useEffect(() => {
|
|
48
|
+
const handleResize = () => {
|
|
49
|
+
setPageSize(window.innerWidth < 721 ? 3 : 6);
|
|
50
|
+
}; // 300ms 딜레이
|
|
51
|
+
window.addEventListener('resize', handleResize);
|
|
52
|
+
return () => window.removeEventListener('resize', handleResize);
|
|
53
|
+
}, []);
|
|
54
|
+
return (<CaseLayout outerClassName="mt-[230px] sm-top:mt-[310px] lg:mt-[294px] " innerClassName={'py-[40px] sm-top:py-[52px] lg:py-[60px]'} isMobilePadding={false}>
|
|
55
|
+
<div className={''}>
|
|
56
|
+
<div className="sm-top:px-[50px] flex flex-row items-center px-[20px] 2sm:px-[40px] lg:px-[60px]">
|
|
57
|
+
<CaseTap title="진행중인 사건" type="ongoing" tap={tapState} setTap={handleOnTap}/>
|
|
58
|
+
<CaseTap title="종결된 사건" type="closed" tap={tapState} setTap={handleOnTap}/>
|
|
59
|
+
</div>
|
|
60
|
+
<div className={'sm-top:px-[50px] sm-top:py-[16px] py-[22px] lg:my-[20px] lg:px-[60px]'}>
|
|
61
|
+
{tapState === 'ongoing' ? (<>
|
|
62
|
+
<div className="max-sm-top:hidden sm-top:gap-[12px] flex flex-row md2:gap-[20px] lg:gap-[28px] ">
|
|
63
|
+
<SubColor1Button title="전체" onClick={() => handleOnSubTap('ongoing')} isSelected={subTapState === 'ongoing'}/>
|
|
64
|
+
|
|
65
|
+
<SubColor1Button title="사건접수" onClick={() => handleOnSubTap('사건접수')} isSelected={subTapState === '사건접수'}/>
|
|
66
|
+
<SubColor1Button title="사건검토" onClick={() => handleOnSubTap('사건검토')} isSelected={subTapState === '사건검토'}/>
|
|
67
|
+
<SubColor1Button title="변호사상담" onClick={() => handleOnSubTap('변호사상담')} isSelected={subTapState === '변호사상담'}/>
|
|
68
|
+
|
|
69
|
+
<SubColor1Button title="소송준비" onClick={() => handleOnSubTap('소송준비')} isSelected={subTapState === '소송준비'}/>
|
|
70
|
+
<SubColor1Button title="소송진행" onClick={() => handleOnSubTap('소송진행')} isSelected={subTapState === '소송진행'}/>
|
|
71
|
+
</div>
|
|
72
|
+
<div className="sm-top:hidden">
|
|
73
|
+
<CaseTabSwiper id="case-tab-swiper" scrollClassName="max-[585px]:!block">
|
|
74
|
+
<SubColor1Button title="전체" onClick={() => handleOnSubTap('ongoing')} isSelected={subTapState === 'ongoing'} outerClassName="ml-[20px] 2sm:ml-[40px]"/>
|
|
75
|
+
|
|
76
|
+
<SubColor1Button title="사건접수" onClick={() => handleOnSubTap('사건접수')} isSelected={subTapState === '사건접수'}/>
|
|
77
|
+
<SubColor1Button title="사건검토" onClick={() => handleOnSubTap('사건검토')} isSelected={subTapState === '사건검토'}/>
|
|
78
|
+
<SubColor1Button title="변호사상담" onClick={() => handleOnSubTap('변호사상담')} isSelected={subTapState === '변호사상담'}/>
|
|
79
|
+
|
|
80
|
+
<SubColor1Button title="소송준비" onClick={() => handleOnSubTap('소송준비')} isSelected={subTapState === '소송준비'}/>
|
|
81
|
+
<SubColor1Button title="소송진행" onClick={() => handleOnSubTap('소송진행')} isSelected={subTapState === '소송진행'}/>
|
|
82
|
+
</CaseTabSwiper>
|
|
83
|
+
</div>
|
|
84
|
+
</>) : (<>
|
|
85
|
+
<div className="max-sm-top:hidden sm-top:gap-[12px] flex flex-row md2:gap-[20px] lg:gap-[28px] ">
|
|
86
|
+
<SubColor1Button title="전체" onClick={() => handleOnSubTap('closed')} isSelected={subTapState === 'closed'}/>
|
|
87
|
+
<SubColor1Button title="사건종결" onClick={() => handleOnSubTap('사건종결')} isSelected={subTapState === '사건종결'}/>
|
|
88
|
+
<SubColor1Button title="환불" onClick={() => handleOnSubTap('환불')} isSelected={subTapState === '환불'}/>
|
|
89
|
+
</div>
|
|
90
|
+
<div className="sm-top:hidden">
|
|
91
|
+
<CaseTabSwiper id="case-tab-swiper">
|
|
92
|
+
<SubColor1Button title="전체" onClick={() => handleOnSubTap('closed')} isSelected={subTapState === 'closed'} outerClassName="ml-[20px] 2sm:ml-[40px]"/>
|
|
93
|
+
<SubColor1Button title="사건종결" onClick={() => handleOnSubTap('사건종결')} isSelected={subTapState === '사건종결'}/>
|
|
94
|
+
<SubColor1Button title="환불" onClick={() => handleOnSubTap('환불')} isSelected={subTapState === '환불'}/>
|
|
95
|
+
</CaseTabSwiper>
|
|
96
|
+
</div>
|
|
97
|
+
</>)}
|
|
98
|
+
</div>
|
|
99
|
+
{isLoading ? (<Loading />) : ((_a = data === null || data === void 0 ? void 0 : data.data) === null || _a === void 0 ? void 0 : _a.list.length) > 0 ? (<>
|
|
100
|
+
<CaseTable list={(_b = data === null || data === void 0 ? void 0 : data.data) === null || _b === void 0 ? void 0 : _b.list} totalLength={(_c = data === null || data === void 0 ? void 0 : data.data) === null || _c === void 0 ? void 0 : _c.totalLength} pageSize={pageSize} pageNumber={pageNumber} onChange={handleOnChange}/>
|
|
101
|
+
<CaseTableMo list={(_d = data === null || data === void 0 ? void 0 : data.data) === null || _d === void 0 ? void 0 : _d.list} totalLength={(_e = data === null || data === void 0 ? void 0 : data.data) === null || _e === void 0 ? void 0 : _e.totalLength} pageSize={pageSize} pageNumber={pageNumber} onChange={handleOnChange}/>
|
|
102
|
+
</>) : (<EmptyTable tap={tapState} subTap={subTapState === 'ongoing' || subTapState === 'closed' ? 0 : 1}/>)}
|
|
103
|
+
</div>
|
|
104
|
+
</CaseLayout>);
|
|
105
|
+
};
|
|
106
|
+
export default CaseContainer;
|
|
@@ -0,0 +1,244 @@
|
|
|
1
|
+
import { useEffect, useState } from 'react';
|
|
2
|
+
import CaseLayout from './_layout/CaseLayout';
|
|
3
|
+
import SubColor1Button from './_button/SubColor1Button';
|
|
4
|
+
|
|
5
|
+
import CaseTable from './_table/CaseTable';
|
|
6
|
+
import { Case } from '../_type/type';
|
|
7
|
+
import EmptyTable from './_empty/EmptyTable';
|
|
8
|
+
import { useRouter, useSearchParams } from 'next/navigation';
|
|
9
|
+
import Loading from './_loading/Loading';
|
|
10
|
+
import { useGetCaseList } from '../_actions/action';
|
|
11
|
+
import CaseTabSwiper from './_table/CaseTabSwiper';
|
|
12
|
+
import CaseTableMo from './_table/CaseTableMo';
|
|
13
|
+
|
|
14
|
+
const CaseTap = ({
|
|
15
|
+
title,
|
|
16
|
+
type,
|
|
17
|
+
tap,
|
|
18
|
+
setTap
|
|
19
|
+
}: {
|
|
20
|
+
title: string;
|
|
21
|
+
type: string;
|
|
22
|
+
tap: string;
|
|
23
|
+
setTap: (tap: string) => void;
|
|
24
|
+
}) => {
|
|
25
|
+
return (
|
|
26
|
+
<button
|
|
27
|
+
onClick={() => {
|
|
28
|
+
if (setTap) {
|
|
29
|
+
setTap(type);
|
|
30
|
+
}
|
|
31
|
+
}}
|
|
32
|
+
className={`items-top sm-top:h-[40px] flex h-[29px] w-full justify-center border-b-[2px] border-solid transition-colors duration-300 lg:h-[45px] ${
|
|
33
|
+
tap === type ? 'border-black text-black' : 'border-grayScale4 text-grayScale4'
|
|
34
|
+
}`}
|
|
35
|
+
>
|
|
36
|
+
<p className={'body_large1_mo sm-top:body_large1_tb lg:body_large1'}>{title}</p>
|
|
37
|
+
</button>
|
|
38
|
+
);
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
const CaseContainer = () => {
|
|
42
|
+
const router = useRouter();
|
|
43
|
+
|
|
44
|
+
const searchParams = useSearchParams();
|
|
45
|
+
const { page, tap, subTap } = searchParams ? Object.fromEntries(searchParams.entries()) : {};
|
|
46
|
+
const tapState = tap ? (tap as string) : 'ongoing';
|
|
47
|
+
const subTapState = subTap ? (subTap as string) : tap ? (tap as string) : 'ongoing';
|
|
48
|
+
const [pageSize, setPageSize] = useState(6);
|
|
49
|
+
|
|
50
|
+
const [caseList, setCaseList] = useState<Case[]>([]);
|
|
51
|
+
const [totalLength, setTotalLength] = useState(0);
|
|
52
|
+
// const [isLoading, setIsLoading] = useState(true);
|
|
53
|
+
const pageNumber = page ? Number(page) : 1;
|
|
54
|
+
|
|
55
|
+
const handleOnChange = (pageNum: number) => {
|
|
56
|
+
router.push(`/mycase?page=${pageNum}&tap=${tap}&subTap=${subTap}`);
|
|
57
|
+
};
|
|
58
|
+
const handleOnTap = (tap: string) => {
|
|
59
|
+
router.push(`/mycase?page=${page}&tap=${tap}&subTap=${tap === 'ongoing' ? 'ongoing' : 'closed'}`);
|
|
60
|
+
};
|
|
61
|
+
const handleOnSubTap = (subTap: string) => {
|
|
62
|
+
router.push(`/mycase?page=1&tap=${tap}&subTap=${subTap}`);
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
const { data, isLoading } = useGetCaseList({
|
|
66
|
+
tapState,
|
|
67
|
+
subTapState,
|
|
68
|
+
pageNumber,
|
|
69
|
+
pageSize
|
|
70
|
+
});
|
|
71
|
+
useEffect(() => {
|
|
72
|
+
const handleResize = () => {
|
|
73
|
+
setPageSize(window.innerWidth < 721 ? 3 : 6);
|
|
74
|
+
}; // 300ms 딜레이
|
|
75
|
+
|
|
76
|
+
window.addEventListener('resize', handleResize);
|
|
77
|
+
return () => window.removeEventListener('resize', handleResize);
|
|
78
|
+
}, []);
|
|
79
|
+
|
|
80
|
+
return (
|
|
81
|
+
<CaseLayout
|
|
82
|
+
outerClassName="mt-[230px] sm-top:mt-[310px] lg:mt-[294px] "
|
|
83
|
+
innerClassName={'py-[40px] sm-top:py-[52px] lg:py-[60px]'}
|
|
84
|
+
isMobilePadding={false}
|
|
85
|
+
>
|
|
86
|
+
<div className={''}>
|
|
87
|
+
<div className="sm-top:px-[50px] flex flex-row items-center px-[20px] 2sm:px-[40px] lg:px-[60px]">
|
|
88
|
+
<CaseTap title="진행중인 사건" type="ongoing" tap={tapState} setTap={handleOnTap} />
|
|
89
|
+
<CaseTap title="종결된 사건" type="closed" tap={tapState} setTap={handleOnTap} />
|
|
90
|
+
</div>
|
|
91
|
+
<div className={'sm-top:px-[50px] sm-top:py-[16px] py-[22px] lg:my-[20px] lg:px-[60px]'}>
|
|
92
|
+
{tapState === 'ongoing' ? (
|
|
93
|
+
<>
|
|
94
|
+
<div className="max-sm-top:hidden sm-top:gap-[12px] flex flex-row md2:gap-[20px] lg:gap-[28px] ">
|
|
95
|
+
<SubColor1Button
|
|
96
|
+
title="전체"
|
|
97
|
+
onClick={() => handleOnSubTap('ongoing')}
|
|
98
|
+
isSelected={subTapState === 'ongoing'}
|
|
99
|
+
/>
|
|
100
|
+
|
|
101
|
+
<SubColor1Button
|
|
102
|
+
title="사건접수"
|
|
103
|
+
onClick={() => handleOnSubTap('사건접수')}
|
|
104
|
+
isSelected={subTapState === '사건접수'}
|
|
105
|
+
/>
|
|
106
|
+
<SubColor1Button
|
|
107
|
+
title="사건검토"
|
|
108
|
+
onClick={() => handleOnSubTap('사건검토')}
|
|
109
|
+
isSelected={subTapState === '사건검토'}
|
|
110
|
+
/>
|
|
111
|
+
<SubColor1Button
|
|
112
|
+
title="변호사상담"
|
|
113
|
+
onClick={() => handleOnSubTap('변호사상담')}
|
|
114
|
+
isSelected={subTapState === '변호사상담'}
|
|
115
|
+
/>
|
|
116
|
+
|
|
117
|
+
<SubColor1Button
|
|
118
|
+
title="소송준비"
|
|
119
|
+
onClick={() => handleOnSubTap('소송준비')}
|
|
120
|
+
isSelected={subTapState === '소송준비'}
|
|
121
|
+
/>
|
|
122
|
+
<SubColor1Button
|
|
123
|
+
title="소송진행"
|
|
124
|
+
onClick={() => handleOnSubTap('소송진행')}
|
|
125
|
+
isSelected={subTapState === '소송진행'}
|
|
126
|
+
/>
|
|
127
|
+
</div>
|
|
128
|
+
<div className="sm-top:hidden">
|
|
129
|
+
<CaseTabSwiper
|
|
130
|
+
id="case-tab-swiper"
|
|
131
|
+
scrollClassName="max-[585px]:!block"
|
|
132
|
+
// handleOnSubTap={handleOnSubTap}
|
|
133
|
+
// subTapState={subTapState}
|
|
134
|
+
>
|
|
135
|
+
<SubColor1Button
|
|
136
|
+
title="전체"
|
|
137
|
+
onClick={() => handleOnSubTap('ongoing')}
|
|
138
|
+
isSelected={subTapState === 'ongoing'}
|
|
139
|
+
outerClassName="ml-[20px] 2sm:ml-[40px]"
|
|
140
|
+
/>
|
|
141
|
+
|
|
142
|
+
<SubColor1Button
|
|
143
|
+
title="사건접수"
|
|
144
|
+
onClick={() => handleOnSubTap('사건접수')}
|
|
145
|
+
isSelected={subTapState === '사건접수'}
|
|
146
|
+
/>
|
|
147
|
+
<SubColor1Button
|
|
148
|
+
title="사건검토"
|
|
149
|
+
onClick={() => handleOnSubTap('사건검토')}
|
|
150
|
+
isSelected={subTapState === '사건검토'}
|
|
151
|
+
/>
|
|
152
|
+
<SubColor1Button
|
|
153
|
+
title="변호사상담"
|
|
154
|
+
onClick={() => handleOnSubTap('변호사상담')}
|
|
155
|
+
isSelected={subTapState === '변호사상담'}
|
|
156
|
+
/>
|
|
157
|
+
|
|
158
|
+
<SubColor1Button
|
|
159
|
+
title="소송준비"
|
|
160
|
+
onClick={() => handleOnSubTap('소송준비')}
|
|
161
|
+
isSelected={subTapState === '소송준비'}
|
|
162
|
+
/>
|
|
163
|
+
<SubColor1Button
|
|
164
|
+
title="소송진행"
|
|
165
|
+
onClick={() => handleOnSubTap('소송진행')}
|
|
166
|
+
isSelected={subTapState === '소송진행'}
|
|
167
|
+
/>
|
|
168
|
+
</CaseTabSwiper>
|
|
169
|
+
</div>
|
|
170
|
+
</>
|
|
171
|
+
) : (
|
|
172
|
+
<>
|
|
173
|
+
<div className="max-sm-top:hidden sm-top:gap-[12px] flex flex-row md2:gap-[20px] lg:gap-[28px] ">
|
|
174
|
+
<SubColor1Button
|
|
175
|
+
title="전체"
|
|
176
|
+
onClick={() => handleOnSubTap('closed')}
|
|
177
|
+
isSelected={subTapState === 'closed'}
|
|
178
|
+
/>
|
|
179
|
+
<SubColor1Button
|
|
180
|
+
title="사건종결"
|
|
181
|
+
onClick={() => handleOnSubTap('사건종결')}
|
|
182
|
+
isSelected={subTapState === '사건종결'}
|
|
183
|
+
/>
|
|
184
|
+
<SubColor1Button
|
|
185
|
+
title="환불"
|
|
186
|
+
onClick={() => handleOnSubTap('환불')}
|
|
187
|
+
isSelected={subTapState === '환불'}
|
|
188
|
+
/>
|
|
189
|
+
</div>
|
|
190
|
+
<div className="sm-top:hidden">
|
|
191
|
+
<CaseTabSwiper
|
|
192
|
+
id="case-tab-swiper"
|
|
193
|
+
// handleOnSubTap={handleOnSubTap}
|
|
194
|
+
// subTapState={subTapState}
|
|
195
|
+
>
|
|
196
|
+
<SubColor1Button
|
|
197
|
+
title="전체"
|
|
198
|
+
onClick={() => handleOnSubTap('closed')}
|
|
199
|
+
isSelected={subTapState === 'closed'}
|
|
200
|
+
outerClassName="ml-[20px] 2sm:ml-[40px]"
|
|
201
|
+
/>
|
|
202
|
+
<SubColor1Button
|
|
203
|
+
title="사건종결"
|
|
204
|
+
onClick={() => handleOnSubTap('사건종결')}
|
|
205
|
+
isSelected={subTapState === '사건종결'}
|
|
206
|
+
/>
|
|
207
|
+
<SubColor1Button
|
|
208
|
+
title="환불"
|
|
209
|
+
onClick={() => handleOnSubTap('환불')}
|
|
210
|
+
isSelected={subTapState === '환불'}
|
|
211
|
+
/>
|
|
212
|
+
</CaseTabSwiper>
|
|
213
|
+
</div>
|
|
214
|
+
</>
|
|
215
|
+
)}
|
|
216
|
+
</div>
|
|
217
|
+
{isLoading ? (
|
|
218
|
+
<Loading />
|
|
219
|
+
) : data?.data?.list.length > 0 ? (
|
|
220
|
+
<>
|
|
221
|
+
<CaseTable
|
|
222
|
+
list={data?.data?.list}
|
|
223
|
+
totalLength={data?.data?.totalLength}
|
|
224
|
+
pageSize={pageSize}
|
|
225
|
+
pageNumber={pageNumber}
|
|
226
|
+
onChange={handleOnChange}
|
|
227
|
+
/>
|
|
228
|
+
<CaseTableMo
|
|
229
|
+
list={data?.data?.list}
|
|
230
|
+
totalLength={data?.data?.totalLength}
|
|
231
|
+
pageSize={pageSize}
|
|
232
|
+
pageNumber={pageNumber}
|
|
233
|
+
onChange={handleOnChange}
|
|
234
|
+
/>
|
|
235
|
+
</>
|
|
236
|
+
) : (
|
|
237
|
+
<EmptyTable tap={tapState} subTap={subTapState === 'ongoing' || subTapState === 'closed' ? 0 : 1} />
|
|
238
|
+
)}
|
|
239
|
+
</div>
|
|
240
|
+
</CaseLayout>
|
|
241
|
+
);
|
|
242
|
+
};
|
|
243
|
+
|
|
244
|
+
export default CaseContainer;
|