dongyukun
2025-06-04 bfa8d50882e3d75d61d484a9e13582152a43fc50
src/views/ai/model/template/index.vue
@@ -32,9 +32,9 @@
                   filterable
                   :fit-input-width="false" placeholder="请选择模型">
          <el-option
            v-for="item in scheduleModelList"
            v-for="item in aiModelList"
            :key="item.id"
            :label="item.modelName"
            :label="item.name"
            :value="item.id"
          />
        </el-select>
@@ -115,7 +115,6 @@
  import * as AiQuestionTemplateApi from '@/api/ai/questiontemplate'
  import TemplateForm from './templateForm.vue'
  import * as AiModelApi from "@/api/ai/model/model";
  import * as ScheduleModelApi from "@/api/model/sche/model";
  defineOptions({name: 'AiTemplate'})
@@ -125,6 +124,7 @@
  const loading = ref(true) // 列表的加载中
  const total = ref(0) // 列表的总页数
  const list = ref([]) // 列表的数据
  const aiModelList = ref([] as AiModelApi.ModelVO[])
  const queryParams = reactive({
    pageNo: 1,
    pageSize: 10,
@@ -138,8 +138,6 @@
  const getList = async () => {
    loading.value = true
    try {
      const scheduleModelList = ref([] as ScheduleModelApi.ScheduleModelVO[])
      scheduleModelList.value = await ScheduleModelApi.getScheduleModelList()
      const page = await AiQuestionTemplateApi.QuestionTemplateApi.getQuestionTemplatePage(queryParams)
      list.value = page.list
      total.value = page.total
@@ -182,6 +180,8 @@
  /** 初始化 **/
  onMounted(async () => {
    aiModelList.value = await AiModelApi.ModelApi.getModelSimpleList(1)
    await getList()
  })
</script>