|
|
@ -81,7 +81,7 @@
|
|
|
|
<el-button
|
|
|
|
<el-button
|
|
|
|
icon="Finished"
|
|
|
|
icon="Finished"
|
|
|
|
type="text"
|
|
|
|
type="text"
|
|
|
|
@click="handleBang()"
|
|
|
|
@click="handleBang(scope.row.id)"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
绑定接收器
|
|
|
|
绑定接收器
|
|
|
|
</el-button>
|
|
|
|
</el-button>
|
|
|
@ -98,19 +98,26 @@
|
|
|
|
@pagination="getList"
|
|
|
|
@pagination="getList"
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
|
|
|
|
|
|
|
|
<el-dialog @close="()=>{bindValue='';bindInput=''}" v-model="bangOpen" append-to-body title="绑定接收器" width="500px">
|
|
|
|
<el-dialog v-model="bangOpen" append-to-body title="绑定接收器" width="500px" @close="()=>{bindValue='';bindInput=''}">
|
|
|
|
<el-input style="width:200px" v-model="bindInput" /> <el-button type="primary" @click="bindSearch" >搜索</el-button>
|
|
|
|
<el-input v-model="bindInput" style="width:200px"/>
|
|
|
|
|
|
|
|
<el-button type="primary" @click="bindSearch">搜索</el-button>
|
|
|
|
<el-table ref="bindRef" v-loading="loading" :data="bindList">
|
|
|
|
<el-table ref="bindRef" v-loading="loading" :data="bindList">
|
|
|
|
<el-table-column align="center" width="25">
|
|
|
|
<el-table-column align="center" width="25">
|
|
|
|
<template #default="scope">
|
|
|
|
<template #default="scope">
|
|
|
|
<el-radio-group v-model="bindValue">
|
|
|
|
<el-radio-group v-model="bindValue">
|
|
|
|
<el-radio @click="bindHandleSelectionChange(scope.row.id)" :label="scope.row.id"> </el-radio>
|
|
|
|
<el-radio :label="scope.row.id" @click="bindHandleSelectionChange(scope.row.internetThingsNo)"></el-radio>
|
|
|
|
</el-radio-group>
|
|
|
|
</el-radio-group>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" label="接收器编号" prop="carLicense" width="150"/>
|
|
|
|
<el-table-column align="center" label="接收器编号" prop="internetThingsNo" width="150"/>
|
|
|
|
<el-table-column align="center" label="设备类型" prop="carQueueId"/>
|
|
|
|
<el-table-column align="center" label="设备类型" prop="deviceType"/>
|
|
|
|
</el-table>
|
|
|
|
</el-table>
|
|
|
|
|
|
|
|
<template #footer>
|
|
|
|
|
|
|
|
<div class="dialog-footer">
|
|
|
|
|
|
|
|
<el-button type="primary" @click="bindOk">{{ t('option.ok') }}</el-button>
|
|
|
|
|
|
|
|
<el-button @click="()=>{bindValue='';bindInput='';bangOpen=false}">{{ t('option.cancel') }}</el-button>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
</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">
|
|
|
@ -162,7 +169,15 @@
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script name="basetyre" setup>
|
|
|
|
<script name="basetyre" setup>
|
|
|
|
import {addBaseCar, delBaseCar, getBaseCar, listBaseCar, updateBaseCar, getCarQueueList,getBindList} from "@/api/basecar/car";
|
|
|
|
import {
|
|
|
|
|
|
|
|
addBaseCar,
|
|
|
|
|
|
|
|
delBaseCar,
|
|
|
|
|
|
|
|
getBaseCar,
|
|
|
|
|
|
|
|
listBaseCar,
|
|
|
|
|
|
|
|
updateBaseCar,
|
|
|
|
|
|
|
|
getCarQueueList,
|
|
|
|
|
|
|
|
getBindList
|
|
|
|
|
|
|
|
} from "@/api/basecar/car";
|
|
|
|
|
|
|
|
|
|
|
|
import {useI18n} from 'vue-i18n';
|
|
|
|
import {useI18n} from 'vue-i18n';
|
|
|
|
import Cookies from "js-cookie";
|
|
|
|
import Cookies from "js-cookie";
|
|
|
@ -197,6 +212,8 @@ const multiple = ref(true);
|
|
|
|
const total = ref(0);
|
|
|
|
const total = ref(0);
|
|
|
|
// 模态框标题
|
|
|
|
// 模态框标题
|
|
|
|
const title = ref("");
|
|
|
|
const title = ref("");
|
|
|
|
|
|
|
|
// 要绑定的行信息
|
|
|
|
|
|
|
|
const waitBind = ref('')
|
|
|
|
// 绑定接收器选择行
|
|
|
|
// 绑定接收器选择行
|
|
|
|
const bindValue = ref('')
|
|
|
|
const bindValue = ref('')
|
|
|
|
// 搜索接收器
|
|
|
|
// 搜索接收器
|
|
|
@ -282,11 +299,19 @@ const bindHandleSelectionChange = (selection) => {
|
|
|
|
|
|
|
|
|
|
|
|
// 搜索接收器
|
|
|
|
// 搜索接收器
|
|
|
|
const bindSearch = () => {
|
|
|
|
const bindSearch = () => {
|
|
|
|
let params = {id:bindInput.value}
|
|
|
|
let params = {id: bindInput.value}
|
|
|
|
getBindList(params).then(response => {
|
|
|
|
getBindList(params).then(response => {
|
|
|
|
bindList.value = response.rows;
|
|
|
|
bindList.value = response.rows;
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// 绑定接收器确定
|
|
|
|
|
|
|
|
const bindOk = () => {
|
|
|
|
|
|
|
|
let params = {
|
|
|
|
|
|
|
|
internetThingsNo: bindValue.value,
|
|
|
|
|
|
|
|
id: waitBind.value
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
console.log(params)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/** 新增按钮操作 */
|
|
|
|
/** 新增按钮操作 */
|
|
|
|
function handleAdd() {
|
|
|
|
function handleAdd() {
|
|
|
@ -314,8 +339,8 @@ function handleUpdate(row) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function handleBang(row) {
|
|
|
|
function handleBang(row) {
|
|
|
|
// console.log(row.id)
|
|
|
|
|
|
|
|
bangOpen.value = true;
|
|
|
|
bangOpen.value = true;
|
|
|
|
|
|
|
|
waitBind.value = row
|
|
|
|
bindSearch()
|
|
|
|
bindSearch()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|