Browse Source

目前正常使用,测试中

lcl 7 months ago
parent
commit
c46fff0764
25 changed files with 377 additions and 277 deletions
  1. 23 11
      src/views/pri/priCondition/components/add/index.vue
  2. 25 13
      src/views/pri/priCondition/components/updatePriCondition/index.vue
  3. 12 20
      src/views/pri/priCondition/hook.tsx
  4. 1 1
      src/views/pri/priCondition/index.vue
  5. 13 7
      src/views/pri/priDatabaseSet/components/add/index.vue
  6. 14 8
      src/views/pri/priDatabaseSet/components/updatePriDatabaseSet/index.vue
  7. 14 14
      src/views/pri/priDatabaseSet/hook.tsx
  8. 10 10
      src/views/pri/priList/components/add/index.vue
  9. 10 10
      src/views/pri/priList/components/updatePriList/index.vue
  10. 15 25
      src/views/pri/priList/hook.tsx
  11. 27 13
      src/views/pri/priPrizeObjectField/components/add/index.vue
  12. 29 15
      src/views/pri/priPrizeObjectField/components/updatePriPrizeObjectField/index.vue
  13. 22 19
      src/views/pri/priPrizeObjectField/hook.tsx
  14. 8 3
      src/views/pri/priPrizeObjectField/index.vue
  15. 10 4
      src/views/pri/priPrizeObjectTable/components/add/index.vue
  16. 10 4
      src/views/pri/priPrizeObjectTable/components/updatePriPrizeObjectTable/index.vue
  17. 0 10
      src/views/pri/priProject/hook.tsx
  18. 28 14
      src/views/pri/priQueryField/components/add/index.vue
  19. 12 12
      src/views/pri/priQueryField/components/updatePriQueryField/index.vue
  20. 22 19
      src/views/pri/priQueryField/hook.tsx
  21. 8 3
      src/views/pri/priQueryField/index.vue
  22. 25 11
      src/views/pri/priReturnField/components/add/index.vue
  23. 9 9
      src/views/pri/priReturnField/components/updatePriReturnField/index.vue
  24. 22 19
      src/views/pri/priReturnField/hook.tsx
  25. 8 3
      src/views/pri/priReturnField/index.vue

+ 23 - 11
src/views/pri/priCondition/components/add/index.vue

@@ -39,6 +39,8 @@ let UpdateForm = ref({
   fieldQueryModel: "", //匹配方式
   fieldQueryValue: "", //匹配值
   fieldQueryValueType: "", //匹配值类型
+  prizePercent: "", //奖励比例
+  prizeAmount: "", //奖励固定金额
 
 
 });
@@ -50,9 +52,9 @@ const ruleFormRef = ref()
 const listIdOptionList = ref([]);
 // 匹配条件选项数据
 const fieldQueryKindOptionList = [
-  { id: 1, label: '模糊匹配' },
-  { id: 2, label: '精确匹配' },
-  { id: 3, label: '范围匹配' },
+  { id: '1', label: '模糊匹配' },
+  { id: '2', label: '精确匹配' },
+  { id: '3', label: '范围匹配' },
 ]
 // 匹配方式选项数据
 const fieldQueryModelOptionList = [
@@ -91,12 +93,14 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      listId: props.listId, //配置ID
-      returnFieldId: null, //条件返回字段
-      fieldQueryKind: "", //匹配条件
-      fieldQueryModel: "", //匹配方式
-      fieldQueryValue: "", //匹配值
-      fieldQueryValueType: "", //匹配值类型
+          listId: props.listId, //配置ID
+          returnFieldId: null, //条件返回字段
+          fieldQueryKind: "", //匹配条件
+          fieldQueryModel: "", //匹配方式
+          fieldQueryValue: "", //匹配值
+          fieldQueryValueType: "", //匹配值类型
+          prizePercent: "", //奖励比例
+          prizeAmount: "", //奖励固定金额
 
         };
         // 关闭新增弹窗;
@@ -120,7 +124,7 @@ const submit = async (formEl) => {
 
 //获取配置ID数据
 const listIdQuery = async () => {
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListDic.method, url: UrlList.prizeSet.prigetPriListDic.url, params: { } });
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListDic.method, url: UrlList.prizeSet.prigetPriListDic.url, params: {} });
   if (status === 1) {
     listIdOptionList.value = data.records;
   }
@@ -143,6 +147,8 @@ const closeVisible = () => {
     fieldQueryModel: "", //匹配方式
     fieldQueryValue: "", //匹配值
     fieldQueryValueType: "", //匹配值类型
+    prizePercent: "", //奖励比例
+    prizeAmount: "", //奖励固定金额
 
   };
   closeFn();
@@ -162,7 +168,7 @@ const isFullscreen = ref(false)
           placeholder="请选择配置ID",
           clearable,
         )
-          el-option(:label="item.id", :value="item.prizeName" v-for="(item,index) in listIdOptionList")
+          el-option(:label="item.prizeName", :value="item.id" v-for="(item,index) in listIdOptionList")
       el-form-item(label='条件返回字段' prop="returnFieldId")
         el-input-number(v-model='UpdateForm.returnFieldId' :min="1" :max="1000"
           placeholder="请输入条件返回字段")
@@ -190,6 +196,12 @@ const isFullscreen = ref(false)
           clearable,
         )
           el-option(:label="item.label", :value="item.id" v-for="(item,index) in fieldQueryValueTypeOptionList")
+      el-form-item(label='奖励比例' prop="prizePercent")
+        el-input-number(v-model='UpdateForm.prizePercent' :min="0" :max="1000"
+          placeholder="请输入奖励比例")
+      el-form-item(label='奖励固定金额' prop="prizeAmount")
+        el-input-number(v-model='UpdateForm.prizeAmount' :min="0" :max="1000"
+          placeholder="请输入奖励固定金额")
 
     .flex.justify-end
       el-button(

+ 25 - 13
src/views/pri/priCondition/components/updatePriCondition/index.vue

@@ -38,15 +38,17 @@ const UpdateForm: any = ref({
   fieldQueryModel: "", //匹配方式
   fieldQueryValue: "", //匹配值
   fieldQueryValueType: "", //匹配值类型
+  prizePercent: "", //奖励比例
+  prizeAmount: "", //奖励固定金额
 
 });
 // 配置ID选项数据
 const listIdOptionList = ref([]);
 // 匹配条件选项数据
 const fieldQueryKindOptionList = [
-  { id: 1, label: '模糊匹配' },
-  { id: 2, label: '精确匹配' },
-  { id: 3, label: '范围匹配' },
+  { id: '1', label: '模糊匹配' },
+  { id: '2', label: '精确匹配' },
+  { id: '3', label: '范围匹配' },
 ]
 // 匹配方式选项数据
 const fieldQueryModelOptionList = [
@@ -87,13 +89,15 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      id: null, //ID
-      listId: null, //配置ID
-      returnFieldId: null, //条件返回字段
-      fieldQueryKind: "", //匹配条件
-      fieldQueryModel: "", //匹配方式
-      fieldQueryValue: "", //匹配值
-      fieldQueryValueType: "", //匹配值类型
+          id: null, //ID
+          listId: null, //配置ID
+          returnFieldId: null, //条件返回字段
+          fieldQueryKind: "", //匹配条件
+          fieldQueryModel: "", //匹配方式
+          fieldQueryValue: "", //匹配值
+          fieldQueryValueType: "", //匹配值类型
+          prizePercent: "", //奖励比例
+          prizeAmount: "", //奖励固定金额
 
         };
         // 关闭修改弹窗;
@@ -117,7 +121,7 @@ const submit = async (formEl) => {
 
 //获取配置ID数据
 const listIdQuery = async () => {
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListDic.method, url: UrlList.prizeSet.prigetPriListDic.url, params: { } });
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListDic.method, url: UrlList.prizeSet.prigetPriListDic.url, params: {} });
   if (status === 1) {
     listIdOptionList.value = data.records;
   }
@@ -133,7 +137,7 @@ const rules = reactive({
 const closeFn: any = inject('closeEditUpdatePriConditionVisible');
 const openVisible = async () => {
   //通过ID获取表格数据
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriConditionQuery.method, url: UrlList.prizeSet.prigetPriConditionQuery.url, params: { id: props.formData.id }});
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriConditionQuery.method, url: UrlList.prizeSet.prigetPriConditionQuery.url, params: { id: props.formData.id } });
   if (status === 1) {
     UpdateForm.value = data;
 
@@ -149,6 +153,8 @@ const closeUpdatePriConditionVisible = () => {
     fieldQueryModel: "", //匹配方式
     fieldQueryValue: "", //匹配值
     fieldQueryValueType: "", //匹配值类型
+    prizePercent: "", //奖励比例
+    prizeAmount: "", //奖励固定金额
 
   };
   closeFn();
@@ -171,7 +177,7 @@ const isFullscreen = ref(false)
           placeholder="请选择配置ID",
           clearable,
         )
-          el-option(:label="item.id", :value="item.prizeName" v-for="(item,index) in listIdOptionList")
+          el-option(:label="item.prizeName", :value="item.id" v-for="(item,index) in listIdOptionList")
       el-form-item(label='条件返回字段' prop="returnFieldId")
         el-input-number(v-model='UpdateForm.returnFieldId' :min="1" :max="1000"
           placeholder="请输入条件返回字段")
@@ -199,6 +205,12 @@ const isFullscreen = ref(false)
           clearable,
         )
           el-option(:label="item.label", :value="item.id" v-for="(item,index) in fieldQueryValueTypeOptionList")
+      el-form-item(label='奖励比例' prop="prizePercent")
+        el-input-number(v-model='UpdateForm.prizePercent' :min="0" :max="1000"
+          placeholder="请输入奖励比例")
+      el-form-item(label='奖励固定金额' prop="prizeAmount")
+        el-input-number(v-model='UpdateForm.prizeAmount' :min="0" :max="1000"
+          placeholder="请输入奖励固定金额")
 
     .flex.justify-end
       el-button(

+ 12 - 20
src/views/pri/priCondition/hook.tsx

@@ -13,11 +13,11 @@ export function usePriCondition() {
 
     UrlList = await getGroupUrl(["prizeSet"]);
     onSearch(ruleFormRef.value);
-  listIdQuery();
+    listIdQuery();
 
   });
   let form = reactive({
-  listId:null, //配置ID
+    listId: null, //配置ID
 
 
   });
@@ -48,14 +48,6 @@ export function usePriCondition() {
       prop: "id",
       minWidth: 200
     },
-    {
-      label: "配置ID",
-      prop: "listId",
-      minWidth: 200
-      formatter: ({ listId }) => {
-        return listIdOptionList.find(item => item.id == listId).label
-      },
-    },
     {
       label: "条件返回字段",
       prop: "returnFieldId",
@@ -143,11 +135,11 @@ export function usePriCondition() {
       }
     })
   }
-    // 配置ID选项数据
-    const listIdOptionList = ref([]);
+  // 配置ID选项数据
+  const listIdOptionList = ref([]);
   //获取配置ID数据
   async function listIdQuery() {
-    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListDic.method, url: UrlList.prizeSet.prigetPriListDic.url, params: { } });
+    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListDic.method, url: UrlList.prizeSet.prigetPriListDic.url, params: {} });
     if (status === 1) {
       listIdOptionList.value = data.records;
     }
@@ -155,8 +147,8 @@ export function usePriCondition() {
 
 
 
-  
-    // 删除
+
+  // 删除
   function handleDelete(row) {
     ElMessageBox.confirm(
       `是否删除该奖励条件? `,
@@ -176,20 +168,20 @@ export function usePriCondition() {
         onSearch(ruleFormRef.value);
       } else {
         ElMessageBox.alert(msg, "提示", {
-        confirmButtonText: "关闭",
-        type: "warning"
-      });
+          confirmButtonText: "关闭",
+          type: "warning"
+        });
       };
     })
   }
 
-    // 新增
+  // 新增
   const addVisible = ref(false);
   function handleAdd() {
     addVisible.value = true;
   };
 
-    // 修改
+  // 修改
   const editUpdatePriConditionVisible = ref(false);
   const editUpdatePriConditionFormData = ref({});
   function handleUpdatePriCondition(row) {

+ 1 - 1
src/views/pri/priCondition/index.vue

@@ -71,7 +71,7 @@ provide('closeEditUpdatePriConditionVisible', closeEditUpdatePriConditionVisible
           placeholder="请选择配置ID",
           clearable,
         )
-          el-option(:label="item.id", :value="item.prizeName" v-for="(item,index) in listIdOptionList")
+          el-option(:label="item.prizeName", :value="item.id" v-for="(item,index) in listIdOptionList")
 
       el-form-item
         el-button(

+ 13 - 7
src/views/pri/priDatabaseSet/components/add/index.vue

@@ -37,6 +37,7 @@ let UpdateForm = ref({
   port: null, //端口
   userId: "", //用户名
   password: "", //密码
+  databaseName: "", //数据库名
   projectId: props.projectId, //项目
 
 
@@ -73,11 +74,12 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      ipAddress: "", //IP地址
-      port: null, //端口
-      userId: "", //用户名
-      password: "", //密码
-      projectId: props.projectId, //项目
+          ipAddress: "", //IP地址
+          port: null, //端口
+          userId: "", //用户名
+          password: "", //密码
+          databaseName: "", //数据库名
+          projectId: props.projectId, //项目
 
         };
         // 关闭新增弹窗;
@@ -101,7 +103,7 @@ const submit = async (formEl) => {
 
 //获取项目数据
 const projectIdQuery = async () => {
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: { } });
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: {} });
   if (status === 1) {
     projectIdOptionList.value = data.records;
   }
@@ -137,6 +139,7 @@ const closeVisible = () => {
     port: null, //端口
     userId: "", //用户名
     password: "", //密码
+    databaseName: "", //数据库名
     projectId: props.projectId, //项目
 
   };
@@ -155,7 +158,7 @@ const isFullscreen = ref(false)
         el-input(v-model='UpdateForm.ipAddress' autocomplete='off'
           placeholder="请输入IP地址")
       el-form-item(label='端口' prop="port")
-        el-input-number(v-model='UpdateForm.port' :min="1" :max="1000"
+        el-input-number(v-model='UpdateForm.port' :min="0" :max="100000"
           placeholder="请输入端口")
       el-form-item(label='用户名' prop="userId")
         el-input(v-model='UpdateForm.userId' autocomplete='off'
@@ -163,6 +166,9 @@ const isFullscreen = ref(false)
       el-form-item(label='密码' prop="password")
         el-input(v-model='UpdateForm.password' autocomplete='off'
           placeholder="请输入密码")
+      el-form-item(label='数据库名' prop="databaseName")
+        el-input(v-model='UpdateForm.databaseName' autocomplete='off'
+          placeholder="请输入数据库名")
       el-form-item(label="项目", prop="projectId")
         el-select(
           v-model="UpdateForm.projectId",

+ 14 - 8
src/views/pri/priDatabaseSet/components/updatePriDatabaseSet/index.vue

@@ -35,6 +35,7 @@ const UpdateForm: any = ref({
   port: null, //端口
   userId: "", //用户名
   password: "", //密码
+  databaseName: "", //数据库名
 
 });
 
@@ -65,11 +66,12 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      id: null, //ID
-      ipAddress: "", //IP地址
-      port: null, //端口
-      userId: "", //用户名
-      password: "", //密码
+          id: null, //ID
+          ipAddress: "", //IP地址
+          port: null, //端口
+          userId: "", //用户名
+          password: "", //密码
+          databaseName: "", //数据库名
 
         };
         // 关闭修改弹窗;
@@ -114,7 +116,7 @@ const rules = reactive({
 const closeFn: any = inject('closeEditUpdatePriDatabaseSetVisible');
 const openVisible = async () => {
   //通过ID获取表格数据
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriDatabaseSetQuery.method, url: UrlList.prizeSet.prigetPriDatabaseSetQuery.url, params: { id: props.formData.id }});
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriDatabaseSetQuery.method, url: UrlList.prizeSet.prigetPriDatabaseSetQuery.url, params: { id: props.formData.id } });
   if (status === 1) {
     UpdateForm.value = data;
 
@@ -128,6 +130,7 @@ const closeUpdatePriDatabaseSetVisible = () => {
     port: null, //端口
     userId: "", //用户名
     password: "", //密码
+    databaseName: "", //数据库名
 
   };
   closeFn();
@@ -142,13 +145,13 @@ const isFullscreen = ref(false)
   el-dialog(v-model='props.editVisible' draggable width="50%" :fullscreen="isFullscreen" title="修改" @close="closeUpdatePriDatabaseSetVisible" @open="openVisible")
     el-form(:model='UpdateForm' label-position="right" ref="ruleFormRef" :rules="rules" label-width="100px")
       el-form-item(label='ID' prop="id")
-        el-input-number(v-model='UpdateForm.id' :min="1" :max="1000"
+        el-input-number(v-model='UpdateForm.id' :min="1" :max="100000"
           placeholder="请输入ID")
       el-form-item(label='IP地址' prop="ipAddress")
         el-input(v-model='UpdateForm.ipAddress' autocomplete='off'
           placeholder="请输入IP地址")
       el-form-item(label='端口' prop="port")
-        el-input-number(v-model='UpdateForm.port' :min="1" :max="1000"
+        el-input-number(v-model='UpdateForm.port' :min="0" :max="100000"
           placeholder="请输入端口")
       el-form-item(label='用户名' prop="userId")
         el-input(v-model='UpdateForm.userId' autocomplete='off'
@@ -156,6 +159,9 @@ const isFullscreen = ref(false)
       el-form-item(label='密码' prop="password")
         el-input(v-model='UpdateForm.password' autocomplete='off'
           placeholder="请输入密码")
+      el-form-item(label='数据库名' prop="databaseName")
+        el-input(v-model='UpdateForm.databaseName' autocomplete='off'
+          placeholder="请输入数据库名")
 
     .flex.justify-end
       el-button(

+ 14 - 14
src/views/pri/priDatabaseSet/hook.tsx

@@ -13,13 +13,13 @@ export function usePriDatabaseSet() {
 
     UrlList = await getGroupUrl(["prizeSet"]);
     onSearch(ruleFormRef.value);
-  projectIdQuery();
+    projectIdQuery();
 
   });
   let form = reactive({
-  ipAddress:"", //IP地址
-  userId:"", //用户名
-  projectId:null, //项目
+    ipAddress: "", //IP地址
+    userId: "", //用户名
+    projectId: null, //项目
 
 
   });
@@ -132,11 +132,11 @@ export function usePriDatabaseSet() {
       }
     })
   }
-    // 项目选项数据
-    const projectIdOptionList = ref([]);
+  // 项目选项数据
+  const projectIdOptionList = ref([]);
   //获取项目数据
   async function projectIdQuery() {
-    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: { } });
+    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: {} });
     if (status === 1) {
       projectIdOptionList.value = data.records;
     }
@@ -144,8 +144,8 @@ export function usePriDatabaseSet() {
 
 
 
-  
-    // 删除
+
+  // 删除
   function handleDelete(row) {
     ElMessageBox.confirm(
       `是否删除该数据库连接配置? `,
@@ -165,20 +165,20 @@ export function usePriDatabaseSet() {
         onSearch(ruleFormRef.value);
       } else {
         ElMessageBox.alert(msg, "提示", {
-        confirmButtonText: "关闭",
-        type: "warning"
-      });
+          confirmButtonText: "关闭",
+          type: "warning"
+        });
       };
     })
   }
 
-    // 新增
+  // 新增
   const addVisible = ref(false);
   function handleAdd() {
     addVisible.value = true;
   };
 
-    // 修改
+  // 修改
   const editUpdatePriDatabaseSetVisible = ref(false);
   const editUpdatePriDatabaseSetFormData = ref({});
   function handleUpdatePriDatabaseSet(row) {

+ 10 - 10
src/views/pri/priList/components/add/index.vue

@@ -86,13 +86,13 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      projectId: props.projectId, //项目
-      prizeName: "", //奖励名称
-      prizePercent: "", //奖励比例
-      prizeAmount: "", //奖励固定金额
-      conditionMode: "", //条件模式
-      recursionFlag: "", //是否递归
-      prizeContent: "", //奖励内容
+          projectId: props.projectId, //项目
+          prizeName: "", //奖励名称
+          prizePercent: "", //奖励比例
+          prizeAmount: "", //奖励固定金额
+          conditionMode: "", //条件模式
+          recursionFlag: "", //是否递归
+          prizeContent: "", //奖励内容
 
         };
         // 关闭新增弹窗;
@@ -116,7 +116,7 @@ const submit = async (formEl) => {
 
 //获取项目数据
 const projectIdQuery = async () => {
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: { } });
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: {} });
   if (status === 1) {
     projectIdOptionList.value = data.records;
   }
@@ -176,10 +176,10 @@ const isFullscreen = ref(false)
         el-input(v-model='UpdateForm.prizeName' autocomplete='off'
           placeholder="请输入奖励名称")
       el-form-item(label='奖励比例' prop="prizePercent")
-        el-input-number(v-model='UpdateForm.prizePercent' :min="1" :max="1000"
+        el-input-number(v-model='UpdateForm.prizePercent' :min="0" :max="1000"
           placeholder="请输入奖励比例")
       el-form-item(label='奖励固定金额' prop="prizeAmount")
-        el-input-number(v-model='UpdateForm.prizeAmount' :min="1" :max="1000"
+        el-input-number(v-model='UpdateForm.prizeAmount' :min="0" :max="1000"
           placeholder="请输入奖励固定金额")
       el-form-item(label="条件模式", prop="conditionMode")
         el-select(

+ 10 - 10
src/views/pri/priList/components/updatePriList/index.vue

@@ -78,13 +78,13 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      id: null, //ID
-      prizeName: "", //奖励名称
-      prizePercent: "", //奖励比例
-      prizeAmount: "", //奖励固定金额
-      conditionMode: "", //条件模式
-      recursionFlag: "", //是否递归
-      prizeContent: "", //奖励内容
+          id: null, //ID
+          prizeName: "", //奖励名称
+          prizePercent: "", //奖励比例
+          prizeAmount: "", //奖励固定金额
+          conditionMode: "", //条件模式
+          recursionFlag: "", //是否递归
+          prizeContent: "", //奖励内容
 
         };
         // 关闭修改弹窗;
@@ -129,7 +129,7 @@ const rules = reactive({
 const closeFn: any = inject('closeEditUpdatePriListVisible');
 const openVisible = async () => {
   //通过ID获取表格数据
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListQuery.method, url: UrlList.prizeSet.prigetPriListQuery.url, params: { id: props.formData.id }});
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriListQuery.method, url: UrlList.prizeSet.prigetPriListQuery.url, params: { id: props.formData.id } });
   if (status === 1) {
     UpdateForm.value = data;
 
@@ -165,10 +165,10 @@ const isFullscreen = ref(false)
         el-input(v-model='UpdateForm.prizeName' autocomplete='off'
           placeholder="请输入奖励名称")
       el-form-item(label='奖励比例' prop="prizePercent")
-        el-input-number(v-model='UpdateForm.prizePercent' :min="1" :max="1000"
+        el-input-number(v-model='UpdateForm.prizePercent' :min="0" :max="1000"
           placeholder="请输入奖励比例")
       el-form-item(label='奖励固定金额' prop="prizeAmount")
-        el-input-number(v-model='UpdateForm.prizeAmount' :min="1" :max="1000"
+        el-input-number(v-model='UpdateForm.prizeAmount' :min="0" :max="1000"
           placeholder="请输入奖励固定金额")
       el-form-item(label="条件模式", prop="conditionMode")
         el-select(

+ 15 - 25
src/views/pri/priList/hook.tsx

@@ -13,14 +13,14 @@ export function usePriList() {
 
     UrlList = await getGroupUrl(["prizeSet"]);
     onSearch(ruleFormRef.value);
-  projectIdQuery();
+    projectIdQuery();
 
   });
   let form = reactive({
-  projectId:null, //项目
-  prizeName:"", //奖励名称
-  conditionMode:"", //条件模式
-  prizeContent:"", //奖励内容
+    projectId: null, //项目
+    prizeName: "", //奖励名称
+    conditionMode: "", //条件模式
+    prizeContent: "", //奖励内容
 
 
   });
@@ -81,16 +81,6 @@ export function usePriList() {
       prop: "prizeContent",
       minWidth: 200
     },
-    {
-      label: "ID",
-      prop: "id",
-      minWidth: 200
-    },
-    {
-      label: "奖励名称",
-      prop: "prizeName",
-      minWidth: 200
-    },
 
     {
       label: "操作",
@@ -153,11 +143,11 @@ export function usePriList() {
       }
     })
   }
-    // 项目选项数据
-    const projectIdOptionList = ref([]);
+  // 项目选项数据
+  const projectIdOptionList = ref([]);
   //获取项目数据
   async function projectIdQuery() {
-    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: { } });
+    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: {} });
     if (status === 1) {
       projectIdOptionList.value = data.records;
     }
@@ -176,7 +166,7 @@ export function usePriList() {
 
 
 
-    //跳转到奖励条件
+  //跳转到奖励条件
   function linkToPriCondition(row) {
     router.push({ path: '../../pri/priCondition/index', query: { listId: row.id } });
   }
@@ -197,7 +187,7 @@ export function usePriList() {
     router.push({ path: '../../pri/priPrizeInTable/index', query: { listId: row.id } });
   }
 
-    // 删除
+  // 删除
   function handleDelete(row) {
     ElMessageBox.confirm(
       `是否删除该奖励配置? `,
@@ -217,20 +207,20 @@ export function usePriList() {
         onSearch(ruleFormRef.value);
       } else {
         ElMessageBox.alert(msg, "提示", {
-        confirmButtonText: "关闭",
-        type: "warning"
-      });
+          confirmButtonText: "关闭",
+          type: "warning"
+        });
       };
     })
   }
 
-    // 新增
+  // 新增
   const addVisible = ref(false);
   function handleAdd() {
     addVisible.value = true;
   };
 
-    // 修改
+  // 修改
   const editUpdatePriListVisible = ref(false);
   const editUpdatePriListFormData = ref({});
   function handleUpdatePriList(row) {

+ 27 - 13
src/views/pri/priPrizeObjectField/components/add/index.vue

@@ -11,6 +11,7 @@ let UrlList = reactive(null)
 // 获取当前板块接口列表
 onMounted(async () => {
   UrlList = await getGroupUrl(["prizeSet"]);
+  objectTableIdQuery();
 
 })
 // 组件传参对象
@@ -48,9 +49,9 @@ const ruleFormRef = ref()
 // 传参选项数据
 // 匹配条件选项数据
 const fieldQueryKindOptionList = [
-  { id: 1, label: '模糊匹配' },
-  { id: 2, label: '精确匹配' },
-  { id: 3, label: '范围匹配' },
+  { id: '1', label: '模糊匹配' },
+  { id: '2', label: '精确匹配' },
+  { id: '3', label: '范围匹配' },
 ]
 // 匹配方式选项数据
 const fieldQueryModelOptionList = [
@@ -64,6 +65,8 @@ const fieldQueryValueTypeOptionList = [
   { id: 'number', label: '数字' },
   { id: 'range', label: '范围' },
 ]
+// 对象表选项数据
+const objectTableIdOptionList = ref([]);
 
 // 选项卡参数(默认值为列表某项的id)
 const activeId = ref('1')
@@ -90,13 +93,13 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      fieldName: "", //字段名称
-      fieldEnName: "", //字段名
-      fieldQueryKind: "", //匹配条件
-      fieldQueryModel: "", //匹配方式
-      fieldQueryValue: "", //匹配值
-      fieldQueryValueType: "", //匹配值类型
-      objectTableId: props.objectTableId, //对象表
+          fieldName: "", //字段名称
+          fieldEnName: "", //字段名
+          fieldQueryKind: "", //匹配条件
+          fieldQueryModel: "", //匹配方式
+          fieldQueryValue: "", //匹配值
+          fieldQueryValueType: "", //匹配值类型
+          objectTableId: props.objectTableId, //对象表
 
         };
         // 关闭新增弹窗;
@@ -118,6 +121,13 @@ const submit = async (formEl) => {
   })
 };
 
+//获取对象表数据
+const objectTableIdQuery = async () => {
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriPrizeObjectTableDic.method, url: UrlList.prizeSet.prigetPriPrizeObjectTableDic.url, params: {} });
+  if (status === 1) {
+    objectTableIdOptionList.value = data.records;
+  }
+};
 
 
 
@@ -180,9 +190,13 @@ const isFullscreen = ref(false)
           clearable,
         )
           el-option(:label="item.label", :value="item.id" v-for="(item,index) in fieldQueryValueTypeOptionList")
-      el-form-item(label='对象表' prop="objectTableId")
-        el-input-number(v-model='UpdateForm.objectTableId' :min="1" :max="1000"
-          placeholder="请输入对象表")
+      el-form-item(label="对象表", prop="objectTableId")
+        el-select(
+          v-model="UpdateForm.objectTableId",
+          placeholder="请选择对象表",
+          clearable,
+        )
+          el-option(:label="item.tableEnName", :value="item.id" v-for="(item,index) in objectTableIdOptionList")
 
     .flex.justify-end
       el-button(

+ 29 - 15
src/views/pri/priPrizeObjectField/components/updatePriPrizeObjectField/index.vue

@@ -11,6 +11,7 @@ let UrlList = reactive(null)
 // 获取当前板块接口列表
 onMounted(async () => {
   UrlList = await getGroupUrl(["prizeSet"]);
+  objectTableIdQuery();
 
 })
 const props = defineProps<{
@@ -42,9 +43,9 @@ const UpdateForm: any = ref({
 });
 // 匹配条件选项数据
 const fieldQueryKindOptionList = [
-  { id: 1, label: '模糊匹配' },
-  { id: 2, label: '精确匹配' },
-  { id: 3, label: '范围匹配' },
+  { id: '1', label: '模糊匹配' },
+  { id: '2', label: '精确匹配' },
+  { id: '3', label: '范围匹配' },
 ]
 // 匹配方式选项数据
 const fieldQueryModelOptionList = [
@@ -58,6 +59,8 @@ const fieldQueryValueTypeOptionList = [
   { id: 'number', label: '数字' },
   { id: 'range', label: '范围' },
 ]
+// 对象表选项数据
+const objectTableIdOptionList = ref([]);
 
 // 表单实例
 const ruleFormRef = ref()
@@ -86,14 +89,14 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      id: null, //ID
-      fieldName: "", //字段名称
-      fieldEnName: "", //字段名
-      fieldQueryKind: "", //匹配条件
-      fieldQueryModel: "", //匹配方式
-      fieldQueryValue: "", //匹配值
-      fieldQueryValueType: "", //匹配值类型
-      objectTableId: null, //对象表
+          id: null, //ID
+          fieldName: "", //字段名称
+          fieldEnName: "", //字段名
+          fieldQueryKind: "", //匹配条件
+          fieldQueryModel: "", //匹配方式
+          fieldQueryValue: "", //匹配值
+          fieldQueryValueType: "", //匹配值类型
+          objectTableId: null, //对象表
 
         };
         // 关闭修改弹窗;
@@ -115,6 +118,13 @@ const submit = async (formEl) => {
   })
 };
 
+//获取对象表数据
+const objectTableIdQuery = async () => {
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriPrizeObjectTableDic.method, url: UrlList.prizeSet.prigetPriPrizeObjectTableDic.url, params: {} });
+  if (status === 1) {
+    objectTableIdOptionList.value = data.records;
+  }
+};
 
 
 
@@ -126,7 +136,7 @@ const rules = reactive({
 const closeFn: any = inject('closeEditUpdatePriPrizeObjectFieldVisible');
 const openVisible = async () => {
   //通过ID获取表格数据
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriPrizeObjectFieldQuery.method, url: UrlList.prizeSet.prigetPriPrizeObjectFieldQuery.url, params: { id: props.formData.id }});
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriPrizeObjectFieldQuery.method, url: UrlList.prizeSet.prigetPriPrizeObjectFieldQuery.url, params: { id: props.formData.id } });
   if (status === 1) {
     UpdateForm.value = data;
 
@@ -189,9 +199,13 @@ const isFullscreen = ref(false)
           clearable,
         )
           el-option(:label="item.label", :value="item.id" v-for="(item,index) in fieldQueryValueTypeOptionList")
-      el-form-item(label='对象表' prop="objectTableId")
-        el-input-number(v-model='UpdateForm.objectTableId' :min="1" :max="1000"
-          placeholder="请输入对象表")
+      el-form-item(label="对象表", prop="objectTableId")
+        el-select(
+          v-model="UpdateForm.objectTableId",
+          placeholder="请选择对象表",
+          clearable,
+        )
+          el-option(:label="item.tableEnName", :value="item.id" v-for="(item,index) in objectTableIdOptionList")
 
     .flex.justify-end
       el-button(

+ 22 - 19
src/views/pri/priPrizeObjectField/hook.tsx

@@ -1,6 +1,5 @@
 import { reactive, onMounted, ref, ElMessage, ElMessageBox, http, getGroupUrl, RegularVerification, verification, PaginationProps } from "@/utils/importUsed";
 import { useRoute } from "vue-router";
-import router from "@/router";
 // 表单实例
 const ruleFormRef = ref()
 export function usePriPrizeObjectField() {
@@ -13,12 +12,13 @@ export function usePriPrizeObjectField() {
 
     UrlList = await getGroupUrl(["prizeSet"]);
     onSearch(ruleFormRef.value);
+    objectTableIdQuery();
 
   });
   let form = reactive({
-  fieldName:"", //字段名称
-  fieldEnName:"", //字段名
-  objectTableId:null, //对象表
+    fieldName: "", //字段名称
+    fieldEnName: "", //字段名
+    objectTableId: null, //对象表
 
 
   });
@@ -79,14 +79,6 @@ export function usePriPrizeObjectField() {
       prop: "fieldQueryValueType",
       minWidth: 200
     },
-    {
-      label: "对象表",
-      prop: "objectTableId",
-      minWidth: 200
-      formatter: ({ objectTableId }) => {
-        return objectTableIdOptionList.find(item => item.id == objectTableId).label
-      },
-    },
 
     {
       label: "操作",
@@ -149,11 +141,20 @@ export function usePriPrizeObjectField() {
       }
     })
   }
+  // 对象表选项数据
+  const objectTableIdOptionList = ref([]);
+  //获取对象表数据
+  async function objectTableIdQuery() {
+    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriPrizeObjectTableDic.method, url: UrlList.prizeSet.prigetPriPrizeObjectTableDic.url, params: {} });
+    if (status === 1) {
+      objectTableIdOptionList.value = data.records;
+    }
+  }
+
 
 
 
-  
-    // 删除
+  // 删除
   function handleDelete(row) {
     ElMessageBox.confirm(
       `是否删除该奖励发放对象字段? `,
@@ -173,20 +174,20 @@ export function usePriPrizeObjectField() {
         onSearch(ruleFormRef.value);
       } else {
         ElMessageBox.alert(msg, "提示", {
-        confirmButtonText: "关闭",
-        type: "warning"
-      });
+          confirmButtonText: "关闭",
+          type: "warning"
+        });
       };
     })
   }
 
-    // 新增
+  // 新增
   const addVisible = ref(false);
   function handleAdd() {
     addVisible.value = true;
   };
 
-    // 修改
+  // 修改
   const editUpdatePriPrizeObjectFieldVisible = ref(false);
   const editUpdatePriPrizeObjectFieldFormData = ref({});
   function handleUpdatePriPrizeObjectField(row) {
@@ -206,6 +207,8 @@ export function usePriPrizeObjectField() {
     handleCurrentChange,
     handleSelectionChange,
     ruleFormRef,
+    objectTableIdQuery,
+    objectTableIdOptionList,
 
     handleAdd,
     addVisible,

+ 8 - 3
src/views/pri/priPrizeObjectField/index.vue

@@ -28,6 +28,7 @@ const {
   handleCurrentChange,
   handleSelectionChange,
   ruleFormRef,
+  objectTableIdOptionList,
   handleAdd,
   addVisible,
   handleUpdatePriPrizeObjectField,
@@ -70,9 +71,13 @@ provide('closeEditUpdatePriPrizeObjectFieldVisible', closeEditUpdatePriPrizeObje
       el-form-item(label='字段名' prop="fieldEnName")
         el-input(v-model='form.fieldEnName' autocomplete='off'
           placeholder="请输入字段名")
-      el-form-item(label='对象表' prop="objectTableId")
-        el-input-number(v-model='form.objectTableId' :min="1" :max="1000"
-          placeholder="请输入对象表")
+      el-form-item(label="对象表", prop="objectTableId")
+        el-select(
+          v-model="form.objectTableId",
+          placeholder="请选择对象表",
+          clearable,
+        )
+          el-option(:label="item.tableEnName", :value="item.id" v-for="(item,index) in objectTableIdOptionList")
 
       el-form-item
         el-button(

+ 10 - 4
src/views/pri/priPrizeObjectTable/components/add/index.vue

@@ -36,6 +36,7 @@ let UpdateForm = ref({
   projectId: props.projectId, //项目
   tableEnName: "", //查询表
   prizeListIds: "", //指定奖励配置
+  selectField: "", //取值字段
 
 
 });
@@ -71,9 +72,10 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      projectId: props.projectId, //项目
-      tableEnName: "", //查询表
-      prizeListIds: "", //指定奖励配置
+          projectId: props.projectId, //项目
+          tableEnName: "", //查询表
+          prizeListIds: "", //指定奖励配置
+          selectField: "", //取值字段
 
         };
         // 关闭新增弹窗;
@@ -97,7 +99,7 @@ const submit = async (formEl) => {
 
 //获取项目数据
 const projectIdQuery = async () => {
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: { } });
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriProjectDic.method, url: UrlList.prizeSet.prigetPriProjectDic.url, params: {} });
   if (status === 1) {
     projectIdOptionList.value = data.records;
   }
@@ -123,6 +125,7 @@ const closeVisible = () => {
     projectId: props.projectId, //项目
     tableEnName: "", //查询表
     prizeListIds: "", //指定奖励配置
+    selectField: "", //取值字段
 
   };
   closeFn();
@@ -149,6 +152,9 @@ const isFullscreen = ref(false)
       el-form-item(label='指定奖励配置' prop="prizeListIds")
         el-input(v-model='UpdateForm.prizeListIds' autocomplete='off'
           placeholder="请输入指定奖励配置")
+      el-form-item(label='取值字段' prop="selectField")
+        el-input(v-model='UpdateForm.selectField' autocomplete='off'
+          placeholder="请输入取值字段")
 
     .flex.justify-end
       el-button(

+ 10 - 4
src/views/pri/priPrizeObjectTable/components/updatePriPrizeObjectTable/index.vue

@@ -33,6 +33,7 @@ const UpdateForm: any = ref({
   tableEnName: "", //查询表
   id: null, //ID
   prizeListIds: "", //指定奖励配置
+  selectField: "", //取值字段
 
 });
 
@@ -63,9 +64,10 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      tableEnName: "", //查询表
-      id: null, //ID
-      prizeListIds: "", //指定奖励配置
+          tableEnName: "", //查询表
+          id: null, //ID
+          prizeListIds: "", //指定奖励配置
+          selectField: "", //取值字段
 
         };
         // 关闭修改弹窗;
@@ -101,7 +103,7 @@ const rules = reactive({
 const closeFn: any = inject('closeEditUpdatePriPrizeObjectTableVisible');
 const openVisible = async () => {
   //通过ID获取表格数据
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriPrizeObjectTableQuery.method, url: UrlList.prizeSet.prigetPriPrizeObjectTableQuery.url, params: { id: props.formData.id }});
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriPrizeObjectTableQuery.method, url: UrlList.prizeSet.prigetPriPrizeObjectTableQuery.url, params: { id: props.formData.id } });
   if (status === 1) {
     UpdateForm.value = data;
 
@@ -113,6 +115,7 @@ const closeUpdatePriPrizeObjectTableVisible = () => {
     tableEnName: "", //查询表
     id: null, //ID
     prizeListIds: "", //指定奖励配置
+    selectField: "", //取值字段
 
   };
   closeFn();
@@ -135,6 +138,9 @@ const isFullscreen = ref(false)
       el-form-item(label='指定奖励配置' prop="prizeListIds")
         el-input(v-model='UpdateForm.prizeListIds' autocomplete='off'
           placeholder="请输入指定奖励配置")
+      el-form-item(label='取值字段' prop="selectField")
+        el-input(v-model='UpdateForm.selectField' autocomplete='off'
+          placeholder="请输入取值字段")
 
     .flex.justify-end
       el-button(

+ 0 - 10
src/views/pri/priProject/hook.tsx

@@ -72,16 +72,6 @@ export function usePriProject() {
       prop: "returnType",
       minWidth: 200
     },
-    {
-      label: "项目名称",
-      prop: "projectName",
-      minWidth: 200
-    },
-    {
-      label: "ID",
-      prop: "id",
-      minWidth: 200
-    },
 
     {
       label: "操作",

+ 28 - 14
src/views/pri/priQueryField/components/add/index.vue

@@ -11,6 +11,7 @@ let UrlList = reactive(null)
 // 获取当前板块接口列表
 onMounted(async () => {
   UrlList = await getGroupUrl(["prizeSet"]);
+  queryTableIdQuery();
 
 })
 // 组件传参对象
@@ -48,9 +49,10 @@ const ruleFormRef = ref()
 // 传参选项数据
 // 匹配条件选项数据
 const fieldQueryKindOptionList = [
-  { id: 1, label: '模糊匹配' },
-  { id: 2, label: '精确匹配' },
-  { id: 3, label: '范围匹配' },
+  { id: "1", label: '模糊匹配' },
+  { id: "2", label: '精确匹配' },
+  { id: "3", label: '范围匹配' },
+  { id: "4", label: '取反匹配' },
 ]
 // 匹配方式选项数据
 const fieldQueryModelOptionList = [
@@ -62,8 +64,9 @@ const fieldQueryModelOptionList = [
 const fieldQueryValueTypeOptionList = [
   { id: 'text', label: '文本' },
   { id: 'number', label: '数字' },
-  { id: 'range', label: '范围' },
 ]
+// 匹配表选项数据
+const queryTableIdOptionList = ref([]);
 
 // 选项卡参数(默认值为列表某项的id)
 const activeId = ref('1')
@@ -90,13 +93,13 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      fieldName: "", //字段名称
-      fieldEnName: "", //字段名
-      fieldQueryKind: "", //匹配条件
-      fieldQueryModel: "", //匹配方式
-      fieldQueryValue: "", //匹配值
-      fieldQueryValueType: "", //匹配值类型
-      queryTableId: props.queryTableId, //匹配表
+          fieldName: "", //字段名称
+          fieldEnName: "", //字段名
+          fieldQueryKind: "", //匹配条件
+          fieldQueryModel: "", //匹配方式
+          fieldQueryValue: "", //匹配值
+          fieldQueryValueType: "", //匹配值类型
+          queryTableId: props.queryTableId, //匹配表
 
         };
         // 关闭新增弹窗;
@@ -118,6 +121,13 @@ const submit = async (formEl) => {
   })
 };
 
+//获取匹配表数据
+const queryTableIdQuery = async () => {
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriQueryTableDic.method, url: UrlList.prizeSet.prigetPriQueryTableDic.url, params: {} });
+  if (status === 1) {
+    queryTableIdOptionList.value = data.records;
+  }
+};
 
 
 
@@ -180,9 +190,13 @@ const isFullscreen = ref(false)
           clearable,
         )
           el-option(:label="item.label", :value="item.id" v-for="(item,index) in fieldQueryValueTypeOptionList")
-      el-form-item(label='匹配表' prop="queryTableId")
-        el-input-number(v-model='UpdateForm.queryTableId' :min="1" :max="1000"
-          placeholder="请输入匹配表")
+      el-form-item(label="匹配表", prop="queryTableId")
+        el-select(
+          v-model="UpdateForm.queryTableId",
+          placeholder="请选择匹配表",
+          clearable,
+        )
+          el-option(:label="item.tableEnName", :value="item.id" v-for="(item,index) in queryTableIdOptionList")
 
     .flex.justify-end
       el-button(

+ 12 - 12
src/views/pri/priQueryField/components/updatePriQueryField/index.vue

@@ -41,9 +41,10 @@ const UpdateForm: any = ref({
 });
 // 匹配条件选项数据
 const fieldQueryKindOptionList = [
-  { id: 1, label: '模糊匹配' },
-  { id: 2, label: '精确匹配' },
-  { id: 3, label: '范围匹配' },
+  { id: "1", label: '模糊匹配' },
+  { id: "2", label: '精确匹配' },
+  { id: "3", label: '范围匹配' },
+  { id: "4", label: '取反匹配' },
 ]
 // 匹配方式选项数据
 const fieldQueryModelOptionList = [
@@ -55,7 +56,6 @@ const fieldQueryModelOptionList = [
 const fieldQueryValueTypeOptionList = [
   { id: 'text', label: '文本' },
   { id: 'number', label: '数字' },
-  { id: 'range', label: '范围' },
 ]
 
 // 表单实例
@@ -85,13 +85,13 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      id: null, //ID
-      fieldName: "", //字段名称
-      fieldEnName: "", //字段名
-      fieldQueryKind: "", //匹配条件
-      fieldQueryModel: "", //匹配方式
-      fieldQueryValue: "", //匹配值
-      fieldQueryValueType: "", //匹配值类型
+          id: null, //ID
+          fieldName: "", //字段名称
+          fieldEnName: "", //字段名
+          fieldQueryKind: "", //匹配条件
+          fieldQueryModel: "", //匹配方式
+          fieldQueryValue: "", //匹配值
+          fieldQueryValueType: "", //匹配值类型
 
         };
         // 关闭修改弹窗;
@@ -124,7 +124,7 @@ const rules = reactive({
 const closeFn: any = inject('closeEditUpdatePriQueryFieldVisible');
 const openVisible = async () => {
   //通过ID获取表格数据
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriQueryFieldQuery.method, url: UrlList.prizeSet.prigetPriQueryFieldQuery.url, params: { id: props.formData.id }});
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriQueryFieldQuery.method, url: UrlList.prizeSet.prigetPriQueryFieldQuery.url, params: { id: props.formData.id } });
   if (status === 1) {
     UpdateForm.value = data;
 

+ 22 - 19
src/views/pri/priQueryField/hook.tsx

@@ -1,6 +1,5 @@
 import { reactive, onMounted, ref, ElMessage, ElMessageBox, http, getGroupUrl, RegularVerification, verification, PaginationProps } from "@/utils/importUsed";
 import { useRoute } from "vue-router";
-import router from "@/router";
 // 表单实例
 const ruleFormRef = ref()
 export function usePriQueryField() {
@@ -13,12 +12,13 @@ export function usePriQueryField() {
 
     UrlList = await getGroupUrl(["prizeSet"]);
     onSearch(ruleFormRef.value);
+    queryTableIdQuery();
 
   });
   let form = reactive({
-  fieldName:"", //字段名称
-  fieldEnName:"", //字段名
-  queryTableId:null, //匹配表
+    fieldName: "", //字段名称
+    fieldEnName: "", //字段名
+    queryTableId: null, //匹配表
 
 
   });
@@ -79,14 +79,6 @@ export function usePriQueryField() {
       prop: "fieldQueryValueType",
       minWidth: 200
     },
-    {
-      label: "匹配表",
-      prop: "queryTableId",
-      minWidth: 200
-      formatter: ({ queryTableId }) => {
-        return queryTableIdOptionList.find(item => item.id == queryTableId).label
-      },
-    },
 
     {
       label: "操作",
@@ -149,11 +141,20 @@ export function usePriQueryField() {
       }
     })
   }
+  // 匹配表选项数据
+  const queryTableIdOptionList = ref([]);
+  //获取匹配表数据
+  async function queryTableIdQuery() {
+    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriQueryTableDic.method, url: UrlList.prizeSet.prigetPriQueryTableDic.url, params: {} });
+    if (status === 1) {
+      queryTableIdOptionList.value = data.records;
+    }
+  }
+
 
 
 
-  
-    // 删除
+  // 删除
   function handleDelete(row) {
     ElMessageBox.confirm(
       `是否删除该条件匹配字段? `,
@@ -173,20 +174,20 @@ export function usePriQueryField() {
         onSearch(ruleFormRef.value);
       } else {
         ElMessageBox.alert(msg, "提示", {
-        confirmButtonText: "关闭",
-        type: "warning"
-      });
+          confirmButtonText: "关闭",
+          type: "warning"
+        });
       };
     })
   }
 
-    // 新增
+  // 新增
   const addVisible = ref(false);
   function handleAdd() {
     addVisible.value = true;
   };
 
-    // 修改
+  // 修改
   const editUpdatePriQueryFieldVisible = ref(false);
   const editUpdatePriQueryFieldFormData = ref({});
   function handleUpdatePriQueryField(row) {
@@ -206,6 +207,8 @@ export function usePriQueryField() {
     handleCurrentChange,
     handleSelectionChange,
     ruleFormRef,
+    queryTableIdQuery,
+    queryTableIdOptionList,
 
     handleAdd,
     addVisible,

+ 8 - 3
src/views/pri/priQueryField/index.vue

@@ -28,6 +28,7 @@ const {
   handleCurrentChange,
   handleSelectionChange,
   ruleFormRef,
+  queryTableIdOptionList,
   handleAdd,
   addVisible,
   handleUpdatePriQueryField,
@@ -70,9 +71,13 @@ provide('closeEditUpdatePriQueryFieldVisible', closeEditUpdatePriQueryFieldVisib
       el-form-item(label='字段名' prop="fieldEnName")
         el-input(v-model='form.fieldEnName' autocomplete='off'
           placeholder="请输入字段名")
-      el-form-item(label='匹配表' prop="queryTableId")
-        el-input-number(v-model='form.queryTableId' :min="1" :max="1000"
-          placeholder="请输入匹配表")
+      el-form-item(label="匹配表", prop="queryTableId")
+        el-select(
+          v-model="form.queryTableId",
+          placeholder="请选择匹配表",
+          clearable,
+        )
+          el-option(:label="item.tableEnName", :value="item.id" v-for="(item,index) in queryTableIdOptionList")
 
       el-form-item
         el-button(

+ 25 - 11
src/views/pri/priReturnField/components/add/index.vue

@@ -11,6 +11,7 @@ let UrlList = reactive(null)
 // 获取当前板块接口列表
 onMounted(async () => {
   UrlList = await getGroupUrl(["prizeSet"]);
+  queryTableIdQuery();
 
 })
 // 组件传参对象
@@ -45,11 +46,13 @@ const ruleFormRef = ref()
 // 传参选项数据
 // 返回类型选项数据
 const fieldReturnKindOptionList = [
-  { id: 1, label: '字段值' },
-  { id: 2, label: '数量' },
-  { id: 3, label: '求和' },
-  { id: 4, label: '平均值' },
+  { id: '1', label: '字段值' },
+  { id: '2', label: '数量' },
+  { id: '3', label: '求和' },
+  { id: '4', label: '平均值' },
 ]
+// 匹配表选项数据
+const queryTableIdOptionList = ref([]);
 
 // 选项卡参数(默认值为列表某项的id)
 const activeId = ref('1')
@@ -76,10 +79,10 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      fieldName: "", //字段名称
-      fieldEnName: "", //字段名
-      fieldReturnKind: "", //返回类型
-      queryTableId: props.queryTableId, //匹配表
+          fieldName: "", //字段名称
+          fieldEnName: "", //字段名
+          fieldReturnKind: "", //返回类型
+          queryTableId: props.queryTableId, //匹配表
 
         };
         // 关闭新增弹窗;
@@ -101,6 +104,13 @@ const submit = async (formEl) => {
   })
 };
 
+//获取匹配表数据
+const queryTableIdQuery = async () => {
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriQueryTableDic.method, url: UrlList.prizeSet.prigetPriQueryTableDic.url, params: {} });
+  if (status === 1) {
+    queryTableIdOptionList.value = data.records;
+  }
+};
 
 
 
@@ -143,9 +153,13 @@ const isFullscreen = ref(false)
           clearable,
         )
           el-option(:label="item.label", :value="item.id" v-for="(item,index) in fieldReturnKindOptionList")
-      el-form-item(label='匹配表' prop="queryTableId")
-        el-input-number(v-model='UpdateForm.queryTableId' :min="1" :max="1000"
-          placeholder="请输入匹配表")
+      el-form-item(label="匹配表", prop="queryTableId")
+        el-select(
+          v-model="UpdateForm.queryTableId",
+          placeholder="请选择匹配表",
+          clearable,
+        )
+          el-option(:label="item.tableEnName", :value="item.id" v-for="(item,index) in queryTableIdOptionList")
 
     .flex.justify-end
       el-button(

+ 9 - 9
src/views/pri/priReturnField/components/updatePriReturnField/index.vue

@@ -38,10 +38,10 @@ const UpdateForm: any = ref({
 });
 // 返回类型选项数据
 const fieldReturnKindOptionList = [
-  { id: 1, label: '字段值' },
-  { id: 2, label: '数量' },
-  { id: 3, label: '求和' },
-  { id: 4, label: '平均值' },
+  { id: '1', label: '字段值' },
+  { id: '2', label: '数量' },
+  { id: '3', label: '求和' },
+  { id: '4', label: '平均值' },
 ]
 
 // 表单实例
@@ -71,10 +71,10 @@ const submit = async (formEl) => {
           type: "success"
         });
         UpdateForm.value = {
-      id: null, //ID
-      fieldName: "", //字段名称
-      fieldEnName: "", //字段名
-      fieldReturnKind: "", //返回类型
+          id: null, //ID
+          fieldName: "", //字段名称
+          fieldEnName: "", //字段名
+          fieldReturnKind: "", //返回类型
 
         };
         // 关闭修改弹窗;
@@ -107,7 +107,7 @@ const rules = reactive({
 const closeFn: any = inject('closeEditUpdatePriReturnFieldVisible');
 const openVisible = async () => {
   //通过ID获取表格数据
-  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriReturnFieldQuery.method, url: UrlList.prizeSet.prigetPriReturnFieldQuery.url, params: { id: props.formData.id }});
+  const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriReturnFieldQuery.method, url: UrlList.prizeSet.prigetPriReturnFieldQuery.url, params: { id: props.formData.id } });
   if (status === 1) {
     UpdateForm.value = data;
 

+ 22 - 19
src/views/pri/priReturnField/hook.tsx

@@ -1,6 +1,5 @@
 import { reactive, onMounted, ref, ElMessage, ElMessageBox, http, getGroupUrl, RegularVerification, verification, PaginationProps } from "@/utils/importUsed";
 import { useRoute } from "vue-router";
-import router from "@/router";
 // 表单实例
 const ruleFormRef = ref()
 export function usePriReturnField() {
@@ -13,12 +12,13 @@ export function usePriReturnField() {
 
     UrlList = await getGroupUrl(["prizeSet"]);
     onSearch(ruleFormRef.value);
+    queryTableIdQuery();
 
   });
   let form = reactive({
-  fieldName:"", //字段名称
-  fieldEnName:"", //字段名
-  queryTableId:null, //匹配表
+    fieldName: "", //字段名称
+    fieldEnName: "", //字段名
+    queryTableId: null, //匹配表
 
 
   });
@@ -64,14 +64,6 @@ export function usePriReturnField() {
       prop: "fieldReturnKind",
       minWidth: 200
     },
-    {
-      label: "匹配表",
-      prop: "queryTableId",
-      minWidth: 200
-      formatter: ({ queryTableId }) => {
-        return queryTableIdOptionList.find(item => item.id == queryTableId).label
-      },
-    },
 
     {
       label: "操作",
@@ -134,11 +126,20 @@ export function usePriReturnField() {
       }
     })
   }
+  // 匹配表选项数据
+  const queryTableIdOptionList = ref([]);
+  //获取匹配表数据
+  async function queryTableIdQuery() {
+    const { status, data }: any = await http.Request({ method: UrlList.prizeSet.prigetPriQueryTableDic.method, url: UrlList.prizeSet.prigetPriQueryTableDic.url, params: {} });
+    if (status === 1) {
+      queryTableIdOptionList.value = data.records;
+    }
+  }
+
 
 
 
-  
-    // 删除
+  // 删除
   function handleDelete(row) {
     ElMessageBox.confirm(
       `是否删除该条件返回字段? `,
@@ -158,20 +159,20 @@ export function usePriReturnField() {
         onSearch(ruleFormRef.value);
       } else {
         ElMessageBox.alert(msg, "提示", {
-        confirmButtonText: "关闭",
-        type: "warning"
-      });
+          confirmButtonText: "关闭",
+          type: "warning"
+        });
       };
     })
   }
 
-    // 新增
+  // 新增
   const addVisible = ref(false);
   function handleAdd() {
     addVisible.value = true;
   };
 
-    // 修改
+  // 修改
   const editUpdatePriReturnFieldVisible = ref(false);
   const editUpdatePriReturnFieldFormData = ref({});
   function handleUpdatePriReturnField(row) {
@@ -191,6 +192,8 @@ export function usePriReturnField() {
     handleCurrentChange,
     handleSelectionChange,
     ruleFormRef,
+    queryTableIdQuery,
+    queryTableIdOptionList,
 
     handleAdd,
     addVisible,

+ 8 - 3
src/views/pri/priReturnField/index.vue

@@ -28,6 +28,7 @@ const {
   handleCurrentChange,
   handleSelectionChange,
   ruleFormRef,
+  queryTableIdOptionList,
   handleAdd,
   addVisible,
   handleUpdatePriReturnField,
@@ -70,9 +71,13 @@ provide('closeEditUpdatePriReturnFieldVisible', closeEditUpdatePriReturnFieldVis
       el-form-item(label='字段名' prop="fieldEnName")
         el-input(v-model='form.fieldEnName' autocomplete='off'
           placeholder="请输入字段名")
-      el-form-item(label='匹配表' prop="queryTableId")
-        el-input-number(v-model='form.queryTableId' :min="1" :max="1000"
-          placeholder="请输入匹配表")
+      el-form-item(label="匹配表", prop="queryTableId")
+        el-select(
+          v-model="form.queryTableId",
+          placeholder="请选择匹配表",
+          clearable,
+        )
+          el-option(:label="item.tableEnName", :value="item.id" v-for="(item,index) in queryTableIdOptionList")
 
       el-form-item
         el-button(