From c4b85acdfce7b6db334faaa4832418a0bcba1719 Mon Sep 17 00:00:00 2001
From: chenhaozhe <cgz@hz-kingdee.com>
Date: 星期四, 13 十一月 2025 08:24:54 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-VUEUI

---
 /dev/null                               |   39 --
 src/views/sell/sellOut/sellOutBill.vue  |   10 
 src/layout/components/Sidebar/index.vue |   15 
 src/store/modules/permission.js         |   81 ++++-
 src/views/system/user/xtUserList.vue    |  754 +++++++++++++++++++++++++++++++++++++++++++++++
 src/router/index.js                     |   27 +
 6 files changed, 850 insertions(+), 76 deletions(-)

diff --git a/src/layout/components/Sidebar/MenuItemRecursive.vue b/src/layout/components/Sidebar/MenuItemRecursive.vue
deleted file mode 100644
index c600bb3..0000000
--- a/src/layout/components/Sidebar/MenuItemRecursive.vue
+++ /dev/null
@@ -1,39 +0,0 @@
-<template>
-    <div>
-        <!-- 閬嶅巻鑿滃崟鍒楄〃 -->
-        <template>
-            <div  v-for="(item, index) in menuList" :key="index">
-                <!-- 鏈夊瓙闆� 鈫� 娓叉煋瀛愯彍鍗曪紙el-submenu锛� -->
-                <el-submenu v-if="item.children && item.children.length > 0" :index="item.index">
-                    <template slot="title">
-                        <!-- 鏄剧ず鍥炬爣锛堝鏋滄湁锛� -->
-                        <i :class="item.icon" v-if="item.icon"></i>
-                        <span>{{ item.label }}</span>
-                    </template>
-                    <!-- 閫掑綊娓叉煋瀛愯彍鍗曪紙鑷皟鐢ㄧ粍浠讹級 -->
-                    <menu-item-recursive :menu-list="item.children"></menu-item-recursive>
-                </el-submenu>
-
-                <!-- 鏃犲瓙闆� 鈫� 娓叉煋鑿滃崟椤癸紙el-menu-item锛� -->
-                <el-menu-item v-else :index="item.index">
-                    <i :class="item.icon" v-if="item.icon"></i>
-                    <span>{{ item.label }}</span>
-                </el-menu-item>
-            </div>
-        </template>
-    </div>
-</template>
-
-<script>
-export default {
-    name: 'MenuItemRecursive',  // 閫掑綊缁勪欢蹇呴』鎸囧畾name
-    props: {
-        // 鎺ユ敹鐖剁粍浠朵紶鍏ョ殑鑿滃崟鍒楄〃
-        menuList: {
-            type: Array,
-            required: true,
-            default: () => []
-        }
-    }
-}
-</script>
\ No newline at end of file
diff --git a/src/layout/components/Sidebar/index.vue b/src/layout/components/Sidebar/index.vue
index 9e8abb7..d35a05a 100644
--- a/src/layout/components/Sidebar/index.vue
+++ b/src/layout/components/Sidebar/index.vue
@@ -7,23 +7,12 @@
                 :background-color="settings.sideTheme === 'theme-dark' ? variables.menuBackground : variables.menuLightBackground"
                 :text-color="settings.sideTheme === 'theme-dark' ? variables.menuColor : variables.menuLightColor"
                 :unique-opened="true" :active-text-color="settings.theme" :collapse-transition="false" mode="vertical">
-                <!-- <el-submenu index="1">
-                    <template slot="title">
-                        <i class="el-icon-location"></i>
-                        <span>瀵艰埅涓�</span>
-                    </template>
-<el-menu-item-group>
-    <el-menu-item index="1-1">閫夐」1</el-menu-item>
-    <el-menu-item index="1-2">閫夐」2</el-menu-item>
-</el-menu-item-group>
-</el-submenu> -->
                 <sidebar-item
                     v-for="(route, index) in sidebarRouters"
                     :key="route.path  + index"
                     :item="route"
                     :base-path="route.path"
                 />
-                <!-- <menu-item-recursive :menu-list="menuData" /> -->
             </el-menu>
         </el-scrollbar>
     </div>
@@ -34,9 +23,8 @@
 import Logo from "./Logo"
 import SidebarItem from "./SidebarItem"
 import variables from "@/assets/styles/variables.scss"
-import MenuItemRecursive from './MenuItemRecursive.vue'  // 瀵煎叆閫掑綊缁勪欢
 export default {
-    components: { SidebarItem, Logo, MenuItemRecursive },
+    components: { SidebarItem, Logo },
     computed: {
         ...mapState(["settings"]),
         ...mapGetters(["sidebarRouters", "sidebar"]),
@@ -45,6 +33,7 @@
             const { meta, path } = route
             // if set path, the sidebar will highlight the path you set
             if (meta.activeMenu) {
+                console.log(meta.activeMenu)
                 return meta.activeMenu
             }
             return path
diff --git a/src/router/index.js b/src/router/index.js
index 47a9976..905613b 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -126,20 +126,39 @@
   //   hidden: true,
   // },
   {
-    path: "/sales/salesOUt/sellOutBillEdit",
+    path: "/sell/sellOut/sellOutBillEdit",
     component: Layout,
     hidden: true,
     redirect: "noredirect",
     meta: {
       breadcrumb: false, // 濡傛灉璁剧疆涓篺alse锛屽垯涓嶄細鍦╞readcrumb闈㈠寘灞戜腑鏄剧ず
-      activeMenu: "/sales/salesOUt/sellOutBillEdit", // 褰撹矾鐢辫缃簡璇ュ睘鎬э紝鍒欎細楂樹寒鐩稿搴旂殑渚ц竟鏍忋��
+      activeMenu: "/sell/sellOut", // 褰撹矾鐢辫缃簡璇ュ睘鎬э紝鍒欎細楂樹寒鐩稿搴旂殑渚ц竟鏍忋��
     },
     children: [
       {
-        path: "/sales/salesOUt/sellOutBillEdit",
+        path: "/sell/sellOut/sellOutBillEdit",
         component: () => import("@/views/sell/sellOutBill/edit"),
         name: "SellOutBillEdit",
-        meta: { title: "閿�鍞嚭搴撳崟缂栬緫", activeMenu: "sales/salesOUt" },
+        meta: { title: "閿�鍞嚭搴撳崟缂栬緫", activeMenu: "sell/sellOut" },
+      },
+    ],
+  },
+  //鐢ㄦ埛鍒楄〃
+  {
+    path: "/system/user/xtUserList",
+    component: Layout,
+    hidden: true,
+    redirect: "noredirect",
+    meta: {
+      breadcrumb: false, // 濡傛灉璁剧疆涓篺alse锛屽垯涓嶄細鍦╞readcrumb闈㈠寘灞戜腑鏄剧ず
+      activeMenu: "/system/user", // 褰撹矾鐢辫缃簡璇ュ睘鎬э紝鍒欎細楂樹寒鐩稿搴旂殑渚ц竟鏍忋��
+    },
+    children: [
+      {
+        path: "/system/user/xtUserList",
+        component: () => import("@/views/system/user/xtUserList.vue"),
+        name: "XtUserList",
+        meta: { title: "鐢ㄦ埛鍒楄〃", activeMenu: "system/user" },
       },
     ],
   },
diff --git a/src/store/modules/permission.js b/src/store/modules/permission.js
index 58da41b..c5581f4 100644
--- a/src/store/modules/permission.js
+++ b/src/store/modules/permission.js
@@ -69,7 +69,7 @@
                       title: "閿�鍞嚭搴撳崟缁存姢",
                     },
                     component: () =>
-                      import("@/views/sell/sellOutBill/index.vue"),
+                      import("@/views/sell/sellOut/sellOutBill.vue"),
                     hidden: false,
                     name: "SellOutBill",
                     path: "sellOutBill",
@@ -81,7 +81,8 @@
                       noCache: false,
                       title: "閿�鍞嚭搴撳崟",
                     },
-                    component: () => import('@/views/sell/sellOutBill/edit/index.vue'),
+                    component: () =>
+                      import("@/views/sell/sellOut/sellOutBillEdit.vue"),
                     hidden: false,
                     name: "SellOutBillEdit",
                     path: "sellOutBillEdit",
@@ -108,7 +109,8 @@
                       noCache: false,
                       title: "閿�鍞鍗曠淮鎶�",
                     },
-                    component: () => import("@/views/sell/xsSeOrderBill/xsSeOrderBill.vue"),
+                    component: () =>
+                      import("@/views/sell/xsSeOrderBill/xsSeOrderBill.vue"),
                     hidden: false,
                     name: "XsSeOrderBill",
                     path: "xsSeOrderBill",
@@ -135,7 +137,8 @@
                       noCache: false,
                       title: "鍙戣揣閫氱煡鍗曠淮鎶�",
                     },
-                    component: () => import("@/views/sell/XsSeOutStockBill.vue"),
+                    component: () =>
+                      import("@/views/sell/XsSeOutStockBill.vue"),
                     hidden: false,
                     name: "XsSeOutStockBill",
                     path: "xsSeOutStockBill",
@@ -162,7 +165,8 @@
                       noCache: false,
                       title: "閫�璐ч�氱煡鍗曠淮鎶�",
                     },
-                    component: () => import("@/views/sell/XsSeOutStockBackBillList.vue"),
+                    component: () =>
+                      import("@/views/sell/XsSeOutStockBackBillList.vue"),
                     hidden: false,
                     name: "XsSeOutStockBackBillList",
                     path: "xsSeOutStockBackBillList",
@@ -205,8 +209,7 @@
                       noCache: false,
                       title: "鐢熶骇璧勬枡鍒楄〃",
                     },
-                    component: () =>
-                      import("@/views/basic/gySource/index.vue"),
+                    component: () => import("@/views/basic/gySource/index.vue"),
                     hidden: false,
                     name: "GySource",
                     path: "gySource",
@@ -246,7 +249,8 @@
                       noCache: false,
                       title: "浠撲綅鍒楄〃",
                     },
-                    component: () => import('@/views/basic/gyStockPlace/gyStockPlace.vue'),
+                    component: () =>
+                      import("@/views/basic/gyStockPlace/gyStockPlace.vue"),
                     hidden: false,
                     name: "GyStockPlace",
                     path: "gyStockPlace",
@@ -258,7 +262,8 @@
                       noCache: false,
                       title: "鑱屽憳鍒楄〃",
                     },
-                    component: () => import('@/views/basic/gyEmployee/gyEmployee.vue'),
+                    component: () =>
+                      import("@/views/basic/gyEmployee/gyEmployee.vue"),
                     hidden: false,
                     name: "GyEmployee",
                     path: "gyEmployee",
@@ -301,12 +306,12 @@
                       noCache: false,
                       title: "閲囪喘璁㈠崟鍒楄〃",
                     },
-                    component: () => import("@/views/purchase/cgPoOrderBill/cgPoOrderBill"),
+                    component: () =>
+                      import("@/views/purchase/cgPoOrderBill/cgPoOrderBill"),
                     hidden: false,
                     name: "CgPoOrderBill",
                     path: "cgPoOrderBill",
                   },
-
                 ],
               },
               {
@@ -330,13 +335,59 @@
                       title: "鏀舵枡閫氱煡鍗曞垪琛�",
                     },
                     component: () =>
-                      import("@/views/purchase/cgPoInStockBill/cgPoInStockBill.vue"),
+                      import(
+                        "@/views/purchase/cgPoInStockBill/cgPoInStockBill.vue"
+                      ),
                     hidden: false,
                     name: "CgPoInStockBill",
                     path: "cgPoInStockBill",
                   },
-                ]
-              }
+                ],
+              },
+              {
+                alwaysShow: true,
+                component: "Layout",
+                meta: {
+                  icon: "build",
+                  link: null,
+                  noCache: false,
+                  title: "绯荤粺绠$悊",
+                },
+                hidden: false,
+                name: "System",
+                path: "/system",
+                redirect: "noRedirect",
+                children: [
+                  {
+                    meta: {
+                      icon: "build",
+                      link: null,
+                      noCache: false,
+                      title: "鐢ㄦ埛绠$悊",
+                    },
+                    hidden: false,
+                    name: "User",
+                    path: "user",
+                    redirect: "noRedirect",
+                    component: "Layout",
+                    children: [
+                      {
+                        meta: {
+                          icon: "build",
+                          link: null,
+                          noCache: false,
+                          title: "鐢ㄦ埛鍒楄〃",
+                        },
+                        component: () =>
+                          import("@/views/system/user/xtUserList.vue"),
+                        hidden: false,
+                        name: "XtUserList",
+                        path: "xtUserList",
+                      },
+                    ],
+                  },
+                ],
+              },
             ],
           },
           {
@@ -392,10 +443,8 @@
         router.addRoutes(asyncRoutes);
         commit("SET_ROUTES", rewriteRoutes);
         commit("SET_SIDEBAR_ROUTERS", constantRoutes.concat(sidebarRoutes));
-        commit("SET_SIDEBAR_ROUTERS", constantRoutes.concat(sidebarRoutes));
         commit("SET_DEFAULT_ROUTES", sidebarRoutes);
         commit("SET_TOPBAR_ROUTES", sidebarRoutes);
-        console.log(11, rewriteRoutes);
         resolve(rewriteRoutes);
       });
     },
diff --git a/src/views/sell/sellOut/sellOutBill.vue b/src/views/sell/sellOut/sellOutBill.vue
index 3e5e46d..c07dc36 100644
--- a/src/views/sell/sellOut/sellOutBill.vue
+++ b/src/views/sell/sellOut/sellOutBill.vue
@@ -170,7 +170,7 @@
           </el-table-column>
         </template>
       </el-table>
-      <pagination v-show="total > 0" :total="total" :page.sync="page" :limit.sync="pageSize" @pagination="getList" />
+      <pagination v-show="total > 0" :total="total" :page.sync="page" :limit.sync="pageSize" :pageSizes="pageSizes" @pagination="getList" />
       <el-dialog title="闅愯棌鍒楄缃�" :visible.sync="openRowHide" width="816px" append-to-body>
         <RowSettings :colName="btResList" HModName="Kf_SellOutBillList" @rowEditClose="rowSetClose"
           v-if="rowHideShow" />
@@ -286,6 +286,7 @@
       tableData: [],//閿�鍞嚭搴撳垪琛�(鍒嗛〉鏄剧ず)
       dataList: [],
       titleData: ["hmainid", "hsupid", "HEmpID", "hmanagerid", "hsecmanagerid", "鍙戣揣浜�", "hkeeperid", "淇濈鍛�", "HDeptID", "閿�鍞柟寮�", "hsubid", "hmaterid", "hunitid", "HWHID"],//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+      pageSizes: [50, 100, 500, 5000, 50000],
       page: 1,
       pageSize: 0,
       total: 0,
@@ -438,21 +439,22 @@
       });
     },
     DisPlay_HideColumn(HModName, user, option, dataOption) {
+      
       this.totalNameList = []
       axios.get(this.baseURL + '/Xt_grdAlignment_WMES/grdAlignmentWMESList', {
         params: {
           "HModName": HModName,
           "user": user,
         },
-      }).then(res => {
+      }).then(res => {        
         let data1 = res.data
-        if (data1.data.length != 0) {
+        if (data1.data.length != 0) {       
           var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
           var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
           newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
           dataCol = data1.data[0].HGridString.split(',');
           //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
-          if (dataCol.length == option.cols[0].length - 1) {
+          if (dataCol.length == option.cols[0].length - 1) {                
             //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
             for (var j = 0; j < option.cols[0].length - 1; j++) {
               for (var i = 0; i < option.cols[0].length - 1; i++) {
diff --git a/src/views/system/user/xtUserList.vue b/src/views/system/user/xtUserList.vue
new file mode 100644
index 0000000..2a2cec0
--- /dev/null
+++ b/src/views/system/user/xtUserList.vue
@@ -0,0 +1,754 @@
+<template>
+  <div style="padding: 10px;">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" label-width="98px" class="searchBox">
+      <el-row>
+        <el-form-item label="鐢ㄦ埛缂栫爜" prop="HNumber" style="margin-left: 100px;">
+          <el-input v-model="queryParams.HNumber" placeholder="璇疯緭鍏ョ敓浜ц祫婧愪唬鐮�" @keyup.enter.native="handleQuery" />
+        </el-form-item>
+        <el-form-item label="鐢ㄦ埛鍚嶇О" prop="HName">
+          <el-input v-model="queryParams.HName" placeholder="璇疯緭鍏ョ敤鎴峰悕绉�" @keyup.enter.native="handleQuery" />
+        </el-form-item>
+        <el-form-item label="瀵瑰簲CLOUD缁勭粐" prop="HUSEORGID" label-width="128px">
+          <el-select v-model="queryParams.HUSEORGID" placeholder="璇烽�夋嫨">
+            <el-option v-for="(item, index) in organizationList" :key="index" :label="item.Name" :value="item.ID">
+            </el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label-width="78px">
+          <el-button type="primary" icon="el-icon-search" @click="handleQuery">
+            鎼� 绱�</el-button>
+          <el-button type="primary" icon="el-icon-refresh" @click="resetQuery">閲� 缃�</el-button>
+        </el-form-item>
+      </el-row>
+      <el-collapse v-model="activeSeach">
+        <el-collapse-item title="鏇村" name="1">
+          <el-card class="box-card">
+            <div slot="header" class="clearfix"><span>杩囨护</span></div>
+            <div>
+              <el-form-item label-width="0">
+                <el-row>
+                  <el-col :span="7">
+                    <el-select v-model="queryParams.ColName1" placeholder="璇烽�夋嫨">
+                      <span v-for="(item, index) in btList" :key="index">
+                        <el-option :label="item.field" :value="item.field" v-if="!item.hide"></el-option>
+                      </span>
+                    </el-select>
+                  </el-col>
+                  <el-col :span="6" style="padding: 0 10px;">
+                    <el-select v-model="queryParams.Comparator1" placeholder="璇烽�夋嫨">
+                      <el-option v-for="(item, index) in comparatorList" :key="index" :label="item.label"
+                        :value="item.value"></el-option>
+                    </el-select>
+                  </el-col>
+                  <el-col :span="11">
+                    <el-input v-model="queryParams.ColContent1" placeholder="璇疯緭鍏�" clearable
+                      @keyup.enter.native="handleQuery" />
+                  </el-col>
+                </el-row>
+              </el-form-item>
+              <el-row>
+                <el-form-item label-width="0">
+                  <el-row>
+                    <el-col :span="7">
+                      <el-select v-model="queryParams.ColName2" placeholder="璇烽�夋嫨">
+                        <span v-for="(item, index) in btList" :key="index">
+                          <el-option :label="item.field" :value="item.field" v-if="!item.hide"></el-option>
+                        </span>
+                      </el-select>
+                    </el-col>
+                    <el-col :span="6" style="padding: 0 10px;">
+                      <el-select v-model="queryParams.Comparator2" placeholder="璇烽�夋嫨">
+                        <span v-for="(item, index) in btList" :key="index">
+                          <el-option :label="item.field" :value="item.field" v-if="!item.hide"></el-option>
+                        </span>
+                      </el-select>
+                    </el-col>
+                    <el-col :span="11">
+                      <el-input v-model="queryParams.ColContent2" placeholder="璇疯緭鍏�" clearable
+                        @keyup.enter.native="handleQuery" />
+                    </el-col>
+                  </el-row>
+                </el-form-item>
+              </el-row>
+              <el-form-item label-width="0">
+                <el-row>
+                  <el-col :span="7">
+                    <el-select v-model="queryParams.ColName" placeholder="璇烽�夋嫨">
+                      <el-option v-for="(item, index) in btList" :key="index" :label="item.field"
+                        :value="item.field"></el-option>
+                    </el-select>
+                  </el-col>
+                  <el-col :span="6" style="padding: 0 10px;">
+                    <el-select v-model="queryParams.Comparator" placeholder="璇烽�夋嫨">
+                      <el-option v-for="(item, index) in comparatorList" :key="index" :label="item.label"
+                        :value="item.value"></el-option>
+                    </el-select>
+                  </el-col>
+                  <el-col :span="11">
+                    <el-input v-model="queryParams.ColContent" placeholder="璇疯緭鍏�" clearable
+                      @keyup.enter.native="handleQuery" />
+                  </el-col>
+                </el-row>
+              </el-form-item>
+            </div>
+          </el-card>
+        </el-collapse-item>
+      </el-collapse>
+    </el-form>
+    <el-row :gutter="10" class="mb8" style="margin-top: 10px;">
+      <!-- <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAddEdit(OperationType = 1)"
+          id="btn-Add">鏂板</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-edit" size="mini" :disabled="single"
+          @click="handleEdit(row = rowForm, OperationType = 3)">缂栬緫</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-share" size="mini" :disabled="single"
+          @click="handleEdit(row = rowForm, OperationType = 2)">鏉冮檺</el-button>
+      </el-col> -->
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-delete" size="mini" :disabled="single" @click="handleDelete">鍒犻櫎
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-download" size="mini" @click="handleExport">瀵煎嚭</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-download" size="mini" @click="handleRowHide">闅愯棌鍒楄缃�</el-button>
+      </el-col>
+    </el-row>
+    <div class="tableBox" v-loading="loading">
+      <el-table :data="tableData" ref="tableData" max-height="750" :summary-method="getSummaries"
+        @selection-change="handleSelectionChange" show-summary border @row-click="handleRowClick" :row-style="rowStyle"
+        @cell-dblclick="handleDblclick" v-if="tableShow">
+        <template v-for="(item, index) in btList">
+          <el-table-column type="selection" width="55" align="center" :fixed="item.fixed" v-if="item.type == 'checkbox'"
+            :key="index" />
+          <el-table-column :align="item.align" :prop="item.field" :label="item.title" :width="item.width"
+            :key="item.sorderid" v-else-if="!item.hide && item.type != 'checkbox'" :sortable="item.sort"
+            show-overflow-tooltip :fixed="item.fixed">
+            <template slot-scope="{row,  column }">
+              <el-checkbox v-model="checked" v-if="item.type == 'checkbox'"></el-checkbox>
+              <div :style="item.style">{{ row[column.label] }}</div>
+            </template>
+          </el-table-column>
+        </template>
+      </el-table>
+      <pagination v-show="total > 0" :total="total" :page.sync="page" :limit.sync="pageSize" :pageSizes="pageSizes"
+        @pagination="currentPage" />
+      <el-dialog title="闅愯棌鍒楄缃�" :visible.sync="openRowHide" width="816px" append-to-body>
+        <RowSettings :colName="btResList" :HModName="HModName" @rowEditClose="rowSetClose" v-if="rowHideShow" />
+      </el-dialog>
+      <!-- 缂栬緫 -->
+      <el-dialog title="鏂板/b缂栬緫鐢ㄦ埛" :visible.sync="openEdit" width="1480px" append-to-body class="xsckdBox" @close="close">
+        <edit :OperationType=OperationType :linterid=this.rowForm.HEmpID :HSouceBillType=this.rowForm.HSourceBillType
+          :copyType="copyType" @editCloseGy="editGyClose" v-if="editShow" />
+      </el-dialog>
+    </div>
+  </div>
+</template>
+
+<script>
+import axios from 'axios'
+import RowSettings from '@/views/component/rowSettings'
+import Edit from '@/views/basic/production/gySourceEdit.vue'
+
+export default {
+  name: 'XtUserList',
+  components: { RowSettings, Edit },
+  props: {
+    openPage: { type: String, },
+  },
+  data() {
+    return {
+      activeSeach: '',
+      HModName: 'Xt_UserList',
+      editShow: false,
+      openEdit: false,
+      totalNameList: [],
+      tableShow: true,
+      openPrintList: false,
+      printListShow: false,
+      HBillType: '1205',
+      openBtnHide: false,
+      btnHideShow: false,
+      rowHideShow: false,
+      openRowHide: false,
+      copyType: 0,
+      comparatorList: [
+        { label: '=', value: '=' },
+        { label: '>=', value: '>=' },
+        { label: '>', value: '>' },
+        { label: '<=', value: '<=' },
+        { label: '<', value: '<' },
+        { label: '<>', value: '<>' },
+        { label: '鍖呭惈', value: '7' },
+        { label: '宸﹀寘鍚�', value: '8' },
+        { label: '鍙冲寘鍚�', value: '9' },
+        { label: '涓嶅寘鍚�', value: '10' },
+      ],
+      sWhere: '',
+      dialogTitle: '',
+      organizationList: JSON.parse(sessionStorage.getItem('organizationList')),//缁勭粐鍒楄〃
+      OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
+      HInterID: null,
+      baseURL: process.env.VUE_APP_BASE_API,
+      lastSelectedRowIndex: null, // 鐢ㄤ簬璁板綍涓婃鐐瑰嚮鐨勮绱㈠紩
+      lastSelectedRow: null, // 涓婁竴娆¢�変腑鐨勮
+      selectedRow: null, // 褰撳墠閫変腑鐨勮
+      rowForm: {},
+      activeName: 'first',
+
+      // 寮瑰嚭灞傛爣棰�
+      title: "",
+      // 鏄惁鏄剧ず寮瑰嚭灞�
+      open: false,
+      // 鏌ヨ鍙傛暟
+      queryParams: {
+        HUSEORGID: null,
+        HName: null,
+        HNumber: null,
+        Comparator1: '',
+        Comparator2: '',
+        Comparator: '',
+        ColContent1: '',
+        ColContent2: '',
+        ColContent: '',
+      },
+      // 閫変腑鏁扮粍
+      ids: [],
+      // 闈炲崟涓鐢�
+      single: true,
+      // 闈炲涓鐢�
+      multiple: true,
+      // 閬僵灞�
+      loading: true,
+      tyResList: [],//鍒楄〃锛堟帴鍙f暟鎹級
+      btList: [
+        { type: 'checkbox', fixed: 'left' }
+        , { field: 'hmainid', title: '鍗曟嵁ID', hide: true }
+        , { field: '鐢ㄦ埛缂栫爜', title: '鐢ㄦ埛缂栫爜' }
+        , { field: '鐢ㄦ埛鍚嶇О', title: '鐢ㄦ埛鍚嶇О' }
+        , { field: '鐢ㄦ埛绫诲瀷', title: '鐢ㄦ埛绫诲瀷' }
+        , { field: '瀵瑰簲鐝粍', title: '瀵瑰簲鐝粍' }
+        , { field: '瀵瑰簲鑱屽憳', title: '瀵瑰簲鑱屽憳' }
+        , { field: '瀵瑰簲淇濈', title: '瀵瑰簲淇濈' }
+        , { field: '瀵瑰簲楠屾敹', title: '瀵瑰簲楠屾敹' }
+        , { field: '瀵瑰簲涓氬姟鍛�', title: '瀵瑰簲涓氬姟鍛�' }
+        , { field: '瀵瑰簲閮ㄩ棬', title: '瀵瑰簲閮ㄩ棬' }
+        , { field: '瀵瑰簲浠撳簱', title: '瀵瑰簲浠撳簱' }
+        , { field: '瀵瑰簲璋冨叆浠撳簱', title: '瀵瑰簲璋冨叆浠撳簱' }
+        , { field: '瀵瑰簲渚涘簲鍟�', title: '瀵瑰簲渚涘簲鍟�' }
+        , { field: '瀵瑰簲CLOUD璐﹀彿', title: '瀵瑰簲CLOUD璐﹀彿' }
+        , { field: '瀵瑰簲CLOUD缁勭粐', title: '瀵瑰簲CLOUD缁勭粐' }
+      ],//琛ㄥご鍒楄〃鏄剧ず
+      btResList: [],
+      tableData: [],//鍒楄〃(鍒嗛〉鏄剧ず)
+      allTableData: [],
+      dataList: [],
+      titleData: [],//涓嶉渶瑕佹樉绀虹殑瀛楁鍙墿灞�
+      pageSizes: [50, 100, 500, 5000, 50000],
+      page: 1,
+      pageSize: 0,
+      total: 0,
+      // 琛ㄥ崟鍙傛暟
+      form: {},
+      // 琛ㄥ崟鏍¢獙
+      rules: {
+        HSupName: [
+          { required: true, message: "瀹㈡埛涓嶈兘涓虹┖", trigger: "blur" }
+        ],
+        HDate: [
+          { required: true, message: "鏃ユ湡涓嶈兘涓虹┖", trigger: "blur" }
+        ],
+        HExRate: [
+          { required: true, message: "姹囩巼涓嶈兘涓虹┖", trigger: "blur" }
+        ]
+      },
+      upload: {
+        // 鏄惁鏄剧ず寮瑰嚭灞�
+        open: false,
+        // 寮瑰嚭灞傛爣棰�
+        title: "",
+        // 鏄惁绂佺敤涓婁紶
+        isUploading: false,
+        // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勬暟鎹�
+        updateSupport: 0,
+        // 璁剧疆涓婁紶鐨勮姹傚ご閮�
+        // headers: { Authorization: "Bearer " + getToken() },
+        // 涓婁紶鐨勫湴鍧�
+        url: process.env.VUE_APP_BASE_API + "/Gy_Source/Gy_Source_Excel"
+      },
+      uploadData: [],
+      alluploadList: [],
+      uploadTableLoading: false,
+      uploadPageSizes: [50, 100, 500, 5000, 50000],
+      uploadPage: 1,
+      uploadPageSize: 50,
+      uploadTotal: 0,
+    };
+  },
+  created() {
+    this.getList()
+  },
+  methods: {
+    getSummaries(param) {
+      const { columns, data } = param;
+      const sums = [];
+      columns.forEach((column, index) => {
+        if (index === 0) {
+          sums[index] = '鍚堣';
+          return;
+        }
+        const values = data.map(item => Number(item[column.property]));
+        if (this.totalNameList[index].totalRow) {
+          if (!values.every(value => isNaN(value))) {
+            sums[index] = values.reduce((prev, curr) => {
+              const value = Number(curr);
+              if (!isNaN(value)) {
+                return prev + curr;
+              } else {
+                return prev;
+              }
+            }, 0)
+
+          } else {
+            sums[index] = '';
+          }
+        }
+      }, 1000);
+      return sums;
+    },
+
+    handleBtnHide() {
+      this.btnHideShow = true
+      this.openBtnHide = true
+    },
+    handleRowHide() {
+      this.rowHideShow = true
+      this.openRowHide = true
+    },
+    rowSetClose(val) {
+      this.rowHideShow = false
+      this.tableShow = true
+      this.openRowHide = val
+      this.getList()
+    },
+    //鍒楄〃鏁版嵁
+    getList() {
+      this.pageSize = 50
+      this.tableShow = false
+      this.loading = true
+      if (this.pageSize == 0) {
+        this.pageSize = 50
+      }
+      this.queryParams.HUSEORGID = sessionStorage["OrganizationID"] - 0
+      // this.sWhere += " and HUSEORGID = '" + this.queryParams.HUSEORGID + "'"
+      //鍒楄〃
+      axios.get(this.baseURL + '/Xt_User/list', {
+        params: {
+          "sWhere": this.sWhere,
+          "user": sessionStorage["HUserName"],
+        },
+      }).then(response => {
+        this.tyResList = response.data.data//鎬绘暟鎹�
+        let data1 = response.data
+        this.allTableData = data1.data
+        let option = []
+        if (data1.code == 1) {
+          this.total = data1.data.length;
+          for (var i = 1; i < this.btList.length; i++) {
+            this.btResList.push({ ColmCols: this.btList[i].field})
+          }
+          var col = [];
+          col = this.btList
+          option.cols = [col]
+          this.dataList = option
+          option.data = data1.data;
+          var result = data1.data;
+          option.data = result;
+          this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
+        }
+      }).catch(error => {
+        this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+      });
+    },
+    DisPlay_HideColumn(HModName, user, option, dataOption) {
+      this.totalNameList = []
+      axios.get(this.baseURL + '/Xt_grdAlignment_WMES/grdAlignmentWMESList', {
+        params: {
+          "HModName": HModName,
+          "user": user,
+        },
+      }).then(res => {
+        let data1 = res.data
+        if (data1.data.length != 0) {
+          var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
+          var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+          newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
+          dataCol = data1.data[0].HGridString.split(',');
+          //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+          if (dataCol.length == option.cols[0].length - 1) {
+            //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+            for (var j = 0; j < option.cols[0].length - 1; j++) {
+              for (var i = 0; i < option.cols[0].length - 1; i++) {
+                var dataCols = dataCol[j].split('|');
+                //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+                if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+                  //闅愯棌鍒�
+                  if (dataCols[1] == 1) {
+                    option.cols[0][i + 1]["hide"] = true;
+                  }
+                  //璁剧疆鍒楀
+                  if (dataCols[3] > 0) {
+                    option.cols[0][i + 1]["width"] = dataCols[3];
+                  }
+                  //璁剧疆鍐呭瀛椾綋澶у皬
+                  if (data1.data[0].HFontSize != 0) {
+                    option.cols[0][i + 1]["style"] = "font-size:" + data1.data[0].HFontSize + "px;";
+                  } else {
+                    option.cols[0][i + 1]["style"] = "font-size:100%";
+                  }
+                  //鏄剧ず鍒�
+                  if (dataCols[1] == 0 && this.titleData.indexOf(option.cols[0][i + 1]["title"]) == -1) {
+                    option.cols[0][i + 1]["hide"] = false;
+                  }
+                  //缁熻鍒�
+                  if (dataCols[6] == 1) {
+                    option.cols[0][i + 1]["totalRow"] = true;
+                  } else {
+                    option.cols[0][i + 1]["totalRow"] = false;
+                  }
+                  //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+                  switch (dataCols[2]) {
+                    case "L":
+                      option.cols[0][i + 1]["align"] = "left";
+                      break;
+                    case "M":
+                      option.cols[0][i + 1]["align"] = "center";
+                      break;
+                    case "R":
+                      option.cols[0][i + 1]["align"] = "right";
+                      break;
+                  }
+                  //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+                  if (dataCols[4] != null && dataCols[4] != "") {
+                    option.cols[0][i + 1]["title"] = dataCols[4];
+                  }
+                  newCols[0].push(option.cols[0][i + 1]);
+                  break;
+                }
+              }
+            }
+            //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+            if (dataCol.length == newCols[0].length - 1) {
+              option.cols = newCols;
+              //鍙栨秷鍐荤粨鍒�
+              for (var i = 1; i < option.cols[0].length - 1; i++) {
+                if (option.cols[0][i + 1]["fixed"] != null) {
+                  option.cols[0][i + 1]["fixed"] = null;
+                }
+                else {
+                  break;
+                }
+              }
+              //鍐荤粨鍒�
+              if (data1.data[0].HFixCols != 0) {
+                for (var i = 0; i < data1.data[0].HFixCols; i++) {
+                  if (dataOption.cols[0].indexOf(option.cols[0][i + 1]["title"]) != -1) {
+                    data1.data[0].HFixCols += 1;
+                  }
+
+                  option.cols[0][i + 1]["fixed"] = "left";
+                }
+              }
+              //璁剧疆鍒楁帓搴�
+              for (var i = 1; i < option.cols[0].length; i++) {
+                if (data1.data[0].HSortFlag == "鏄�") {
+                  option.cols[0][i]["sort"] = true;
+                }
+                else {
+                  option.cols[0][i]["sort"] = false;
+                }
+              }
+            }
+          }
+          this.btList = option.cols[0]
+          this.btList.map(item => {
+            if (!item.hide) {
+              this.totalNameList.push(item)
+            }
+          })
+          if (data1.data[0].HPageSize == 0) {
+            this.pageSize = 50
+          } else {
+            this.pageSize = data1.data[0].HPageSize
+          }
+          this.allTableData = option.data//鏃犲垎椤垫帴鍙e垎椤�
+          this.tableData = this.getPage(this.page, this.allTableData)//鏃犲垎椤垫帴鍙e垎椤�
+          this.tableShow = true
+          this.loading = false
+        } else {
+          this.btList = dataOption.cols[0]
+          this.btList.map(item => {
+            if (!item.hide) {
+              this.totalNameList.push(item)
+            }
+          })
+          this.allTableData = dataOption.data//鏃犲垎椤垫帴鍙e垎椤�
+          this.tableData = this.getPage(this.page, this.allTableData)//鏃犲垎椤垫帴鍙e垎椤�
+          this.tableShow = true
+          this.loading = false
+        }        
+      }).catch(error => {
+        this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+      });
+    },
+    renderHeader(h, { column, $index }) {// 鏂板缓涓�涓� span
+      let span = document.createElement(span)// 璁剧疆琛ㄥご鍚嶇О
+      span.innerText = column.label
+      //涓存椂鎻掑叆 document
+      document.body.appendChild(span)// 閲嶇偣:鑾峰彇 span 鏈�灏忓搴︼紝璁剧疆褰撳墠鍒楋紝娉ㄦ剰杩欓噷鍔犱簡 20锛屽瓧娈佃緝澶氭椂column.minWidth=span.getBoundingClientRect().width + 50.//绉婚櫎 document 涓复鏃剁殑 span
+      document.body.removeChild(span)
+      return h(span, column.label)
+    },
+    //鐐瑰嚮琛�
+    handleRowClick(row, column, event) {
+      this.lastSelectedRow = this.selectedRow; // 璁板綍涓婁竴娆¢�変腑鐨勮
+      this.selectedRow = row; // 璁板綍褰撳墠閫変腑鐨勮
+      this.lastSelectedRowIndex = this.tableData.indexOf(row);
+      this.$refs.tableData.toggleRowSelection(row);
+    },
+    //閫変腑琛岄珮浜牱寮�
+    rowStyle({ row, rowIndex }) {
+      if (this.ids.includes(row.HEmpID)) {
+        return { "background": "#ecf5ff" }
+      }
+    },
+    //鍙屽嚮琛�
+    handleDblclick(row, column, cell, event) {
+      this.OperationType = 3
+      this.handleEdit()
+    },
+    // 澶氶�夋閫変腑鏁版嵁
+    handleSelectionChange(selection) {
+      // this.rowForm = {}
+      this.ids = selection.map(item => item.HEmpID)
+      this.single = selection.length != 1
+      this.multiple = !selection.length
+      if (!this.single) {
+        this.rowForm = selection[0]
+      }
+    },
+    /** 鎼滅储鎸夐挳鎿嶄綔 */
+    handleQuery() {
+      this.sWhere = ''
+      if (this.queryParams.ColName && this.queryParams.Comparator) {
+        var com = "";
+        switch (this.queryParams.Comparator) {
+          case "7":
+            com = "like'%" + this.queryParams.ColContent + "%'";
+            break;
+          case "8":
+            com = "like'%" + this.queryParams.ColContent + "'";
+            break;
+          case "9":
+            com = "like'" + this.queryParams.ColContent + "%'";
+            break;
+          case "10":
+            com = "not like'%" + this.queryParams.ColContent + "%'";
+            break;
+          default:
+            com = "" + this.queryParams.Comparator + "'" + this.queryParams.ColContent + "'";
+            break;
+        }
+        this.sWhere += " and " + this.queryParams.ColName + " " + com;
+      }
+      if (this.queryParams.ColName1 && this.queryParams.Comparator1) {
+        var com1 = "";
+        switch (this.queryParams.Comparator1) {
+          case "7":
+            com1 = "like'%" + this.queryParams.ColContent1 + "%'";
+            break;
+          case "8":
+            com1 = "like'%" + this.queryParams.ColContent1 + "'";
+            break;
+          case "9":
+            com1 = "like'" + this.queryParams.ColContent1 + "%'";
+            break;
+          case "10":
+            com1 = "not like'%" + this.queryParams.ColContent1 + "%'";
+            break;
+          default:
+            com1 = "" + this.queryParams.Comparator1 + "'" + this.queryParams.ColContent1 + "'";
+            break;
+        }
+        this.sWhere += " and " + this.queryParams.ColName1 + " " + com1;
+      }
+      if (this.queryParams.ColName2 && this.queryParams.Comparator2) {
+        var com2 = "";
+        switch (this.queryParams.Comparator2) {
+          case "7":
+            com2 = "like'%" + this.queryParams.ColContent2 + "%'";
+            break;
+          case "8":
+            com2 = "like'%" + this.queryParams.ColContent2 + "'";
+            break;
+          case "9":
+            com2 = "like'" + this.queryParams.ColContent2 + "%'";
+            break;
+          case "10":
+            com2 = "not like'%" + this.queryParams.ColContent2 + "%'";
+            break;
+          default:
+            com2 = "" + this.queryParams.Comparator + "'" + this.queryParams.ColContent + "'";
+            break;
+        }
+        this.sWhere += " and " + this.queryParams.ColName2 + " " + com2;
+      }
+      if (this.queryParams.HNumber) {
+        this.sWhere += " and 鐢ㄦ埛缂栫爜 like '%" + this.queryParams.HNumber + "%'";
+      }
+      if (this.queryParams.HName) {
+        this.sWhere += " and 鐢ㄦ埛鍚嶇О like '%" + this.queryParams.HName + "%'";
+      }
+      // if (this.queryParams.HUSEORGID) {
+      //   this.sWhere += " and HUSEORGID = '" + this.queryParams.HUSEORGID + "'"
+      // }
+      // this.sWhere += this.addSWhereByOpenType()
+      // this.sWhere += this.getOrgIDByUser()
+      this.getList()
+
+    },
+    // 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+    addSWhereByOpenType() {
+      //鑾峰彇鍙傛暟
+      var sWhere = "";
+      //this.openPage鍒ゆ柇鏄惁鏈夊�硷紝鏈変唬琛ㄥ叾瀹冮〉闈㈤�氳繃閫夋嫨鎸夐挳鎵撳紑
+      if (this.openPage) {
+        sWhere += " and 绂佺敤鏍囪 != 'Y' and ISNULL(瀹℃牳浜�,'')  != ''"
+        return sWhere;
+      }
+      return sWhere;
+    },
+    //鏍规嵁鐢ㄦ埛鑾峰彇鐢ㄦ埛鍏宠仈缁勭粐鐨勮繃婊ゆ潯浠�
+    getOrgIDByUser() {
+      var res = "";
+      axios.get(this.baseURL + '/Xt_User/getOrgIDListByUser', {
+        params: {
+          HModName: this.HModName,
+          user: sessionStorage["HUserName"],
+          HOrgID: sessionStorage["OrganizationID"]
+        },
+      }).then(response => {
+        let result = response.data
+        if (result.count == 1) {
+          if (result.data[0].sWhere == "1") {
+            res = " and HUSEORGID = '" + sessionStorage["OrganizationID"] + "'";
+          } else {
+            res = result.data[0].sWhere;
+          }
+        }
+      }).catch(error => {
+        res = " and 1 = 0";
+        this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+      });
+      return res;
+    },
+    /** 閲嶇疆鎸夐挳鎿嶄綔 */
+    resetQuery() {
+      this.sWhere = ''
+      this.queryParams = {
+        // HOrgID: null,
+        HName: null,
+        HNumber: null,
+        Comparator1: '',
+        Comparator2: '',
+        Comparator: '',
+        ColContent1: '',
+        ColContent2: '',
+        ColContent: '',
+      }
+      this.resetForm("queryForm")
+      this.getList()
+    },
+
+    //閫�鍑�
+    close() {
+      this.tableShow = true
+      this.openEdit = false
+      this.editShow = false
+      this.getList()
+    },
+    //鎵撳紑鏂板缁勪欢寮圭獥
+    handleAddEdit() {
+      this.rowForm.HEmpID = 0
+      this.$nextTick(() => {
+        this.openEdit = true
+        this.editShow = true
+      })
+
+    },
+    //鎵撳紑淇敼缁勪欢寮圭獥
+    handleEdit() {
+      this.$nextTick(() => {
+        this.openEdit = true
+        this.editShow = true
+      })
+    },
+    //鍏抽棴缂栬緫椤甸潰
+    editGyClose(val) {
+      this.editShow = false
+      this.openEdit = false
+      this.multiple = true,
+        this.getList()
+    },
+    /** 鍒犻櫎鎸夐挳鎿嶄綔 */
+    handleDelete() {
+      this.$modal.confirm('纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠').then(() => {
+         var HCzybm = this.rowForm.鐢ㄦ埛缂栫爜.toString();
+          axios.get(this.baseURL + "/Xt_User/DeltetUser", {
+            params: { "HCzybm": HCzybm }
+          }).then(response => {
+            if (response.data.count == 1) {
+              this.getList()
+              this.$modal.msgSuccess("鍒犻櫎鎴愬姛")
+            } else {
+              this.$modal.msgError("閿欒:" + result.code + result.Message);
+            }
+          }).catch(error => {
+            this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+          });
+      }).catch(() => { })
+    },
+    //瀵煎嚭
+    handleExport() {
+      const ws = this.$XLSX.utils.json_to_sheet(this.tyResList); // 灏嗘暟鎹浆鎹负宸ヤ綔琛�
+      const wb = this.$XLSX.utils.book_new(); // 鍒涘缓涓�涓柊鐨勫伐浣滅翱
+      this.$XLSX.utils.book_append_sheet(wb, ws, "Sheet1"); // 灏嗗伐浣滆〃娣诲姞鍒板伐浣滅翱涓紝骞跺懡鍚嶄负"Sheet1"
+      this.$XLSX.writeFile(wb, `xtUsetList_${new Date().getTime()}.xlsx`); // 瀵煎嚭鏂囦欢      
+    },   
+    getPage(page, list) {
+      let sindex = (parseInt(page) - 1) * this.pageSize
+      let eindex = parseInt(page) * this.pageSize
+      let newList = list.slice(sindex, eindex)
+      console.log(newList)
+      return newList
+    },
+    currentPage(val) {
+      console.log(val)
+      this.page = val.page
+      setTimeout(() => {
+        this.tableData = this.getPage(this.page, this.allTableData)
+      }, 100)
+    },
+  }
+};
+</script>
+<style>
+.xsckdBox .el-date-editor.el-input {
+  width: 100%;
+}
+</style>

--
Gitblit v1.9.1