完善启动流程以及预制对象-接口获取用户信息存储本地修改获取用户信息方法
已修改5个文件
55 ■■■■ 文件已修改
Source/plt-web/plt-web-ui/src/components/actions/base/StartWorkflowAction.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue 39 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/page/login/index.vue 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/store/modules/user.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/styles/login.scss 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/plt-web/plt-web-ui/src/components/actions/base/StartWorkflowAction.js
@@ -8,6 +8,10 @@
export const doAction = (options,callback) => {
  //modelName 流程名称 默认为 当前用户+'启动流程'+当前分类
  //multi 是否开启多选
  //checknotprocess 是否允许发起流程
  options.sourceData = options.sourceData || {};
  options.dataStore = options.dataStore || [];
  // if (!options.dataStore || options.dataStore.length < 1) {
@@ -58,7 +62,7 @@
  let instance = new dialogConstructor();
  instance.sourceData = options.sourceData;
  instance.dataStore = options.dataStore;
  instance.paramVOS = paramVOS
  instance.paramVOS = paramVOS;
  instance.dialogClose = function () {
    vm.visible = false;
Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue
@@ -26,9 +26,9 @@
    </el-form>
    <el-divider></el-divider>
    <div class="btns-icon">
      <el-button circle icon="el-icon-star-off" @click="handleCollect"></el-button>
    </div>
<!--    <div class="btns-icon">-->
<!--      <el-button circle icon="el-icon-star-off" @click="handleCollect"></el-button>-->
<!--    </div>-->
    <el-form :model="collectParam" class="demo-form-inline" label-position="left" label-width="auto">
      <el-form-item v-for="(item, index) in initFrom" :key="index" :label="item.taskName">
        <el-select v-model="collectParam.flowTaskUsers[index]['userId']" :placeholder="item.taskName" filterable
@@ -70,11 +70,16 @@
  data() {
    return {
      visible: false,
      saveParam: {},
      users: [],
      collectParam: {},
      initFrom: [],
      typeName: [],
      saveParam: {}, // 对象包含 {modelName流程模板(由接口返回当前流程模板) , processName流程名称(为当前用户+'启动流程'+当前分类) , processDesc流程描述 }
      initFrom: [],  // 当前流程节点循环数组
      collectParam: {}, // 流程节点下拉框双向绑定属性
      typeName: [], // 流程节点option循环选项
      rules: {
        processName: [
          { required: true, message: '流程名称不能为空', trigger: 'blur' },
          { min: 3, max: 50, message: '长度在 3 到 50 个字符', trigger: 'blur' }
        ]
      }
    }
  },
  watch: {
@@ -87,7 +92,7 @@
    },
    parameter: {
      handler(newval, oldval) {
        this.saveParam = Object.assign({processName: '', processDesc: ''}, newval);
        this.saveParam = Object.assign({processName: '', processDesc: '' , }, newval);
      },
      deep: true,
      immediate: true
@@ -114,6 +119,9 @@
      }
    },
  },
  mounted() {
    this.modelNameChange();
  },
  methods: {
    // 关闭弹窗
    dialogClose() {
@@ -133,7 +141,20 @@
    },
    handleConfirm() {
      console.log(this.paramVOS)
    },
  //  流程名称初始化绑定
    modelNameChange(){
      var userInfo = JSON.parse(localStorage.getItem('saber-userInfo'));
      if (this.paramVOS && this.paramVOS.modelName) {
        this.saveParam.modelName = this.paramVOS.modelName;
      } else if (userInfo.content && userInfo.content.userName) {
        this.saveParam.modelName = userInfo.content.userName + '[启动流程]';
      } else {
        this.saveParam.modelName = '';
      }
    }
  }
}
Source/plt-web/plt-web-ui/src/page/login/index.vue
@@ -18,7 +18,7 @@
    </div>
    <div class="login-bg-image" style="color: white;text-align: center">
      <div style="font-size: 80px; font-weight: bold" >欢迎登录</div>
      <h1>PLT-WEB平台</h1>
      <h1 style="font-size: 40px">PLT-WEB平台</h1>
    </div>
  </div>
</template>
@@ -119,13 +119,13 @@
<style lang="scss" scoped>
.login-container {
  background: #fff url('../../../public/img/login-background.png') no-repeat center;
  background:  url('../../../public/img/login-background.png') no-repeat center;
  background-size: 100% 100%;
}
.login-bg-image{
  position: fixed;
  left: 10%;
  top: 25%;
  top: 30%;
}
</style>
Source/plt-web/plt-web-ui/src/store/modules/user.js
@@ -71,7 +71,7 @@
            commit('CLEAR_LOCK');
            getUserInfo().then((res) => {
              const data = res.data.data;
              const data = res.data;
              commit('SET_USER_INFO', data.obj);
            }).catch(err => {
              console.log(err)
Source/plt-web/plt-web-ui/src/styles/login.scss
@@ -12,7 +12,7 @@
  margin: 0 auto;
  width: 500px;
  border-radius: 20px;
  background-color: rgba(256, 256, 256, 0.6);
  background-color: rgba(256, 256, 256, 0.9);
  box-shadow: -4px 5px 10px rgba(0, 0, 0, 0.3);
  .el-input-group__append {
    border: none;