马宇豪
2024-11-15 d8b570430066fae42d6884671cef541fc820de1c
src/views/safetyReview/expertManage/postEvaluation/index.vue
@@ -24,11 +24,11 @@
        </el-form-item>
      </el-form>
      <el-row :gutter="10" class="mb8">
        <el-col :span="1.5">
          <el-button type="primary" plain :icon="Plus" @click="openDialog('add',{})">新增</el-button>
        </el-col>
      </el-row>
<!--      <el-row :gutter="10" class="mb8">-->
<!--        <el-col :span="1.5">-->
<!--          <el-button type="primary" plain :icon="Plus" @click="openAdd('add',{})">新增</el-button>-->
<!--        </el-col>-->
<!--      </el-row>-->
      <el-table v-loading="loading" :data="expertList" :border="true">
        <el-table-column type="index" width="55" align="center" />
        <el-table-column label="项目名称" align="center" prop="name" />
@@ -61,18 +61,18 @@
          v-model:limit="queryParams.pageSize"
          @pagination="getList"
      />
      <expert-form ref="expertFormRef" @getList="getList"></expert-form>
      <expert-dialog ref="expertListRef" @getList="getList"></expert-dialog>
    </div>
</template>
<script setup>
import {getCurrentInstance, onMounted, onUnmounted, reactive, ref, toRefs} from "vue";
import {ElMessage, ElMessageBox} from "element-plus";
import ExpertForm from "./components/expertForm";
import ExpertDialog from "./components/expertList";
import {delExpert, getExpertsList, getExpertTypes} from "../../../../api/form";
import { Plus } from '@element-plus/icons-vue'
const loading = ref(false);
const loading = ref(false)
const data = reactive({
  showSearch: true,
  total: 0,
@@ -95,10 +95,11 @@
});
const { showSearch,total, expertTypes,expertList,queryParams,classiFy,searchTime} = toRefs(data);
const expertFormRef = ref()
const expertListRef = ref()
onMounted(()=>{
  getList()
  getTypes()
  // getList()
  // getTypes()
})
onUnmounted(()=>{
@@ -168,8 +169,8 @@
  loading.value = false;
}
const openDialog = (type, value) => {
  expertFormRef.value.openDialog(type, value)
const openDialog = async (type, value) => {
  expertListRef.value.openDialog(type, value)
}
const handleDelete = (val) => {