From 51f5871ddf759b6a82b82b653a06f6c8714a7622 Mon Sep 17 00:00:00 2001 From: xingjx Date: Tue, 19 Sep 2023 15:46:11 +0800 Subject: [PATCH] =?UTF-8?q?fix():=E4=BF=AE=E6=94=B9=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=EF=BC=8C=E8=BD=A6=E8=BE=86=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/css/base.scss | 6 +- src/components/TableModule/index.jsx | 10 +- .../ArrearsRecover/ArrearsCar/index.scss | 6 + .../ArrearsRecover/ArrearsCar/loadable.jsx | 234 +++++++---- .../OperationCenter/CarMgm/CarAuth/index.scss | 11 +- .../OperationCenter/CarMgm/CarAuth/loadable.jsx | 72 +++- .../OperationCenter/CarMgm/CarInfo/dataSource.js | 262 +++--------- .../OperationCenter/CarMgm/CarInfo/index.scss | 31 +- .../OperationCenter/CarMgm/CarInfo/loadable.jsx | 372 ++++++++-------- .../OperationCenter/UserMgm/UserInfo/dataSource.js | 258 ------------ .../OperationCenter/UserMgm/UserInfo/error.png | Bin 0 -> 7538 bytes .../OperationCenter/UserMgm/UserInfo/index.scss | 71 ++-- .../OperationCenter/UserMgm/UserInfo/loadable.jsx | 466 ++++++++++++--------- 13 files changed, 824 insertions(+), 975 deletions(-) delete mode 100644 src/pages/OperationCenter/UserMgm/UserInfo/dataSource.js create mode 100644 src/pages/OperationCenter/UserMgm/UserInfo/error.png diff --git a/src/assets/css/base.scss b/src/assets/css/base.scss index eba803e..e92980b 100644 --- a/src/assets/css/base.scss +++ b/src/assets/css/base.scss @@ -109,18 +109,18 @@ a { tr { &:nth-child(2n) { td { - background: #fff !important; + //background: #fff !important; } } &:hover { td { - background: #f0f5fc !important; + //background: #f0f5fc !important; } } td { - background: #fff !important; + //background: #fff !important; border-bottom-color: #f2f2f2; } } diff --git a/src/components/TableModule/index.jsx b/src/components/TableModule/index.jsx index 01264d9..ea8d988 100644 --- a/src/components/TableModule/index.jsx +++ b/src/components/TableModule/index.jsx @@ -161,7 +161,10 @@ function TableModule(props) { name={item.name} key={item.name} > - + { + item.hiddenCount ? : + + } ); break; @@ -225,10 +228,7 @@ function TableModule(props) { { openModal(); - setDetailData(record); - setParkID(record.park_id) + setCarId(record.car_id) + searchDetail(record.car_id) }}> 欠费详情 @@ -119,18 +115,18 @@ function ArrearsCar() { }, { title: "区域", - dataIndex: "region", - key: "region", + dataIndex: "area", + key: "area", }, { title: "停车场名称", - dataIndex: "operator", - key: "operator", + dataIndex: "road_name", + key: "road_name", }, { title: "车牌号", - dataIndex: "road", - key: "road", + dataIndex: "plate_number", + key: "plate_number", }, { title: "入场时间", @@ -144,23 +140,23 @@ function ArrearsCar() { }, { title: "停车时长", - dataIndex: "admission_time", - key: "admission_time", + dataIndex: "parking_duration", + key: "parking_duration", }, { title: "欠费金额", - dataIndex: "in_person", - key: "in_person", + dataIndex: "arrears_mount", + key: "arrears_mount", }, { title: "入场照片", - dataIndex: "out_person", - key: "out_person", + dataIndex: "in_veh_pic", + key: "in_veh_pic", }, { title: "出场照片", - dataIndex: "authentication", - key: "authentication", + dataIndex: "out_veh_pic", + key: "out_veh_pic", }, ]; const formSearch = [ @@ -171,7 +167,22 @@ function ArrearsCar() { placeholder: "请输入车牌号", }, { - name: "k", + name: "refund_amount_min", + type: "Input", + label: "欠费金额", + placeholder: "请输入", + hiddenCount: 1 + + }, + { + name: "refund_amount_max", + type: "Input", + label: "至", + placeholder: "请输入", + hiddenCount: 1 + }, + { + name: "if_call", type: "Select", label: "可触达性", options: [ @@ -190,13 +201,42 @@ function ArrearsCar() { ], }, { - name: "phone", - type: "Input", + name: "user_mobile", + type: "Select", label: "会员电话", - placeholder: "请输入会员电话", + placeholder: "请选择", + options: [ + { + label: "全部", + value: 0, + }, + { + label: "有", + value: 1, + }, + { + label: "无", + value: 2, + }, + ], }, { - name: "status", + name: "count_min", + type: "Input", + label: "电话追缴次数", + placeholder: "请输入", + hiddenCount: 1 + + }, + { + name: "count_max", + type: "Input", + label: "至", + placeholder: "请输入", + hiddenCount: 1 + }, + { + name: "auto_parking", type: "Select", label: "近日自主停车", placeholder: "请选择", @@ -207,17 +247,17 @@ function ArrearsCar() { value: 0, }, { - label: "是", + label: "有", value: 1, }, { - label: "否", + label: "无", value: 2, }, ], }, { - name: "type", + name: "police", type: "Select", label: "公安接口电话", defaultValue: 1, @@ -227,44 +267,71 @@ function ArrearsCar() { value: 0, }, { - label: "是", + label: "有", value: 1, }, { - label: "否", + label: "无", value: 2, }, ], }, ]; const [resultData, setResultData] = useState([]) - const [detailData, setDetailData] = useState([]) + const [detailData, setDetailData] = useState([{ index: '1' }]) const [modalVisible, setModalVisible] = useState(false); const [total, setTotal] = useState(0); - + const [pageData, setPageData] = useState({ + // 分页参数 + pn: 1, + page_size: 15, + }); + function onShowSizeChange(pn, page_size) { + setPageData({ + pn, + page_size, + }); + } function openModal(params) { setModalVisible(true); } function search(e) { - if (!e.type) { - e.type = 1 - } + //setResultData([{ index: '1', car_id: '21111' }]) ajax({ - url: "/api/bpm/record/get_record_list", + url: "/api/ope/record/get_refund_car_list", type: "post", - data: { ...e, cj_temporary: 1 }, + data: { ...e }, }).then((res) => { let { status, data, total } = res if (status == 20000) { - setResultData(data.list) - setTotal(data.total) + setResultData(data) + setTotal(total) } else { message.error(res.message) } }) } - + function searchDetail(e) { + //setResultData([{ index: '1' }]) + //console.log(carId, e) + ajax({ + url: "/api/ope/record/get_arrearage_car_info", + type: "get", + data: { carId: e }, + }).then((res) => { + let { status, data, total } = res + if (status == 20000) { + setDetailData(data) + //setTotal(total) + } else { + message.error(res.message) + } + }) + } + useEffect(() => { + searchDetail() + }, [pageData]); return ( <> { setModalVisible(false); }} footer={false} > -
- - +
+ `共 ${total_records} 条`} + total={0} + current={pageData.pn} + pageSize={pageData.page_size} + pageSizeOptions={dictionary?.pageSizeOptions} + onChange={onShowSizeChange} + onShowSizeChange={onShowSizeChange} + /> - ); } diff --git a/src/pages/OperationCenter/CarMgm/CarAuth/index.scss b/src/pages/OperationCenter/CarMgm/CarAuth/index.scss index 4c620ce..f3103e9 100644 --- a/src/pages/OperationCenter/CarMgm/CarAuth/index.scss +++ b/src/pages/OperationCenter/CarMgm/CarAuth/index.scss @@ -214,4 +214,13 @@ $color-primary : var(--color-primary); } } -} \ No newline at end of file +} +.pass-icon { + height: 22px; + width: 20px; + border-radius: 10px; + background: #ffbb26; + display: inline-block; + text-align: center; + font-weight: 800; +} \ No newline at end of file diff --git a/src/pages/OperationCenter/CarMgm/CarAuth/loadable.jsx b/src/pages/OperationCenter/CarMgm/CarAuth/loadable.jsx index bc9507f..88d2afd 100644 --- a/src/pages/OperationCenter/CarMgm/CarAuth/loadable.jsx +++ b/src/pages/OperationCenter/CarMgm/CarAuth/loadable.jsx @@ -14,6 +14,7 @@ import { Descriptions, Transfer } from "antd"; +const { TextArea } = Input; import moment from "moment"; import ajax from '@/config/ajax.js' import { TableModule, ResultFlow, } from "@/components"; @@ -95,22 +96,26 @@ function CarAuth() { <> { setTag('2'); + setCarId(record.carId) setIndexby(index) }}> - 详情 + {record.auditState == "待审核" || record.auditState == "残疾车待审核" ? "审核" : "查看"} ), }, ]; + const [carId, setCarId] = useState(); const [loading, setLoading] = useState(false); const [tag, setTag] = useState('1'); const [bigpicVisible, setBigpicVisible] = useState(false);//大图展示 + const [passVisible, setPassVisible] = useState(false); + const [refuseVisible, setRefuseVisible] = useState(false); + const [toText, setToText] = useState(); const [bigPic, setBigPic] = useState(); const [resultData, setResultData] = useState([]); const [total, setTotal] = useState(0); const [indexby, setIndexby] = useState(0); - const [sfyVisible, setSfyVisible] = useState(false); const [formData, setFormData] = useState({}) const [pageData, setPageData] = useState({ // 分页参数 @@ -145,6 +150,27 @@ function CarAuth() { } }) } + function toAudits(e) { + ajax({ + url: "/api/ope/car/audit", + type: "post", + data: { carId: carId, audit: e ? "pass" : "refuse", text: e ? null : toText }, + }).then((res) => { + let { status, data, total } = res + if (status == 20000) { + // setResultData(data) + // setTotal(total) + setPassVisible(false) + setRefuseVisible(false) + setToText('') + } else { + message.error(res.message) + } + }) + } + const handleOpinion = (v) => { + setToText(v.target.value) + } useEffect(() => { search() }, [formData, pageData]); @@ -188,10 +214,10 @@ function CarAuth() { - {resultData[indexby].r == 1 || resultData[indexby].r == 4 ? + {resultData[indexby].auditState == '待审核' || resultData[indexby].auditState == '残疾车待审核' ?
-
{ }}>通过
-
{ }}>拒绝
+
{ setPassVisible(true) }}>通过
+
{ setRefuseVisible(true) }}>拒绝
{ setTag('1') }}>取消
: null} : @@ -285,6 +311,42 @@ function CarAuth() { + { + setPassVisible(false); + }} + onOk={() => { toAudits(1) }} + > +
+
!
请您确认审核资料是否无误! +
+
+ { + setRefuseVisible(false); + }} + onOk={() => { toAudits(0) }} + > +
+
+ 请输入拒审理由: +