Browse Source

fix():修改路内BUG

tags/PMS_Frontend_v1.0.5-develop
guoxin 1 year ago
parent
commit
7faba54187
  1. 2
      src/pages/OperationCenter/ArrearsRecover/ArrearsTask/loadable.jsx
  2. 10
      src/pages/OperationCenter/OtherBusiness/Staggered/StaggeredMgm/loadable.jsx
  3. 367
      src/pages/SystemMgm/BusinessConfig/BusinessConf/loadable.jsx

2
src/pages/OperationCenter/ArrearsRecover/ArrearsTask/loadable.jsx

@ -338,7 +338,7 @@ function arrearsTask(props) {
remark: getReject.remark
}
if (getReject.remark === '') {
message.error('请输入拒绝原')
message.error('请输入拒绝原')
} else {
ajax.getDeployTask(data).then(res => {
if (res.status === 20000) {

10
src/pages/OperationCenter/OtherBusiness/Staggered/StaggeredMgm/loadable.jsx

@ -122,7 +122,7 @@ function StaggeredMgm(props) {
}
const checkModal = () => {
setCheckVisible(false)
setGetSaleMsg([infoData])
// setGetSaleMsg([infoData])
setGetCarMsg({
operator_id: '',
road: ''
@ -234,8 +234,8 @@ function StaggeredMgm(props) {
let infoData = {
start_date: moment().subtract(30, 'days').startOf('day').format('YYYY-MM-DD'),
end_date: moment().format('YYYY-MM-DD'),
start_time: moment('00:00:00', 'HH:mm:ss'),
end_time: moment('23:59:59', 'HH:mm:ss'),
start_time: moment().format('HH:mm:ss 00:00:00'),
end_time: moment().format('HH:mm:ss 23:59:59'),
week: '',
num: '',
price: '',
@ -590,6 +590,7 @@ function StaggeredMgm(props) {
disabled={true}
value={[moment(item.start_time), moment(item.end_time)]}
style={{ width: 250, marginLeft: 20 }}
format="HH:mm:ss"
onChange={(time, timeString) => handleChangeTime(
time, timeString, index
)}
@ -751,6 +752,7 @@ function StaggeredMgm(props) {
<TimePicker.RangePicker
defaultValue={[moment(item.start_time), moment(item.end_time)]}
style={{ width: 250, marginLeft: 20 }}
format="HH:mm:ss"
onChange={(time, timeString) => handleChangeTime(
time, timeString, index
)}
@ -895,6 +897,7 @@ function StaggeredMgm(props) {
{getSaleMsg.length ?
getSaleMsg?.map((item, index) => {
// console.log(item);
return (
<>
<div className="carTitle">
@ -921,6 +924,7 @@ function StaggeredMgm(props) {
disabled={item.disabled}
defaultValue={[moment(item.start_time), moment(item.end_time)]}
style={{ width: 250, marginLeft: 20 }}
format="HH:mm:ss"
onChange={(time, timeString) => handleChangeTime(
time, timeString, index
)}

367
src/pages/SystemMgm/BusinessConfig/BusinessConf/loadable.jsx

@ -67,7 +67,6 @@ function BusinessConf(props) {
const [getMessage, setGetMessage] = useState({})
const handleConfiguration = (v, option) => {
setGetMessage(option);
setGetConfiguration(v)
setAddManage({
...addManage, item_name: v,
area_name: '0',
@ -104,7 +103,6 @@ function BusinessConf(props) {
//
const [getGovernment, setGetGovernment] = useState([])
console.log(getGovernment);
const handleDeptName = (e) => {
let arr = e
let lastElement = arr[arr.length - 1];
@ -145,9 +143,7 @@ function BusinessConf(props) {
} else if (addManage.item_name === '') {
message.error('请选择配置项')
// radio,radio
} else if (getConfiguration === 0 || getConfiguration === 2 || getConfiguration === 3 || getConfiguration === 4 || getConfiguration === 5
|| getConfiguration === 9 || getConfiguration === 10 || getConfiguration === 13
|| getConfiguration === 14 || getConfiguration === 15 || getConfiguration === 16 || getConfiguration === 17) {
} else if (getMessage.is_text === 1) {
if (addManage.parameter) {
if (!pattern1.test(addManage.parameter) || pattern.test(addManage.parameter)) {
message.error('禁止输入特殊符号,中文,英文,负数且只能保留两位小数点,最多输入30位')
@ -161,7 +157,7 @@ function BusinessConf(props) {
item_name: ''
})
getData(formData)
setGetConfiguration(0)
setGetMessage({})
} else {
message.error(res.message)
}
@ -180,7 +176,7 @@ function BusinessConf(props) {
item_name: ''
})
getData(formData)
setGetConfiguration(0)
setGetMessage({})
} else {
message.error(res.message)
}
@ -266,7 +262,6 @@ function BusinessConf(props) {
if (res.status === 20000) {
setCheckVisible(true)
setGetMessage(res.data.parameter_dsc);
setGetConfiguration(res.data.item_id)
setGetCheckData(res.data)
}
})
@ -283,8 +278,8 @@ function BusinessConf(props) {
item_name: '',
parameterValue: 1
})
setGetConfiguration(0)
setGetMessage({})
// setGetMessage({})
}
//
const [geteditData, setGetEditData] = useState({
@ -336,7 +331,7 @@ function BusinessConf(props) {
setPasswordVisible(false)
getData(formData)
message.success(res.message)
setGetConfiguration(0)
setGetMessage({})
}
})
}
@ -353,7 +348,6 @@ function BusinessConf(props) {
item_name: ''
})
setGetMessage({})
setGetConfiguration(0)
}
const cancelImg = () => {
@ -427,9 +421,7 @@ function BusinessConf(props) {
message.error('请选择商户名称')
} else if (geteditData.item_name === '') {
message.error('请选择配置项')
} else if (getConfiguration === 0 || getConfiguration === 2 || getConfiguration === 3 || getConfiguration === 4 || getConfiguration === 5
|| getConfiguration === 9 || getConfiguration === 10 || getConfiguration === 13
|| getConfiguration === 14 || getConfiguration === 15 || getConfiguration === 16 || getConfiguration === 17) {
} else if (getMessage.is_text === 1) {
if (geteditData.parameter) {
if (!pattern1.test(geteditData.parameter) || pattern.test(geteditData.parameter)) {
message.error('禁止输入特殊符号,中文,英文,负数且只能保留两位小数点,最多输入30位')
@ -438,7 +430,7 @@ function BusinessConf(props) {
if (res.status === 20000) {
setEditVisible(false)
getData(formData)
setGetConfiguration(0)
setGetMessage(0)
} else {
message.error(res.message)
}
@ -452,7 +444,7 @@ function BusinessConf(props) {
if (res.status === 20000) {
setEditVisible(false)
getData(formData)
setGetConfiguration(0)
setGetMessage({})
} else {
message.error(res.message)
}
@ -475,19 +467,24 @@ function BusinessConf(props) {
setGetMerchantDataName(res.data)
})
}
//redio
const [getDisable, setGetDisable] = useState(false)
useEffect(() => {
if (getConfiguration === 1 || getConfiguration === 6 || getConfiguration === 7 || getConfiguration === 12 || getConfiguration === 16) {
if (getMessage.is_global === 1) {
setGetVIsible(false)
} else {
setGetVIsible(true)
}
}, [getConfiguration])
}, [getMessage])
useEffect(() => {
getData()
plateColor()
merchantDataName()
roleData()
}, [])
useEffect(() => {
console.log(getMessage, 1111);
}, [getMessage])
return <>
<div className="paid-BusinessConf">
<div className="paid-search">
@ -597,10 +594,7 @@ function BusinessConf(props) {
/>
</div>
{
getConfiguration === 0 || getConfiguration === 2 || getConfiguration === 3 || getConfiguration === 4 || getConfiguration === 5
|| getConfiguration === 9 || getConfiguration === 10 || getConfiguration === 13
|| getConfiguration === 14 || getConfiguration === 15 || getConfiguration === 16 || getConfiguration === 17
getMessage.is_text === 1
?
<>
<div className="yisa-search">
@ -613,86 +607,24 @@ function BusinessConf(props) {
style={{ width: 260, marginLeft: 50 }}
onChange={handleParameter}
/>
{
getConfiguration === 2 ?
<label style={{ marginLeft: 10 }}>小时</label> : ''
}
{
getConfiguration === 3 ?
<label style={{ marginLeft: 10 }}></label> : ''
}
{
getConfiguration === 4 || getConfiguration === 5 ?
<label style={{ marginLeft: 10 }}>/</label> : ''
}
<label style={{ marginLeft: 10 }}>{getMessage.unit}</label>
</div>
</>
: ''
}
{
getConfiguration === 1 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={onChangeAdd} value={addManage.parameterValue}>
<Radio value={1}>取信地磁</Radio>
<Radio value={2}>PDA审核</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 12 ?
<div className="yisa-search">
: <div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={onChangeAdd} value={addManage.parameterValue}>
<Radio value={1}>第三方封闭车场本地计费</Radio>
<Radio value={2}>爱泊车服务端计费</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 6 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={onChangeAdd} value={addManage.parameterValue}>
<Radio value={1}></Radio>
<Radio value={2}></Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 7 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={onChangeAddType} value={addManage.parameterValue}>
<Radio value={1}>取信地磁</Radio>
<Radio value={2}>PDA审核</Radio>
{
getType == 1 ?
< div>
<Radio.Group onChange={onChangehoose} value={addManage.parameter_exit}>
<Radio value={3}>自动出场</Radio>
<Radio value={4}>PDA确认出场</Radio>
</Radio.Group>
</div>
: ''
getMessage.values?.map(item => {
return (
<>
<Radio disabled={item.disabled == 0 ? false : true} value={item.value}>{item.label}</Radio>
</>
)
})
}
</Radio.Group>
</div> : ''
}
{
getConfiguration === 8 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={onChangeAdd} value={addManage.parameterValue}>
<Radio value={1}>自动补单</Radio>
<Radio value={2}>人工补单</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 11 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={onChangeAdd} value={addManage.parameterValue}>
<Radio value={1}>自动退款</Radio>
<Radio value={2}>人工退款</Radio>
</Radio.Group>
</div> : ''
</div>
}
<div className="font-size" dangerouslySetInnerHTML={{ __html: getMessage?.message || '' }}>
{/* {getMessage.message} */}
</div>
@ -753,7 +685,6 @@ function BusinessConf(props) {
options={getNewPlateColor}
onChange={(v, option) => {
setGetMessage(option);
setGetConfiguration(v)
setGetCheckData(
Object.assign({}, getCheckData, { item_id: v })
);
@ -765,10 +696,7 @@ function BusinessConf(props) {
/>
</div>
{
getConfiguration === 0 || getConfiguration === 2 || getConfiguration === 3 || getConfiguration === 4 || getConfiguration === 5
|| getConfiguration === 9 || getConfiguration === 10 || getConfiguration === 13
|| getConfiguration === 14 || getConfiguration === 15 || getConfiguration === 16
getMessage.is_text === 1
?
<>
<div className="yisa-search">
@ -784,86 +712,10 @@ function BusinessConf(props) {
);
}}
/>
{
getConfiguration === 2 ?
<label style={{ marginLeft: 10 }}>小时</label> : ''
}
{
getConfiguration === 3 ?
<label style={{ marginLeft: 10 }}></label> : ''
}
{
getConfiguration === 4 || getConfiguration === 5 ?
<label style={{ marginLeft: 10 }}>/</label> : ''
}
<label style={{ marginLeft: 10 }}>{getMessage.unit}</label>
</div>
</>
: ''
}
{
getConfiguration === 1 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetCheckData(
Object.assign({}, getCheckData, { parameterValue: v.target.value })
);
}}
value={getCheckData.parameterValue}>
<Radio value={1} disabled={true}>取信地磁</Radio>
<Radio value={2} disabled={true}>PDA审核</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 12 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetCheckData(
Object.assign({}, getCheckData, { parameterValue: v.target.value })
);
}}
value={getCheckData.parameterValue}>
<Radio value={1} disabled={true}>第三方封闭车场本地计费</Radio>
<Radio value={2} disabled={true}>爱泊车服务端计费</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 6 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={(v) => {
setGetCheckData(
Object.assign({}, getCheckData, { parameterValue: v.target.value })
);
}}
value={getCheckData.parameterValue}>
<Radio value={1} disabled={true}></Radio>
<Radio value={2} disabled={true}></Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 7 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetCheckData(
Object.assign({}, getCheckData, { parameterValue: v.target.value })
);
}}
value={getCheckData.parameterValue}>
<Radio value={1} disabled={true}>取信地磁</Radio>
<Radio value={2} disabled={true}>PDA审核</Radio>
<Radio value={3} disabled={true}>自动出场</Radio>
<Radio value={4} disabled={true}>PDA确认出场</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 8 ?
<div className="yisa-search">
: <div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetCheckData(
@ -871,27 +723,19 @@ function BusinessConf(props) {
);
}}
value={getCheckData.parameterValue}>
<Radio value={1} disabled={true}>自动补单</Radio>
<Radio value={2} disabled={true}>人工补单</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 11 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetCheckData(
Object.assign({}, getCheckData, { parameterValue: v.target.value })
);
}}
value={getCheckData.parameterValue}>
<Radio value={1} disabled={true}>自动退款</Radio>
<Radio value={2} disabled={true}>人工退款</Radio>
{
getMessage.values?.map(item => {
return (
<>
<Radio disabled={item.disabled == 0 ? false : true} value={item.value}>{item.label}</Radio>
</>
)
})
}
</Radio.Group>
</div> : ''
</div>
}
<div className="font-size" dangerouslySetInnerHTML={{ __html: getMessage?.message || getMessage }}>
{/* {getMessage.message} */}
</div>
@ -952,7 +796,6 @@ function BusinessConf(props) {
options={getNewPlateColor}
onChange={(v, option) => {
setGetMessage(option);
setGetConfiguration(v)
setGetEditData(
Object.assign({}, geteditData, { item_id: v, area_id: "0", operator_id: "0", parameter: '', parameterValue: 1 })
);
@ -964,9 +807,7 @@ function BusinessConf(props) {
/>
</div>
{
getConfiguration === 0 || getConfiguration === 2 || getConfiguration === 3 || getConfiguration === 4 || getConfiguration === 5
|| getConfiguration === 9 || getConfiguration === 10 || getConfiguration === 13
|| getConfiguration === 14 || getConfiguration === 15 || getConfiguration === 16
getMessage.is_text === 1
?
<>
@ -983,122 +824,28 @@ function BusinessConf(props) {
);
}}
/>
{
getConfiguration === 2 ?
<label style={{ marginLeft: 10 }}>小时</label> : ''
}
{
getConfiguration === 3 ?
<label style={{ marginLeft: 10 }}></label> : ''
}
{
getConfiguration === 4 || getConfiguration === 5 ?
<label style={{ marginLeft: 10 }}>/</label> : ''
}
<label style={{ marginLeft: 10 }}>{getMessage.unit}</label>
</div>
</>
: ''
}
{
getConfiguration === 1 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetEditData(
Object.assign({}, geteditData, { parameterValue: v.target.value })
);
}}
value={geteditData.parameterValue}>
<Radio value={1}>取信地磁</Radio>
<Radio value={2}>PDA审核</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 12 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetEditData(
Object.assign({}, geteditData, { parameterValue: v.target.value })
);
}}
value={geteditData.parameterValue}>
<Radio value={1}>第三方封闭车场本地计费</Radio>
<Radio value={2}>爱泊车服务端计费</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 6 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }} onChange={(v) => {
: <div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetEditData(
Object.assign({}, geteditData, { parameterValue: v.target.value })
);
}}
value={geteditData.parameterValue}>
<Radio value={1}></Radio>
<Radio value={2}></Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 7 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetType(v.target.value)
setGetEditData(
Object.assign({}, geteditData, { parameterValue: v.target.value })
);
}}
value={geteditData.parameterValue}>
<Radio value={1}>取信地磁</Radio>
<Radio value={2}>PDA审核</Radio>
{
getType == 1 ?
< div>
<Radio.Group onChange={onChangeEdithoose} value={geteditData.parameter_exit}>
<Radio value={3}>自动出场</Radio>
<Radio value={4}>PDA确认出场</Radio>
</Radio.Group>
</div>
: ''
value={geteditData.parameterValue}>
{
getMessage.values?.map(item => {
return (
<>
<Radio disabled={item.disabled == 0 ? false : true} value={item.value}>{item.label}</Radio>
</>
)
})
}
</Radio.Group>
</div> : ''
}
{
getConfiguration === 8 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetEditData(
Object.assign({}, geteditData, { parameterValue: v.target.value })
);
}}
value={geteditData.parameterValue}>
<Radio value={1}>自动补单</Radio>
<Radio value={2}>人工补单</Radio>
</Radio.Group>
</div> : ''
}
{
getConfiguration === 11 ?
<div className="yisa-search">
<Radio.Group style={{ marginLeft: 42 }}
onChange={(v) => {
setGetEditData(
Object.assign({}, geteditData, { parameterValue: v.target.value })
);
}}
value={geteditData.parameterValue}>
<Radio value={1}>自动退款</Radio>
<Radio value={2}>人工退款</Radio>
</Radio.Group>
</div> : ''
</Radio.Group>
</div>
}
<div className="font-size" dangerouslySetInnerHTML={{ __html: getMessage?.message || getMessage }}>
{/* {getMessage.message} */}

Loading…
Cancel
Save