优化代码

This commit is contained in:
java110 2020-11-24 09:10:38 +08:00
parent 728c34247e
commit 802acf55f7
2 changed files with 3 additions and 3 deletions

View File

@ -2,7 +2,7 @@
<div class="row margin-top"> <div class="row margin-top">
<div class="col-lg-2 text-left"> <div class="col-lg-2 text-left">
<select class="custom-select" v-model="simplifyCarFeeInfo.carId" @change="changeCar()"> <select class="custom-select" v-model="simplifyCarFeeInfo.carId" @change="changeSimplifyCar()">
<option v-for="(item,index) in simplifyCarFeeInfo.ownerCars" :value="item.carId">{{item.carNum}}</option> <option v-for="(item,index) in simplifyCarFeeInfo.ownerCars" :value="item.carId">{{item.carNum}}</option>
</select> </select>
</div> </div>

View File

@ -155,7 +155,7 @@
}, },
changeCar: function () { changeSimplifyCar: function () {
let _car = null; let _car = null;
$that.simplifyCarFeeInfo.ownerCars.forEach(item => { $that.simplifyCarFeeInfo.ownerCars.forEach(item => {
if (item.carId == $that.simplifyCarFeeInfo.carId) { if (item.carId == $that.simplifyCarFeeInfo.carId) {
@ -169,7 +169,7 @@
$that.simplifyCarFeeInfo.carNum = _car.carNum; $that.simplifyCarFeeInfo.carNum = _car.carNum;
$that.simplifyCarFeeInfo.num = _car.num; $that.simplifyCarFeeInfo.num = _car.num;
$that.simplifyCarFeeInfo.parkingName = _car.areaNum + '停车场' + _car.num + '停车位'; $that.simplifyCarFeeInfo.parkingName = _car.areaNum + '停车场' + _car.num + '停车位';
$that._listSimplifyCarFee(); $that._listSimplifyCarFee(DEFAULT_PAGE,DEFAULT_ROWS);
}, },
clearSimplifyCarFeeInfo: function () { clearSimplifyCarFeeInfo: function () {
$that.simplifyCarFeeInfo = { $that.simplifyCarFeeInfo = {