| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="showAdvanceQueryUI"> |
| | | <el-form-item label="业务类型"> |
| | | <el-select clearable="" filterable="" v-model="queryParams.deviceType" placeholder="业务类型"> |
| | | <el-option v-for="(item,index) in dl('DeviceTypeEnum')" :key="index" :value="item.value" :label="`${item.name} (${item.code}) [${item.value}] `" /> |
| | | |
| | | </el-select> |
| | | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="showAdvanceQueryUI"> |
| | | <el-form-item label="工位号"> |
| | | <el-input v-model="queryParams.stationNum" clearable="" placeholder="请输入工位号" /> |
| | | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="showAdvanceQueryUI"> |
| | | <el-form-item label="描述"> |
| | | <el-input v-model="queryParams.text" clearable="" placeholder="请输入描述" /> |
| | | |
| | |
| | | style="margin-left:5px;"> 隐藏 </el-button> |
| | | <el-button type="primary" style="margin-left:5px;" icon="ele-Plus" @click="openAddWcsDevice" |
| | | v-auth="'wcsDevice:add'"> 新增 </el-button> |
| | | |
| | | </el-button-group> |
| | | </el-form-item> |
| | | |
| | |
| | | </template> |
| | | |
| | | </el-table-column> |
| | | <el-table-column prop="deviceType" label="交互类型" show-overflow-tooltip=""> |
| | | <template #default="scope"> |
| | | <el-tag :type="dv('DeviceTypeEnum', scope.row.deviceType)?.tagType"> {{ dv('DeviceTypeEnum', |
| | | scope.row.deviceType)?.name }}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="level" label="设备级别" show-overflow-tooltip=""> |
| | | <template #default="scope"> |
| | | <el-tag :type="dv('DeviceLevelEnum', scope.row.level)?.tagType"> {{ dv('DeviceLevelEnum', |
| | | scope.row.level)?.name}}</el-tag> |
| | | scope.row.level)?.name }}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="dbNumber" label="DB区域" show-overflow-tooltip="" /> |
| | |
| | | <el-table-column prop="posType" label="流程字类型" show-overflow-tooltip=""> |
| | | <template #default="scope"> |
| | | <el-tag :type="dv('PLCDataTypeEnum', scope.row.posType)?.tagType"> {{ dv('PLCDataTypeEnum', |
| | | scope.row.posType)?.name}}</el-tag> |
| | | scope.row.posType)?.name }}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="ledIP" label="显示屏ip地址" show-overflow-tooltip="" /> |
| | |
| | | <ModifyRecord :data="scope.row" /> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="操作" width="140" align="center" fixed="right" show-overflow-tooltip="" |
| | | <el-table-column label="操作" width="220" align="center" fixed="right" show-overflow-tooltip="" |
| | | v-if="auth('wcsDevice:update') || auth('wcsDevice:delete')"> |
| | | <template #default="scope"> |
| | | <el-button icon="ele-Edit" size="small" text="" type="primary" @click="openEditWcsDevice(scope.row)" |
| | | v-auth="'wcsDevice:update'"> 编辑 </el-button> |
| | | <el-button icon="ele-Delete" size="small" text="" type="primary" @click="delWcsDevice(scope.row)" |
| | | v-auth="'wcsDevice:delete'"> 删除 </el-button> |
| | | <el-button icon="ele-Plus" size="small" text="" type="primary" @click="generateDevicePos(scope.row)" |
| | | v-auth="'wcsDevice:generate'"> 生成点位 </el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | |
| | | import printDialog from '/@/views/system/print/component/hiprint/preview.vue' |
| | | import editDialog from '/@/views/wcs/wcsDevice/component/editDialog.vue' |
| | | import { pageWcsDevice, deleteWcsDevice } from '/@/api/wcs/wcsDevice'; |
| | | import { pageWcsDevice, deleteWcsDevice, generatePos } from '/@/api/wcs/wcsDevice'; |
| | | import { getWcsPlcPlcIdDropdown } from '/@/api/wcs/wcsDevice'; |
| | | |
| | | const showAdvanceQueryUI = ref(false); |
| | |
| | | const queryParams = ref<any>({}); |
| | | const tableParams = ref({ |
| | | page: 1, |
| | | pageSize: 10, |
| | | pageSize: 20, |
| | | total: 0, |
| | | }); |
| | | |
| | |
| | | editWcsDeviceTitle.value = '编辑设备信息'; |
| | | editDialogRef.value.openDialog(row); |
| | | }; |
| | | |
| | | //生成点位 |
| | | const generateDevicePos = (row: any) => { |
| | | ElMessageBox.prompt('请输入起始点位', '生成点位', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | }) |
| | | .then(async ({ value }) => { |
| | | await generatePos({ id: row.id, pos: value }); |
| | | ElMessage({ |
| | | type: 'success', |
| | | message: `生成点位成功`, |
| | | }) |
| | | }) |
| | | } |
| | | // 删除 |
| | | const delWcsDevice = (row: any) => { |
| | | ElMessageBox.confirm(`确定要删除吗?`, "提示", { |