sort 구조 변경
This commit is contained in:
@@ -34,25 +34,22 @@ export const ListWrap = () => {
|
||||
|
||||
const { mutateAsync: vatReturnList } = useVatReturnListMutation();
|
||||
|
||||
const callList = (option?: {
|
||||
sortType?: SortTypeKeys
|
||||
}) => {
|
||||
const callList = () => {
|
||||
let params: VatReturnListParams = {
|
||||
mid: mid,
|
||||
startMonth: startMonth,
|
||||
endMonth: endMonth,
|
||||
receiptType: receiptType,
|
||||
targetType: targetType,
|
||||
page: pageParam
|
||||
page: {
|
||||
...pageParam,
|
||||
...{ sortType: sortType }
|
||||
}
|
||||
};
|
||||
if(params.page){
|
||||
params.page.sortType = option?.sortType || sortType;
|
||||
setPageParam(params.page);
|
||||
}
|
||||
|
||||
vatReturnList(params).then((rs: VatReturnListResponse) => {
|
||||
setListItems(rs.content);
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
const onClickToOpenFIlter = () => {
|
||||
@@ -72,7 +69,7 @@ export const ListWrap = () => {
|
||||
callList();
|
||||
}, [
|
||||
mid, startMonth, endMonth,
|
||||
receiptType, targetType
|
||||
receiptType, targetType, sortType
|
||||
]);
|
||||
|
||||
const getListDateGroup = () => {
|
||||
|
||||
Reference in New Issue
Block a user