diff --git a/src/components/NoticeModal/NoticeModal.tsx b/src/components/NoticeModal/NoticeModal.tsx index 5bfca42..2611574 100644 --- a/src/components/NoticeModal/NoticeModal.tsx +++ b/src/components/NoticeModal/NoticeModal.tsx @@ -217,27 +217,29 @@ export default function NoticeModal() { const rowSelection = { selectedRowKeys, onChange: (newselectedRowKeys: React.Key[], selectedRows: DataType[]) => { - selectedRowKeyRef.current[page]=newselectedRowKeys - selectedRowRef.current[page]=selectedRows + selectedRowKeyRef.current[page] = newselectedRowKeys + selectedRowRef.current[page] = selectedRows // console.log(11111111, newselectedRowKeys, selectedRowKeyRef.current); - const arr=[] + + const arr = [] for (const element in selectedRowKeyRef.current) { // console.log(22222,element); - + arr.push(...selectedRowKeyRef.current[element]) } setSelectedRowKeys(arr); - const arrIds=[] + const arrIds = [] for (const element in selectedRowRef.current) { // console.log(22222,element); - + arrIds.push(...selectedRowRef.current[element]) } const selectedOrderIds = arrIds.map(row => row.userMsgId); setIds(selectedOrderIds) + // setIds(arr) }, }; diff --git a/src/components/RefunModal/RefunModal.css b/src/components/RefunModal/RefunModal.css new file mode 100644 index 0000000..57640ae --- /dev/null +++ b/src/components/RefunModal/RefunModal.css @@ -0,0 +1,30 @@ +.refunModal{ + padding-top: 20px; +} +.refunModal-item{ + display: flex; + /* background-color: skyblue; */ + /* align-items: center; */ + /* justify-content: center; */ +} +.refunModal-title{ + font-size: 16px; + margin-right: 22px; + /* background-color: pink; */ + width: 80px; + display: flex; + justify-content: flex-end; + margin-top: 5px; + margin-left: 10px; +} +.refunModal-red{ + font-size: 20px; + margin-left: 5px; + color:#F04C4C +} +.refunModal-btn{ + /* background-color: skyblue; */ + display: flex; + justify-content: center; + margin-top: 20px; +} \ No newline at end of file diff --git a/src/components/RefunModal/RefunModal.tsx b/src/components/RefunModal/RefunModal.tsx new file mode 100644 index 0000000..41cbc9f --- /dev/null +++ b/src/components/RefunModal/RefunModal.tsx @@ -0,0 +1,189 @@ +import { useEffect, useState } from 'react' +import './RefunModal.css' +import { Form, Select, Button, Upload, message, Input } from 'antd'; +import { UploadOutlined } from '@ant-design/icons'; +import { uploadImageUrl, DevUserId,get } from "../../util/AjaxUtils.ts"; +const { TextArea } = Input; + +export default function RefunModal(props:any) { + const [messageApi, contextHolder] = message.useMessage(); + // 上传附件 + const [refunArray, setRefunArray] = useState([]); + const [selectedReason, setSelectedReason] = useState(''); //选择原因 + + const handleReasonChange = (value: any) => { + setSelectedReason(value); + }; + // const [refunDataArray,setRefunDataArray] = useState([]) //未退款项目 + // 提交表单 + const onFinish = (values: any) => { + console.log('Form values:', values); + props.closeModal() + }; + // 获取未退款项目 + const getRefunData = () => { + get({ + messageApi, + url: `/api/proj/refund/apply/list-proj-unapply/self`, + // url: `/api/proj/refund/apply/listpage?applyStatus=${state.type}`, + onSuccess({data}) { + console.log(data); + + } + }) + } + useEffect(()=>{ + getRefunData() + },[]) + return ( +
+ {contextHolder} +
+
+
+ 退款软著* +
+ + + +
+ {selectedReason === '其他' && ( +
+
+ 其他* +
+ +