优化代码

This commit is contained in:
java110 2022-08-30 01:25:49 +08:00
parent 8b3203089d
commit 9cff3d1ea6
2 changed files with 8 additions and 7 deletions

View File

@ -14,16 +14,16 @@
</div>
<div class="form-group row" v-if="parkingAreaControlCustomCarInoutInfo.type != '1101'">
<label class="col-sm-2 col-form-label"><span><vc:i18n name="收费金额" namespace="parkingAreaControlCustomCarInout"></vc:i18n></span></label>
<div class="col-sm-10"><input v-model="parkingAreaControlCustomCarInoutInfo.amount" type="number" :placeholder="vc.i18n('必填,请填写收费金额','parkingAreaControlCustomCarInout')" class="form-control"></div>
<div class="col-sm-10"><input v-model="parkingAreaControlCustomCarInoutInfo.amount" type="text" :placeholder="vc.i18n('必填,请填写收费金额','parkingAreaControlCustomCarInout')" class="form-control"></div>
</div>
<div class="form-group row" v-if="parkingAreaControlCustomCarInoutInfo.type != '1101'">
<label class="col-sm-2 col-form-label"><span><vc:i18n name="停车时间" namespace="parkingAreaControlCustomCarInout"></vc:i18n></span></label>
<div class="col-sm-10"><input v-model="parkingAreaControlCustomCarInoutInfo.costMin" type="number" disabled :placeholder="vc.i18n('必填,请填写停车时间','parkingAreaControlCustomCarInout')" class="form-control"></div>
<div class="col-sm-10"><input v-model="parkingAreaControlCustomCarInoutInfo.costMin" type="text" disabled :placeholder="vc.i18n('必填,请填写停车时间','parkingAreaControlCustomCarInout')" class="form-control"></div>
</div>
<div class="form-group row" v-if="parkingAreaControlCustomCarInoutInfo.type != '1101'">
<label class="col-sm-2 col-form-label"><span><vc:i18n name="支付方式" namespace="parkingAreaControlCustomCarInout"></vc:i18n></span></label>
<div class="col-sm-10">
<select class="custom-select" v-model="parkingAreaControlCustomCarInoutInfo.payType" @change="_swatchVedio()">
<select class="custom-select" v-model="parkingAreaControlCustomCarInoutInfo.payType">
<option selected value="">{{vc.i18n('请选择支付方式','parkingAreaControlCustomCarInout')}}</option>
<option :value="item.statusCd"
v-for="(item,index) in parkingAreaControlCustomCarInoutInfo.payTypes">{{item.name}}

View File

@ -55,10 +55,10 @@
function(json, res) {
//vm.menus = vm.refreshMenuActive(JSON.parse(json),0);
let _data = JSON.parse(json);
$('#parkingAreaControlCustomCarInoutModel').modal('hide');
if (_data.code != 0) {
vc.toast(_data.msg);
} else {
$('#parkingAreaControlCustomCarInoutModel').modal('hide');
vc.toast(_data.msg);
vc.emit('parkingAreaControlFee', 'clear', {})
}
@ -106,9 +106,10 @@
vc.toast('未查询在场车辆,请检查!');
return;
}
$that.parkingAreaControlCustomCarInout.payCharge = _data[0].payCharge;
$that.parkingAreaControlCustomCarInout.inoutId = _data[0].inoutId;
$that.parkingAreaControlCustomCarInout.costMin = _data[0].hours + "时" + _data[0].min + "分";
$that.parkingAreaControlCustomCarInoutInfo.payCharge = _data[0].payCharge;
$that.parkingAreaControlCustomCarInoutInfo.amount = _data[0].payCharge;
$that.parkingAreaControlCustomCarInoutInfo.inoutId = _data[0].inoutId;
$that.parkingAreaControlCustomCarInoutInfo.costMin = _data[0].hours + "时" + _data[0].min + "分";
},
function() {
console.log('请求失败处理');