From 43ed2d886f1cc3b2cf27258efcdb39f47cc3ec94 Mon Sep 17 00:00:00 2001
From: 田源 <lastanimals@163.com>
Date: 星期四, 20 六月 2024 11:44:44 +0800
Subject: [PATCH] 完善启动流程以及预制对象-接口获取用户信息存储本地修改获取用户信息方法

---
 Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue      |   39 ++++++++++++++++++++++++++++++---------
 Source/plt-web/plt-web-ui/src/components/actions/base/StartWorkflowAction.js |    6 +++++-
 Source/plt-web/plt-web-ui/src/styles/login.scss                              |    2 +-
 Source/plt-web/plt-web-ui/src/store/modules/user.js                          |    2 +-
 Source/plt-web/plt-web-ui/src/page/login/index.vue                           |    6 +++---
 5 files changed, 40 insertions(+), 15 deletions(-)

diff --git a/Source/plt-web/plt-web-ui/src/components/actions/base/StartWorkflowAction.js b/Source/plt-web/plt-web-ui/src/components/actions/base/StartWorkflowAction.js
index ab77ad8..ddb084d 100644
--- a/Source/plt-web/plt-web-ui/src/components/actions/base/StartWorkflowAction.js
+++ b/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;
diff --git a/Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue b/Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue
index 5c8cdb1..ea93acf 100644
--- a/Source/plt-web/plt-web-ui/src/components/actions/base/startWorkFlow.vue
+++ b/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娴佺▼妯℃澘(鐢辨帴鍙h繑鍥炲綋鍓嶆祦绋嬫ā鏉�) , 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 = '';
+      }
     }
   }
 }
diff --git a/Source/plt-web/plt-web-ui/src/page/login/index.vue b/Source/plt-web/plt-web-ui/src/page/login/index.vue
index 92b55bd..3a0ffea 100644
--- a/Source/plt-web/plt-web-ui/src/page/login/index.vue
+++ b/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>
diff --git a/Source/plt-web/plt-web-ui/src/store/modules/user.js b/Source/plt-web/plt-web-ui/src/store/modules/user.js
index 6f14ce8..cc12802 100644
--- a/Source/plt-web/plt-web-ui/src/store/modules/user.js
+++ b/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)
diff --git a/Source/plt-web/plt-web-ui/src/styles/login.scss b/Source/plt-web/plt-web-ui/src/styles/login.scss
index 3760c17..2c1c23c 100644
--- a/Source/plt-web/plt-web-ui/src/styles/login.scss
+++ b/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;

--
Gitblit v1.9.3