<el-table
:data="vehicleModelTableData"
highlight-current-row
ref="singleTable2"
@row-click="handleCurrentChangeModel"
height="450"
border
style="width: 100%;">
<el-table-column
type="index"
label="序号"
width="52">
</el-table-column>
<el-table-column
prop="modelCode"
label="车型编码"
sortable>
</el-table-column>
<el-table-column
prop="modelName"
sortable
label="车辆型号">
</el-table-column>
</el-table>
handleCurrentChangeModel: function(val) {
// 车辆型号
this.rowDeriveModel = {};
if(this.rowCarModel.id == val.id){
this.$refs.singleTable2.setCurrentRow();
this.rowCarModel = {};
// this.handleCurrentChange();
} else {
// 车辆型号
this.rowCarModel.id = val.id;
this.rowCarModel.code = val.modelCode;
this.rowCarModel.name = val.modelName;
this.rowCarModel.brandId = val.brandId;
this.addDerive.carModel = this.rowCarModel.id;
let vehicleModelParam = { brandId: this.rowCarBrand.id, modelParentId: this.rowCarModel.id };
this.$get(consts.VSP_API_CONTEXT + '/portal/basicVehicleInformation/queryVehicleModel', vehicleModelParam, data => {
this.deriveTableData = data.responseBody;
this.mainLoading = false;
}, { isSuccessPrompt: false })
}
},
Vue页面表格选中取消不刷新
最新推荐文章于 2024-01-16 09:56:33 发布