修改删除提示

master
夜笙歌 2 years ago
parent 7a6783a331
commit f9fe8b8f97

@ -143,6 +143,8 @@ export default {
}, },
baseCar: { baseCar: {
car: { car: {
team:'Team',
model:'BelongingToTheModel',
companyCode: 'Enterprise number', companyCode: 'Enterprise number',
carQueueId: 'Fleet ID', carQueueId: 'Fleet ID',
carTypeId: 'Model ID', carTypeId: 'Model ID',

@ -143,6 +143,8 @@ export default {
}, },
baseCar: { baseCar: {
car: { car: {
team:'所属车队',
model:'所属车型',
companyCode: '企业编号', companyCode: '企业编号',
carQueueId: '车队ID', carQueueId: '车队ID',
carTypeId: '车型ID', carTypeId: '车型ID',

@ -22,22 +22,22 @@
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
v-hasPermi="['basecar:car:add']"
icon="Plus" icon="Plus"
plain plain
type="primary" type="primary"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['basecar:car:add']"
>{{ t('option.add') }} >{{ t('option.add') }}
</el-button> </el-button>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
v-hasPermi="['basecar:car:edit']"
:disabled="single" :disabled="single"
icon="Edit" icon="Edit"
plain plain
type="success" type="success"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['basecar:car:edit']"
>{{ t('option.edit') }} >{{ t('option.edit') }}
</el-button> </el-button>
</el-col> </el-col>
@ -69,8 +69,8 @@
<el-table v-loading="loading" :data="postList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="postList" @selection-change="handleSelectionChange">
<el-table-column align="center" fixed type="selection" width="55"/> <el-table-column align="center" fixed type="selection" width="55"/>
<el-table-column :label="t('baseCar.car.carLicense')" align="center" prop="carLicense" width="150"/> <el-table-column :label="t('baseCar.car.carLicense')" align="center" prop="carLicense" width="150"/>
<el-table-column align="center" label="所属车队" prop="carQueueId" /> <el-table-column :label="t('baseCar.car.team')" align="center" prop="carQueueId"/>
<el-table-column align="center" label="所属车型" prop="carTypeId" /> <el-table-column :label="t('baseCar.car.model')" align="center" prop="carTypeId"/>
<el-table-column :label="t('baseCar.car.deviceId')" align="center" prop="deviceId" width="150"/> <el-table-column :label="t('baseCar.car.deviceId')" align="center" prop="deviceId" width="150"/>
<el-table-column :label="t('baseCar.car.deviceBindTime')" align="center" prop="deviceBindTime" width="150"/> <el-table-column :label="t('baseCar.car.deviceBindTime')" align="center" prop="deviceBindTime" width="150"/>
<el-table-column :label="t('common.createTime')" align="center" prop="createTime" width="160"/> <el-table-column :label="t('common.createTime')" align="center" prop="createTime" width="160"/>
@ -79,8 +79,8 @@
width="160"> width="160">
<template #default="scope"> <template #default="scope">
<el-button <el-button
type="text"
icon="Finished" icon="Finished"
type="text"
@click="handleBang()" @click="handleBang()"
> >
绑定接收器 绑定接收器
@ -98,14 +98,18 @@
@pagination="getList" @pagination="getList"
/> />
<el-dialog title="绑定接收器" v-model="bangOpen" width="500px" append-to-body> <el-dialog v-model="bangOpen" append-to-body title="绑定接收器" width="500px">
<el-form ref="postRef" :label-width=" locale ? '120px':'140px'" :model="form" :rules="rules"> <el-table ref="bindRef" v-loading="loading" :data="postList">
<el-table v-loading="loading" :data="postList" @selection-change="handleSelectionChange"> <el-table-column align="center" width="25">
<el-table-column align="center" fixed type="selection" width="10"></el-table-column> <template #default="scope">
<el-table-column label="接收器编号" align="center" prop="carLicense" width="150"/> <el-radio-group v-model="bindValue">
<el-radio @click.native="bindHandleSelectionChange(scope.row.id)" :label="scope.row.id"> </el-radio>
</el-radio-group>
</template>
</el-table-column>
<el-table-column align="center" label="接收器编号" prop="carLicense" width="150"/>
<el-table-column align="center" label="设备类型" prop="carQueueId"/> <el-table-column align="center" label="设备类型" prop="carQueueId"/>
</el-table> </el-table>
</el-form>
</el-dialog> </el-dialog>
<!-- 添加或修改岗位对话框 --> <!-- 添加或修改岗位对话框 -->
<el-dialog v-model="open" :title="title" append-to-body width="500px"> <el-dialog v-model="open" :title="title" append-to-body width="500px">
@ -115,7 +119,7 @@
v-model="form.carLicense" v-model="form.carLicense"
:placeholder="t('common.pleaseEnter') + t('baseCar.car.carLicense')"/> :placeholder="t('common.pleaseEnter') + t('baseCar.car.carLicense')"/>
</el-form-item> </el-form-item>
<el-form-item label="所属车队" prop="carQueueId"> <el-form-item :label="t('baseCar.car.team')" prop="carQueueId">
<el-select <el-select
v-model="form.carQueueId" v-model="form.carQueueId"
:placeholder="t('common.pleaseEnter') + t('baseCar.car.carQueueId')" :placeholder="t('common.pleaseEnter') + t('baseCar.car.carQueueId')"
@ -130,7 +134,7 @@
/> />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="所属车型" prop="carTypeId"> <el-form-item :label="t('baseCar.car.model')" prop="carTypeId">
<el-select <el-select
v-model="form.carTypeId" v-model="form.carTypeId"
:placeholder="t('common.pleaseEnter') + t('baseCar.car.carQueueId')" :placeholder="t('common.pleaseEnter') + t('baseCar.car.carQueueId')"
@ -156,7 +160,7 @@
</div> </div>
</template> </template>
<script setup name="basetyre"> <script name="basetyre" setup>
import {addBaseCar, delBaseCar, getBaseCar, listBaseCar, updateBaseCar, getCarQueueList} from "@/api/basecar/car"; import {addBaseCar, delBaseCar, getBaseCar, listBaseCar, updateBaseCar, getCarQueueList} from "@/api/basecar/car";
import {useI18n} from 'vue-i18n'; import {useI18n} from 'vue-i18n';
@ -192,6 +196,8 @@ const multiple = ref(true);
const total = ref(0); const total = ref(0);
// //
const title = ref(""); const title = ref("");
//
const bindValue = ref('')
// //
const queryParams = ref({ const queryParams = ref({
@ -264,6 +270,11 @@ function handleSelectionChange(selection) {
multiple.value = !selection.length; multiple.value = !selection.length;
} }
const bindHandleSelectionChange = (selection) => {
bindValue.value = selection
console.log(bindValue.value)
}
/** 新增按钮操作 */ /** 新增按钮操作 */
function handleAdd() { function handleAdd() {
reset(); reset();
@ -288,6 +299,7 @@ function handleUpdate(row) {
title.value = t('baseCar.car.editTitle'); title.value = t('baseCar.car.editTitle');
}); });
} }
function handleBang(row) { function handleBang(row) {
// console.log(row.id) // console.log(row.id)
bangOpen.value = true; bangOpen.value = true;

Loading…
Cancel
Save