瀏覽代碼

Merge remote-tracking branch 'origin/master'

shiqian 4 年之前
父節點
當前提交
e7dfc6aca9

+ 3 - 9
boman-web-core/src/main/java/com/boman/web/core/utils/HandlerFormDataUtils.java

@@ -18,10 +18,7 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 import java.nio.charset.StandardCharsets;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
+import java.util.*;
 
 import static com.boman.common.core.utils.obj.ObjectUtils.*;
 import static com.boman.domain.constant.FormDataConstant.*;
@@ -49,11 +46,8 @@ public class HandlerFormDataUtils {
         for (JSONObject jsonObject : result) {
             //获取到所有rows查询字段的值
             Set<String> strings = jsonObject.keySet();
-
-            if ( strings.size() == 0){
-                break;
-            }
-            for (String string : strings) {
+            List<String> arrays = new ArrayList<>(strings);
+            for (String string : arrays) {
                 for (GenTableColumn column : allColumns) {
                     String dictType = column.getDictType();
                     String columnName = column.getColumnName();

+ 21 - 1
ruoyi-ui/src/api/modeler.js

@@ -1,5 +1,25 @@
 import request from '@/utils/request'
 
+export const getTabList = (data) => {
+  return request({
+    headers: {
+      'accountName': 'guest'
+    },
+    url: '/jflow/p/c/meta/table/list',
+    method: 'post',
+    data
+  })
+}
+export const getColumnList = (data) => {
+  return request({
+    headers: {
+      'accountName': 'guest'
+    },
+    url: '/jflow/p/c/meta/column/list',
+    method: 'post',
+    data
+  })
+}
 // 流程模型列表
 export const getSearch = (data) => {
   return request({
@@ -93,4 +113,4 @@ export const getPublish = (data) => {
     method: 'post',
     data
   })
-}
+}

+ 3 - 3
ruoyi-ui/src/api/system/menu.js

@@ -35,14 +35,14 @@ export function roleMenuTreeselect(roleId) {
 // 根据角色ID查询菜单下拉树结构
 export function treeMenuNotAddLeafNode(roleId) {
   return request({
-    url: '/system/menu/treeMenuNotAddLeafNode/' + roleId,
+    url: '/system/menu/listTreeByRoleId/' + roleId,
     method: 'get'
   })
 }
 // 获取权限
-export function listMenus(id) {
+export function listMenus(id,menuId) {
   return request({
-    url: '/system/menu/listMenus/' + id,
+    url: '/system/menu/listMenus/roleId/' + menuId+'/menuId/'+id,
     method: 'get'
   })
 }

二進制
ruoyi-ui/src/assets/images/nodata.png


+ 1 - 1
ruoyi-ui/src/components/FlowChartComponent/index.vue

@@ -519,7 +519,7 @@ export default {
   }
 }
 </script>
-<style lang=scss" >
+<style lang="scss" >
 .FlowChartComponent{
   width: 100%;
   height: 100%;

+ 1 - 1
ruoyi-ui/src/components/FlowSuccess/index.vue

@@ -11,7 +11,7 @@ export default {
 
 }
 </script>
-<style lang=scss" scoped>
+<style lang="scss" scoped>
   .FlowSuccess{
     display: flex;
     flex-direction: column;

+ 5 - 4
ruoyi-ui/src/components/FormItemComponent/index.vue

@@ -28,7 +28,7 @@
 </template>
 <script>
 import Vue from "vue";
-import layoutAlgorithm from "../../utils/layoutAlgorithm.js";
+import layoutAlgorithm from "@/utils/layoutAlgorithm.js";
 export default {
   name: "FormItemComponent",
   props: {
@@ -57,12 +57,14 @@ export default {
     // 通过layoutAlgorithm算法得到对应的位置坐标
     dataColRol() {
       const list = layoutAlgorithm(this.defaultColumn, this.currentFormList);
-      return Object.keys(list).reduce((temp, current) => {
+      let obj = Object.keys(list).reduce((temp, current) => {
         // 计算显示行数
         list[current].component = Vue.extend(list[current].component);
         temp.push(list[current]);
         return temp;
       }, []);
+      console.log(obj,98882123)
+      return obj
     },
     // 计算属性的 div 的坐标起始点
     setDiv() {
@@ -92,7 +94,7 @@ export default {
   },
   created() {
     this.currentFormList = this.formItemLists.concat([]);
-    console.log(this.formItemLists,999999999)
+    console.log(this.currentFormList,999999999)
   },
   methods: {
     inputChange(value, items, type) {
@@ -146,4 +148,3 @@ export default {
   grid-auto-rows: minmax(auto);
 }
 </style>
-

+ 9 - 1
ruoyi-ui/src/components/MutipleSelectPop/index.vue

@@ -26,6 +26,11 @@
           @on-select-change="getSelectedNodes"
           @on-check-change="getCheckedNodes"
         ></Tree>
+        <!-- <el-tree
+          :props="treeLists"
+          show-checkbox
+          @check-change="handleCheckChange">
+        </el-tree> -->
       </div>
     </div>
     <div class="dialog_center">
@@ -94,7 +99,7 @@
       <div class="left_top right_top">
         <div>已选中({{resultMessage.total || 0 }})</div>
         <div>
-          <i class="iconfont iconios-trash-outline" @click="delecFun"></i>
+          <i class="el-icon-delete" @click="delecFun"></i>
         </div>
       </div>
       <div class="right_center">
@@ -852,6 +857,9 @@ export default {
       });
       return result;
     },
+    handleCheckChange(){
+     
+    }
   },
   mounted() {
     // if(this.isCallInterface){

+ 373 - 369
ruoyi-ui/src/components/ParameterConfiguration/index.vue

@@ -1,44 +1,42 @@
 //参数配置界面
 <template>
   <div class="ParameterConfiguration">
-    <FormItemComponent
-      class="form"
-      :formItemLists="formLists"
-      :buttonType="false"
-      :defaultColumn="1"
-      @formChange="formChange"
-    ></FormItemComponent>
+    <FormItemComponent class="form" :formItemLists="formLists" :buttonType="false" :defaultColumn="1" @formChange="formChange"></FormItemComponent>
   </div>
 </template>
 <script>
-import FormItemComponent from '@/components/FormItemComponent';
-import ItemComponent from '@/components/ItemComponent';
-export default {
-  components:{FormItemComponent},
-  props:{
-    data:{
-      type:Object
-    }
-  },
-  watch:{
-    data:{
-      handler () {
-        this.formLists = [
-            {
-              row:1,
-              col:1,
-              component:ItemComponent,
-              item:{
-                type:'select',
-                title:'模版类型',
-                filed:'moduleType',
-                value:this.data.moduleType,
-                props:{
-                  disabled:this.disabled,
+  import FormItemComponent from '@/components/FormItemComponent';
+  import ItemComponent from '@/components/ItemComponent';
+  import {
+    getColumnList,
+    getTabList
+  } from '@/api/modeler.js'
+  export default {
+    components: {
+      FormItemComponent
+    },
+    props: {
+      data: {
+        type: Object
+      }
+    },
+    watch: {
+      data: {
+        handler() {
+          this.formLists = [{
+              row: 1,
+              col: 1,
+              component: ItemComponent,
+              item: {
+                type: 'select',
+                title: '模版类型',
+                filed: 'moduleType',
+                value: this.data.moduleType,
+                props: {
+                  disabled: this.disabled,
                   clearable: false,
                 },
-                options:[
-                  {
+                options: [{
                     value: 0,
                     label: '固定模版'
                   },
@@ -50,28 +48,28 @@ export default {
               }
             },
             {
-              row:1,
-              col:1,
-              component:ItemComponent,
-              item:{
-                type:'DropDownSelectFilter',
-                title:'单据类型',
-                filed:'businessType',
-                required:true,
+              row: 1,
+              col: 1,
+              component: ItemComponent,
+              item: {
+                type: 'DropDownSelectFilter',
+                title: '单据类型',
+                filed: 'businessType',
+                required: true,
                 hidden: this.data.moduleType === 1,
-                props:{
-                  columnsKey:['NAME'],
-                  AutoData:[],
-                  hidecolumns:['id'],
-                  data:{},
-                  totalRowCount:0,
-                  defaultSelected:this.data.businessType,
-                  disabled:this.disabled
+                props: {
+                  columnsKey: ['NAME'],
+                  AutoData: [],
+                  hidecolumns: ['id'],
+                  data: {},
+                  totalRowCount: 0,
+                  defaultSelected: this.data.businessType,
+                  disabled: this.disabled
                 },
-                event:{
+                event: {
                   inputValueChange: (value) => {
-                      // 外键的模糊搜索
-                      this.fkFuzzyquerybyak(value)
+                    // 外键的模糊搜索
+                    this.fkFuzzyquerybyak(value)
                   },
                   'on-show': ($this) => {
                     // 当外键下拉站开始去请求数据
@@ -79,10 +77,11 @@ export default {
                   },
                   pageChange: (currentPage, $this) => {
                     // 外键的分页查询
-                    this.freshDropDownSelectFilterData($this,currentPage)
+                    this.freshDropDownSelectFilterData($this, currentPage)
                   },
-                  blur:(event,instance) => {
-                    if(Object.prototype.toString.call(this.data.businessType) !== '[object Array]' || this.data.businessType.length === 0){
+                  blur: (event, instance) => {
+                    if (Object.prototype.toString.call(this.data.businessType) !== '[object Array]' || this.data.businessType
+                      .length === 0) {
                       this.data.businessType = []
                       instance.inputValue = ''
                     }
@@ -92,58 +91,58 @@ export default {
               }
             },
             {
-              row:1,
-              col:1,
-              component:ItemComponent,
-              item:{
-                type:'input',
-                title:'模版名称',
-                filed:'name',
-                required:true,
-                value:this.data.name,
-                props:{
+              row: 1,
+              col: 1,
+              component: ItemComponent,
+              item: {
+                type: 'input',
+                title: '模版名称',
+                filed: 'name',
+                required: true,
+                value: this.data.name,
+                props: {
                   // disabled:this.data.status === 1
                 }
               }
             },
             {
-              row:1,
-              col:1,
-              component:ItemComponent,
-              item:{
-                type:'DropDownSelectFilter',
-                title:'查询索引',
-                filed:'businessNumber',
+              row: 1,
+              col: 1,
+              component: ItemComponent,
+              item: {
+                type: 'DropDownSelectFilter',
+                title: '查询索引',
+                filed: 'businessNumber',
                 hidden: this.data.moduleType === 1,
-                props:{
-                  columnsKey:['NAME'],
-                  AutoData:[],
-                  hidecolumns:['id'],
-                  data:{},
-                  totalRowCount:0,
-                  defaultSelected:this.data.businessNumber,
+                props: {
+                  columnsKey: ['NAME'],
+                  AutoData: [],
+                  hidecolumns: ['id'],
+                  data: {},
+                  totalRowCount: 0,
+                  defaultSelected: this.data.businessNumber,
                   // disabled:this.data.status === 1
                 },
-                event:{
-                  inputValueChange: (value,instance) => {
-                      if(!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID){
-                        this.$Modal.fcWarning({
-                          title:'警告',
-                          content:'请先选择单据类型!'
-                        })
-                        this.data.businessNumber = []
-                        instance.inputValue = ''
-                        return
-                      }
-                      // 外键的模糊搜索
-                      this.fkFuzzyquerybyakcolumn(value)
+                event: {
+                  inputValueChange: (value, instance) => {
+                    if (!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID) {
+                      this.$Modal.fcWarning({
+                        title: '警告',
+                        content: '请先选择单据类型!'
+                      })
+                      this.data.businessNumber = []
+                      instance.inputValue = ''
+                      return
+                    }
+                    // 外键的模糊搜索
+                    this.fkFuzzyquerybyakcolumn(value)
                   },
                   'on-show': ($this) => {
                     // 当外键下拉站开始去请求数据
-                    if(!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID){
+                    if (!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID) {
                       this.$Modal.fcWarning({
-                        title:'警告',
-                        content:'请先选择单据类型!'
+                        title: '警告',
+                        content: '请先选择单据类型!'
                       })
                       this.data.businessNumber = []
                       $this.inputValue = ''
@@ -153,10 +152,11 @@ export default {
                   },
                   pageChange: (currentPage, $this) => {
                     // 外键的分页查询
-                    this.freshDropDownSelectFilterDataColumn($this,currentPage)
+                    this.freshDropDownSelectFilterDataColumn($this, currentPage)
                   },
-                  blur:(event,instance) => {
-                    if(Object.prototype.toString.call(this.data.businessNumber) !== '[object Array]' || this.data.businessNumber.length === 0){
+                  blur: (event, instance) => {
+                    if (Object.prototype.toString.call(this.data.businessNumber) !== '[object Array]' || this.data.businessNumber
+                      .length === 0) {
                       this.data.businessNumber = []
                       instance.inputValue = ''
                     }
@@ -166,149 +166,148 @@ export default {
               }
             },
             {
-              row:1,
-              col:1,
-              component:ItemComponent,
-              item:{
-                type:'input',
-                title:'模版描述',
-                filed:'description',
-                value:this.data.description,
-                props:{
-                  type:'textarea',
+              row: 1,
+              col: 1,
+              component: ItemComponent,
+              item: {
+                type: 'input',
+                title: '模版描述',
+                filed: 'description',
+                value: this.data.description,
+                props: {
+                  type: 'textarea',
                   // disabled:this.data.status === 1
                 }
               }
             },
             {
-              row:1,
-              col:1,
-              component:ItemComponent,
-              item:{
-                type:'Switch',
-                title:'开启自动处理',
-                filed:'autoClose',
-                value:this.data.autoClose,
+              row: 1,
+              col: 1,
+              component: ItemComponent,
+              item: {
+                type: 'Switch',
+                title: '开启自动处理',
+                filed: 'autoClose',
+                value: this.data.autoClose,
               }
             },
             {
-              row:1,
-              col:1,
-              component:ItemComponent,
-              item:{
-                type:'input',
-                title:'业务数据检查',
-                filed:'businessCheckUrl',
-                value:this.data.businessCheckUrl
+              row: 1,
+              col: 1,
+              component: ItemComponent,
+              item: {
+                type: 'input',
+                title: '业务数据检查',
+                filed: 'businessCheckUrl',
+                value: this.data.businessCheckUrl
               }
             }
           ]
-      },
-      deep:true
-    }
-  },
-  data () {
-    return {
-      formLists:[
-        {
-          row:1,
-          col:1,
-          component:ItemComponent,
-          item:{
-            type:'select',
-            title:'模版类型',
-            filed:'moduleType',
-            value: 0,
-            props:{
-              disabled:false,
-              clearable: false
-            },
-            options:[
-              {
-                value: 0,
-                label: '固定模版'
-              },
-              {
-                value: 1,
-                label: '动态模版'
-              }
-            ]
-          }
         },
-        {
-          row:1,
-          col:1,
-          component:ItemComponent,
-          item:{
-            type:'DropDownSelectFilter',
-            title:'单据类型',
-            filed:'businessType',
-            required:true,
-            hidden: this.data.moduleType === 1,
-            props:{
-              columnsKey:['NAME'],
-              AutoData:[],
-              hidecolumns:['id'],
-              data:{},
-              totalRowCount:0
-            },
-            event:{
-              inputValueChange: (value) => {
-                  // 外键的模糊搜索
-                  this.fkFuzzyquerybyak(value)
-              },
-              'on-show': ($this) => {
-                // 当外键下拉站开始去请求数据
-                this.freshDropDownSelectFilterData($this)
-              },
-              pageChange: (currentPage, $this) => {
-                // 外键的分页查询
-                this.freshDropDownSelectFilterData($this,currentPage)
+        deep: true
+      }
+    },
+    data() {
+      return {
+        formLists: [{
+            row: 1,
+            col: 1,
+            component: ItemComponent,
+            item: {
+              type: 'select',
+              title: '模版类型',
+              filed: 'moduleType',
+              value: 0,
+              props: {
+                disabled: false,
+                clearable: false
               },
-              blur:(event,instance) => {
-                if(Object.prototype.toString.call(this.data.businessType) !== '[object Array]' || this.data.businessType.length === 0){
-                  this.data.businessType = []
-                  instance.inputValue = ''
+              options: [{
+                  value: 0,
+                  label: '固定模版'
+                },
+                {
+                  value: 1,
+                  label: '动态模版'
                 }
+              ]
+            }
+          },
+          {
+            row: 1,
+            col: 1,
+            component: ItemComponent,
+            item: {
+              type: 'DropDownSelectFilter',
+              title: '单据类型',
+              filed: 'businessType',
+              required: true,
+              hidden: this.data.moduleType === 1,
+              props: {
+                columnsKey: ['NAME'],
+                AutoData: [],
+                hidecolumns: ['id'],
+                data: {},
+                totalRowCount: 0
+              },
+              event: {
+                inputValueChange: (value) => {
+                  // 外键的模糊搜索
+                  this.fkFuzzyquerybyak(value)
+                },
+                'on-show': ($this) => {
+                  // 当外键下拉站开始去请求数据
+                  this.freshDropDownSelectFilterData($this)
+                },
+                pageChange: (currentPage, $this) => {
+                  // 外键的分页查询
+                  this.freshDropDownSelectFilterData($this, currentPage)
+                },
+                blur: (event, instance) => {
+                  if (Object.prototype.toString.call(this.data.businessType) !== '[object Array]' || this.data.businessType
+                    .length === 0) {
+                    this.data.businessType = []
+                    instance.inputValue = ''
+                  }
 
+                }
               }
             }
-          }
-        },
-        {
-          row:1,
-          col:1,
-          component:ItemComponent,
-          item:{
-            type:'input',
-            title:'模版名称',
-            filed:'name',
-            required:true,
-            value:this.data.name
-          }
-        },
-        {
-          row:1,
-          col:1,
-          component:ItemComponent,
-          item:{
-            type:'DropDownSelectFilter',
-            title:'查询索引',
-            filed:'businessNumber',
-            hidden: this.data.moduleType === 1,
-            props:{
-              columnsKey:['NAME'],
-              AutoData:[],
-              hidecolumns:['id'],
-              data:{},
-              totalRowCount:0
-            },
-            event:{
-              inputValueChange: (value,instance) => {
-                  if(!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID){
+          },
+          {
+            row: 1,
+            col: 1,
+            component: ItemComponent,
+            item: {
+              type: 'input',
+              title: '模版名称',
+              filed: 'name',
+              required: true,
+              value: this.data.name
+            }
+          },
+          {
+            row: 1,
+            col: 1,
+            component: ItemComponent,
+            item: {
+              type: 'DropDownSelectFilter',
+              title: '查询索引',
+              filed: 'businessNumber',
+              hidden: this.data.moduleType === 1,
+              props: {
+                columnsKey: ['NAME'],
+                AutoData: [],
+                hidecolumns: ['id'],
+                data: {},
+                totalRowCount: 0
+              },
+              event: {
+                inputValueChange: (value, instance) => {
+                  if (!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID) {
                     this.$Modal.fcWarning({
-                      title:'警告',
-                      content:'请先选择单据类型!'
+                      title: '警告',
+                      content: '请先选择单据类型!'
                     })
                     this.data.businessNumber = []
                     instance.inputValue = ''
@@ -316,128 +315,131 @@ export default {
                   }
                   // 外键的模糊搜索
                   this.fkFuzzyquerybyakcolumn(value)
-              },
-              'on-show': ($this) => {
-                // 当外键下拉站开始去请求数据
-                if(!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID){
-                  this.$Modal.fcWarning({
-                    title:'警告',
-                    content:'请先选择单据类型!'
-                  })
-                  this.data.businessNumber = []
-                  $this.inputValue = ''
-                  return
-                }
-                this.freshDropDownSelectFilterDataColumn($this)
-              },
-              pageChange: (currentPage, $this) => {
-                // 外键的分页查询
-                this.freshDropDownSelectFilterDataColumn($this,currentPage)
-              },
-              blur:(event,instance) => {
+                },
+                'on-show': ($this) => {
+                  // 当外键下拉站开始去请求数据
+                  if (!this.data.businessType || this.data.businessType.lengt == 0 || !this.data.businessType[0].ID) {
+                    this.$Modal.fcWarning({
+                      title: '警告',
+                      content: '请先选择单据类型!'
+                    })
+                    this.data.businessNumber = []
+                    $this.inputValue = ''
+                    return
+                  }
+                  this.freshDropDownSelectFilterDataColumn($this)
+                },
+                pageChange: (currentPage, $this) => {
+                  // 外键的分页查询
+                  this.freshDropDownSelectFilterDataColumn($this, currentPage)
+                },
+                blur: (event, instance) => {
 
-                if(Object.prototype.toString.call(this.data.businessNumber) !== '[object Array]' || this.data.businessNumber.length === 0){
-                  this.data.businessNumber = []
-                  instance.inputValue = ''
-                }
+                  if (Object.prototype.toString.call(this.data.businessNumber) !== '[object Array]' || this.data.businessNumber
+                    .length === 0) {
+                    this.data.businessNumber = []
+                    instance.inputValue = ''
+                  }
 
+                }
               }
             }
-          }
-        },
-        {
-          row:1,
-          col:1,
-          component:ItemComponent,
-          item:{
-            type:'input',
-            title:'模版描述',
-            filed:'description',
-            value:this.data.description,
-            props:{
-              type:'textarea',
+          },
+          {
+            row: 1,
+            col: 1,
+            component: ItemComponent,
+            item: {
+              type: 'input',
+              title: '模版描述',
+              filed: 'description',
+              value: this.data.description,
+              props: {
+                type: 'textarea',
+              }
+            }
+          },
+          {
+            row: 1,
+            col: 1,
+            component: ItemComponent,
+            item: {
+              type: 'Switch',
+              title: '开启自动处理',
+              filed: 'autoClose',
+              value: true,
+            }
+          },
+          {
+            row: 1,
+            col: 1,
+            component: ItemComponent,
+            item: {
+              type: 'input',
+              title: '业务数据检查',
+              filed: 'businessCheckUrl',
+              value: this.data.businessCheckUrl
             }
           }
-        },
-        {
-          row:1,
-          col:1,
-          component:ItemComponent,
-          item:{
-            type:'Switch',
-            title:'开启自动处理',
-            filed:'autoClose',
-            value:true,
-          }
-        },
-        {
-          row:1,
-          col:1,
-          component:ItemComponent,
-          item:{
-            type:'input',
-            title:'业务数据检查',
-            filed:'businessCheckUrl',
-            value:this.data.businessCheckUrl
-          }
-        }
-      ],
-      formData:{},
-      row:[],
-      disabled: false
-    }
-  },
-  methods:{
-    formChange (data) {  //数据修改
-      if(data.businessType && data.businessType.length > 0){
-        this.row.map(item => {
-          if(item.ID.val === data.businessType[0].ID){
-            data.businessType[0].val = item.DESCRIPTION.val
-            data.businessType[0].Label = item.NAME.val
-          }
-          return item
-        })
-      }
-
-      if(data.businessNumber && data.businessNumber.length > 0){
-        this.row.map(item => {
-          if(item.ID.val === data.businessNumber[0].ID){
-            data.businessNumber[0].val = item.DESCRIPTION.val
-            data.businessNumber[0].Label = item.NAME.val
-          }
-          return item
-        })
+        ],
+        formData: {},
+        row: [],
+        disabled: false
       }
-
-      this.formData = Object.assign(this.formData,data)
-      this.$emit('dataChange',this.formData)
     },
-    fkFuzzyquerybyak (value) {  //单据类型模糊搜素
-      this.formLists[1].item.props.AutoData = []
-      this.$network.post('/p/c/meta/table/list',{DESCRIPTION:value}).then(res => {
-        if(res.data.code === 0){
-          this.row = res.data.data.row.concat([])
-          this.formLists[1].item.props.AutoData = res.data.data.row.reduce((arr,item) => {
-            arr.push({
-              value:item.NAME.val,
-              id:item.ID.val,
-              NAME:item.DESCRIPTION.val
-            })
-            return arr
-          },[]);
+    methods: {
+      formChange(data) { //数据修改
+        if (data.businessType && data.businessType.length > 0) {
+          this.row.map(item => {
+            if (item.ID.val === data.businessType[0].ID) {
+              data.businessType[0].val = item.DESCRIPTION.val
+              data.businessType[0].Label = item.NAME.val
+            }
+            return item
+          })
         }
 
-      })
-    },
-    freshDropDownSelectFilterData (instance,currentPage) {  //外键列表查询
-        this.$network.post('/p/c/meta/table/list',{
-          pageSize:instance.pageSize,
-          page:currentPage?currentPage:1
+        if (data.businessNumber && data.businessNumber.length > 0) {
+          this.row.map(item => {
+            if (item.ID.val === data.businessNumber[0].ID) {
+              data.businessNumber[0].val = item.DESCRIPTION.val
+              data.businessNumber[0].Label = item.NAME.val
+            }
+            return item
+          })
+        }
+
+        this.formData = Object.assign(this.formData, data)
+        this.$emit('dataChange', this.formData)
+      },
+      fkFuzzyquerybyak(value) { //单据类型模糊搜素
+        this.formLists[1].item.props.AutoData = []
+        getTabList({
+          DESCRIPTION: value
         }).then(res => {
-          if(res.data.code === 0){
+          if (res.data.code === 0) {
+            this.row = res.data.data.row.concat([])
+            this.formLists[1].item.props.AutoData = res.data.data.row.reduce((arr, item) => {
+              arr.push({
+                value: item.NAME.val,
+                id: item.ID.val,
+                NAME: item.DESCRIPTION.val
+              })
+              return arr
+            }, []);
+          }
+
+        })
+      },
+      freshDropDownSelectFilterData(instance, currentPage) { //外键列表查询
+        getTabList({
+          pageSize: instance.pageSize,
+          page: currentPage ? currentPage : 1
+        }).then(res => {
+          if (res.data.code === 0) {
             this.row = res.data.data.row.concat([])
             res.data.data.tabth.forEach(item => {
-              if(item.colname === 'DESCRIPTION'){
+              if (item.colname === 'DESCRIPTION') {
                 item.isak = true
               }
               return item
@@ -451,35 +453,37 @@ export default {
           }
 
         })
-    },
-    fkFuzzyquerybyakcolumn (value) {  //单据类型模糊搜素
-      this.formLists[3].item.props.AutoData = []
-      this.$network.post('/p/c/meta/column/list',{ DESCRIPTION: value, AD_TABLE_ID: this.data.businessType[0].ID}).then(res => {
-        if(res.data.code === 0){
-          this.row = res.data.data.row.concat([])
-          this.formLists[3].item.props.AutoData = res.data.data.row.reduce((arr,item) => {
-            arr.push({
-              value:item.NAME.val,
-              id:item.ID.val,
-              NAME:item.DESCRIPTION.val
-            })
-            return arr
-          },[]);
-        }
-
-      })
-    },
-    freshDropDownSelectFilterDataColumn (instance,currentPage) {  //外键列表查询
+      },
+      fkFuzzyquerybyakcolumn(value) { //单据类型模糊搜素
+        this.formLists[3].item.props.AutoData = []
+        getColumnList({
+          DESCRIPTION: value,
+          AD_TABLE_ID: this.data.businessType[0].ID
+        }).then(res => {
+          if (res.data.code === 0) {
+            this.row = res.data.data.row.concat([])
+            this.formLists[3].item.props.AutoData = res.data.data.row.reduce((arr, item) => {
+              arr.push({
+                value: item.NAME.val,
+                id: item.ID.val,
+                NAME: item.DESCRIPTION.val
+              })
+              return arr
+            }, []);
+          }
 
-        this.$network.post('/p/c/meta/column/list',{
-          pageSize:instance.pageSize,
-          page:currentPage?currentPage:1,
+        })
+      },
+      freshDropDownSelectFilterDataColumn(instance, currentPage) { //外键列表查询
+        getColumnList({
+          pageSize: instance.pageSize,
+          page: currentPage ? currentPage : 1,
           AD_TABLE_ID: this.data.businessType[0].ID
         }).then(res => {
-          if(res.data.code === 0){
+          if (res.data.code === 0) {
             this.row = res.data.data.row.concat([])
             res.data.data.tabth.forEach(item => {
-              if(item.colname === 'DESCRIPTION'){
+              if (item.colname === 'DESCRIPTION') {
                 item.isak = true
               }
               return item
@@ -493,22 +497,22 @@ export default {
           }
 
         })
+      }
+    },
+    created() {
+      this.$route.params.id !== '-1' ? this.disabled = true : this.disabled = false
     }
-  },
-  created () {
-    this.$route.params.id !== '-1'?this.disabled = true:this.disabled = false
   }
-}
 </script>
-<style lang=scss" scoped>
-.ParameterConfiguration{
-  padding-top:50px;
-  display: flex;
-  justify-content:center;
+<style lang="scss" scoped>
+  .ParameterConfiguration {
+    padding-top: 50px;
+    display: flex;
+    justify-content: center;
 
-  .form{
-    border: none;
-    width: 420px;
+    .form {
+      border: none;
+      width: 420px;
+    }
   }
-}
 </style>

+ 9 - 1
ruoyi-ui/src/components/mutipleSelectPop/index.vue

@@ -26,6 +26,11 @@
           @on-select-change="getSelectedNodes"
           @on-check-change="getCheckedNodes"
         ></Tree>
+        <!-- <el-tree
+          :props="treeLists"
+          show-checkbox
+          @check-change="handleCheckChange">
+        </el-tree> -->
       </div>
     </div>
     <div class="dialog_center">
@@ -94,7 +99,7 @@
       <div class="left_top right_top">
         <div>已选中({{resultMessage.total || 0 }})</div>
         <div>
-          <i class="iconfont iconios-trash-outline" @click="delecFun"></i>
+          <i class="el-icon-delete" @click="delecFun"></i>
         </div>
       </div>
       <div class="right_center">
@@ -852,6 +857,9 @@ export default {
       });
       return result;
     },
+    handleCheckChange(){
+     
+    }
   },
   mounted() {
     // if(this.isCallInterface){

+ 435 - 0
ruoyi-ui/src/views/activiti/TemplateManagementLists/index.vue

@@ -0,0 +1,435 @@
+<template>
+  <div class="TemplateManagementLists">
+    <div class="listContent">
+      <p class="title">模版管理</p>
+      <p class="buttonLists">
+        <Button type="primary" @click="searchData.page = 1;queryLists()">查询</Button>
+        <Button type="fcdefault" :disabled="listsStatus === 1" @click="addTemplate">新建模板</Button>
+        <Button type="fcdefault" v-if="listsStatus === 0" @click="templateMigration">模版迁移</Button>
+        <Button type="fcdefault" v-if="listsStatus === 1" @click="removeMigration">取消迁移</Button>
+        <Button type="fcdefault" v-if="listsStatus === 1" @click="perform">执行</Button>
+        <Button type="fcdefault" v-if="listsStatus === 1" @click="performAll">执行全部</Button>
+      </p>
+      <Alert show-icon closable v-if="listsStatus === 1">依次单击模板可进行多选模板</Alert>
+      <FormItemComponent
+        class="form"
+        :formItemLists="formLists"
+        :buttonType="false"
+        @formChange="formChange"
+      ></FormItemComponent>
+
+      <StandardTable
+        class="table"
+        :currentPage="searchData.page"
+        :pageSize="searchData.pageSize"
+        :pageSizeOpts="[20,40,60,80]"
+        :total="total"
+        :showTable="false"
+        :standardTableEvent="standardTableEvent"
+      >
+      </StandardTable>
+
+      <div class="list">
+        <FormItemComponent
+          class="listsForm"
+          :formItemLists="listsConfig"
+          :buttonType="false"
+          :readonly="listsStatus === 1"
+        ></FormItemComponent>
+
+        <div  class="noData" v-if="listsConfig.length == 0" >
+          <span>
+            暂无模版
+          </span>
+        </div>
+      </div>
+    </div>
+
+    <!-- 模版迁移弹窗 -->
+    <Modal
+      v-model="migrationModel"
+      title="模版迁移"
+      mask
+      :width="440"
+      :mask-closable="false"
+      >
+      <div class="migrationModelContent">
+        <p>
+          <Input v-model="serverUrl"  placeholder="请输入目标服务器地址" style="width: 320px" />
+        </p>
+      </div>
+
+      <p slot="footer">
+        <Button :loading="performloading" @click="migrationModel = false">取消</Button>
+        <Button :loading="performloading" type="primary" @click="performConfirm">确定</Button>
+      </p>
+    </Modal>
+  </div>
+</template>
+<script>
+import FormItemComponent from '@/components/FormItemComponent';
+import ItemComponent from '@/components/ItemComponent';
+import StandardTable from '@/components/StandardTable';
+import listModalComponent from '@/components/listModalComponent'
+// import router from '../config/router.config'
+import {  mapMutations,mapState } from 'vuex';
+export default {
+  name:'TemplateManagementLists',
+  components:{FormItemComponent,StandardTable},
+  data () {
+    return {
+      // 状态  0为搜索状态,1为模版迁移状态
+      listsStatus:0,
+      //表单配置
+      formLists:[
+        {
+          row:1,
+          col:1,
+          component:ItemComponent,
+          item:{
+            type:'input',
+            title:'模型名称',
+            filed:'name',
+            event:{
+              'keydown': (event) => {
+                if(event.keyCode === 13){
+                  this.searchData.page = 1
+                  this.queryLists()
+                }
+              }
+            }
+          }
+        },
+        {
+          row:1,
+          col:1,
+          component:ItemComponent,
+          item:{
+            type:'select',
+            title:'模版状态',
+            filed:'status',
+            options: [
+              { value: 1, label: '已发布'},
+              { value: 0, label: '未发布'},
+              { value: 2, label: '已停用'}
+            ],
+            props:{
+              multiple: true,
+              multipleType: true
+            },
+            value:[0,1]
+          }
+        },
+        {
+          row:1,
+          col:1,
+          component:ItemComponent,
+          item:{
+            type:'DatePicker',
+            title:'创建时间',
+            filed:'createTime',
+            value:[]
+          }
+        }
+      ],
+      //查询条件
+      searchData:{
+        page:1,
+        pageSize:20,
+        createTime:[],
+        status: [0,1]
+      },
+
+      //分页数据
+      total:0,
+      standardTableEvent:{
+        'on-change':(page) => {
+          this.searchData.page = page
+          this.queryLists()
+        },
+        'on-page-size-change':(pageSize) => {
+          this.searchData.page = 1
+          this.searchData.pageSize = pageSize
+          this.queryLists()
+        }
+      },
+      listsConfig:[  //列表数据
+      ],
+
+      // 迁移数据
+      selectModal:[],  //选中的迁移模版
+      migrationModel:false, //控制模版迁移弹窗
+      serverUrl:null,  //目标服务地址
+      migrationType:null,  //0为执行  1为执行全部
+      performloading:false
+
+    }
+  },
+  computed:{
+    ...mapState({
+      currentMenu:(state) =>{
+        return  state.currentMenu
+      }
+    })
+  },
+  watch:{
+    listsStatus () {
+      if(this.listsStatus === 0){
+        this.selectModal = []
+      }
+    }
+  },
+  methods:{
+    ...mapMutations(['currentChange','changeKeepAliveArray']),
+    formChange (data) {  //表单数据修改时,修改searchData数据
+      if(data.status){
+        this.formLists[0].item.value = data.name
+        this.formLists[1].item.value = data.status
+        this.formLists[2].item.value = data.createTime
+        // this.formLists = this.formLists.concat([])
+      }
+      this.searchData = Object.assign({},this.searchData,data)
+      if(Object.prototype.toString.call(this.searchData.status) === '[object Array]' && this.searchData.status.length === 0){
+        delete this.searchData.searchStatus
+        delete this.searchData.status
+      }
+
+      // this.queryLists()
+    },
+    queryLists () {  //查询列表
+      if(this.searchData.status && this.searchData.status.indexOf('bSelect-all') >= 0){
+        this.searchData.searchStatus = []
+      }else{
+        this.searchData.searchStatus = this.searchData.status
+      }
+
+      if(this.searchData.createTime && this.searchData.createTime[0] && this.searchData.createTime[1]){
+        this.searchData.startTime = new Date(this.searchData.createTime[0]).format('yyyy-MM-dd hh:mm')
+        this.searchData.endTime = new Date(this.searchData.createTime[1]).format('yyyy-MM-dd hh:mm')
+      }else{
+        this.searchData.startTime = ''
+        this.searchData.endTime = ''
+      }
+
+      let obj = Object.assign({},this.searchData)
+      delete obj.createTime
+      delete obj.status
+      this.$network.post('/p/cs/module/search', obj).then((res) => {
+        if(res.data.resultCode !== 0){
+          return
+        }
+        let data = res.data.data
+        this.total = data.total
+
+        this.listsConfig = data.records.reduce((arr,item) => {
+          let items = {
+            event:{
+              queryLists:() => {
+                this.queryLists()
+              }
+            }
+          }
+          items = Object.assign(items,item)
+          arr.push({
+            row:1,
+            col:1,
+            component:listModalComponent,
+            item:items
+          })
+          return arr
+        },[])
+      });
+    },
+    addTemplate () {  //新建模版
+      this.changeKeepAliveArray(['TemplateManagementLists'])
+      // router.push({ path: '/TemplateManagementNew/-1' })
+      this.currentChange({
+        path:'/TemplateManagementLists'
+      });
+    },
+    templateMigration () { //模版迁移
+      this.listsStatus = 1
+    },
+    removeMigration () {  //取消迁移
+      this.listsStatus = 0
+    },
+    modalClick (event) {  //模版点击
+      let value = event.detail.value
+      let items = event.detail.items
+      if(value){
+        this.selectModal.push(items.id)
+      }else{
+        this.selectModal.splice(this.selectModal.findIndex(item => item === items.id), 1)
+      }
+    },
+    perform () {  //执行迁移
+      if(this.selectModal.length === 0){
+        this.$Modal.fcWarning({
+          title:'警告',
+          content:'请选择需要迁移的模版!',
+          mask:true
+        })
+        return
+      }
+      this.migrationType = 0
+      this.serverUrl = null
+      this.migrationModel = true
+
+    },
+    performAll () {  //迁移全部
+      this.migrationType = 1
+      this.serverUrl = null
+      this.migrationModel = true
+    },
+    performConfirm () {  //模版迁移确认
+      let obj = {}
+      if(!(this.serverUrl.startsWith('http://') || this.serverUrl.startsWith('https://'))){
+        this.$Modal.fcWarning({
+          title:'警告',
+          content:'目标服务器地址必须以http://或者https://开头',
+          mask:true
+        })
+        return
+      }
+      this.performloading = true
+      if(this.migrationType === 0){  //执行选中模版
+        obj = {
+          moduleIds:this.selectModal.join(',')
+        }
+      }else{  //执行所有模版
+        if(this.searchData.createTime && this.searchData.createTime[0] && this.searchData.createTime[1]){
+          this.searchData.startTime = new Date(this.searchData.createTime[0]).format('yyyy-MM-dd hh:mm')
+          this.searchData.endTime = new Date(this.searchData.createTime[1]).format('yyyy-MM-dd hh:mm')
+        }else{
+          this.searchData.startTime = ''
+          this.searchData.endTime = ''
+        }
+
+        obj = Object.assign({},this.searchData)
+      }
+
+      obj.url = this.serverUrl
+      this.$network.post('/p/cs/module/migrate', obj)
+        .then((res) => {
+          if(res.data.resultCode === 0){
+            this.$Modal.fcSuccess({
+              title:'成功',
+              content:res.data.resultMsg,
+              onOk: () => {
+                this.queryLists()
+                this.listsStatus = 0
+                this.migrationModel = false
+                this.performloading = false
+              }
+            })
+
+          }else{
+            this.performloading = false
+          }
+
+        })
+    }
+  },
+  created () {
+    //判断首页跳转状态,修改查询条件
+    let status = Number(this.$route.query.status)
+    if(status){
+      this.searchData.status = [status]
+      this.formLists[1].item.value = [status]
+      this.formLists = this.formLists.concat([])
+    }
+    this.queryLists()
+  },
+  mounted () {
+    // 监听modal的点击事件
+    window.addEventListener('modalClick',this.modalClick)
+  },
+  beforeDestroy () {
+    window.removeEventListener('modalClick', this.modalClick);
+  },
+  activated () {
+    this.queryLists()
+  }
+}
+</script>
+<style lang="less" >
+.TemplateManagementLists{
+  display: flex;
+  flex-direction: column;
+  .listContent{
+    background: white;
+    flex: 1;
+    padding: 16px;
+    display: flex;
+    flex-direction: column;
+    overflow: hidden;
+
+    .title{
+      font-size:18px;
+      font-family:PingFangSC-Medium;
+      font-weight:500;
+      color:rgba(81,90,110,1);
+      line-height:24px;
+      margin-bottom: 16px;
+    }
+
+    .buttonLists{
+      margin-bottom: 10px;
+      >button{
+        width: 90px;
+        margin-right: 10px;
+      }
+    }
+    .form{
+      margin-bottom: 16px;
+    }
+
+    .list{
+      flex: 1;
+      margin-right: -16px;
+      overflow: auto;
+      position: relative;
+      .listsForm{
+        border: none;
+        padding: 0;
+        margin-left: 5px;
+        margin-top: 5px;
+
+        .FormItemComponent-item{
+          margin-right: 16px;
+          margin-bottom: 20px;
+        }
+      }
+
+      .noData{
+        position: absolute;
+        top: 50%;
+        left: 50%;
+        width: 280px;
+        height: 292px;
+        margin-top: -146px;
+        margin-left: -140px;
+        background-image: url('~@/assets/images/nodata.png');
+        background-size: cover;
+
+        >span{
+          position: absolute;
+          bottom: 40px;
+          left: 20px;
+          display: inline-block;
+          width: 240px;
+          height: 40px;
+          text-align: center;
+        }
+      }
+    }
+
+  }
+}
+
+.migrationModelContent{
+  height: 115px;
+  padding: 30px 44px 17px 44px;
+  box-sizing: border-box;
+}
+</style>

+ 4 - 3
ruoyi-ui/src/views/activiti/TemplateManagementNew/index.vue

@@ -476,14 +476,15 @@ export default {
   created () {
     Vue.component(`component_${this.currentSteps}`,Vue.extend(Object.assign({isKeepAliveModel:true},ParameterConfiguration)))
     this.currentComponent = `component_${this.currentSteps}`
+    console.log(this.$route.params.id,99998)
     if(this.$route.params.flag === '1'){
       this.readOnly = true
       this.noFreshFlag = true
       this.getModuleInfo(this.$route.params.id)
       return
     }
-    if(this.$route.params.id === '-1'){  //新增
-
+    if(this.$route.params.id === undefined){  //新增
+      console.log(22233)
     }else{  //编辑
       this.noFreshFlag = true
       this.currentSteps = 1
@@ -495,7 +496,7 @@ export default {
   }
 }
 </script>
-<style lang=scss" >
+<style lang="scss" >
 .TemplateManagementNew{
   padding:16px;
   background: white;

+ 113 - 109
ruoyi-ui/src/views/system/role/fz-index.vue

@@ -33,11 +33,13 @@
           </div>
         </div>
         <div class="searList">
-          <div class="searItem searItemLeft" element-loading-text="拼命加载中" v-loading.fullscreen.lock="fullscreenLoading" element-loading-spinner="el-icon-loading" element-loading-background="rgba(0, 0, 0, 0.4)" v-for="item in roleList" @click="searBtnFn(item)" :class="{'active': item.id == roleId}" :key="item.id">
-            <span>
-              {{item.roleName}}
-            </span>
-            <i class="el-icon-delete" @click.stop="handleDelete(item)" v-if="item.id == roleId"></i>
+          <div class="searItem searItemLeft" element-loading-text="拼命加载中" v-loading.fullscreen.lock="fullscreenLoading"
+            element-loading-spinner="el-icon-loading" element-loading-background="rgba(0, 0, 0, 0.4)" v-for="item in roleList"
+            @click="searBtnFn(item)" :class="{'active': item.id == roleId}" :key="item.id">
+            <span>
+              {{item.roleName}}
+            </span>
+            <i class="el-icon-delete" @click.stop="handleDelete(item)" v-if="item.id == roleId"></i>
           </div>
         </div>
         <pagination sty v-show="total>0" :total="total" layout="prev, pager, next" :page.sync="queryParams.pageNum"
@@ -47,7 +49,8 @@
         <div class="roleContrBox">
           <el-col :span="7">
             <div class="searContLeft">
-              <el-tree class="tree-border" @node-click="qxList" :data="deptOptions" default-expand-all ref="dept" node-key="id" :props="defaultProps"></el-tree>
+              <el-tree class="tree-border" @node-click="qxList" :data="deptOptions"
+                default-expand-all ref="dept" node-key="id" :props="defaultProps"></el-tree>
             </div>
           </el-col>
           <el-col :span="17">
@@ -60,41 +63,42 @@
                   {{item.name}}
                 </div>
               </div>
-              <div class="searCont" v-if="menusList.sysMenus.length" v-for="items in menusList.sysMenus" @click="searIndex = items.id" :class="{'active': searIndex == items.id}" :key="items.id">
+              <div class="searCont" v-if="menusList.sysMenus.length" v-for="items in menusList.sysMenus" @click="searIndex = items.id"
+                :class="{'active': searIndex == items.id}" :key="items.id">
                 <div class="searName">
                   {{items.menuName}}
                 </div>
-                <div class="searItem" v-for="(itemChild,indexChild) in items.containsHead" :key="indexChild">
-                  <el-checkbox @change="checkChange" :disabled="itemChild.type==='0'" v-model="itemChild.type"></el-checkbox>
+                <div class="searItem" v-for="(itemChild,indexChild) in items.containsHead" :key="indexChild">
+                  <el-checkbox @change="checkChange" :disabled="itemChild.type==='0'" v-model="itemChild.type"></el-checkbox>
                 </div>
               </div>
             </div>
           </el-col>
         </div>
       </el-col>
-    </el-row>
-
-
-    <!-- 添加或修改角色配置对话框 -->
-    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
-      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
-        <el-form-item label="角色名称" prop="roleName">
-          <el-input v-model="form.roleName" placeholder="请输入角色名称" />
-        </el-form-item>
-        <el-form-item label="权限字符" prop="roleKey">
-          <el-input v-model="form.roleKey" placeholder="请输入权限字符" />
-        </el-form-item>
-        <el-form-item label="角色顺序" prop="roleSort">
-          <el-input-number v-model="form.roleSort" controls-position="right" :min="0" />
-        </el-form-item>
-        <el-form-item label="备注">
-          <el-input v-model="form.remark" type="textarea" placeholder="请输入内容"></el-input>
-        </el-form-item>
-      </el-form>
-      <div slot="footer" class="dialog-footer">
-        <el-button type="primary" @click="submitForm">确 定</el-button>
-        <el-button @click="cancel">取 消</el-button>
-      </div>
+    </el-row>
+
+
+    <!-- 添加或修改角色配置对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="角色名称" prop="roleName">
+          <el-input v-model="form.roleName" placeholder="请输入角色名称" />
+        </el-form-item>
+        <el-form-item label="权限字符" prop="roleKey">
+          <el-input v-model="form.roleKey" placeholder="请输入权限字符" />
+        </el-form-item>
+        <el-form-item label="角色顺序" prop="roleSort">
+          <el-input-number v-model="form.roleSort" controls-position="right" :min="0" />
+        </el-form-item>
+        <el-form-item label="备注">
+          <el-input v-model="form.remark" type="textarea" placeholder="请输入内容"></el-input>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
     </el-dialog>
   </div>
 </template>
@@ -107,12 +111,12 @@
     addRole,
     updateRole,
     exportRole,
-    dataScope,
-    setMenu,
+    dataScope,
+    setMenu,
     changeRoleStatus
   } from "@/api/system/role";
   import {
-    treeselect as menuTreeselect,
+    treeselect as menuTreeselect,
     listMenus,
     treeMenuNotAddLeafNode
   } from "@/api/system/menu";
@@ -122,19 +126,19 @@
   } from "@/api/system/dept";
 
   export default {
-    name: "Role",
+    name: "Role",
     inject: ['reload'],
     data() {
-      return {
-        modifyStatus: false,
+      return {
+        modifyStatus: false,
         fullscreenLoading: false,
         searIndex: '',
         data: [],
         defaultProps: {
           children: 'children',
-          label: 'label'
+          label: 'menuName'
         },
-        indexs: 3,
+        indexs: 3,
         menusList: '',
         // 遮罩层
         loading: true,
@@ -227,61 +231,60 @@
         this.statusOptions = response.data;
       });
     },
-    methods: {
-      checkChange() {
-        this.modifyStatus = true
-      },
-      handleMenu() {
-        if(!this.modifyStatus){
-          this.msgInfo('没有修改的内容!')
-          return
-        }
-        let data = []
-        for(let item of this.menusList.sysMenus){
-          let obj = {}
-          obj.roleId = this.roleId
-          obj.menuId = item.id
-          obj.head = []
-          for(let itemChild of item.containsHead){
-            if(itemChild.type === true){
-              obj.head.push(itemChild.name)
-            }
-          }
-          data.push(obj)
-        }
-        setMenu(JSON.stringify(data)).then(res => {
-          this.msgSuccess('保存成功')
-          this.modifyStatus = false
-        })
-      },
-      qxList(e) {
-        const _this = this
-        console.log(this.modifyStatus)
-        if(this.modifyStatus){
-          this.$confirm('当前页面存在未保存内容,是否保存后切换?', "提醒", {
-            confirmButtonText: "留下",
-            cancelButtonText: "取消",
-            type: "warning"
-          }).then(function() {
-
-          }).catch(function() {
-            _this.modifyStatus = false
-            _this.qxList(e)
-          });
-          return
-        }
-        listMenus(e.id).then(res => {
-          let data = res.data
-          this.menusList = data
-        })
-      },
-      refreshFn() {
-        // this.getList()
-        this.reload()
-        // this.deptOptions = []
+    methods: {
+      checkChange() {
+        this.modifyStatus = true
+      },
+      handleMenu() {
+        if (!this.modifyStatus) {
+          this.msgInfo('没有修改的内容!')
+          return
+        }
+        let data = []
+        for (let item of this.menusList.sysMenus) {
+          let obj = {}
+          obj.roleId = this.roleId
+          obj.menuId = item.id
+          obj.head = []
+          for (let itemChild of item.containsHead) {
+            if (itemChild.type === true) {
+              obj.head.push(itemChild.name)
+            }
+          }
+          data.push(obj)
+        }
+        setMenu(JSON.stringify(data)).then(res => {
+          this.msgSuccess('保存成功')
+          this.modifyStatus = false
+        })
+      },
+      qxList(e) {
+        const _this = this
+        if (this.modifyStatus) {
+          this.$confirm('当前页面存在未保存内容,是否保存后切换?', "提醒", {
+            confirmButtonText: "留下",
+            cancelButtonText: "取消",
+            type: "warning"
+          }).then(function() {
+
+          }).catch(function() {
+            _this.modifyStatus = false
+            _this.qxList(e)
+          });
+          return
+        }
+        listMenus(e.id,this.roleId).then(res => {
+          let data = res.data
+          this.menusList = data
+        })
+      },
+      refreshFn() {
+        // this.getList()
+        this.reload()
+        // this.deptOptions = []
       },
       searBtnFn(item) {
-        this.roleId = item.id
+        this.roleId = item.id
         this.handleUpdate()
       },
       handleNodeClick() {
@@ -301,13 +304,13 @@
       /** 查询菜单树结构 */
       getMenuTreeselect() {
         menuTreeselect().then(response => {
-          this.menuOptions = response.data;
+          this.menuOptions = response.data;
         });
       },
       /** 查询部门树结构 */
       getDeptTreeselect() {
         deptTreeselect().then(response => {
-          this.deptOptions = response.data;
+          this.deptOptions = response.data;
         });
       },
       // 所有菜单节点数据
@@ -331,7 +334,7 @@
       /** 根据角色ID查询菜单树结构 */
       getRoleMenuTreeselect(id) {
         return treeMenuNotAddLeafNode(id).then(response => {
-          this.menuOptions = response.menus;
+          this.menuOptions = response.data;
           return response;
         });
       },
@@ -446,12 +449,12 @@
       },
       /** 修改按钮操作 */
       handleUpdate() {
-        this.reset();
+        this.reset();
         this.fullscreenLoading = true
         const roleMenu = this.getRoleMenuTreeselect(this.roleId);
-        roleMenu.then(res => {
+        roleMenu.then(res => {
           // let checkedKeys = res.checkedKeys
-          this.deptOptions = res.menus
+          this.deptOptions = res.data
           this.fullscreenLoading = false
         });
       },
@@ -515,12 +518,12 @@
         this.$confirm('是否确认删除角色编号为"' + ids + '"的数据项?', "警告", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
-          type: "warning",
+          type: "warning",
 
         }).then(function() {
           return delRole(ids);
         }).then(() => {
-          this.getList();
+          this.getList();
           this.deptOptions = []
           this.msgSuccess("删除成功");
         })
@@ -534,12 +537,13 @@
     }
   };
 </script>
-<style lang="scss" scoped>
-  .searItemLeft{
-    display: flex;
-    justify-content: space-between;
-    align-items: center;
+<style lang="scss" scoped>
+  .searItemLeft {
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
   }
+
   .roleContrBox {
     background-color: #fff;
     border-radius: 6px;
@@ -579,7 +583,7 @@
 
         .searItem {
           flex: 1;
-          font-size: 12px;
+          font-size: 12px;
           text-align: center;
         }
       }
@@ -600,7 +604,7 @@
 
         .searItem {
           flex: 1;
-          font-size: 12px;
+          font-size: 12px;
           text-align: center;
         }
 
@@ -673,7 +677,7 @@
         line-height: 30px;
         font-size: 12px;
         color: #343434;
-        cursor: pointer;
+        cursor: pointer;
         text-align: center;
       }
 

+ 1 - 1
ruoyi-ui/src/views/system/surface/index.vue

@@ -26,7 +26,7 @@
               <img class="img_icon" v-if="item.htmlType=='imageUpload' && scope.row[scope.column.property]" @click="imgBtn(JSON.parse(scope.row[scope.column.property])[0].url)"
                 :src="JSON.parse(scope.row[scope.column.property])[0].url" alt="">
               <!-- :style="scope.row.list_class" scope.row[scope.column.property] -->
-              <span  :style="scope.row.list_class" v-else-if="item.columnComment == '状态' || item.columnComment == '提交' " >{{ scope.row[scope.column.property] }}</span>
+              <span  :style="scope.row.list_class" v-else-if="item.columnName == 'status' " >{{ scope.row[scope.column.property] }}</span>
               <span  v-else>{{ scope.row[scope.column.property] }}</span>
             </template>
           </el-table-column>