From 89600b73ad557ff3e1b4614536379d1a30ea78df Mon Sep 17 00:00:00 2001
From: wangting <675591594@qq.com>
Date: 星期五, 15 十一月 2024 10:55:43 +0800
Subject: [PATCH] 修改action

---
 Source/plt-web/plt-web-ui/src/components/actions/base/ViewAction.js           |    9 ++++++---
 Source/plt-web/plt-web-ui/src/store/index.js                                  |    2 +-
 Source/plt-web/plt-web-ui/src/components/dynamic-components/dynamic-table.vue |    2 +-
 Source/plt-web/plt-web-ui/src/components/actions/base/ViewDialogAction.js     |    5 ++---
 Source/plt-web/plt-web-ui/src/permission.js                                   |    4 ++++
 Source/plt-web/plt-web-ui/src/router/views/index.js                           |    9 +++++----
 6 files changed, 19 insertions(+), 12 deletions(-)

diff --git a/Source/plt-web/plt-web-ui/src/components/actions/base/ViewAction.js b/Source/plt-web/plt-web-ui/src/components/actions/base/ViewAction.js
index 344364c..d08e4c9 100644
--- a/Source/plt-web/plt-web-ui/src/components/actions/base/ViewAction.js
+++ b/Source/plt-web/plt-web-ui/src/components/actions/base/ViewAction.js
@@ -53,11 +53,11 @@
     }
   }
   paramVOS.component=component;
-  let name="鏌ョ湅璇︽儏"
   if(paramVOS.showname){
-    name="鏌ョ湅銆�"+replaceFreeMarker(paramVOS.showname,options.dataStore,options.sourceData)+"銆�"
+    const name="鏌ョ湅銆�"+replaceFreeMarker(paramVOS.showname,options.dataStore,options.sourceData)+"銆�";
+    paramVOS.title=name;
   }
-  paramVOS.title=name;
+
   const params= {
     options:options,
     paramVOS:paramVOS,
@@ -68,6 +68,9 @@
   router.push({
     name: "鏌ョ湅璇︽儏",
     params:params,
+    query:{
+      name:paramVOS.title
+    }
   });
 }
 
diff --git a/Source/plt-web/plt-web-ui/src/components/actions/base/ViewDialogAction.js b/Source/plt-web/plt-web-ui/src/components/actions/base/ViewDialogAction.js
index d63fb9d..49e066a 100644
--- a/Source/plt-web/plt-web-ui/src/components/actions/base/ViewDialogAction.js
+++ b/Source/plt-web/plt-web-ui/src/components/actions/base/ViewDialogAction.js
@@ -51,11 +51,10 @@
     }
   }
   paramVOS.component=component;
-  let name="鏌ョ湅璇︽儏"
   if(paramVOS.showname){
-    name="鏌ョ湅銆�"+replaceFreeMarker(paramVOS.showname,options.dataStore,options.sourceData)+"銆�"
+    const name="鏌ョ湅銆�"+replaceFreeMarker(paramVOS.showname,options.dataStore,options.sourceData)+"銆�"
+    paramVOS.title=name;
   }
-  paramVOS.title=name;
   const dialogConstructor = Vue.extend(ViewDialog);
   let instance = new dialogConstructor();
   instance.sourceData = options.sourceData;
diff --git a/Source/plt-web/plt-web-ui/src/components/dynamic-components/dynamic-table.vue b/Source/plt-web/plt-web-ui/src/components/dynamic-components/dynamic-table.vue
index 3f07b29..8a7ccc6 100644
--- a/Source/plt-web/plt-web-ui/src/components/dynamic-components/dynamic-table.vue
+++ b/Source/plt-web/plt-web-ui/src/components/dynamic-components/dynamic-table.vue
@@ -354,7 +354,7 @@
       this.$refs.dataTable.rowView(row,index)
     },
     rowClickChange(row){
-      this.$refs.dataTable.toggleRowSelection(row);
+      this.$refs.dataTable.toggleRowSelection(row,true);
     },
     selectChange(row) {
       this.selectList = row;
diff --git a/Source/plt-web/plt-web-ui/src/permission.js b/Source/plt-web/plt-web-ui/src/permission.js
index 3af463c..fd61203 100644
--- a/Source/plt-web/plt-web-ui/src/permission.js
+++ b/Source/plt-web/plt-web-ui/src/permission.js
@@ -30,6 +30,10 @@
          const label = to.query.name || to.name;
          const meta = to.meta || router.$avueRouter.meta || {};
          const i18n = to.query.i18n;
+         if(to.query.name){
+           //淇敼璺敱鏍囬
+           meta.title=to.query.name;
+         }
          if (to.query.target) {
            window.open(value)
          } else if (meta.isTab !== false && !validatenull(value) && !validatenull(label)) {
diff --git a/Source/plt-web/plt-web-ui/src/router/views/index.js b/Source/plt-web/plt-web-ui/src/router/views/index.js
index 92e7775..7b9f113 100644
--- a/Source/plt-web/plt-web-ui/src/router/views/index.js
+++ b/Source/plt-web/plt-web-ui/src/router/views/index.js
@@ -104,14 +104,15 @@
       import( /* webpackChunkName: "views" */ '@/views/work/process/leave/detail')
   }]
 },{
-  path: '/viewTab',
+  path: '/base',
   component: Layout,
-  redirect: '/viewTab/index',
+  redirect: '/viewTab',
   children: [{
-    path: 'index',
+    path: 'viewTab',
     name: '鏌ョ湅璇︽儏',
     meta: {
-      i18n: 'viewTab'
+      i18n: 'viewTab',
+      title:'鏌ョ湅璇︽儏'
     },
     component: () =>
       import('@/views/base/ViewTab')
diff --git a/Source/plt-web/plt-web-ui/src/store/index.js b/Source/plt-web/plt-web-ui/src/store/index.js
index cbeb5d1..1e2a682 100644
--- a/Source/plt-web/plt-web-ui/src/store/index.js
+++ b/Source/plt-web/plt-web-ui/src/store/index.js
@@ -21,7 +21,7 @@
   },
   getters,
   state: {
-    viewtabparams:undefined, //鏌ョ湅tab Action鍙傛暟
+    viewtabparams:undefined, //tab娴忚 Action鍙傛暟
   },
   mutations: {
     // 瑙勭▼璇︽儏鍙傛暟

--
Gitblit v1.9.3