|
|
@@ -38,6 +38,11 @@
|
|
|
<el-form-item label="产品编号" prop="productNo">
|
|
|
<el-input v-model="queryParams.productNo" placeholder="请输入产品编号" clearable @keyup.enter="handleQuery" />
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="设备类型" prop="equipMainType" required>
|
|
|
+ <el-select v-model="queryParams.equipMainType" placeholder="请选择设备类型" clearable>
|
|
|
+ <el-option v-for="dict in getIntDictOptions(DICT_TYPE.PRESSURE2_EQUIP_MAIN_TYPE)" :key="dict.value" :label="dict.label" :value="dict.value" />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
<!-- 操作按钮 -->
|
|
|
<el-form-item label-width="0px">
|
|
|
<div class="w-full flex justify-center gap-80px">
|
|
|
@@ -84,6 +89,7 @@ import SmartTable from '@/components/SmartTable/SmartTable'
|
|
|
import { usePlanNewStore } from '@/store/modules/planNew'
|
|
|
import { usePageParamsStore } from '@/hooks/web/usePageParamsStore'
|
|
|
import { useTagsViewStore } from '@/store/modules/tagsView'
|
|
|
+import {DICT_TYPE, getIntDictOptions} from "@/utils/dict";
|
|
|
const tagsViewStore = useTagsViewStore()
|
|
|
defineOptions({ name: 'NewPressurePlan' })
|
|
|
|
|
|
@@ -96,7 +102,8 @@ const queryFormRef = ref<InstanceType<typeof ElForm>>()
|
|
|
const queryParams = ref<Record<string, any>>({
|
|
|
scene: 0,
|
|
|
pageNo: 1,
|
|
|
- pageSize: 10
|
|
|
+ pageSize: 10,
|
|
|
+ equipMainType: getIntDictOptions(DICT_TYPE.PRESSURE2_EQUIP_MAIN_TYPE)[0].value
|
|
|
})
|
|
|
|
|
|
const tableData = ref<PlanNewPageVO[]>([]) // 列表的数据
|
|
|
@@ -367,12 +374,33 @@ const handleEdit = (row: PlanNewPageVO) => {
|
|
|
tagsViewStore.delVisitedNameView(routerValue)
|
|
|
console.log('handleEdit', row)
|
|
|
addPlanNewData(row)
|
|
|
- router.push({
|
|
|
- name: 'PlanNewDetail',
|
|
|
- query: {
|
|
|
- id: row.id
|
|
|
- }
|
|
|
- })
|
|
|
+ switch (queryParams.value.equipMainType) {
|
|
|
+ case 200:
|
|
|
+ router.push({
|
|
|
+ name: 'BoilerDetail',
|
|
|
+ query: {
|
|
|
+ id: row.id
|
|
|
+ }
|
|
|
+ })
|
|
|
+ break;
|
|
|
+ case 300:
|
|
|
+ router.push({
|
|
|
+ name: 'PipeDetail',
|
|
|
+ query: {
|
|
|
+ id: row.id
|
|
|
+ }
|
|
|
+ })
|
|
|
+ break
|
|
|
+ case 100:
|
|
|
+ default:
|
|
|
+ router.push({
|
|
|
+ name: 'PlanNewDetail',
|
|
|
+ query: {
|
|
|
+ id: row.id
|
|
|
+ }
|
|
|
+ })
|
|
|
+ break;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
/** 初始化 **/
|