@daeryun/dr_components 0.5.78 → 0.5.80

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.
@@ -27,7 +27,7 @@ const MyCaseDetailPageContainer = ({ jwt }) => {
27
27
  const { data: detailList, isLoading: detailListLoading } = useActionGetDetailList(id, jwt);
28
28
  const { data: timeLine, isLoading: timeLineLoading } = useActionGetTimeLine(id, jwt);
29
29
  const { data: courtFileList, isLoading: courtFileListLoading } = useActionGetCourtFileList(id, jwt);
30
- const { data: myFileList, isLoading: myFileListLoading } = useActionGetMyFileList(id, jwt);
30
+ const { data: myFileList, isLoading: myFileListLoading, refetch: myFileListRefetch } = useActionGetMyFileList(id, jwt);
31
31
  const { data: myCaseQuestion, isLoading: myCaseQuestionLoading, refetch: myCaseQuestionRefetch } = useActionGetMyCaseQuestion(id, pageNumber, pageSize, jwt);
32
32
  const handleOnChange = (pageNum) => {
33
33
  router.push(`/mycase/${id}?page=${pageNum}`);
@@ -59,7 +59,7 @@ const MyCaseDetailPageContainer = ({ jwt }) => {
59
59
  </div>
60
60
  {selected === '사건 정보' && (<DetailInfo detailList={detailList === null || detailList === void 0 ? void 0 : detailList.data} isLoading={detailListLoading}/>)}
61
61
  {selected === '사건 타임라인' && (<TimeLine timeLine={timeLine === null || timeLine === void 0 ? void 0 : timeLine.list} isLoading={timeLineLoading}/>)}
62
- {selected === '문서함' && (<Document courtFileList={courtFileList === null || courtFileList === void 0 ? void 0 : courtFileList.data} myFileList={myFileList === null || myFileList === void 0 ? void 0 : myFileList.data} id={id} refetch={myCaseQuestionRefetch}/>)}
62
+ {selected === '문서함' && (<Document courtFileList={courtFileList === null || courtFileList === void 0 ? void 0 : courtFileList.data} myFileList={myFileList === null || myFileList === void 0 ? void 0 : myFileList.data} id={id} refetch={myFileListRefetch}/>)}
63
63
  {selected === '계약정보' && <ContactInfo id={id}/>}
64
64
  {selected === '사건문의' && (<CaseInquiry myCaseQuestion={myCaseQuestion === null || myCaseQuestion === void 0 ? void 0 : myCaseQuestion.list} isLoading={myCaseQuestionLoading} id={id} refetch={myCaseQuestionRefetch} pageSize={pageSize} totalLength={(_a = myCaseQuestion === null || myCaseQuestion === void 0 ? void 0 : myCaseQuestion.totalLength) !== null && _a !== void 0 ? _a : 0} pageNumber={pageNumber} onChange={handleOnChange}/>)}
65
65
  </HeaderLayout>
@@ -40,7 +40,12 @@ const MyCaseDetailPageContainer = ({ jwt }: { jwt?: string }) => {
40
40
  const { data: detailList, isLoading: detailListLoading } = useActionGetDetailList(id as string, jwt);
41
41
  const { data: timeLine, isLoading: timeLineLoading } = useActionGetTimeLine(id as string, jwt);
42
42
  const { data: courtFileList, isLoading: courtFileListLoading } = useActionGetCourtFileList(id as string, jwt);
43
- const { data: myFileList, isLoading: myFileListLoading } = useActionGetMyFileList(id as string, jwt);
43
+ const {
44
+ data: myFileList,
45
+ isLoading: myFileListLoading,
46
+ refetch: myFileListRefetch
47
+ } = useActionGetMyFileList(id as string, jwt);
48
+
44
49
  const {
45
50
  data: myCaseQuestion,
46
51
  isLoading: myCaseQuestionLoading,
@@ -142,7 +147,7 @@ const MyCaseDetailPageContainer = ({ jwt }: { jwt?: string }) => {
142
147
  courtFileList={courtFileList?.data as FileList[]}
143
148
  myFileList={myFileList?.data as FileList[]}
144
149
  id={id as string}
145
- refetch={myCaseQuestionRefetch}
150
+ refetch={myFileListRefetch}
146
151
  />
147
152
  )}
148
153
  {selected === '계약정보' && <ContactInfo id={id as string} />}
@@ -1,6 +1,8 @@
1
1
  import dayjs from 'dayjs';
2
2
  import CaseLayout from '../../_component/_layout/CaseLayout';
3
3
  import Image from 'next/image';
4
+ import checkCircle from '../../../../../asset/images/myCase/icon/check_circle.webp';
5
+ import checkCircle2 from '../../../../../asset/images/myCase/icon/check_circle2.webp';
4
6
  const TimeBox = ({ item }) => {
5
7
  return (<div className="rounded-[4px] bg-grayScale7 px-[20px] py-[16px] sm-top:rounded-[8px] sm-top:px-[28px] sm-top:py-[20px] lg:rounded-[12px] lg:px-[28px] lg:py-[20px]">
6
8
  <div className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
@@ -13,7 +15,7 @@ const TimeBox = ({ item }) => {
13
15
  };
14
16
  const TimeContainer = ({ list, isFirst }) => {
15
17
  const isCourt = !!list[0].progress_idx;
16
- const imgUrl = isCourt ? '/images/mycase/icon/check_circle.webp' : '/images/mycase/icon/check_circle2.webp';
18
+ const imgUrl = isCourt ? checkCircle : checkCircle2;
17
19
  const color = isCourt ? 'text-subColor05' : 'text-mycaseMainColor';
18
20
  const borderColor = isCourt ? 'border-subColor05' : 'border-mycaseMainColor';
19
21
  return (<>
@@ -19,7 +19,7 @@ const TimeBox = ({ item }: { item: TimeLineItem }) => {
19
19
  };
20
20
  const TimeContainer = ({ list, isFirst }: { list: TimeLineItem[]; isFirst: boolean }) => {
21
21
  const isCourt = !!list[0].progress_idx;
22
- const imgUrl = isCourt ? '/images/mycase/icon/check_circle.webp' : '/images/mycase/icon/check_circle2.webp';
22
+ const imgUrl = isCourt ? checkCircle : checkCircle2;
23
23
  const color = isCourt ? 'text-subColor05' : 'text-mycaseMainColor';
24
24
  const borderColor = isCourt ? 'border-subColor05' : 'border-mycaseMainColor';
25
25
  return (
@@ -22,6 +22,7 @@ export declare const useActionGetCourtFileList: (id: string, jwt?: string) => {
22
22
  export declare const useActionGetMyFileList: (id: string, jwt?: string) => {
23
23
  data: FetchType<FileList[]> | undefined;
24
24
  isLoading: boolean;
25
+ refetch: (options?: import("@tanstack/react-query").RefetchOptions) => Promise<import("@tanstack/react-query").QueryObserverResult<FetchType<FileList[]>, Error>>;
25
26
  };
26
27
  export declare const useActionGetMyCaseQuestion: (id: string, page: number, pageSize: number, jwt?: string) => {
27
28
  data: FetchType<Question[]> | undefined;
@@ -96,7 +96,7 @@ export const useActionGetCourtFileList = (id, jwt) => {
96
96
  return { data, isLoading };
97
97
  };
98
98
  export const useActionGetMyFileList = (id, jwt) => {
99
- const { data, isLoading } = useQuery({
99
+ const { data, isLoading, refetch } = useQuery({
100
100
  queryKey: ['case', 'myFileList', id],
101
101
  queryFn: () => getMyFileList({
102
102
  jwt: jwt ? jwt : jwt2,
@@ -110,7 +110,7 @@ export const useActionGetMyFileList = (id, jwt) => {
110
110
  // console.log(error);
111
111
  // }
112
112
  });
113
- return { data, isLoading };
113
+ return { data, isLoading, refetch };
114
114
  };
115
115
  export const useActionGetMyCaseQuestion = (id, page, pageSize, jwt) => {
116
116
  const { data, isLoading, refetch } = useQuery({
@@ -109,7 +109,7 @@ export const useActionGetCourtFileList = (id: string, jwt?: string) => {
109
109
  };
110
110
 
111
111
  export const useActionGetMyFileList = (id: string, jwt?: string) => {
112
- const { data, isLoading } = useQuery<FetchType<FileList[]>>({
112
+ const { data, isLoading, refetch } = useQuery<FetchType<FileList[]>>({
113
113
  queryKey: ['case', 'myFileList', id],
114
114
  queryFn: () =>
115
115
  getMyFileList({
@@ -124,7 +124,7 @@ export const useActionGetMyFileList = (id: string, jwt?: string) => {
124
124
  // console.log(error);
125
125
  // }
126
126
  });
127
- return { data, isLoading };
127
+ return { data, isLoading, refetch };
128
128
  };
129
129
 
130
130
  export const useActionGetMyCaseQuestion = (id: string, page: number, pageSize: number, jwt?: string) => {