diff --git a/src/route/Correction/Correction.tsx b/src/route/Correction/Correction.tsx index 034dc5d..df66679 100644 --- a/src/route/Correction/Correction.tsx +++ b/src/route/Correction/Correction.tsx @@ -57,7 +57,7 @@ export default function Correction() { // const MenuActive = getMenuActive() == 'Correction-PENDING' ? 'PENDING' : getMenuActive() == 'Correction-APPROVED' ? 'APPROVED' : getMenuActive() == 'Correction-REJECTED' ? 'REJECTED' : getMenuActive() == 'Correction-CANCELED' ? 'CANCELED' : '' // const [type, setType] = useState(null) const [isLoading, setIsLoading] = useState(false) - const [page, setPage] = useState(1) // 分页 + const [revokeModal, setRevokeModal] = useState(false) //撤销弹窗 // const [numtype, setnumtype] = useState(null) //类型 一次 二次 // const [correctionType, setcorrectionType] = useState(null) //补正种类 @@ -72,6 +72,8 @@ export default function Correction() { const authorId = state ? state.authorId : '' const correctionNumType = state ? state.correctionNumType : '' const correctionType = state ? state.correctionType : '' + // const Ppage = state? state.page : 1 + const [page, setPage] = useState(1) // 分页 // const columns: TableProps['columns'] = // // 撤销状态 // applyStatus == 'CANCELED' ? [ @@ -876,8 +878,9 @@ export default function Correction() { useEffect(() => { // getData(1) - setPage(1) + getData(1) + setPage(1) // console.log(tagCor); // console.log('嘻嘻',correctionArray); @@ -1194,7 +1197,7 @@ export default function Correction() {
- { + { setPage(page) getData(page) diff --git a/src/route/Refun/Refun.tsx b/src/route/Refun/Refun.tsx index 773e5fc..0ee28c3 100644 --- a/src/route/Refun/Refun.tsx +++ b/src/route/Refun/Refun.tsx @@ -754,7 +754,7 @@ export default function Refun() {
- { + { setPage(page) getData(page) diff --git a/src/route/index/Index.tsx b/src/route/index/Index.tsx index 7eff8c1..8119acd 100644 --- a/src/route/index/Index.tsx +++ b/src/route/index/Index.tsx @@ -81,7 +81,7 @@ export default function Index() { // 选择的标签 const [tagCor, setTagCor] = useState(null) - + // 选项数组 const [tagArray, setTagArray] = useState([]) @@ -242,7 +242,7 @@ export default function Index() { setCurrentPage(page); } }; - + const nav = useNavigate(); // // home页初始化搜索条件 const init = () => { setNowKeyWord('') @@ -252,12 +252,15 @@ export default function Index() { settagDataId(null) setpayStatus(null) setprojRemindId(null) + nav('/home') } // 退款页初搜索条件始化 const refunInit = () => { setnewRefunValue('') setrefunKeywords('') setapplyStatus(null) + // 刷新当前页面 + } // 补正页面搜索条件初始化 const correctionInit = () => { @@ -268,7 +271,7 @@ export default function Index() { setcorrectionApplyStatus(null) setTagCor(null) } - const nav = useNavigate(); + const [searchParams] = useSearchParams(); const listReducer = (state: ListData, action: ListAction) => { @@ -892,7 +895,8 @@ export default function Index() { state: { keywords: refunKeywords, applyStatus: applyStatus, - authorId: authorId + authorId: authorId, + } }) } @@ -904,12 +908,13 @@ export default function Index() { correctionType: correctionType, applyStatus: correctionApplyStatus, authorId: authorId, - tagCor:tagCor, + tagCor: tagCor, + } }) } - }, [type, chargeAdditionals, keywords, tagDataId, projRemindId, payStatus, authorId, refunKeywords, applyStatus, correctionKeywords, correctionNumType, correctionType, correctionApplyStatus,tagCor]); + }, [type, chargeAdditionals, keywords, tagDataId, projRemindId, payStatus, authorId, refunKeywords, applyStatus, correctionKeywords, correctionNumType, correctionType, correctionApplyStatus, tagCor]); // const [menuName,setMenuName] = useState('') // useEffect(()=>{ @@ -963,7 +968,8 @@ export default function Index() { state: { keywords: value, applyStatus: applyStatus, - authorId: authorId + authorId: authorId, + } }) } @@ -976,7 +982,8 @@ export default function Index() { state: { keywords: '', applyStatus: applyStatus, - authorId: authorId + authorId: authorId, + } }) } @@ -992,7 +999,8 @@ export default function Index() { correctionType: correctionType, applyStatus: correctionApplyStatus, authorId: authorId, - tagCor:tagCor, + tagCor: tagCor, + } }) } @@ -1008,7 +1016,8 @@ export default function Index() { correctionType: correctionType, applyStatus: correctionApplyStatus, authorId: authorId, - tagCor:tagCor, + tagCor: tagCor, + } }) } @@ -1052,7 +1061,7 @@ export default function Index() { correctionNumType={correctionNumType ? correctionNumType : ''} correctionType={correctionType ? correctionType : ''} correctionApplyStatus={correctionApplyStatus ? correctionApplyStatus : ''} - tagCor = {tagCor? tagCor : ''} + tagCor={tagCor ? tagCor : ''} // enableBelongpeople = {()=>{setClickBelongpeople(true)}} /> @@ -1346,7 +1355,7 @@ export default function Index() { // if (part1 == 'TAG_NOT') { // setTagNot(true) // } - + settagDataId(value) // alert(`selected ${value}`) // lyp @@ -1374,7 +1383,7 @@ export default function Index() { />
0 ? 'block' : 'none', + display: remindTagArray.length > 0 ? 'block' : 'none', }}> { @@ -1646,7 +1659,8 @@ export default function Index() { correctionType: correctionType, applyStatus: applyStatus, authorId: authorId, - tagCor:value, + tagCor: value, + } }) }}