diff --git a/src/components/SelectGaodeLngLat/blue-point.png b/src/components/SelectGaodeLngLat/blue-point.png
new file mode 100644
index 0000000..ee86a76
Binary files /dev/null and b/src/components/SelectGaodeLngLat/blue-point.png differ
diff --git a/src/components/SelectGaodeLngLat/index.jsx b/src/components/SelectGaodeLngLat/index.jsx
index 7f1b24b..bf894e1 100644
--- a/src/components/SelectGaodeLngLat/index.jsx
+++ b/src/components/SelectGaodeLngLat/index.jsx
@@ -6,7 +6,8 @@ import "leaflet/dist/leaflet.css";
import "leaflet.chinatmsproviders";
import ajax from "@/services";
import "./index.scss";
-
+import { compileString } from "sass";
+import Rerm from "./blue-point.png";
let timer = null;
function SelectGaodeLngLat(props) {
const {
@@ -17,6 +18,7 @@ function SelectGaodeLngLat(props) {
onChange = () => { },
} = props;
const [lnglat, setLnglat] = useState([]);
+ const [marker, setMarker] = useState([]);
const [address, setAddress] = useState("");
const [searchLnglatValue, setSearchLnglatValue] = useState([]);
const [getLngLabel, setGetLngLabel] = useState([])
@@ -59,6 +61,7 @@ function SelectGaodeLngLat(props) {
let add = getLngLabel.filter((ele) => ele.value == data)[0] || [];
console.log(add);
// setSearchLnglatValue([ add.lng,add.lat])
+ setMarker([add.lng, add.lat])
setLnglat([add.lng, add.lat]);
getLntLat([add.lng, add.lat]);
};
@@ -103,7 +106,9 @@ function SelectGaodeLngLat(props) {
setLnglat={setLnglat}
getLntLat={getLntLat}
searchLnglatValue={searchLnglatValue}
- />
+ markerPoint={marker}
+ >
+
@@ -142,6 +147,7 @@ function ModalMap(props) {
setLnglat = () => { },
getLntLat = () => { },
searchLnglatValue = [],
+ markerPoint = []
} = props;
const mapConfig = {
center: sysConfig.map.center,
@@ -154,6 +160,7 @@ function ModalMap(props) {
mapTileType: sysConfig.map.mapTileType,
};
const [map, setMap] = useState(null);
+ const [Marker, setMarker] = useState(null);
const mapRef = useRef(null);
const initMap = () => {
// console.log(mapConfig);
@@ -195,6 +202,30 @@ function ModalMap(props) {
})
mapRef.current = map
};
+ useEffect(() => {
+ if (map) {
+ addMarker(markerPoint); // 添加点位
+ }
+ }, [markerPoint]);
+ const markerContent = `
+

+
`;
+ const addMarker = (data) => {
+ if(data.length==0) return
+ if (Marker) {
+ map.remove(Marker);
+ }
+ let marker = new AMap.Marker({
+ position: new AMap.LngLat(parseFloat(data[0]), parseFloat(data[1])),
+ content: markerContent,
+ offset: new AMap.Pixel(-24, -45),
+ });
+ map.add(marker);
+ setMarker(marker);
+ setTimeout(() => {
+ map.setCenter(new AMap.LngLat(parseFloat(data[0]), parseFloat(data[1])));
+ }, 800);
+ };
function clearMarkers(map) {
map.eachLayer(function (layer) {
if (layer instanceof L.Marker) {
@@ -211,10 +242,10 @@ function ModalMap(props) {
};
}, []);
useEffect(() => {
- setTimeout(()=>{
+ setTimeout(() => {
if (searchLnglatValue.length === 0) return;
mapRef.current.setView(searchLnglatValue, 13);
- },800)
+ }, 800)
}, [searchLnglatValue]);
return (
diff --git a/src/pages/DataAnalysisPrediction/ParkingBusinessAly/CarTypeAly/loadable.jsx b/src/pages/DataAnalysisPrediction/ParkingBusinessAly/CarTypeAly/loadable.jsx
index 0dd664f..f89e284 100644
--- a/src/pages/DataAnalysisPrediction/ParkingBusinessAly/CarTypeAly/loadable.jsx
+++ b/src/pages/DataAnalysisPrediction/ParkingBusinessAly/CarTypeAly/loadable.jsx
@@ -77,6 +77,7 @@ function CarTypeAly() {
}
}, [isAjax])
useEffect(() => {
+ console.log(formData)
if (show.length > 0 || show == 1) {
setSessionTabList({
...formData,
@@ -85,6 +86,7 @@ function CarTypeAly() {
} else {
setSessionTabList({
...formData,
+ //show: show.length > 0 ? show : []
})
}
}, [formData, show])
diff --git a/src/pages/FinancialMgm/OrderInquiry/OrderChangeInquiry/index.jsx b/src/pages/FinancialMgm/OrderInquiry/OrderChangeInquiry/index.jsx
index a261324..9f2dbaf 100644
--- a/src/pages/FinancialMgm/OrderInquiry/OrderChangeInquiry/index.jsx
+++ b/src/pages/FinancialMgm/OrderInquiry/OrderChangeInquiry/index.jsx
@@ -294,7 +294,7 @@ function EditOrderInquiry(props) {
align: "center",
width: 160,
render: (text, data) => {
- console.log(text);
+ //console.log(text);
if (data.arrearsAmount_new) {
return
{data.arrearsAmount}
@@ -888,7 +888,7 @@ function EditOrderInquiry(props) {
diff --git a/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/EffectiveDate.jsx b/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/EffectiveDate.jsx
index 89a0f23..21ce667 100644
--- a/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/EffectiveDate.jsx
+++ b/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/EffectiveDate.jsx
@@ -76,6 +76,7 @@ function EffectiveDate(props) {
"minutes"
)
);
+ total += 1;
} else {
total += Math.abs(
moment(timePartList[i].end, "HH:mm:ss").diff(
@@ -83,11 +84,16 @@ function EffectiveDate(props) {
"minutes"
)
);
+ console.log(Math.abs(
+ moment(timePartList[i].end, "HH:mm:ss").diff(
+ moment(timePartList[i].start, "HH:mm:ss"),
+ "minutes"
+ )
+ ))
}
arr.push(timePartList[i].end)
arr.push(timePartList[i].start)
}
- total += 1;
if (total === 1440) {
if ([...new Set(arr)].length != timePartList.length) {
message.error('时段范围不能重叠!')
diff --git a/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/TimePart.jsx b/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/TimePart.jsx
index ecfdabd..e1be6cb 100644
--- a/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/TimePart.jsx
+++ b/src/pages/OutRoadMgm/OutSegmentMgm/ChargeRulesMgm/TimePart.jsx
@@ -192,7 +192,7 @@ function TimePart(props) {
-
*时段结束时间00:00:00相当于23:59:59
+
*时段结束时间设置00:00:00相当于23:59:59
{index === 1 ? null : (
diff --git a/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/AddParking.jsx b/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/AddParking.jsx
index 1cb79f6..0e8a611 100644
--- a/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/AddParking.jsx
+++ b/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/AddParking.jsx
@@ -273,7 +273,20 @@ function AddParking(props) {
})
.catch((err) => console.error(err));
}
-
+ const valueChange = (value, all) => {
+ if (value.road_type) {
+ form.setFieldsValue({
+ pid: '',
+ area_id: '',
+ operator_id: '',
+ address: '',
+ is_business: '',
+ cooperate_type: '',
+ access_type:'',
+ })
+ setLngLat([])
+ }
+ };
useEffect(() => {
getAreaList();
operationName();
@@ -295,6 +308,7 @@ function AddParking(props) {
form={form}
labelCol={{ span: 8 }}
colon={false}
+ onValuesChange={valueChange}
initialValues={
status === "edit"
? {
@@ -348,7 +362,6 @@ function AddParking(props) {
>
{({ getFieldValue }) => {
const type = getFieldValue("road_type");
- console.log(type);
if (type !== 0 && type !== 1) {
return (
diff --git a/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/BillingRules.jsx b/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/BillingRules.jsx
index ee446d4..6ff2779 100644
--- a/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/BillingRules.jsx
+++ b/src/pages/OutRoadMgm/OutSegmentMgm/OutSegment/ConfigParking/BillingRules.jsx
@@ -72,7 +72,7 @@ function BillingRules(props) {
{
- setModalData({ ...modalData, visible: true });
+ setModalData({ ...modalData, visible: true, stutus: 'edit' });
console.log(record.group_ids);
editform.setFieldsValue({
rule_id: record.rule_id,
@@ -125,7 +125,7 @@ function BillingRules(props) {
id: "",
});
const addRule = () => {
- setModalData({ ...modalData, visible: true });
+ setModalData({ ...modalData, visible: true, status: 'add' });
};
//搜索方法
@@ -150,8 +150,8 @@ function BillingRules(props) {
});
};
//获取临时车辆组
- const getTempGroup = () => {
- ajax.getRoadTemporaryGroup({ road_id: id }).then((res) => {
+ const getTempGroup = (type) => {
+ ajax.getRoadTemporaryGroup({ road_id: id, vehicle_type: type }).then((res) => {
if (res.status === 20000) {
setTempGroup(res.data);
}
@@ -216,8 +216,14 @@ function BillingRules(props) {
useEffect(() => {
getChargeRuleList();
- getTempGroup();
}, []);
+ const valueChange = (value, all) => {
+ console.log(value, all)
+ if (value.vehicle_type) {
+ getTempGroup(value.vehicle_type);
+ editform.setFieldsValue({ group_ids: '' })
+ }
+ };
useEffect(() => {
search();
}, [pageData]);
@@ -266,7 +272,7 @@ function BillingRules(props) {
>
{
setModalData({ ...modalData, visible: false });
@@ -274,7 +280,7 @@ function BillingRules(props) {
}}
onOk={submit}
>
-
-
+
@@ -398,7 +398,7 @@ function BlacklistManagement({ id }) {
>