From 4846055a89e780009fab6f8be86417ab1ba0cca9 Mon Sep 17 00:00:00 2001 From: guoxin Date: Thu, 7 Dec 2023 18:02:34 +0800 Subject: [PATCH] =?UTF-8?q?fix():=E5=A4=84=E7=90=86=E8=B7=AF=E5=86=85bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../InRoadMgm/BusinessMgm/Blacklist/loadable.jsx | 5 ++- .../BusinessMgm/SpecialRecord/loadable.jsx | 15 ++++++--- .../Attendance/WorkerSchedule/loadable.jsx | 38 ++++++++++++++-------- .../DisabledCarParkRecordTotal/loadable.jsx | 2 +- .../InRoadMgm/RoadMgm/ConfigRoad/loadable.jsx | 12 ++----- .../CallbackSuggestion/loadable.jsx | 30 ++++++++++++----- .../GeoSignalIgnore/GeoSignalIgnoreConf/index.scss | 1 + .../GeoSignalIgnoreConf/loadable.jsx | 32 +++++++++++++----- src/pages/SystemMgm/RoleMgm/loadable.jsx | 7 ++-- src/services/InroadMgm/RoadMgm/RoadMgm.js | 4 +-- 10 files changed, 93 insertions(+), 53 deletions(-) diff --git a/src/pages/InRoadMgm/BusinessMgm/Blacklist/loadable.jsx b/src/pages/InRoadMgm/BusinessMgm/Blacklist/loadable.jsx index 7783614..fabd5da 100644 --- a/src/pages/InRoadMgm/BusinessMgm/Blacklist/loadable.jsx +++ b/src/pages/InRoadMgm/BusinessMgm/Blacklist/loadable.jsx @@ -53,6 +53,7 @@ function Blacklist(props) { const handlePlateColor = (v) => { setGetAddData({ ...getAddData, plate_color_id: v }) } + console.log(getAddData); //商户名称 const handleOperatorName = (v) => { setGetAddData({ ...getAddData, operator_id: v }) @@ -69,7 +70,7 @@ function Blacklist(props) { message.error('请输入车牌号') } else if (getAddData.operator_id == '') { message.error('请选择商户名称') - } else if (getAddData.plate_color_id == '') { + } else if (getAddData.plate_color_id === '') { message.error('请选择车牌颜色') }else { ajax.addChange(data).then(res => { @@ -82,6 +83,8 @@ function Blacklist(props) { plate_color: '', content: '', }) + }else{ + message.error(res.message) } }) } diff --git a/src/pages/InRoadMgm/BusinessMgm/SpecialRecord/loadable.jsx b/src/pages/InRoadMgm/BusinessMgm/SpecialRecord/loadable.jsx index bd8e88f..dfa1811 100644 --- a/src/pages/InRoadMgm/BusinessMgm/SpecialRecord/loadable.jsx +++ b/src/pages/InRoadMgm/BusinessMgm/SpecialRecord/loadable.jsx @@ -377,12 +377,14 @@ function CollectorWorkStat(props) { }, ] const [getCheckPic, setGetCheckPic] = useState([]) + const [getTableId, setGetTableId] = useState({}) + const CheckBtn = (record) => { setGetCheckData(record) setGetCheckPic(record.image) setCheckVisible(true) - columnList(record) - getTable() + getTable(record) + setGetTableId(record.id) } const [getImage, setGetImage] = useState([]) const CheckApplyBtn = (record) => { @@ -439,15 +441,18 @@ function CollectorWorkStat(props) { data: [], total_records: 0, }) - const [getTableId, setGetTableId] = useState({}) const columnList = (record) => { setGetTableId(record) } // useEffect(() => { // }, [getTableId.id]) - const getTable = (data = lastColumnList) => { - ajax.columnData({ ...data, white_id: getTableId.id }).then(res => { + const getTable = (record) => { + let data ={ + ...lastColumnList, + id:record.id + } + ajax.columnData(data).then(res => { if (res.status === 20000) { let resDataArr = res.data.list.map((item) => { item.key = item.id diff --git a/src/pages/InRoadMgm/PersonMgm/Attendance/WorkerSchedule/loadable.jsx b/src/pages/InRoadMgm/PersonMgm/Attendance/WorkerSchedule/loadable.jsx index d014498..9206125 100644 --- a/src/pages/InRoadMgm/PersonMgm/Attendance/WorkerSchedule/loadable.jsx +++ b/src/pages/InRoadMgm/PersonMgm/Attendance/WorkerSchedule/loadable.jsx @@ -110,7 +110,8 @@ function WorkerSchedule(props) { setGetId(record.id) setGetName(record.pdaManagerName) let data = { - user_id: record.id + user_id: record.id, + date:record.date } ajax.getDateList(data).then(res => { if (res.status === 20000) { @@ -127,7 +128,8 @@ function WorkerSchedule(props) { operation(record) setGetName(record.pdaManagerName) let data = { - user_id: record.id + user_id: record.id, + date:record.date } ajax.getDateList(data).then(res => { if (res.status === 20000) { @@ -201,21 +203,32 @@ function WorkerSchedule(props) { const [getMonthDate, setGetMonthDate] = useState({}) console.log(getMonthDate); //编辑批量修改 + const [getAllChange, setGetAllChange] = useState({ + scheduleId:'' + }) const changeBtn = () => { let str = JSON.stringify(getMonthDate) console.log(str); let data = { - scheduleId: getAllChange, + ...getAllChange, date: str === '{}' ? getDateListNum : getMonthDate, user_id: getId, is_batch: 1 } - ajax.editList(data).then(res => { - if (res.status === 20000) { - setEditVisible(false) - message.success(res.message) - } - }) + if(getAllChange.scheduleId===''){ + message.error('请选择休息或者排班班次') + }else{ + ajax.editList(data).then(res => { + if (res.status === 20000) { + setEditVisible(false) + message.success(res.message) + setGetAllChange({ + scheduleId:'' + }) + } + }) + } + } const getListData = (value) => { let listData; @@ -316,12 +329,9 @@ function WorkerSchedule(props) { } }) } - const [getAllChange, setGetAllChange] = useState({ - scheduleId:1 - }) - const handleAllChange = (v) => { - setGetAllChange(v) + const handleAllChange = (v) => { + setGetAllChange({ ...getAllChange, scheduleId: v }) } const changeTime = (value) => { let data = { diff --git a/src/pages/InRoadMgm/RecordInquiry/DisabledCarParkRecordTotal/loadable.jsx b/src/pages/InRoadMgm/RecordInquiry/DisabledCarParkRecordTotal/loadable.jsx index 5557c5d..041e4c3 100644 --- a/src/pages/InRoadMgm/RecordInquiry/DisabledCarParkRecordTotal/loadable.jsx +++ b/src/pages/InRoadMgm/RecordInquiry/DisabledCarParkRecordTotal/loadable.jsx @@ -733,7 +733,7 @@ function DisabledCarParkRecordTotal() { mandatory_name={'车牌号'} pageName={'disabledCarParkRecordTotal'} search={search} - exportUrl={'http://192.168.5.149:90/PMS/api/bpm/record/get_record_export'} + exportUrl="/api/bpm/record/get_record_export_cj" /> { if (res.status === 20000) { setResultData({ @@ -1107,14 +1107,8 @@ function ConfigRoad() { title: item.label }) }) - res.data.right.map(item => { - temparrRight.push({ - key: item.value + '', - title: item.label - }) - }) setLeftGetBerth(temparr) - setTargetKeys(temparrRight) + setTargetKeys(res.data.right) } }) } @@ -2280,7 +2274,7 @@ function ConfigRoad() { { dataAcquistionModal.isEdit === 0 ? - + { setSubmitDeploy({ ...submitDeploy, deal_reason: value.target.value }) @@ -446,19 +451,25 @@ function CallbackSuggestion(props) { } const cancelBtn = () => { setOrderVisible(false) + setSubmitDeploy({change_content:'',update_value:'',plate_type:'',deal_reason:''}) } const submitBtn = () => { let data = { ...submitDeploy, - id: getId + id: getImg.parkRecordId } - if (submitDeploy.change_content === undefined) { + if(submitDeploy.deal_reason===''){ + message.error('请输入处理理由') + }else if (submitDeploy.change_content === '') { message.error('请选择对应的更改项') } else { ajax.submitData(data).then(res => { if (res.status === 20000) { setOrderVisible(false) setImgVisible(false) + setSubmitDeploy({change_content:'',update_value:'',plate_type:'',deal_reason:''}) + setGetAdjustTimeValue(1) + setGetValueList({}) } }) } @@ -874,7 +885,7 @@ function CallbackSuggestion(props) {
处理理由
-