Browse Source

fix():bug修改

master
xingjx 1 year ago
parent
commit
212b209c6c
  1. 31
      src/pages/OperationCenter/ArrearsRecover/ArrearsCar/loadable.jsx
  2. 2
      src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/CarMgm/CarManagement.jsx
  3. 30
      src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/LEDConfiguration.jsx
  4. 2
      src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/index.jsx
  5. 9
      src/services/OutRoadMgm/OutSegment.js

31
src/pages/OperationCenter/ArrearsRecover/ArrearsCar/loadable.jsx

@ -26,61 +26,88 @@ function ArrearsCar() {
title: "车牌号", title: "车牌号",
dataIndex: "plate_info", dataIndex: "plate_info",
key: "plate_info", key: "plate_info",
align: "center",
fixed: "right",
render: (text) => {
return <div style={{ width: 90 }}> {text}</div>;
},
}, },
{ {
title: "车辆归属地", title: "车辆归属地",
dataIndex: "area", dataIndex: "area",
key: "area", key: "area",
align: "center",
fixed: "right",
}, },
{ {
title: "欠费总金额(元)", title: "欠费总金额(元)",
dataIndex: "amount", dataIndex: "amount",
key: "amount", key: "amount",
align: "center",
fixed: "right",
}, },
{ {
title: "追缴金额(元)", title: "追缴金额(元)",
dataIndex: "currentRefund", dataIndex: "currentRefund",
key: "currentRefund", key: "currentRefund",
align: "center",
fixed: "right",
}, },
{ {
title: "欠费总订单数", title: "欠费总订单数",
dataIndex: "amount_count", dataIndex: "amount_count",
key: "amount_count", key: "amount_count",
align: "center",
fixed: "right",
}, },
{ {
title: "追缴单数", title: "追缴单数",
dataIndex: "refund_count", dataIndex: "refund_count",
key: "refund_count", key: "refund_count",
align: "center",
fixed: "right",
}, },
{ {
title: "电话追缴次数", title: "电话追缴次数",
dataIndex: "mobile_count", dataIndex: "mobile_count",
key: "mobile_count", key: "mobile_count",
align: "center",
fixed: "right",
}, },
{ {
title: "会员电话", title: "会员电话",
dataIndex: "user_mobile", dataIndex: "user_mobile",
key: "user_mobile", key: "user_mobile",
align: "center",
fixed: "right",
}, },
{ {
title: "公安接口电话", title: "公安接口电话",
dataIndex: "police_mobile", dataIndex: "police_mobile",
key: "police_mobile", key: "police_mobile",
align: "center",
fixed: "right",
}, },
{ {
title: "三方导入电话", title: "三方导入电话",
dataIndex: "third_mobile", dataIndex: "third_mobile",
key: "third_mobile", key: "third_mobile",
align: "center",
fixed: "right",
}, },
{ {
title: "近日自主停车", title: "近日自主停车",
dataIndex: "parking_mobile", dataIndex: "parking_mobile",
key: "parking_mobile", key: "parking_mobile",
align: "center",
fixed: "right",
}, },
{ {
title: "可触达性", title: "可触达性",
dataIndex: "if_call", dataIndex: "if_call",
key: "if_call", key: "if_call",
align: "center",
fixed: "right",
}, },
{ {
title: "操作", title: "操作",
@ -159,7 +186,7 @@ function ArrearsCar() {
key: "in_veh_pic", key: "in_veh_pic",
render: (text, record, index) => { render: (text, record, index) => {
return <div className="veh-item-img "> return <div className="veh-item-img ">
<img src={text || require("../../../../../src/assets/images/error-img.png")} onClick={() => { setBigPic(baseData.authImg2); setBigpicVisible(true) }}/>
<img src={text || require("../../../../../src/assets/images/error-img.png")} onClick={() => { setBigPic(text); setBigpicVisible(true) }}/>
</div> </div>
}, },
}, },
@ -169,7 +196,7 @@ function ArrearsCar() {
key: "out_veh_pic", key: "out_veh_pic",
render: (text, record, index) => { render: (text, record, index) => {
return <div className="veh-item-img "> return <div className="veh-item-img ">
<img src={text || require("../../../../../src/assets/images/error-img.png")} onClick={() => { setBigPic(baseData.authImg2); setBigpicVisible(true) }}/>
<img src={text || require("../../../../../src/assets/images/error-img.png")} onClick={() => { setBigPic(text); setBigpicVisible(true) }}/>
</div> </div>
}, },
}, },

2
src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/CarMgm/CarManagement.jsx

@ -130,9 +130,11 @@ function CarManagement({ id }) {
onClick={() => { onClick={() => {
if (record.status === 1) { if (record.status === 1) {
disableVehicle(record.id); disableVehicle(record.id);
submit(form.getFieldValue());
return; return;
} }
enableVehicle(record.id); enableVehicle(record.id);
submit(form.getFieldValue());
}} }}
> >
{record.status === 1 ? "禁用" : "启用"} {record.status === 1 ? "禁用" : "启用"}

30
src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/LEDConfiguration.jsx

@ -13,7 +13,7 @@ import {
} from "antd"; } from "antd";
const { TextArea } = Input; const { TextArea } = Input;
import ajax from "@/services"; import ajax from "@/services";
function GateControlManagement({ id: road_id }) {
function LEDConfiguration({ id }) {
const columns = [ const columns = [
{ {
title: "业务场景", title: "业务场景",
@ -94,6 +94,7 @@ function GateControlManagement({ id: road_id }) {
visible: false, visible: false,
id: null, id: null,
}); });
const [businessList, setBusinessList] = useState([]); //
const [dataSource, setDataSource] = useState([]); // const [dataSource, setDataSource] = useState([]); //
const [total, setTotal] = useState(0); const [total, setTotal] = useState(0);
const addLEDText = () => { const addLEDText = () => {
@ -104,7 +105,7 @@ function GateControlManagement({ id: road_id }) {
page_size: 10, page_size: 10,
}); });
const search = () => { const search = () => {
const params = { ...form.getFieldsValue(), ...pageData, road_id };
const params = { ...form.getFieldsValue(), ...pageData, id };
ajax.getLEDList(params).then((res) => { ajax.getLEDList(params).then((res) => {
if (res.status === 20000) { if (res.status === 20000) {
setDataSource(res.data.list); setDataSource(res.data.list);
@ -144,10 +145,10 @@ function GateControlManagement({ id: road_id }) {
.validateFields() .validateFields()
.then((res) => { .then((res) => {
if (modalData.status === "add") { if (modalData.status === "add") {
res.road_id = road_id;
res.road_id = id;
addLED(res); addLED(res);
} else { } else {
res.road_id = road_id;
res.road_id = id;
editLED(res); editLED(res);
} }
}) })
@ -164,6 +165,19 @@ function GateControlManagement({ id: road_id }) {
}); });
setDelModal({ visible: false, id: null }); setDelModal({ visible: false, id: null });
} }
function getLEDBusiness() {
ajax.getLEDBusiness({ road_id: id }).then((res) => {
if (res.status == 20000) {
setBusinessList(res.data)
} else {
message.error(res.message);
}
});
setDelModal({ visible: false, id: null });
}
useEffect(() => {
getLEDBusiness();
}, []);
useEffect(() => { useEffect(() => {
search(); search();
}, [pageData]); }, [pageData]);
@ -174,7 +188,7 @@ function GateControlManagement({ id: road_id }) {
<Row> <Row>
<Col span="4_8" style={{ width: "30%" }}> <Col span="4_8" style={{ width: "30%" }}>
<Form.Item label="业务场景" name="business_type"> <Form.Item label="业务场景" name="business_type">
<Select />
<Select options={businessList || []}/>
</Form.Item> </Form.Item>
</Col> </Col>
<Form.Item> <Form.Item>
@ -194,7 +208,7 @@ function GateControlManagement({ id: road_id }) {
<Table <Table
dataSource={dataSource} dataSource={dataSource}
columns={columns} columns={columns}
// className="yisa-table"
// className="yisa-table"
/> />
</main> </main>
<Modal <Modal
@ -212,7 +226,7 @@ function GateControlManagement({ id: road_id }) {
rules={[{ required: true }]} rules={[{ required: true }]}
name="business_type" name="business_type"
> >
<Select disabled={modalData.status === "edit"} />
<Select options={businessList || []} disabled={modalData.status === "edit"} />
</Form.Item> </Form.Item>
<Form.Item <Form.Item
label="LED显示文案" label="LED显示文案"
@ -240,4 +254,4 @@ function GateControlManagement({ id: road_id }) {
); );
} }
export default GateControlManagement;
export default LEDConfiguration;

2
src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/index.jsx

@ -36,7 +36,7 @@ function ConfigParking(props) {
{ {
label: "开闸方式管理", label: "开闸方式管理",
key: "5", key: "5",
children: <GateControlManagement />,
children: <GateControlManagement id={itemData.id}/>,
}, },
{ {
label: "LED配置", label: "LED配置",

9
src/services/OutRoadMgm/OutSegment.js

@ -279,6 +279,14 @@ const deleteWhiteVehicle = (params) => {
data: params, data: params,
}); });
}; };
///api/orp/road/can_add_business_type 能够新增的业务场景
const getLEDBusiness = (params) => {
return ajax({
url: "/api/orp/road/can_add_business_type",
type: "post",
data: params,
});
};
///api/orp/road/led_list led配置列表 ///api/orp/road/led_list led配置列表
const getLEDList = (params) => { const getLEDList = (params) => {
return ajax({ return ajax({
@ -489,6 +497,7 @@ export default {
enableWhiteVehicle, enableWhiteVehicle,
disableWhiteVehicle, disableWhiteVehicle,
deleteWhiteVehicle, deleteWhiteVehicle,
getLEDBusiness,
getLEDList, getLEDList,
editLED, editLED,
addLED, addLED,

Loading…
Cancel
Save