| | |
| | | </el-icon> |
| | | 新增RFID |
| | | </el-button> |
| | | <el-button type="primary" :icon="Upload" size="default" @click="openUploadDialog('id')">导入</el-button> |
| | | </div> |
| | | <el-table :data="RFIDData.data" style="width: 100%"> |
| | | <el-table-column type="index" label="序号" width="60" /> |
| | |
| | | <br /> |
| | | </el-card> |
| | | <RFIDDialog ref="RFIDDialogRef" @refreshRFID="initRFIDTableData" /> |
| | | <upload-dialog ref="uploadRef" @refresh="initRFIDTableData"></upload-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | import { toRefs, reactive, onMounted, ref, defineComponent } from 'vue'; |
| | | import { ElMessageBox, ElMessage } from 'element-plus'; |
| | | import RFIDDialog from './components/RFIDDialog.vue'; |
| | | import uploadDialog from '/@/views/intellectInspect/inspectTaskManage/inspectTask/components/upload.vue' |
| | | import { RFIDApi } from '/@/api/intellectInspectSystem/RFID'; |
| | | import { Edit, View, Plus, Delete, Refresh, Search, Download } from '@element-plus/icons-vue'; |
| | | import { Edit, View, Plus, Delete, Refresh, Search, Download, Upload } from '@element-plus/icons-vue'; |
| | | import type { UploadProps, UploadUserFile } from 'element-plus' |
| | | import {departmentApi} from "/@/api/systemManage/department"; |
| | | // 定义接口来定义对象的类型 |
| | |
| | | |
| | | export default defineComponent({ |
| | | name: 'RFID', |
| | | components: { RFIDDialog, Edit, Delete }, |
| | | components: { RFIDDialog, uploadDialog }, |
| | | setup() { |
| | | const RFIDDialogRef = ref(); |
| | | const uploadRef = ref() |
| | | const state = reactive<TableDataState>({ |
| | | RFIDData: { |
| | | data: [], |
| | |
| | | } |
| | | }; |
| | | |
| | | const openUploadDialog = (type: string)=>{ |
| | | uploadRef.value.open(type) |
| | | } |
| | | |
| | | const handleSearch = () => { |
| | | initRFIDTableData(); |
| | | }; |
| | |
| | | return { |
| | | Edit, |
| | | Delete, |
| | | Upload, |
| | | uploadRef, |
| | | openUploadDialog, |
| | | handleSearch, |
| | | onOpenDialogRef, |
| | | onHandleSizeChange, |
| | | onDelProductionDevice, |
| | | onHandleCurrentChange, |
| | | RFIDDialog, |
| | | RFIDDialogRef, |
| | | |
| | | initRFIDTableData, |
| | | ...toRefs(state) |
| | | }; |