新增个人车辆增加两辆车限制
parent
5654adf8e9
commit
181ba78374
|
|
@ -43,6 +43,10 @@ function List(props) {
|
||||||
icon={(<AddIcon />)}
|
icon={(<AddIcon />)}
|
||||||
type="primary"
|
type="primary"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
|
if (tableProps.dataSource.length >= 2) {
|
||||||
|
message.warning("最多添加两辆车");
|
||||||
|
return;
|
||||||
|
}
|
||||||
props.history.push("./add");
|
props.history.push("./add");
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|
|
||||||
|
|
@ -58,6 +58,10 @@ function List(props) {
|
||||||
icon={(<AddIcon />)}
|
icon={(<AddIcon />)}
|
||||||
type="primary"
|
type="primary"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
|
if (tableProps.dataSource.length >= 2) {
|
||||||
|
message.warning("最多添加两辆车");
|
||||||
|
return;
|
||||||
|
}
|
||||||
props.history.push("./add");
|
props.history.push("./add");
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue