sr 4 лет назад
Родитель
Сommit
693543248e

+ 7 - 1
ruoyi-ui/src/components/DynamicForms/index.vue

@@ -16,7 +16,7 @@
     <!-- 下拉框搜索 -->
     <el-select :disabled="formConfig.disabshow" v-model="config[formConfig.columnName]" v-if="formConfig.htmlType == 'select'&&(formConfig.fkInfo)"
       filterable remote :remote-method="remoteMethod" :loading="loading" :placeholder="'请输入'+formConfig.columnComment">
-      <el-option v-for="itemChild in filterList" :key="itemChild.id" :label="itemChild.table_name" :value="itemChild.id">
+      <el-option v-for="itemChild in filterList" :key="itemChild[formConfig.fkInfo.fkColumnName]" :label="itemChild[formConfig.fkInfo.dkColumnName]" :value="itemChild[formConfig.fkInfo.fkColumnName]">
       </el-option>
     </el-select>
     <!-- 复选框 -->
@@ -153,11 +153,17 @@
         if (this.formConfig.htmlType == 'checkbox' || this.formConfig.htmlType == 'imageUpload' || this.formConfig.htmlType ==
           'fileUpload') {
           this.config = []
+        }else if (this.formConfig.htmlType == 'select') {
+          this.$set(this.config, this.formConfig.columnName, (this.formConfig.columnValue - 0))
         } else {
           this.$set(this.config, this.formConfig.columnName, (this.formConfig.columnValue || ''))
         }
+
         if(this.formConfig.fkInfo){
           this.aliemg.table = this.formConfig.fkInfo.fkTableName
+          if(this.formConfig.fkInfo.value){
+            this.aliemg.fixedData.condition[this.formConfig.fkInfo.dkColumnName] = this.formConfig.fkInfo.value
+          }
           this.listIndexfouFn()
         }
       },

+ 1 - 0
ruoyi-ui/src/views/activiti/TemplateManagementNew/index.vue

@@ -483,6 +483,7 @@ export default {
     if(this.$route.params.flag === '1'){
       this.readOnly = true
       this.noFreshFlag = true
+      this.currentSteps = 1
       this.getModuleInfo(this.$route.params.id)
       return
     }