From cfd0b53967daca92d98cd304e4d4e0577e2efbd3 Mon Sep 17 00:00:00 2001
From: chenhaozhe <cgz@hz-kingdee.com>
Date: 星期二, 13 一月 2026 13:27:45 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-VUEUI
---
src/views/scMould/basicModeling/Gy_MouldFile.vue | 20
src/views/scMould/warehouse/Sc_MouldOutRequestBillList.vue | 2
src/views/scMould/warehouse/Sc_MouldProdBackBillEdit.vue | 18
src/views/scMould/warehouse/Sc_MouldProdOutBillEdit.vue | 18
src/views/basic/gyCurrency/gyCurrencyEdit.vue | 336 +++
src/views/scMould/warehouse/Sc_MouldProdMoveBillList.vue | 11
src/views/basic/gyUnit/gyUnit.vue | 1560 +++++++++++++++
src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillList.vue | 2
src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue | 10
src/views/scMould/basicModeling/Gy_MouldFileList.vue | 157
src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillEdit.vue | 16
src/store/modules/permission.js | 99
src/router/index.js | 125 +
src/views/basic/gyUnit/gyUnitEdit.vue | 625 ++++++
src/views/basic/gyUnit/gyUnitGroup.vue | 289 ++
src/views/scMould/warehouse/Sc_MouldProdMoveBillEdit.vue | 17
.env.development | 4
src/views/basic/gyCurrency/gyCurrency.vue | 1686 ++++++++++++++++
src/views/logistics/transportGPS/WL_YayBill.vue | 912 +++++++++
src/views/scMould/warehouse/Sc_MouldInRequestBillList.vue | 2
src/views/logistics/transportGPS/Add_Edit_WL_YayBill.vue | 10
src/views/scMould/warehouse/Sc_MouldInRequestBillEdit.vue | 16
src/views/scMould/warehouse/Sc_MouldOutRequestBillEdit.vue | 18
src/views/scMould/warehouse/Sc_MouldProdOutBillList.vue | 10
24 files changed, 5,846 insertions(+), 117 deletions(-)
diff --git a/.env.development b/.env.development
index 2c94c9c..8d8d39f 100644
--- a/.env.development
+++ b/.env.development
@@ -5,8 +5,8 @@
ENV = 'development'
# 鏅轰簯杩堟�滾-MOM绠$悊绯荤粺/寮�鍙戠幆澧�
-VUE_APP_BASE_API = 'http://localhost:81/API/'
-# VUE_APP_BASE_API = 'http://47.96.97.237/API/'
+# VUE_APP_BASE_API = 'http://localhost:81/API/'
+VUE_APP_BASE_API = 'http://47.96.97.237/API/'
# VUE_APP_BASE_API = 'http://220.189.218.155:9010/API/'
# VUE_APP_BASE_API = 'http://localhost:8082/LuBaoAPI/'
# VUE_APP_BASE_API = 'http://192.168.1.11/API/'
diff --git a/src/router/index.js b/src/router/index.js
index 9be7e6f..7cdaf7a 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -1573,6 +1573,54 @@
//#endregion
//#endregion
+//#region 璐㈠姟缁撶畻鍩虹璧勬枡
+//#region 璐у竵鍒楄〃
+ {
+ //src\views\basic\gyItemMoney\gyItemMoney.vue
+ path: "/basic/gy/gyCurrency",
+ component: Layout,
+ hidden: true,
+ redirect: "noredirect",
+ meta: {
+ breadcrumb: false, // 濡傛灉璁剧疆涓篺alse锛屽垯涓嶄細鍦╞readcrumb闈㈠寘灞戜腑鏄剧ず
+ activeMenu: "/basic/gy", // 褰撹矾鐢辫缃簡璇ュ睘鎬э紝鍒欎細楂樹寒鐩稿搴旂殑渚ц竟鏍忋��
+ },
+ children: [
+ {
+ path: "/basic/gy/gyCurrency",
+ component: () => import("@/views/basic/gyCurrency/gyCurrency.vue"),
+ name: "GyCurrency",
+ meta: { title: "璐у竵鍒楄〃", activeMenu: "basic/gy" },
+ },
+ ],
+ },
+//#endregion
+//#endregion
+
+//#region 鍗曚綅鍩虹璧勬枡
+//#region 璁¢噺鍗曚綅鍒楄〃
+ {
+ //src\views\basic\gyUnit\gyUnit.vue
+ path: "/basic/gy/gyUnit",
+ component: Layout,
+ hidden: true,
+ redirect: "noredirect",
+ meta: {
+ breadcrumb: false, // 濡傛灉璁剧疆涓篺alse锛屽垯涓嶄細鍦╞readcrumb闈㈠寘灞戜腑鏄剧ず
+ activeMenu: "/basic/gy", // 褰撹矾鐢辫缃簡璇ュ睘鎬э紝鍒欎細楂樹寒鐩稿搴旂殑渚ц竟鏍忋��
+ },
+ children: [
+ {
+ path: "/basic/gy/gyUnit",
+ component: () => import("@/views/basic/gyUnit/gyUnit.vue"),
+ name: "GyCurrency",
+ meta: { title: "璁¢噺鍗曚綅鍒楄〃", activeMenu: "basic/gy" },
+ },
+ ],
+ },
+//#endregion
+//#endregion
+
//#region 杈呭姪灞炴�у熀纭�璧勬枡
{
//src\views\basic\gyItemMoney\gyItemMoney.vue
@@ -1679,6 +1727,39 @@
meta: { title: "浠撳簱鍒楄〃", noCache: true, noLoading: true },
},
{
+ path: "GyCurrency",
+ component: () => import("@/views/basic/gyCurrency/gyCurrency"), // 璐у竵鍒楄〃
+ name: "IframeGyCurrency",
+ meta: { title: "璐у竵鍒楄〃", noCache: true, noLoading: true },
+ },
+ {
+ path: "GyCurrencyEdit",
+ component: () => import("@/views/basic/gyCurrency/gyCurrencyEdit"), // 璐у竵缂栬緫
+ name: "IframeGyCurrencyEdit",
+ meta: { title: "璐у竵鍒楄〃", noCache: true, noLoading: true },
+ },
+ {
+ path: "GyUnit",
+ component: () => import("@/views/basic/gyUnit/gyUnit"),
+
+ name: "IframeGyUnit",
+ meta: { title: "璁¢噺鍗曚綅鍒楄〃", noCache: true, noLoading: true },
+ },
+ {
+ path: "GyUnitEdit",
+ component: () => import("@/views/basic/gyUnit/gyUnitEdit"), // 璁¢噺鍗曚綅缂栬緫
+ name: "IframeGyUnitEdit",
+ meta: { title: "璁¢噺鍗曚綅缂栬緫", noCache: true, noLoading: true },
+
+ },
+ {
+ path: "GyUnitGroup",
+ component: () => import("@/views/basic/gyUnit/gyUnitGroup"), // 璁¢噺鍗曚綅缁勫垪琛�
+ name: "IframeGyUnitGroup",
+ meta: { title: "璁¢噺鍗曚綅缁勫垪琛�", noCache: true, noLoading: true },
+
+ },
+ {
path: "GySupplier",
component: () => import("@/views/basic/gy/gySupplier"), // 渚涘簲鍟�
name: "IframeGySupplier",
@@ -1702,6 +1783,7 @@
name: "IframeGyCarEdit",
meta: { title: "杞﹁締缂栬緫", noCache: true, noLoading: true },
},
+
{
path: "GyProperty",
component: () => import("@/views/basic/gyProperty/gyPropertyList"), // 杈呭姪灞炴��
@@ -1717,6 +1799,49 @@
],
},
//#endregion
+
+ //#region 鐗╂祦绠$悊
+ //#region 杩愯緭瀹氫綅
+ //#region 杩愬崟鍒楄〃
+ {
+ path: "logistics/transportGPS/WL_YayBill",
+ component: Layout,
+ hidden: true,
+ redirect: "noredirect",
+ meta: {
+ breadcrumb: false, // 濡傛灉璁剧疆涓篺alse锛屽垯涓嶄細鍦╞readcrumb闈㈠寘灞戜腑鏄剧ず
+ activeMenu: "/logistics/transportGPS", // 褰撹矾鐢辫缃簡璇ュ睘鎬э紝鍒欎細楂樹寒鐩稿搴旂殑渚ц竟鏍忋��
+ },
+ children: [
+ {
+ path: "/logistics/transportGPS/WL_YayBill",
+ component: () => import("@/views/logistics/transportGPS/WL_YayBill.vue"),
+ name: "WL_YayBill",
+ meta: { title: "鍑鸿繍鍗�", activeMenu: "logistics/transportGPS" },
+ },
+ ],
+ },
+ //#endregion
+ //#region 杩愬崟缂栬緫
+ {
+ path: "logistics/transportGPS/Add_Edit_WL_YayBill",
+ component: Layout,
+ hidden: true,
+ redirect: "noredirect",
+ meta: {
+ breadcrumb: false, // 濡傛灉璁剧疆涓篺alse锛屽垯涓嶄細鍦╞readcrumb闈㈠寘灞戜腑鏄剧ず
+ activeMenu: "/logistics/transportGPS", // 褰撹矾鐢辫缃簡璇ュ睘鎬э紝鍒欎細楂樹寒鐩稿搴旂殑渚ц竟鏍忋��
+ },
+ children: [
+ {
+ path: "/logistics/transportGPS/Add_Edit_WL_YayBill",
+ component: () => import("@/views/logistics/transportGPS/Add_Edit_WL_YayBill.vue"),
+ name: "Add_Edit_WL_YayBill",
+ meta: { title: "杩愬崟缂栬緫", activeMenu: "logistics/transportGPS" },
+ },
+ ],
+ },
+ //#endregion
];
// 鍔ㄦ�佽矾鐢憋紝鍩轰簬鐢ㄦ埛鏉冮檺鍔ㄦ�佸幓鍔犺浇
diff --git a/src/store/modules/permission.js b/src/store/modules/permission.js
index a620b50..d4cc6e6 100644
--- a/src/store/modules/permission.js
+++ b/src/store/modules/permission.js
@@ -41,6 +41,63 @@
icon: "build",
link: null,
noCache: false,
+ title: "鐗╂祦绠$悊",
+ },
+ hidden: false,
+ name: "Logistics",
+ path: "/logistics",
+ redirect: "noRedirect",
+ children: [
+ {
+ meta: {
+ icon: "build",
+ link: null,
+ noCache: false,
+ title: "杩愯緭瀹氫綅",
+ },
+ hidden: false,
+ name: "TransportGPS",
+ path: "transportGPS",
+ redirect: "noRedirect",
+ component: "Layout",
+ children: [
+ {
+ meta: {
+ icon: "build",
+ link: null,
+ noCache: false,
+ title: "鍑鸿繍鍗�",
+ },
+ component: () =>
+ import("@/views/logistics/transportGPS/WL_YayBill.vue"),
+ hidden: false,
+ name: "WL_YayBill",
+ path: "WL_YayBill",
+ },
+ // {
+ // meta: {
+ // icon: "build",
+ // link: null,
+ // noCache: false,
+ // title: "杩愬崟缂栬緫",
+ // },
+ // component: () =>
+ // import("@/views/logistics/transportGPS/Add_Edit_WL_YayBill.vue"),
+ // hidden: false,
+ // name: "Add_Edit_WL_YayBill",
+ // path: "Add_Edit_WL_YayBill",
+ // },
+ ],
+ },
+ ],
+ },
+ {
+ alwaysShow: true,
+ component: "Layout",
+ meta: {
+ icon: "build",
+ link: null,
+ noCache: false,
title: "閿�鍞鐞�",
},
hidden: false,
@@ -520,7 +577,9 @@
title: "鎵胯繍鍚堝悓鍗曟嵁",
},
component: () =>
- import("@/views/basic/gytransport/cgContractTransportBillList/Cg_ContractTransportBillList.vue"),
+ import(
+ "@/views/basic/gytransport/cgContractTransportBillList/Cg_ContractTransportBillList.vue"
+ ),
hidden: false,
name: "CgContractTransportBillList",
path: "cgContractTransportBillList",
@@ -579,7 +638,7 @@
name: "GyCartypelist",
path: "gyCartypelist",
},
- {
+ {
meta: {
icon: "build",
link: null,
@@ -636,6 +695,33 @@
icon: "build",
link: null,
noCache: false,
+ title: "璐у竵鍒楄〃",
+ },
+ component: () =>
+ import("@/views/basic/gyCurrency/gyCurrency.vue"),
+ hidden: false,
+ name: "GyCurrency",
+ path: "gyCurrency",
+ },
+
+ {
+ meta: {
+ icon: "build",
+ link: null,
+ noCache: false,
+ title: "璁¢噺鍗曚綅鍒楄〃",
+ },
+ component: () => import("@/views/basic/gyUnit/gyUnit.vue"),
+ hidden: false,
+ name: "GyUnit",
+ path: "gyUnit",
+ },
+
+ {
+ meta: {
+ icon: "build",
+ link: null,
+ noCache: false,
title: "渚涘簲鍟嗗垪琛�",
},
component: () => import("@/views/basic/gy/gySupplier.vue"),
@@ -675,7 +761,8 @@
noCache: false,
title: "杈呭姪灞炴�у垪琛�",
},
- component: () => import("@/views/basic/gyProperty/gyPropertyList.vue"),
+ component: () =>
+ import("@/views/basic/gyProperty/gyPropertyList.vue"),
hidden: false,
name: "GyProperty",
path: "gyProperty",
@@ -888,7 +975,7 @@
hidden: false,
name: "Kf_POStockInBackBillList",
path: "Kf_POStockInBackBillList",
- query: "{\"type\":1}"
+ query: '{"type":1}',
},
{
meta: {
@@ -904,7 +991,7 @@
hidden: false,
name: "Kf_POStockInBackBillList",
path: "Kf_POStockInBackBillList0",
- query: "{\"type\":0}"
+ query: '{"type":0}',
},
],
},
@@ -1422,7 +1509,7 @@
noCache: false,
title: "椹鹃┒鍛樺垪琛�",
},
- component: () =>import("@/views/system/user/GyDriver.vue"),
+ component: () => import("@/views/system/user/GyDriver.vue"),
hidden: false,
name: "gyDriver",
path: "GyDriver",
diff --git a/src/views/basic/gyCurrency/gyCurrency.vue b/src/views/basic/gyCurrency/gyCurrency.vue
new file mode 100644
index 0000000..84d8f57
--- /dev/null
+++ b/src/views/basic/gyCurrency/gyCurrency.vue
@@ -0,0 +1,1686 @@
+<template>
+ <div style="padding: 10px">
+ <el-form
+ :model="queryParams"
+ ref="queryForm"
+ size="small"
+ :inline="true"
+ label-width="78px"
+ class="searchBox"
+ >
+ <el-row>
+ <el-form-item label="寮�濮嬫棩鏈�" style="margin-left: 100px">
+ <el-date-picker
+ v-model="sTime"
+ type="date"
+ placeholder="寮�濮嬫棩鏈�"
+ style="width: 150px"
+ :disabled="queryParams.HInitTimeCycle != -1"
+ value-format="yyyy-MM-dd"
+ >
+ </el-date-picker>
+ </el-form-item>
+ <el-form-item label="缁撴潫鏃ユ湡">
+ <el-date-picker
+ v-model="eTime"
+ type="date"
+ placeholder="缁撴潫鏃ユ湡"
+ style="width: 150px"
+ :disabled="queryParams.HInitTimeCycle != -1"
+ value-format="yyyy-MM-dd"
+ >
+ </el-date-picker>
+ </el-form-item>
+ <el-form-item label="鏃ユ湡闂撮殧">
+ <el-select
+ v-model="queryParams.HInitTimeCycle"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ >
+ <el-option
+ v-for="(item, index) in rqsgList"
+ :key="index"
+ :label="item.label"
+ :value="item.value"
+ >
+ </el-option>
+ </el-select>
+ </el-form-item>
+ <el-form-item label="璐у竵浠g爜" prop="HNumber">
+ <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="缁勭粐">
+ <el-select
+ v-model="queryParams.HOrgID"
+ placeholder="璇烽�夋嫨"
+ class="ForFilteringSchemes"
+ >
+ <el-option
+ v-for="(item, index) in organizationList"
+ :key="index"
+ :label="item.Name"
+ :value="item.ID.toString()"
+ >
+ </el-option>
+ </el-select>
+ </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-row>
+ <el-form-item label-width="0">
+ <el-col :span="7">
+ <el-select
+ v-model="queryParams.ColName1"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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"
+ class="ForFilteringSchemes"
+ />
+ </el-col>
+ </el-form-item>
+ </el-row>
+ <el-row>
+ <el-form-item label-width="0">
+ <el-col :span="7">
+ <el-select
+ v-model="queryParams.ColName2"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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"
+ class="ForFilteringSchemes"
+ />
+ </el-col>
+ </el-form-item>
+ </el-row>
+ <el-row>
+ <el-form-item label-width="0">
+ <el-col :span="7">
+ <el-select
+ v-model="queryParams.ColName"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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"
+ class="ForFilteringSchemes"
+ />
+ </el-col>
+ </el-form-item>
+ </el-row>
+ </div>
+ </el-card>
+ </el-collapse-item>
+ </el-collapse>
+
+ <el-form-item label-width="78px">
+ <el-button type="primary" size="small" icon="el-icon-search" @click="handleQuery">
+ 鎼� 绱�</el-button
+ >
+ <el-button icon="el-icon-circle-close" size="small" @click="searchOpen = false"
+ >鍙� 娑�</el-button
+ >
+ </el-form-item>
+ </el-form>
+
+ <el-row :gutter="10" class="mb8">
+ <!-- <el-col :span="1.5">
+ <el-button
+ type="warning"
+ plain
+ icon="el-icon-download"
+ size="mini"
+ @click="handleImport"
+ >瀵煎叆</el-button
+ >
+ </el-col> -->
+ <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-delete"
+ size="mini"
+ :disabled="single"
+ @click="handleDelete"
+ >鍒犻櫎
+ </el-button>
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CheckBill(0, (form = rowForm))"
+ >瀹℃牳</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CheckBill(1, (form = rowForm))"
+ >鍙嶅鏍�</el-button
+ >
+ </el-col>
+ <!-- <el-col :span="1.5">
+ <el-button
+ type="success"
+ plain
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_De_Stop(0, (form = rowForm))"
+ >绂佺敤</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="success"
+ plain
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_De_Stop(1, (form = rowForm))"
+ >鍙嶇鐢�</el-button
+ >
+ </el-col> -->
+ <!-- <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CloseBill(1, (form = rowForm))"
+ >鍏抽棴</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CloseBill(2, (form = rowForm))"
+ >鍙嶅叧闂�</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CloseRow(0, (form = rowForm))"
+ >琛屽叧闂�</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CloseRow(1, (form = rowForm))"
+ >琛屽弽鍏抽棴</el-button
+ >
+ </el-col> -->
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_Stop(0, (form = rowForm))"
+ >绂佺敤</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_Stop(1, (form = rowForm))"
+ >鍙嶇鐢�</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-col :span="1.5">
+ <el-button type="primary" icon="el-icon-help" size="mini" @click="handleSearch"
+ >鎼� 绱�</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button type="primary" icon="el-icon-refresh" size="mini" @click="resetQuery"
+ >閲� 缃�</el-button
+ >
+ </el-col>
+ <!-- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> -->
+ </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">
+ <span v-if="column.property.includes('鏃ユ湡')">{{
+ parseTime(row[column.property], "{y}-{m}-{d}")
+ }}</span>
+ <el-button
+ type="text"
+ @click.stop="handleEdit(row, (OperationType = 3))"
+ v-else-if="column.property == '璐у竵浠g爜'"
+ >{{ row.璐у竵浠g爜 }}</el-button
+ >
+ <span v-else>{{ row[column.label] }}</span>
+ </div>
+ </template>
+ </el-table-column>
+ </template>
+ </el-table>
+ <pagination
+ v-show="total > 0"
+ :total="total"
+ :page.sync="page"
+ :limit.sync="pageSize"
+ :pageSizes="pageSizes"
+ @pagination="handleQuery"
+ />
+ <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="缂栬緫杞﹁締"
+ :visible.sync="openEdit"
+ width="1480px"
+ append-to-body
+ class="xsckdBox"
+ :before-close="close"
+ >
+ <!-- <edit
+ :OperationType="OperationType"
+ :linterid="this.rowForm.hmainid"
+ :HSouceBillType="this.rowForm.HSourceBillType"
+ :HOrgID="this.queryParams.HOrgID"
+ :copyType="copyType"
+ @editCloseGy="editGyClose"
+ v-if="editShow"
+ /> -->
+ <div style="height: 80vh" v-if="openEdit">
+ <iframe :src="iframeUrl" frameborder="0" width="100%" height="100%"></iframe>
+ </div>
+ </el-dialog>
+ <el-dialog
+ :title="upload.title"
+ :visible.sync="upload.open"
+ width="1500px"
+ append-to-body
+ v-if="false"
+ >
+ <div style="margin-top: -20px">
+ <el-button type="primary" @click="set_AddNew">瀵煎叆鏁版嵁</el-button>
+ <el-button type="primary" @click="upload.open = false">閫� 鍑�</el-button>
+ <el-upload
+ ref="upload"
+ :limit="1"
+ accept=".xlsx, .xls"
+ style="display: inline-block; margin-left: 10px"
+ :action="upload.url + '?updateSupport=' + upload.updateSupport"
+ :disabled="upload.isUploading"
+ :on-progress="handleFileUploadProgress"
+ :on-success="handleFileSuccess"
+ >
+ <el-button type="primary">鏂囦欢涓婁紶</el-button>
+ </el-upload>
+ </div>
+ <el-table
+ :data="uploadData"
+ v-loading="uploadTableLoading"
+ :row-class-name="uploadDataIndex"
+ border
+ height="550"
+ >
+ <el-table-column type="index" label="搴忓彿" width="55" align="center" />
+ <el-table-column label="缁勭粐浠g爜" prop="缁勭粐浠g爜" align="center" width="120" />
+ <el-table-column label="缁勭粐鍚嶇О" prop="缁勭粐鍚嶇О" align="center" width="120" />
+ <el-table-column
+ label="鐢熶骇璧勬簮鍚嶇О"
+ prop="鐢熶骇璧勬簮鍚嶇О"
+ align="center"
+ width="120"
+ />
+ <el-table-column
+ label="鐢熶骇璧勬簮浠g爜"
+ prop="鐢熶骇璧勬簮浠g爜"
+ align="center"
+ width="120"
+ />
+ <el-table-column label="閮ㄩ棬浠g爜" prop="閮ㄩ棬浠g爜" align="center" width="120" />
+ <el-table-column label="閮ㄩ棬鍚嶇О" prop="閮ㄩ棬鍚嶇О" align="center" width="120" />
+ <el-table-column
+ label="璐熻矗浜轰唬鐮�"
+ prop="璐熻矗浜轰唬鐮�"
+ align="center"
+ width="120"
+ />
+ <el-table-column label="璐熻矗浜�" prop="璐熻矗浜�" align="center" width="120" />
+ <el-table-column
+ label="宸ヤ綔涓績浠g爜"
+ prop="宸ヤ綔涓績浠g爜"
+ align="center"
+ width="120"
+ />
+ <el-table-column
+ label="宸ヤ綔涓績鍚嶇О"
+ prop="宸ヤ綔涓績鍚嶇О"
+ align="center"
+ width="120"
+ />
+ <el-table-column label="鍗曠彮宸ユ椂" prop="鍗曠彮宸ユ椂" align="center" width="120" />
+ <el-table-column label="鎿嶄綔" align="center">
+ <template slot-scope="scope">
+ <el-button
+ size="mini"
+ type="text"
+ icon="el-icon-delete"
+ @click="uploadDataDelete(scope.row)"
+ >鍒犻櫎</el-button
+ >
+ </template>
+ </el-table-column>
+ </el-table>
+ <pagination
+ v-show="uploadTotal > 0"
+ :total="uploadTotal"
+ :page.sync="uploadPage"
+ :limit.sync="uploadPageSize"
+ :pageSizes="uploadPageSizes"
+ @pagination="currentPage"
+ />
+ </el-dialog>
+ </div>
+ </div>
+</template>
+
+<script>
+import axios from "axios";
+import RowSettings from "@/views/component/rowSettings";
+import dayjs from "dayjs";
+
+export default {
+ name: "gyCarList",
+ components: { RowSettings },
+ props: {
+ openPage: { type: String },
+ },
+ data() {
+ return {
+ iframeUrl: "",
+ activeSeach: "",
+ HModName: "gyCarList",
+ editShow: false,
+ openEdit: false,
+ totalNameList: [],
+ dateRange: [],
+ tableShow: true,
+ openPrintList: false,
+ printListShow: false,
+ HClassTag: "ForFilteringSchemes", //杩囨护鏉′欢鐨刢lass绫�
+ 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: "",
+ sTime: "",
+ eTime: "",
+ rqsgList: [
+ { label: "浠婂ぉ", value: 0 },
+ { label: "杩戜袱澶�", value: 1 },
+ { label: "杩戜笁澶�", value: 2 },
+ { label: "杩戝洓澶�", value: 3 },
+ { label: "杩戜簲澶�", value: 4 },
+ { label: "杩戝叚澶�", value: 5 },
+ { label: "杩戜竷澶�", value: 6 },
+ { label: "杩�30澶�", value: 29 },
+ { label: "杩戝崐骞�", value: 180 },
+ { label: "杩戜竴骞�", value: 365 },
+ { label: "浠绘剰鏃ユ湡", value: -1 },
+ ],
+ hPriceTypeList: ["鎴愭湰浠�", "缁撶畻浠�"],
+ addBtnShow: false,
+ zbIndex: null,
+ zbSelForm: {}, //瀛愯〃閫変腑鏁版嵁
+ dialogTypeNum: null, //閮ㄩ棬寮圭獥1锛屼粨搴撳脊绐�2
+ deptShow: false, //閮ㄩ棬鏁版嵁缁勪欢
+ warehouseShow: false, //浠撳簱鏁版嵁缁勪欢
+ materialShow: false, //鐗╂枡鏁版嵁缁勪欢
+ deptform: {}, //寮圭獥閫変腑鏁版嵁
+ openData: false, //鏁版嵁寮圭獥
+ dialogTitle: "",
+ zuzhiId: "",
+ organizationList: JSON.parse(sessionStorage["organizationList"]), //缁勭粐鍒楄〃
+ subDisabled: false, //缂栬緫椤甸潰淇濆瓨鎸夐挳鏄惁绂佺敤(true绂佺敤锛宖alse鍙敤)
+ OperationType: null, //淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
+ HInterID: null,
+ baseURL: process.env.VUE_APP_BASE_API || "http://47.96.97.237/API/",
+ currentRow: [],
+ lastSelectedRowIndex: null, // 鐢ㄤ簬璁板綍涓婃鐐瑰嚮鐨勮绱㈠紩
+ lastSelectedRow: null, // 涓婁竴娆¢�変腑鐨勮
+ selectedRow: null, // 褰撳墠閫変腑鐨勮
+ rowForm: {},
+ checkedSysZb: [],
+ editData: [], //杞﹁締瀛愯〃
+ editBtData: [], //瀛愯〃琛ㄥご
+ activeName: "first",
+ searchOpen: false,
+ // 寮瑰嚭灞傛爣棰�
+ title: "",
+ // 鏄惁鏄剧ず寮瑰嚭灞�
+ open: false,
+ // 鏃ユ湡鑼冨洿
+ dateRange: [],
+ // 鏌ヨ鍙傛暟
+ queryParams: {
+ HOrgID: sessionStorage["OrganizationID"],
+ HName: null,
+ HNumber: null,
+ Comparator1: "",
+ Comparator2: "",
+ Comparator: "",
+ ColContent1: "",
+ ColContent2: "",
+ ColContent: "",
+ HInitTimeCycle: 29,
+ HBeginDate: dayjs(new Date()).subtract(29, "d").format("YYYY-MM-DDTHH:mm:ss"),
+ HEndDate: dayjs(new Date()).format("YYYY-MM-DDTHH:mm:ss"),
+ },
+ // 鏄剧ず鎼滅储鏉′欢
+ showSearch: true,
+ // 閫変腑鏁扮粍
+ ids: [],
+ // 闈炲崟涓鐢�
+ single: true,
+ // 闈炲涓鐢�
+ multiple: true,
+ // 閬僵灞�
+ loading: true,
+ // 绂佺敤鏃ユ湡閫夋嫨
+ disableDataPicker: true,
+ tyResList: [], //鏀舵枡閫氱煡鍗曞垪琛紙鎺ュ彛鏁版嵁锛�
+ btList: [], //鏀舵枡閫氱煡鍗曞垪琛ㄦ樉绀�
+ btResList: [],
+ tableData: [], //鏀舵枡閫氱煡鍗曞垪琛�(鍒嗛〉鏄剧ず)
+ dataList: [],
+ titleData: [
+ "HItemID",
+ "hmainid",
+ "Hprocid",
+ "HUSEORGID",
+ "HCREATEORGID",
+ "HParentID",
+ ], //涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+ pageSizes: [50, 100, 500, 5000, 50000],
+ page: 1,
+ pageSize: 50,
+ total: 0,
+ scollHeight: document.body.clientHeight * (38.056 / 100),
+ // 琛ㄥ崟鍙傛暟
+ form: {},
+ // 琛ㄥ崟鏍¢獙
+ rules: {},
+ upload: {
+ // 鏄惁鏄剧ず寮瑰嚭灞�
+ open: false,
+ // 寮瑰嚭灞傛爣棰�
+ title: "",
+ // 鏄惁绂佺敤涓婁紶
+ isUploading: false,
+ // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勬暟鎹�
+ updateSupport: 0,
+ // 璁剧疆涓婁紶鐨勮姹傚ご閮�
+ // headers: { Authorization: "Bearer " + getToken() },
+ // 涓婁紶鐨勫湴鍧�
+ url: "http://47.96.97.237/API/Gy_Source/Gy_Source_Excel",
+ },
+ uploadData: [],
+ alluploadList: [],
+ uploadTableLoading: false,
+ uploadPageSizes: [50, 100, 500, 5000, 50000],
+ uploadPage: 1,
+ uploadPageSize: 50,
+ uploadTotal: 0,
+ };
+ },
+ mounted() {
+ window.editGyClose = () => {
+ this.editGyClose(); // 缁勪欢鍐呯殑鏂规硶缁戝畾鍒皐indows
+ };
+ this.queryParams.HOrgID = sessionStorage["OrganizationID"];
+ },
+
+ beforeDestroy() {
+ // 缁勪欢閿�姣佹椂娓呯悊鍏ㄥ眬鏂规硶锛岄伩鍏嶅唴瀛樻硠婕�
+ delete window.editGyClose;
+ },
+ created() {
+ this.riqiChange();
+ this.handleQuery();
+ },
+ methods: {
+ onDateScanOptionChangerHandler(e) {
+ this.queryParams.timeSpan = e;
+ if (e == -1) {
+ this.disableDataPicker = true;
+ return;
+ }
+
+ this.disableDataPicker = false;
+ },
+ 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;
+ },
+
+ //#region 鑾峰彇鍏徃鍚嶏紝鏍规嵁鍏徃杩涜瀹氬埗鍖栧紑鍙�
+ defaintOperationByCompanyName() {
+ var result = false;
+ axios
+ .get(this.baseURL + "/Xt_getInfo/getCompanyName")
+ .then((res) => {
+ var data1 = res.data;
+ if (data1.count == 1) {
+ if (data1.data == "姘村姟") {
+ result = true;
+ }
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ return result;
+ },
+ handleSellOpen() {
+ this.$router.push("/sellBill");
+ },
+ handleSellOutOpen() {
+ this.$router.push("/sellOutBill");
+ },
+ 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.handleQuery();
+ },
+ riqiChange() {
+ if (this.queryParams.HInitTimeCycle == -1) {
+ // 闅忔剰鏃ユ湡涓嶈绠�
+ return;
+ }
+ const end = new Date();
+ const start = new Date();
+ start.setTime(start.getTime() - 3600 * 1000 * 24 * this.queryParams.HInitTimeCycle);
+ const yyyyS = start.getFullYear();
+ const mmS = String(start.getMonth() + 1).padStart(2, "0"); // 鏈堜唤鏄粠0寮�濮嬬殑
+ const ddS = String(start.getDate()).padStart(2, "0");
+ const yyyyE = end.getFullYear();
+ const mmE = String(end.getMonth() + 1).padStart(2, "0"); // 鏈堜唤鏄粠0寮�濮嬬殑
+ const ddE = String(end.getDate()).padStart(2, "0");
+ this.sTime = yyyyS + "-" + mmS + "-" + ddS;
+ this.eTime = yyyyE + "-" + mmE + "-" + ddE;
+ this.dateRange = [this.sTime, this.eTime];
+ },
+ organizationChange(val) {
+ // let options=undefined
+ // this.form=this.organizationList.find(option => option.ID === val)?.Name || '';
+ },
+ //閮ㄩ棬寮圭獥璧嬪��
+ dbEmitData(deptRow, num) {
+ // num=1閮ㄩ棬 num=2鍑哄簱浠撳簱
+ if (num == 1) {
+ this.form.HDeptName = deptRow.閮ㄩ棬鍚嶇О;
+ this.form.HDeptID = deptRow.HItemID;
+ this.form.HEmpID = deptRow.HEmpID;
+ this.form.HManagerName = deptRow.璐熻矗浜�;
+ this.openData = false;
+ } else if (num == 2) {
+ this.editData[this.zbIndex].HWHID = deptRow.HItemID;
+ this.editData[this.zbIndex].鍙戣揣浠撳簱 = deptRow.浠撳簱鍚嶇О;
+ this.openData = false;
+ } else if (num == 3) {
+ this.editData[this.zbIndex].HMaterID = deptRow.HItemID;
+ this.editData[this.zbIndex].鐗╂枡浠g爜 = deptRow.鐗╂枡浠g爜;
+ this.editData[this.zbIndex].鐗╂枡鍚嶇О = deptRow.鐗╂枡鍚嶇О;
+ this.editData[this.zbIndex].HUnitID = deptRow.HUnitID;
+ this.editData[this.zbIndex].瑙勬牸鍨嬪彿 = deptRow.瑙勬牸鍨嬪彿;
+ this.editData[this.zbIndex].璁¢噺鍗曚綅 = deptRow.璁¢噺鍗曚綅鍚嶇О;
+ this.editData[this.zbIndex].HTaxPrice = deptRow.鍚◣鎴愭湰浠�;
+ this.editData[this.zbIndex].HTaxRate = deptRow.榛樿绋庣巼;
+ this.openData = false;
+ }
+ },
+ emitData(deptRow, num) {
+ this.dialogTypeNum = num;
+ this.deptform = deptRow;
+ },
+ deptClickSub() {
+ this.dbEmitData(this.deptform, this.dialogTypeNum);
+ this.deptform = {};
+ },
+ async getList() {
+ this.tableShow = false;
+ this.loading = true;
+ if (this.pageSize == 0) {
+ this.pageSize = 50;
+ }
+
+ try {
+ let res = await axios.get(this.baseURL + "/Gy_Currency/list1", {
+ params: {
+ sWhere: this.sWhere,
+ user: sessionStorage["HUserName"],
+
+ },
+ });
+ this.tyResList = [...JSON.parse(JSON.stringify(res.data.data))]; //鎬绘暟鎹�
+ let data1 = res.data;
+ let option = [];
+ if (data1.code == 1) {
+ this.btResList = data1.list; //杞﹁締鎺ュ彛琛ㄥご鏁版嵁
+ this.total = data1.count;
+ var data = []; //鍒楀瓧娈垫暟鎹�
+ var col = [];
+ var totalArray = [];
+ //缁欑┖鐨勬暟缁勮祴鍊�
+ for (var key in data1.list) {
+ //寰簭閬嶅巻鏁扮粍
+ data.push({
+ id: data1.list[key].ColmCols,
+ name: data1.list[key].ColmCols,
+ Type: data1.list[key].ColmType,
+ }); //浠庢瘡涓璞′腑鎻愬彇鏁版嵁
+ }
+ //鍦ㄥ垪琛ㄥ乏杈规坊鍔犲嬀閫夋
+ col.push({ type: "checkbox", fixed: "left", totalRowText: "鍚堣" });
+ for (var i = 0; i < data.length; i++) {
+ //閬嶅巻data鏁扮粍閲嶇殑鏁版嵁
+ if (this.titleData.indexOf(data[i].name) > -1) {
+ //妫�鏌ata銆恑銆�.name鏄惁鍦ㄦ暟缁勪腑 //璁$畻鍒�
+ col.push({
+ field: data[i].id,
+ title: data[i].name,
+ align: "center",
+ hide: true,
+ }); //闅愯棌id鍒�
+ } else if (
+ totalArray.indexOf(data[i].name) > -1 ||
+ data[i].Type == "Decimal" ||
+ data[i].Type == "Int32"
+ ) {
+ //璁$畻鍒�
+ col.push({
+ field: data[i].id,
+ title: data[i].name,
+ align: "center",
+ sort: true,
+ totalRow: true,
+ width: 120,
+ });
+ } else {
+ col.push({
+ field: data[i].id,
+ title: data[i].name,
+ align: "center",
+ sort: true,
+ width: 200,
+ });
+ }
+ }
+ option.cols = [col];
+ this.dataList = option;
+ option.data = data1.data;
+ var result = data1.data;
+ var temp = "";
+ for (var i = 0; i < result.length; i++) {
+ if (temp != result[i]["hmainid"]) {
+ temp = result[i]["hmainid"];
+ } else {
+ result[i].鏃ユ湡 = null;
+ result[i].鍗曟嵁鍙� = "";
+ /*result[i].鐘舵�� = "";*/
+ result[i].绾㈣摑鍗曟爣璁� = "";
+ result[i].hsupid = "";
+ result[i].瀹㈡埛 = "";
+ result[i].HEmpID = "";
+ result[i].涓氬姟鍛� = "";
+ result[i].hmanagerid = "";
+ result[i].涓荤 = "";
+ result[i].hsecmanagerid = "";
+ result[i].鍙戣揣浜� = "";
+ result[i].hkeeperid = "";
+ result[i].淇濈鍛� = "";
+ result[i].HDeptID = "";
+ result[i].閮ㄩ棬 = "";
+ result[i].閿�鍞柟寮� = "";
+ }
+ }
+ option.data = result;
+ this.DisPlay_HideColumn(
+ this.HModName,
+ sessionStorage["HUserName"],
+ option,
+ this.dataList
+ );
+ }
+ } catch (err) {
+ this.$modal.msgError(`鑾峰彇璐у竵閿欒: ${err}`);
+ }
+ },
+ 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.tableData = option.data;
+ this.tableShow = true;
+ this.loading = false;
+ } else {
+ this.btList = dataOption.cols[0];
+ this.btList.map((item) => {
+ if (!item.hide) {
+ this.totalNameList.push(item);
+ }
+ });
+ this.tableData = dataOption.data;
+ 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; // 璁板綍褰撳墠閫変腑鐨勮
+ if (this.checkIsIframe()) {
+ // 灏嗗綋鍓嶉�変腑鐨勬暟鎹毚闇插埌window涓�
+ window.selectedRow = row;
+ }
+ this.lastSelectedRowIndex = this.tableData.indexOf(row);
+ this.$refs.tableData.toggleRowSelection(row);
+ },
+ //閫変腑琛岄珮浜牱寮�
+ rowStyle({ row, rowIndex }) {
+ if (this.ids.includes(row.hmainid)) {
+ return { background: "#ecf5ff" };
+ }
+ },
+ checkIsIframe() {
+ if (window.self == window.top) {
+ return false;
+ }
+ return true;
+ },
+ //鍙屽嚮琛�
+ handleDblclick(row, column, cell, event) {
+ if (this.checkIsIframe()) {
+ window.parent.iframeCarCallBack(row);
+ return;
+ }
+ this.OperationType = 3;
+ this.handleEdit(row, this.OperationType);
+ },
+ // 澶氶�夋閫変腑鏁版嵁
+ handleSelectionChange(selection) {
+ // this.rowForm = {}
+ this.ids = selection.map((item) => item.hmainid);
+ this.single = selection.length != 1;
+ this.multiple = !selection.length;
+ if (!this.single) {
+ this.rowForm = selection[0];
+ }
+ },
+ //鎵撳紑渚ц竟鎼滅储寮圭獥
+ handleSearch() {
+ this.searchOpen = true;
+ },
+ /** 鎼滅储鎸夐挳鎿嶄綔 */
+ 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 璐у竵浠g爜 like '%" + this.queryParams.HNumber + "%'";
+ }
+
+ if (this.queryParams.HName) {
+ this.sWhere += " and 璐у竵鍚嶇О like '%" + this.queryParams.HName + "%'";
+ }
+
+ // if (this.queryParams.HBeginDate && this.queryParams.HEndDate) {
+ // this.sWhere += ` and CONVERT(varchar(100),鏃ユ湡, 23) >= '${this.queryParams.HBeginDate}' and CONVERT(varchar(100),鏃ユ湡, 23) <= '${this.queryParams.HEndDate}'`;
+ // }
+
+ this.sWhere += this.addSWhereByOpenType();
+ // this.sWhere += this.getOrgIDByUser();
+ this.searchOpen = false;
+ this.getList();
+ },
+ // 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var sWhere = "";
+ //this.openPage鍒ゆ柇鏄惁鏈夊�硷紝鏈変唬琛ㄥ叾瀹冮〉闈㈤�氳繃閫夋嫨鎸夐挳鎵撳紑
+ if (this.openPage || window.parent != window.self) {
+ sWhere += " and 绂佺敤鏍囧織 != '1' and ISNULL(瀹℃牳浜�,'') != ''";
+ return sWhere;
+ }
+ return sWhere;
+ },
+ //鏍规嵁鐢ㄦ埛鑾峰彇鐢ㄦ埛鍏宠仈缁勭粐鐨勮繃婊ゆ潯浠�
+ getOrgIDByUser() {
+ var res = "";
+ axios
+ .get(this.baseURL + "/Xt_User/getOrgIDListByUser", {
+ params: {
+ HModName: this.HModName,
+ user: sessionStorage["HUserName"],
+ HOrgID: this.zuzhiId,
+ },
+ })
+ .then((res) => {
+ let result = res.data;
+ if (result.count == 1) {
+ if (result.data[0].sWhere == "1") {
+ res = " and HUSEORGID = '" + this.zuzhiId + "'";
+ } else {
+ res = result.data[0].sWhere;
+ }
+ }
+ })
+ .catch((error) => {
+ res = " and 1 = 0";
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ return res;
+ },
+ /** 閲嶇疆鎸夐挳鎿嶄綔 */
+ resetQuery() {
+ this.dateRange = [];
+ this.sWhere = "";
+ Object.assign(this.Parameters, {
+ HBillNo: "",
+ HInitTimeCycle: 29,
+ HProjectNumber: "",
+ HCusID: null,
+ HMaterNumber: "",
+ HMaterName: "",
+ ColName1: "",
+ ColName2: "",
+ ColName: "",
+ Comparator1: "",
+ Comparator2: "",
+ Comparator: "",
+ ColContent1: "",
+ ColContent2: "",
+ ColContent: "",
+ });
+ this.riqiChange();
+ this.resetForm("queryForm");
+ this.getList();
+ },
+
+ //閫�鍑�
+ close() {
+ this.tableShow = true;
+ this.openEdit = false;
+ this.handleQuery();
+ },
+ //鎵撳紑鏂板缁勪欢寮圭獥
+ handleAddEdit() {
+ // this.rowForm.HItemID = 0;
+ this.iframeUrl = `/iframe/gyCurrencyEdit?HInterID=0&OperationType=1`;
+ this.$nextTick(() => {
+ this.openEdit = true;
+ this.editShow = true;
+ });
+ },
+ //鎵撳紑淇敼缁勪欢寮圭獥
+ handleEdit(row, OperationType) {
+ this.iframeUrl = `/iframe/gyCurrencyEdit?HInterID=${row.HItemID}&OperationType=${OperationType}`;
+ this.$nextTick(() => {
+ this.openEdit = true;
+ this.editShow = true;
+ });
+ },
+ //鍏抽棴缂栬緫椤甸潰
+ editGyClose(val) {
+ this.editShow = false;
+ this.openEdit = false;
+ (this.multiple = true), this.handleQuery();
+ },
+ /** 鍒犻櫎鎸夐挳鎿嶄綔 */
+ handleDelete() {
+ this.$modal
+ .confirm("纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠")
+ .then(() => {
+ if (!this.rowForm.瀹℃牳浜�) {
+ axios
+ .get(this.baseURL + "DeltetGy_Currency", {
+ params: {
+ HInterID: this.rowForm.hmainid.toString(),
+ user: sessionStorage["HUserName"],
+ },
+ })
+ .then((res) => {
+ if (res.data.count == 1) {
+ this.handleQuery();
+ this.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+ } else {
+ this.$modal.msgError("閿欒:" + result.code + result.Message);
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ } else {
+ this.$modal.msgError("姝ゆ潯鏁版嵁涓嶆槸鍒涘缓鐘舵��,鏃犳硶鍒犻櫎!");
+ }
+ })
+ .catch(() => {});
+ },
+ // 鍙嶅鏍�/瀹℃牳鏁版嵁
+ set_CheckBill(num, form) {
+ var InterID = form.HItemID || form.HInterID || form.hmainid;
+ //閫昏緫瀹℃牳鏂规硶
+ axios
+ .get(this.baseURL + "Gy_Currency/AuditGy_Currency", {
+ params: {
+ HInterID: InterID,
+ IsAudit: num,
+ CurUserName: sessionStorage["HUserName"],
+ },
+ })
+ .then((res) => {
+ let result = res.data;
+ if (result.code == 1) {
+ this.$modal.msgSuccess("鎿嶄綔鎴愬姛");
+ this.handleQuery();
+ } else {
+ this.$modal.msgError("閿欒:" + result.code + result.Message);
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ // 绂佺敤/鍙嶇鐢ㄦ暟鎹�
+ async set_Stop(num, form) {
+ let HInterID = form.HItemID || form.HInterID || form.hmainid;
+ try {
+ let res = await axios
+ .get(
+ this.baseURL + "/Gy_Currency/StopGy_Currency",
+ {
+ params: {
+ HInterID: HInterID,
+ IsStop: num,
+ CurUserName: sessionStorage["HUserName"],
+ },
+ }
+ );
+
+ let { data, Message, count } = res.data;
+
+ if (count == 1) {
+ this.handleQuery();
+ } else {
+ this.$modal.msgError(`${Message}`);
+ }
+ } catch (err) {
+ this.$modal.msgError(`鎺ュ彛璇锋眰澶辫触: ${err}`);
+ }
+ },
+ // // 鍏抽棴/鍙嶅叧闂暟鎹�
+ // async set_CloseBill(num, form) {
+ // let HInterID = form.HItemID || form.HInterID || form.hmainid;
+ // try {
+ // let res = await axios.get(
+ // `${this.baseURL}/Cg_POInStockBill/CloseCg_POInStockBill`,
+ // {
+ // params: {
+ // HInterID: HInterID,
+ // Type: num,
+ // user: sessionStorage["HUserName"],
+ // },
+ // }
+ // );
+
+ // let { data, Message, count } = res.data;
+
+ // if (count == 1) {
+ // this.handleQuery();
+ // } else {
+ // this.$modal.msgError(`${Message}`);
+ // }
+ // } catch (err) {
+ // this.$modal.msgError(`鎺ュ彛璇锋眰澶辫触: ${err}`);
+ // }
+ // },
+ // // 琛屽叧闂�/琛屽弽鍏抽棴鏁版嵁
+ // async set_CloseRow(num, form) {
+ // let HInterID = form.HItemID || form.HInterID || form.hmainid;
+ // let HEntryID = form.HEntryID || form.hsubid;
+ // try {
+ // let res = await axios.get(
+ // `${this.baseURL}/Cg_POInStockBill/CloseRowCg_POInStockBill`,
+ // {
+ // params: {
+ // HInterID: HInterID,
+ // HEntryID: HEntryID,
+ // ISAudit: num,
+ // CurUserName: sessionStorage["HUserName"],
+ // },
+ // }
+ // );
+
+ // let { data, Message, count } = res.data;
+
+ // if (count == 1) {
+ // this.handleQuery();
+ // } else {
+ // this.$modal.msgError(`${Message}`);
+ // }
+ // } catch (err) {
+ // this.$modal.msgError(`鎺ュ彛璇锋眰澶辫触: ${err}`);
+ // }
+ // },
+ // // 浣滃簾/鍙嶄綔搴熸暟鎹�
+ // async set_DropBill(num, form) {
+ // let HInterID = form.HItemID || form.HInterID || form.hmainid;
+ // try {
+ // let res = await axios.get(
+ // `${this.baseURL}/Cg_POInStockBill/DropCg_POInStockBill`,
+ // {
+ // params: {
+ // HInterID: HInterID,
+ // Type: num,
+ // user: sessionStorage["HUserName"],
+ // },
+ // }
+ // );
+
+ // let { data, Message, count } = res.data;
+
+ // if (count == 1) {
+ // this.handleQuery();
+ // } else {
+ // this.$modal.msgError(`${Message}`);
+ // }
+ // } catch (err) {
+ // this.$modal.msgError(`鎺ュ彛璇锋眰澶辫触: ${err}`);
+ // }
+ // },
+ // 鍙嶇鐢�/绂佺敤鏁版嵁
+ set_De_Stop(num, form) {
+ var InterID = form.HItemID || form.HInterID;
+ //閫昏緫瀹℃牳鏂规硶
+ axios
+ .get(this.baseURL + "/Gy_Employee/StopGy_Employee", {
+ params: {
+ HInterID: InterID,
+ IsStop: num,
+ CurUserName: sessionStorage["HUserName"],
+ },
+ })
+ .then((res) => {
+ let result = res.data;
+ if (result.code == 1) {
+ this.$modal.msgSuccess("鎿嶄綔鎴愬姛");
+ this.handleQuery();
+ } else {
+ this.$modal.msgError("閿欒:" + result.code + result.Message);
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ //瀵煎嚭
+ 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, `gySource_${new Date().getTime()}.xlsx`); // 瀵煎嚭鏂囦欢
+ },
+ handleImport() {
+ this.uploadData = [];
+ this.upload.isUploading = false;
+ this.upload.title = "瀵煎叆";
+ this.upload.open = true;
+ },
+ // 鏂囦欢涓婁紶涓鐞�
+ handleFileUploadProgress(event, file, fileList) {
+ this.upload.isUploading = true;
+ this.uploadTableLoading = true;
+ },
+ // 鏂囦欢涓婁紶鎴愬姛澶勭悊
+ handleFileSuccess(res, file, fileList) {
+ // this.upload.open = false;
+ this.upload.isUploading = true;
+ this.$refs.upload.clearFiles();
+ if (res.code == 1) {
+ this.alluploadList = res.data;
+ this.uploadData = this.getPage(this.uploadPage, this.alluploadList);
+ this.uploadTotal = this.alluploadList.length;
+ this.uploadTableLoading = false;
+ // this.set_AddNew(res.data)
+ } else {
+ this.$alert(
+ "<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" +
+ res.Message +
+ "</div>",
+ "瀵煎叆缁撴灉",
+ { dangerouslyUseHTMLString: true }
+ );
+ }
+ },
+ // 鎻愪氦涓婁紶鏂囦欢
+ submitFileForm() {
+ this.$refs.upload.submit();
+ },
+ set_AddNew() {
+ var num = [];
+ for (var i = 0; i < this.uploadData.length; i++) {
+ if (this.uploadData[i] != "") {
+ num.push(this.uploadData[i]);
+ }
+ }
+ var sSubStr = JSON.stringify(num);
+ var sMainSub = sSubStr + "&鍜�" + sessionStorage["HUserName"];
+ axios({
+ method: "post",
+ url: this.baseURL + "/Gy_Source/Gy_Source_btnSave",
+ data: {
+ sMainSub: sMainSub,
+ },
+ })
+ .then((res) => {
+ this.$alert(
+ "<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" +
+ res.data.Message +
+ "</div>",
+ "瀵煎叆缁撴灉",
+ { dangerouslyUseHTMLString: true }
+ );
+ this.upload.open = false;
+ this.handleQuery();
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ uploadDataIndex({ row, rowIndex }) {
+ row.index = rowIndex + 1;
+ },
+ uploadDataDelete(row) {
+ this.$modal
+ .confirm("纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠")
+ .then(() => {
+ const deleteList = [row.index];
+ const data = this.uploadData;
+ this.uploadData = data.filter((item) => {
+ return deleteList.indexOf(item.index) == -1;
+ });
+ })
+ .catch(() => {});
+ },
+ getPage(page, list) {
+ let sindex = (parseInt(page) - 1) * this.uploadPageSize;
+ let eindex = parseInt(page) * this.uploadPageSize;
+ let newList = list.slice(sindex, eindex);
+ console.log(newList);
+ return newList;
+ },
+ currentPage(val) {
+ this.uploadPage = val.page;
+ setTimeout(() => {
+ this.uploadData = this.getPage(this.uploadPage, this.alluploadList);
+ }, 100);
+ },
+ },
+};
+</script>
+<style>
+.xsckdBox .el-date-editor.el-input {
+ width: 100%;
+}
+
+.form-item-inline > .el-form-item__content {
+ display: flex;
+ flex-direction: row;
+ width: 60%;
+}
+</style>
diff --git a/src/views/basic/gyCurrency/gyCurrencyEdit.vue b/src/views/basic/gyCurrency/gyCurrencyEdit.vue
new file mode 100644
index 0000000..5dce9fd
--- /dev/null
+++ b/src/views/basic/gyCurrency/gyCurrencyEdit.vue
@@ -0,0 +1,336 @@
+<template>
+ <div v-loading="formLoading" v-if="formShow">
+ <div style="margin-bottom: 10px; border-bottom: 1px solid #f6f6f6">
+ <el-button type="primary" @click="submitForm" :disabled="subDisabled"
+ >淇� 瀛�</el-button
+ >
+ <el-button type="primary" @click="close">閫� 鍑�</el-button>
+ </div>
+
+ <el-form ref="form" :model="form" :rules="rules" label-width="110px">
+ <el-tabs v-model="activeName" type="card">
+ <el-tab-pane label="鍩烘湰淇℃伅" name="first">
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="浠g爜锛�" prop="HNumber">
+ <el-input
+ v-model="form.HNumber"
+ placeholder="璇疯緭鍏ヨ揣甯佷唬鐮�"
+ :disabled="isEditMode"
+ />
+ <el-input v-model="form.HItemID" type="hidden" />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="鍚嶇О锛�" prop="HName">
+ <el-input
+ v-model="form.HName"
+ placeholder="璇疯緭鍏ヨ揣甯佸悕绉�"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="鍔╄鐮侊細">
+ <el-input
+ v-model="form.HHelpCode"
+ placeholder="璇疯緭鍏ュ姪璁扮爜"
+ />
+ </el-form-item>
+ </el-col>
+ </el-row>
+
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="灏忔暟浣嶏細">
+ <el-input
+ v-model="form.HScale"
+ type="number"
+ placeholder="璇疯緭鍏ュ皬鏁颁綅"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="姹囩巼锛�">
+ <el-input
+ v-model="form.HExchangeRate"
+ type="number"
+ placeholder="璇疯緭鍏ユ眹鐜�"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="绂佺敤鏍囧織锛�">
+ <el-checkbox v-model="form.HStopflag" disabled>绂佺敤</el-checkbox>
+ </el-form-item>
+ </el-col>
+ </el-row>
+
+ <el-row>
+ <el-col :span="24">
+ <el-form-item label="澶囨敞锛�">
+ <el-input
+ v-model="form.HRemark"
+ type="textarea"
+ placeholder="璇疯緭鍏ュ娉�"
+ :rows="3"
+ />
+ </el-form-item>
+ </el-col>
+ </el-row>
+ </el-tab-pane>
+ </el-tabs>
+ </el-form>
+ </div>
+</template>
+
+<script>
+import axios from "axios";
+import dayjs from "dayjs";
+
+export default {
+ name: "GyCurrencyEdit",
+ components: {},
+ props: {
+ OperationType: { type: Number }, // 1:鏂板, 3:缂栬緫, 2:澶嶅埗
+ linterid: { type: Number }, // 缂栬緫鏃剁殑ID
+ HOrgID: { type: Number }, // 缁勭粐ID
+ },
+ data() {
+ return {
+ formShow: false,
+ formLoading: true,
+ subDisabled: false,
+ isEditMode: false,
+ activeName: "first",
+ isIframe: false,
+
+ // 琛ㄥ崟鍙傛暟
+ form: {
+ HItemID: 0,
+ HNumber: "",
+ HName: "",
+ HHelpCode: "",
+ HScale: "2",
+ HExchangeRate: "1",
+ HStopflag: false,
+ HRemark: "",
+ HUserName: "",
+ },
+
+ // 琛ㄥ崟鏍¢獙
+ rules: {
+ HNumber: [{ required: true, message: "璐у竵浠g爜涓嶈兘涓虹┖", trigger: "blur" }],
+ HName: [{ required: true, message: "璐у竵鍚嶇О涓嶈兘涓虹┖", trigger: "blur" }],
+ },
+
+ baseURL: process.env.VUE_APP_BASE_API || "http://47.96.97.237/API/",
+ user: "admin",
+ };
+ },
+ created() {
+ this.reset();
+ this.fetchData();
+ this.checkIframe();
+ },
+ mounted() {
+ this.user = sessionStorage["HUserName"] || "admin";
+ },
+ methods: {
+ // 妫�鏌ユ槸鍚﹀湪iframe涓�
+ checkIframe() {
+ this.isIframe = window.self !== window.top;
+ },
+
+ fetchData() {
+ // 浠嶶RL鑾峰彇鍙傛暟
+ const urlParams = this.getUrlParams();
+ const hID = urlParams.HInterID ? parseInt(urlParams.HInterID) : 0;
+ const opType = urlParams.OperationType ? parseInt(urlParams.OperationType) : 1;
+
+ // 濡傛灉props娌℃湁浼犻�掞紝浣跨敤URL鍙傛暟
+ const operationType = this.OperationType || opType;
+ const linterid = this.linterid || hID;
+
+ if (operationType !== 1 && linterid) {
+ // 缂栬緫鎴栧鍒舵ā寮�
+ this.getDetailData(linterid, operationType);
+ } else {
+ // 鏂板妯″紡
+ this.formShow = true;
+ this.formLoading = false;
+ this.form.HItemID = 0;
+ this.isEditMode = false;
+ }
+ },
+
+ // 浠嶶RL鑾峰彇鍙傛暟
+ getUrlParams() {
+ const params = {};
+ const queryString = window.location.search.substring(1);
+ const pairs = queryString.split('&');
+
+ for (let i = 0; i < pairs.length; i++) {
+ const pair = pairs[i].split('=');
+ if (pair.length === 2) {
+ params[pair[0]] = decodeURIComponent(pair[1]);
+ }
+ }
+
+ return params;
+ },
+
+ getDetailData(hID, operationType) {
+ this.formLoading = true;
+ axios
+ .get(this.baseURL + "/GetGy_CurrencyDetail", {
+ params: {
+ HID: hID,
+ },
+ })
+ .then((response) => {
+ let result = response.data;
+ if (result.code == 1) {
+ var data = result.data.h_v_Edit_Gy_CurrencyList[0];
+ console.log("杩斿洖鐨勬暟鎹�:", data);
+
+ this.form = {
+ HItemID: operationType == 2 ? 0 : data.HItemID, // 澶嶅埗鏃禝D璁句负0
+ HNumber: data.璐у竵浠g爜,
+ HName: data.璐у竵鍚嶇О,
+ HHelpCode: data.鍔╄浠g爜,
+ HScale: data.灏忔暟浣� || "2",
+ HExchangeRate: data.姹囩巼 || "1",
+ HStopflag: data.绂佺敤鏍囪 === "true",
+ HRemark: data.澶囨敞 || "",
+ HUserName: this.user,
+ };
+
+ this.isEditMode = operationType === 3;
+ } else {
+ this.$modal.msgError(result.msg || "鑾峰彇鏁版嵁澶辫触");
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ })
+ .finally(() => {
+ this.formShow = true;
+ this.formLoading = false;
+ });
+ },
+
+ // 閲嶇疆琛ㄥ崟
+ reset() {
+ this.form = {
+ HItemID: 0,
+ HNumber: "",
+ HName: "",
+ HHelpCode: "",
+ HScale: "2",
+ HExchangeRate: "1",
+ HStopflag: false,
+ HRemark: "",
+ HUserName: this.user,
+ };
+ this.subDisabled = false;
+ },
+
+ // 閫�鍑�
+ close() {
+ if (this.isIframe) {
+ // 鍦╥frame涓紝閫氱煡鐖剁獥鍙e叧闂垨杩斿洖
+ if (window.parent.editGyClose) {
+ window.parent.editGyClose();
+ } else {
+ // 灏濊瘯鍏抽棴iframe
+ try {
+ const index = parent.layer && parent.layer.getFrameIndex ? parent.layer.getFrameIndex(window.name) : null;
+ if (index !== null && index !== undefined) {
+ parent.layer.close(index);
+ } else {
+ // 濡傛灉娌℃湁layer锛屼娇鐢ㄥ叾浠栨柟寮�
+ window.parent.postMessage({ action: 'closeIframe' }, '*');
+ }
+ } catch (e) {
+ console.log("鍏抽棴iframe澶辫触:", e);
+ this.$router.back();
+ }
+ }
+ } else {
+ // 涓嶅湪iframe涓紝浣跨敤璺敱杩斿洖鎴栬烦杞�
+ if (this.$route) {
+ this.$router.back();
+ } else if (this.OperationType === 1) {
+ // 鏂板妯″紡锛岃繑鍥為椤�
+ window.location.href = "/index.html";
+ } else {
+ window.history.back();
+ }
+ }
+ },
+
+ // 鎻愪氦淇濆瓨
+ // 鎻愪氦淇濆瓨
+ submitForm() {
+ this.$refs["form"].validate((valid) => {
+ if (valid) {
+ this.subDisabled = true;
+
+ // 鍑嗗鏁版嵁
+ const formData = {
+ ...this.form,
+ HStopflag: this.form.HStopflag ? "true" : "false",
+ HUserName: this.user,
+ };
+
+ const sMainStr = JSON.stringify(formData);
+
+ // 鐩存帴鍙戦�丣SON鏁版嵁锛屼笉瑕佷娇鐢‵ormData
+ const requestData = {
+ msg: sMainStr + ';' + this.user,
+ };
+
+ axios({
+ method: "POST",
+ url: this.baseURL + "/SaveGy_CurrencyList",
+ data: requestData, // 鐩存帴鍙戦�丣SON瀵硅薄
+ headers: {
+ 'Content-Type': 'application/json', // 浣跨敤JSON鏍煎紡
+ },
+ })
+ .then((response) => {
+ if (response.data.count == 1) {
+ this.$modal.msgSuccess(response.data.Message || "淇濆瓨鎴愬姛");
+ this.subDisabled = true;
+
+ // 淇濆瓨鎴愬姛鍚庯紝濡傛灉鏄柊澧炴ā寮忥紝鍙互缁х画娣诲姞锛屾垨鑰呮彁绀虹敤鎴�
+
+ } else {
+ this.$modal.msgError(response.data.Message || "淇濆瓨澶辫触");
+ this.subDisabled = false;
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("淇濆瓨澶辫触: " + (error.message || "鏈煡閿欒"));
+ this.subDisabled = false;
+ });
+ }
+ });
+ }
+ },
+};
+</script>
+
+<style scoped>
+.el-form-item {
+ margin-bottom: 22px;
+}
+
+.el-row {
+ margin-bottom: 10px;
+}
+
+.hidden-input {
+ display: none;
+}
+</style>
\ No newline at end of file
diff --git a/src/views/basic/gyUnit/gyUnit.vue b/src/views/basic/gyUnit/gyUnit.vue
new file mode 100644
index 0000000..2905483
--- /dev/null
+++ b/src/views/basic/gyUnit/gyUnit.vue
@@ -0,0 +1,1560 @@
+<template>
+ <div style="padding: 10px; position: relative;">
+ <el-form
+ :model="queryParams"
+ ref="queryForm"
+ size="small"
+ :inline="true"
+ label-width="78px"
+ class="searchBox"
+ >
+ <el-row>
+ <el-form-item label="寮�濮嬫棩鏈�" style="margin-left: 100px">
+ <el-date-picker
+ v-model="sTime"
+ type="date"
+ placeholder="寮�濮嬫棩鏈�"
+ style="width: 150px"
+ :disabled="queryParams.HInitTimeCycle != -1"
+ value-format="yyyy-MM-dd"
+ >
+ </el-date-picker>
+ </el-form-item>
+ <el-form-item label="缁撴潫鏃ユ湡">
+ <el-date-picker
+ v-model="eTime"
+ type="date"
+ placeholder="缁撴潫鏃ユ湡"
+ style="width: 150px"
+ :disabled="queryParams.HInitTimeCycle != -1"
+ value-format="yyyy-MM-dd"
+ >
+ </el-date-picker>
+ </el-form-item>
+ <el-form-item label="鏃ユ湡闂撮殧">
+ <el-select
+ v-model="queryParams.HInitTimeCycle"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ >
+ <el-option
+ v-for="(item, index) in rqsgList"
+ :key="index"
+ :label="item.label"
+ :value="item.value"
+ >
+ </el-option>
+ </el-select>
+ </el-form-item>
+ <el-form-item label="璁¢噺鍗曚綅浠g爜" prop="HName">
+ <el-input
+ v-model="queryParams.HName"
+ placeholder="璁¢噺鍗曚綅浠g爜"
+ @keyup.enter.native="handleQuery"
+ />
+ </el-form-item>
+ <el-form-item label="璁¢噺鍗曚綅鍚嶇О" prop="HNumber">
+ <el-input
+ v-model="queryParams.HNumber"
+ placeholder="璇疯緭鍏ヨ閲忓崟浣嶅悕绉�"
+ @keyup.enter.native="handleQuery"
+ />
+ </el-form-item>
+ <el-form-item label="缁勭粐">
+ <el-select
+ v-model="queryParams.HOrgID"
+ placeholder="璇烽�夋嫨"
+ class="ForFilteringSchemes"
+ >
+ <el-option
+ v-for="(item, index) in organizationList"
+ :key="index"
+ :label="item.Name"
+ :value="item.ID.toString()"
+ >
+ </el-option>
+ </el-select>
+ </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-row>
+ <el-form-item label-width="0">
+ <el-col :span="7">
+ <el-select
+ v-model="queryParams.ColName1"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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"
+ class="ForFilteringSchemes"
+ />
+ </el-col>
+ </el-form-item>
+ </el-row>
+ <el-row>
+ <el-form-item label-width="0">
+ <el-col :span="7">
+ <el-select
+ v-model="queryParams.ColName2"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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"
+ class="ForFilteringSchemes"
+ />
+ </el-col>
+ </el-form-item>
+ </el-row>
+ <el-row>
+ <el-form-item label-width="0">
+ <el-col :span="7">
+ <el-select
+ v-model="queryParams.ColName"
+ placeholder="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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="璇烽�夋嫨"
+ @change="riqiChange"
+ class="ForFilteringSchemes"
+ >
+ <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"
+ class="ForFilteringSchemes"
+ />
+ </el-col>
+ </el-form-item>
+ </el-row>
+ </div>
+ </el-card>
+ </el-collapse-item>
+ </el-collapse>
+
+ <el-form-item label-width="78px">
+ <el-button type="primary" size="small" icon="el-icon-search" @click="handleQuery">
+ 鎼� 绱�</el-button
+ >
+ <el-button icon="el-icon-circle-close" size="small" @click="searchOpen = false"
+ >鍙� 娑�</el-button
+ >
+ </el-form-item>
+ </el-form>
+
+ <el-row :gutter="10" class="mb8">
+ <!-- <el-col :span="1.5">
+ <el-button
+ type="warning"
+ plain
+ icon="el-icon-download"
+ size="mini"
+ @click="handleImport"
+ >瀵煎叆</el-button
+ >
+ </el-col> -->
+ <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-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-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CheckBill(1, (form = rowForm))"
+ >瀹℃牳</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_CheckBill(2, (form = rowForm))"
+ >鍙嶅鏍�</el-button
+ >
+ </el-col>
+ <!-- <el-col :span="1.5">
+ <el-button
+ type="success"
+ plain
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_De_Stop(0, (form = rowForm))"
+ >绂佺敤</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="success"
+ plain
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_De_Stop(1, (form = rowForm))"
+ >鍙嶇鐢�</el-button
+ >
+ </el-col> -->
+
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_De_Stop(0, (form = rowForm))"
+ >绂佺敤</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ icon="el-icon-edit"
+ size="mini"
+ :disabled="single"
+ @click="set_De_Stop(1, (form = rowForm))"
+ >鍙嶇鐢�</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-col :span="1.5">
+ <el-button type="primary" icon="el-icon-help" size="mini" @click="handleSearch"
+ >鎼� 绱�</el-button
+ >
+ </el-col>
+ <el-col :span="1.5">
+ <el-button type="primary" icon="el-icon-refresh" size="mini" @click="resetQuery"
+ >閲� 缃�</el-button
+ >
+ </el-col>
+ <!-- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> -->
+ </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">
+ <span v-if="column.property.includes('鏃ユ湡')">{{
+ parseTime(row[column.property], "{y}-{m}-{d}")
+ }}</span>
+ <el-button
+ type="text"
+ @click.stop="handleEdit(row, (OperationType = 3))"
+ v-else-if="column.property == '璁¢噺鍗曚綅浠g爜'"
+ >{{ row.璁¢噺鍗曚綅浠g爜}}</el-button
+ >
+ <span v-else>{{ row[column.label] }}</span>
+ </div>
+ </template>
+ </el-table-column>
+ </template>
+ </el-table>
+ <pagination
+ v-show="total > 0"
+ :total="total"
+ :page.sync="page"
+ :limit.sync="pageSize"
+ :pageSizes="pageSizes"
+ @pagination="handleQuery"
+ />
+ <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="缂栬緫璁¢噺鍗曚綅"
+ :visible.sync="openEdit"
+ width="1480px"
+ append-to-body
+ class="xsckdBox"
+ :before-close="close"
+ >
+ <!-- <edit
+ :OperationType="OperationType"
+ :linterid="this.rowForm.hmainid"
+ :HSouceBillType="this.rowForm.HSourceBillType"
+ :HOrgID="this.queryParams.HOrgID"
+ :copyType="copyType"
+ @editCloseGy="editGyClose"
+ v-if="editShow"
+ /> -->
+ <div style="height: 80vh" v-if="openEdit">
+ <iframe :src="iframeUrl" frameborder="0" width="100%" height="100%"></iframe>
+ </div>
+ </el-dialog>
+ <el-dialog
+ :title="upload.title"
+ :visible.sync="upload.open"
+ width="1500px"
+ append-to-body
+ v-if="false"
+ >
+ <div style="margin-top: -20px">
+ <el-button type="primary" @click="set_AddNew">瀵煎叆鏁版嵁</el-button>
+ <el-button type="primary" @click="upload.open = false">閫� 鍑�</el-button>
+ <el-upload
+ ref="upload"
+ :limit="1"
+ accept=".xlsx, .xls"
+ style="display: inline-block; margin-left: 10px"
+ :action="upload.url + '?updateSupport=' + upload.updateSupport"
+ :disabled="upload.isUploading"
+ :on-progress="handleFileUploadProgress"
+ :on-success="handleFileSuccess"
+ >
+ <el-button type="primary">鏂囦欢涓婁紶</el-button>
+ </el-upload>
+ </div>
+ <el-table
+ :data="uploadData"
+ v-loading="uploadTableLoading"
+ :row-class-name="uploadDataIndex"
+ border
+ height="550"
+ >
+ <el-table-column type="index" label="搴忓彿" width="55" align="center" />
+ <el-table-column label="缁勭粐浠g爜" prop="缁勭粐浠g爜" align="center" width="120" />
+ <el-table-column label="缁勭粐鍚嶇О" prop="缁勭粐鍚嶇О" align="center" width="120" />
+ <el-table-column
+ label="鐢熶骇璧勬簮鍚嶇О"
+ prop="鐢熶骇璧勬簮鍚嶇О"
+ align="center"
+ width="120"
+ />
+ <el-table-column
+ label="鐢熶骇璧勬簮浠g爜"
+ prop="鐢熶骇璧勬簮浠g爜"
+ align="center"
+ width="120"
+ />
+ <el-table-column label="閮ㄩ棬浠g爜" prop="閮ㄩ棬浠g爜" align="center" width="120" />
+ <el-table-column label="閮ㄩ棬鍚嶇О" prop="閮ㄩ棬鍚嶇О" align="center" width="120" />
+ <el-table-column
+ label="璐熻矗浜轰唬鐮�"
+ prop="璐熻矗浜轰唬鐮�"
+ align="center"
+ width="120"
+ />
+ <el-table-column label="璐熻矗浜�" prop="璐熻矗浜�" align="center" width="120" />
+ <el-table-column
+ label="宸ヤ綔涓績浠g爜"
+ prop="宸ヤ綔涓績浠g爜"
+ align="center"
+ width="120"
+ />
+ <el-table-column
+ label="宸ヤ綔涓績鍚嶇О"
+ prop="宸ヤ綔涓績鍚嶇О"
+ align="center"
+ width="120"
+ />
+ <el-table-column label="鍗曠彮宸ユ椂" prop="鍗曠彮宸ユ椂" align="center" width="120" />
+ <el-table-column label="鎿嶄綔" align="center">
+ <template slot-scope="scope">
+ <el-button
+ size="mini"
+ type="text"
+ icon="el-icon-delete"
+ @click="uploadDataDelete(scope.row)"
+ >鍒犻櫎</el-button
+ >
+ </template>
+ </el-table-column>
+ </el-table>
+ <pagination
+ v-show="uploadTotal > 0"
+ :total="uploadTotal"
+ :page.sync="uploadPage"
+ :limit.sync="uploadPageSize"
+ :pageSizes="uploadPageSizes"
+ @pagination="currentPage"
+ />
+ </el-dialog>
+ </div>
+ </div>
+</template>
+
+<script>
+import axios from "axios";
+import RowSettings from "@/views/component/rowSettings";
+import dayjs from "dayjs";
+
+export default {
+ name: "gyCarList",
+ components: { RowSettings },
+ props: {
+ openPage: { type: String },
+ },
+ data() {
+ return {
+ iframeUrl: "",
+ activeSeach: "",
+ HModName: "gyUnit",
+ editShow: false,
+ openEdit: false,
+ totalNameList: [],
+ dateRange: [],
+ tableShow: true,
+ openPrintList: false,
+ printListShow: false,
+ HClassTag: "ForFilteringSchemes", //杩囨护鏉′欢鐨刢lass绫�
+ 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: "",
+ sTime: "",
+ eTime: "",
+ rqsgList: [
+ { label: "浠婂ぉ", value: 0 },
+ { label: "杩戜袱澶�", value: 1 },
+ { label: "杩戜笁澶�", value: 2 },
+ { label: "杩戝洓澶�", value: 3 },
+ { label: "杩戜簲澶�", value: 4 },
+ { label: "杩戝叚澶�", value: 5 },
+ { label: "杩戜竷澶�", value: 6 },
+ { label: "杩�30澶�", value: 29 },
+ { label: "杩戝崐骞�", value: 180 },
+ { label: "杩戜竴骞�", value: 365 },
+ { label: "浠绘剰鏃ユ湡", value: -1 },
+ ],
+ hPriceTypeList: ["鎴愭湰浠�", "缁撶畻浠�"],
+ addBtnShow: false,
+ zbIndex: null,
+ zbSelForm: {}, //瀛愯〃閫変腑鏁版嵁
+ dialogTypeNum: null, //閮ㄩ棬寮圭獥1锛屼粨搴撳脊绐�2
+ deptShow: false, //閮ㄩ棬鏁版嵁缁勪欢
+ warehouseShow: false, //浠撳簱鏁版嵁缁勪欢
+ materialShow: false, //鐗╂枡鏁版嵁缁勪欢
+ deptform: {}, //寮圭獥閫変腑鏁版嵁
+ openData: false, //鏁版嵁寮圭獥
+ dialogTitle: "",
+ zuzhiId: "",
+ organizationList: JSON.parse(sessionStorage["organizationList"]), //缁勭粐鍒楄〃
+ subDisabled: false, //缂栬緫椤甸潰淇濆瓨鎸夐挳鏄惁绂佺敤(true绂佺敤锛宖alse鍙敤)
+ OperationType: null, //淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
+ HInterID: null,
+ baseURL: process.env.VUE_APP_BASE_API || "http://47.96.97.237/API/",
+ currentRow: [],
+ lastSelectedRowIndex: null, // 鐢ㄤ簬璁板綍涓婃鐐瑰嚮鐨勮绱㈠紩
+ lastSelectedRow: null, // 涓婁竴娆¢�変腑鐨勮
+ selectedRow: null, // 褰撳墠閫変腑鐨勮
+ rowForm: {},
+ checkedSysZb: [],
+ editData: [],
+ activeName: "first",
+ searchOpen: false,
+ // 寮瑰嚭灞傛爣棰�
+ title: "",
+ // 鏄惁鏄剧ず寮瑰嚭灞�
+ open: false,
+ // 鏃ユ湡鑼冨洿
+ dateRange: [],
+ // 鏌ヨ鍙傛暟
+ queryParams: {
+ HOrgID: sessionStorage["OrganizationID"],
+ HName: null,
+ HNumber: null,
+ Comparator1: "",
+ Comparator2: "",
+ Comparator: "",
+ ColContent1: "",
+ ColContent2: "",
+ ColContent: "",
+ HInitTimeCycle: 29,
+ HBeginDate: dayjs(new Date()).subtract(29, "d").format("YYYY-MM-DDTHH:mm:ss"),
+ HEndDate: dayjs(new Date()).format("YYYY-MM-DDTHH:mm:ss"),
+ },
+ // 鏄剧ず鎼滅储鏉′欢
+ showSearch: true,
+ // 閫変腑鏁扮粍
+ ids: [],
+ // 闈炲崟涓鐢�
+ single: true,
+ // 闈炲涓鐢�
+ multiple: true,
+ // 閬僵灞�
+ loading: true,
+ // 绂佺敤鏃ユ湡閫夋嫨
+ disableDataPicker: true,
+ tyResList: [], //鏀舵枡閫氱煡鍗曞垪琛紙鎺ュ彛鏁版嵁锛�
+ btList: [], //鏀舵枡閫氱煡鍗曞垪琛ㄦ樉绀�
+ btResList: [],
+ tableData: [], //鏀舵枡閫氱煡鍗曞垪琛�(鍒嗛〉鏄剧ず)
+ dataList: [],
+ titleData: [
+ "HItemID",
+ "hmainid",
+ "Hprocid",
+ "HUSEORGID",
+ "HCREATEORGID",
+ "HParentID",
+ ], //涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+ pageSizes: [50, 100, 500, 5000, 50000],
+ page: 1,
+ pageSize: 50,
+ total: 0,
+ scollHeight: document.body.clientHeight * (38.056 / 100),
+ // 琛ㄥ崟鍙傛暟
+ form: {},
+ // 琛ㄥ崟鏍¢獙
+ rules: {},
+ upload: {
+ // 鏄惁鏄剧ず寮瑰嚭灞�
+ open: false,
+ // 寮瑰嚭灞傛爣棰�
+ title: "",
+ // 鏄惁绂佺敤涓婁紶
+ isUploading: false,
+ // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勬暟鎹�
+ updateSupport: 0,
+ // 璁剧疆涓婁紶鐨勮姹傚ご閮�
+ // headers: { Authorization: "Bearer " + getToken() },
+ // 涓婁紶鐨勫湴鍧�
+ url: "http://47.96.97.237/API/Gy_Source/Gy_Source_Excel",
+ },
+ uploadData: [],
+ alluploadList: [],
+ uploadTableLoading: false,
+ uploadPageSizes: [50, 100, 500, 5000, 50000],
+ uploadPage: 1,
+ uploadPageSize: 50,
+ uploadTotal: 0,
+ };
+ },
+ mounted() {
+ window.editGyClose = () => {
+ this.editGyClose(); // 缁勪欢鍐呯殑鏂规硶缁戝畾鍒皐indows
+ };
+ this.queryParams.HOrgID = sessionStorage["OrganizationID"];
+ },
+
+ beforeDestroy() {
+ // 缁勪欢閿�姣佹椂娓呯悊鍏ㄥ眬鏂规硶锛岄伩鍏嶅唴瀛樻硠婕�
+ delete window.editGyClose;
+ },
+ created() {
+ this.riqiChange();
+ this.handleQuery();
+ },
+ methods: {
+ onDateScanOptionChangerHandler(e) {
+ this.queryParams.timeSpan = e;
+ if (e == -1) {
+ this.disableDataPicker = true;
+ return;
+ }
+
+ this.disableDataPicker = false;
+ },
+ 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;
+ },
+
+ //#region 鑾峰彇鍏徃鍚嶏紝鏍规嵁鍏徃杩涜瀹氬埗鍖栧紑鍙�
+ defaintOperationByCompanyName() {
+ var result = false;
+ axios
+ .get(this.baseURL + "/Xt_getInfo/getCompanyName")
+ .then((res) => {
+ var data1 = res.data;
+ if (data1.count == 1) {
+ if (data1.data == "姘村姟") {
+ result = true;
+ }
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ return result;
+ },
+ handleSellOpen() {
+ this.$router.push("/sellBill");
+ },
+ handleSellOutOpen() {
+ this.$router.push("/sellOutBill");
+ },
+ 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.handleQuery();
+ },
+ riqiChange() {
+ if (this.queryParams.HInitTimeCycle == -1) {
+ // 闅忔剰鏃ユ湡涓嶈绠�
+ return;
+ }
+ const end = new Date();
+ const start = new Date();
+ start.setTime(start.getTime() - 3600 * 1000 * 24 * this.queryParams.HInitTimeCycle);
+ const yyyyS = start.getFullYear();
+ const mmS = String(start.getMonth() + 1).padStart(2, "0"); // 鏈堜唤鏄粠0寮�濮嬬殑
+ const ddS = String(start.getDate()).padStart(2, "0");
+ const yyyyE = end.getFullYear();
+ const mmE = String(end.getMonth() + 1).padStart(2, "0"); // 鏈堜唤鏄粠0寮�濮嬬殑
+ const ddE = String(end.getDate()).padStart(2, "0");
+ this.sTime = yyyyS + "-" + mmS + "-" + ddS;
+ this.eTime = yyyyE + "-" + mmE + "-" + ddE;
+ this.dateRange = [this.sTime, this.eTime];
+ },
+ organizationChange(val) {
+ // let options=undefined
+ // this.form=this.organizationList.find(option => option.ID === val)?.Name || '';
+ },
+ //閮ㄩ棬寮圭獥璧嬪��
+ dbEmitData(deptRow, num) {
+ // num=1閮ㄩ棬 num=2鍑哄簱浠撳簱
+ if (num == 1) {
+ this.form.HDeptName = deptRow.閮ㄩ棬鍚嶇О;
+ this.form.HDeptID = deptRow.HItemID;
+ this.form.HEmpID = deptRow.HEmpID;
+ this.form.HManagerName = deptRow.璐熻矗浜�;
+ this.openData = false;
+ } else if (num == 2) {
+ this.editData[this.zbIndex].HWHID = deptRow.HItemID;
+ this.editData[this.zbIndex].鍙戣揣浠撳簱 = deptRow.浠撳簱鍚嶇О;
+ this.openData = false;
+ } else if (num == 3) {
+ this.editData[this.zbIndex].HMaterID = deptRow.HItemID;
+ this.editData[this.zbIndex].鐗╂枡浠g爜 = deptRow.鐗╂枡浠g爜;
+ this.editData[this.zbIndex].鐗╂枡鍚嶇О = deptRow.鐗╂枡鍚嶇О;
+ this.editData[this.zbIndex].HUnitID = deptRow.HUnitID;
+ this.editData[this.zbIndex].瑙勬牸鍨嬪彿 = deptRow.瑙勬牸鍨嬪彿;
+ this.editData[this.zbIndex].璁¢噺鍗曚綅 = deptRow.璁¢噺鍗曚綅鍚嶇О;
+ this.editData[this.zbIndex].HTaxPrice = deptRow.鍚◣鎴愭湰浠�;
+ this.editData[this.zbIndex].HTaxRate = deptRow.榛樿绋庣巼;
+ this.openData = false;
+ }
+ },
+ emitData(deptRow, num) {
+ this.dialogTypeNum = num;
+ this.deptform = deptRow;
+ },
+ deptClickSub() {
+ this.dbEmitData(this.deptform, this.dialogTypeNum);
+ this.deptform = {};
+ },
+ async getList() {
+ this.tableShow = false;
+ this.loading = true;
+ if (this.pageSize == 0) {
+ this.pageSize = 50;
+ }
+ // 璁¢噺鍗曚綅鍒楄〃
+
+ try {
+ let res = await axios.get(this.baseURL + "/Gy_Unit/list1", {
+ params: {
+ sWhere: this.sWhere,
+ user: sessionStorage["HUserName"],
+ Organization:this.getOrgNameById(this.queryParams.HOrgID)
+ },
+ });
+ this.tyResList = [...JSON.parse(JSON.stringify(res.data.data))]; //鎬绘暟鎹�
+ let data1 = res.data;
+ let option = [];
+ if (data1.code == 1) {
+ this.btResList = data1.list; //杞﹁締鎺ュ彛琛ㄥご鏁版嵁
+ this.total = data1.count;
+ var data = []; //鍒楀瓧娈垫暟鎹�
+ var col = [];
+ var totalArray = [];
+ //缁欑┖鐨勬暟缁勮祴鍊�
+ for (var key in data1.list) {
+ //寰簭閬嶅巻鏁扮粍
+ data.push({
+ id: data1.list[key].ColmCols,
+ name: data1.list[key].ColmCols,
+ Type: data1.list[key].ColmType,
+ }); //浠庢瘡涓璞′腑鎻愬彇鏁版嵁
+ }
+ //鍦ㄥ垪琛ㄥ乏杈规坊鍔犲嬀閫夋
+ col.push({ type: "checkbox", fixed: "left", totalRowText: "鍚堣" });
+ for (var i = 0; i < data.length; i++) {
+ //閬嶅巻data鏁扮粍閲嶇殑鏁版嵁
+ if (this.titleData.indexOf(data[i].name) > -1) {
+ //妫�鏌ata銆恑銆�.name鏄惁鍦ㄦ暟缁勪腑 //璁$畻鍒�
+ col.push({
+ field: data[i].id,
+ title: data[i].name,
+ align: "center",
+ hide: true,
+ }); //闅愯棌id鍒�
+ } else if (
+ totalArray.indexOf(data[i].name) > -1 ||
+ data[i].Type == "Decimal" ||
+ data[i].Type == "Int32"
+ ) {
+ //璁$畻鍒�
+ col.push({
+ field: data[i].id,
+ title: data[i].name,
+ align: "center",
+ sort: true,
+ totalRow: true,
+ width: 120,
+ });
+ } else {
+ col.push({
+ field: data[i].id,
+ title: data[i].name,
+ align: "center",
+ sort: true,
+ width: 200,
+ });
+ }
+ }
+ option.cols = [col];
+ this.dataList = option;
+ option.data = data1.data;
+ var result = data1.data;
+ var temp = "";
+ for (var i = 0; i < result.length; i++) {
+ if (temp != result[i]["hmainid"]) {
+ temp = result[i]["hmainid"];
+ } else {
+ result[i].鏃ユ湡 = null;
+ result[i].鍗曟嵁鍙� = "";
+ /*result[i].鐘舵�� = "";*/
+ result[i].绾㈣摑鍗曟爣璁� = "";
+ result[i].hsupid = "";
+ result[i].瀹㈡埛 = "";
+ result[i].HEmpID = "";
+ result[i].涓氬姟鍛� = "";
+ result[i].hmanagerid = "";
+ result[i].涓荤 = "";
+ result[i].hsecmanagerid = "";
+ result[i].鍙戣揣浜� = "";
+ result[i].hkeeperid = "";
+ result[i].淇濈鍛� = "";
+ result[i].HDeptID = "";
+ result[i].閮ㄩ棬 = "";
+ result[i].閿�鍞柟寮� = "";
+ }
+ }
+ option.data = result;
+ this.DisPlay_HideColumn(
+ this.HModName,
+ sessionStorage["HUserName"],
+ option,
+ this.dataList
+ );
+ }
+ } catch (err) {
+ this.$modal.msgError(`鑾峰彇璁¢噺鍗曚綅鍒楄〃閿欒: ${err}`);
+ }
+ },
+ 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.tableData = option.data;
+ this.tableShow = true;
+ this.loading = false;
+ } else {
+ this.btList = dataOption.cols[0];
+ this.btList.map((item) => {
+ if (!item.hide) {
+ this.totalNameList.push(item);
+ }
+ });
+ this.tableData = dataOption.data;
+ 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; // 璁板綍褰撳墠閫変腑鐨勮
+ if (this.checkIsIframe()) {
+ // 灏嗗綋鍓嶉�変腑鐨勬暟鎹毚闇插埌window涓�
+ window.selectedRow = row;
+ }
+ this.lastSelectedRowIndex = this.tableData.indexOf(row);
+ this.$refs.tableData.toggleRowSelection(row);
+ },
+ //閫変腑琛岄珮浜牱寮�
+ rowStyle({ row, rowIndex }) {
+ if (this.ids.includes(row.hmainid)) {
+ return { background: "#ecf5ff" };
+ }
+ },
+ checkIsIframe() {
+ if (window.self == window.top) {
+ return false;
+ }
+ return true;
+ },
+ //鍙屽嚮琛�
+ handleDblclick(row, column, cell, event) {
+ if (this.checkIsIframe()) {
+ window.parent.iframeCarCallBack(row);
+ return;
+ }
+ this.OperationType = 3;
+ this.handleEdit(row, this.OperationType);
+ },
+ // 澶氶�夋閫変腑鏁版嵁
+ handleSelectionChange(selection) {
+ // this.rowForm = {}
+ this.ids = selection.map((item) => item.hmainid);
+ this.single = selection.length != 1;
+ this.multiple = !selection.length;
+ if (!this.single) {
+ this.rowForm = selection[0];
+ }
+ },
+ //鎵撳紑渚ц竟鎼滅储寮圭獥
+ handleSearch() {
+ this.searchOpen = true;
+ },
+ /** 鎼滅储鎸夐挳鎿嶄綔 */
+ 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 璁¢噺鍗曚綅浠g爜 like '%" + this.queryParams.HNumber + "%'";
+ }
+
+ if (this.queryParams.HName) {
+ this.sWhere += " and 璁¢噺鍗曚綅鍚嶇О like '%" + this.queryParams.HName + "%'";
+ }
+
+ // if (this.queryParams.HBeginDate && this.queryParams.HEndDate) {
+ // this.sWhere += ` and CONVERT(varchar(100),鏃ユ湡, 23) >= '${this.queryParams.HBeginDate}' and CONVERT(varchar(100),鏃ユ湡, 23) <= '${this.queryParams.HEndDate}'`;
+ // }
+
+ this.sWhere += this.addSWhereByOpenType();
+ // this.sWhere += this.getOrgIDByUser();
+ this.searchOpen = false;
+ this.getList();
+ },
+ // 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var sWhere = "";
+ //this.openPage鍒ゆ柇鏄惁鏈夊�硷紝鏈変唬琛ㄥ叾瀹冮〉闈㈤�氳繃閫夋嫨鎸夐挳鎵撳紑
+ if (this.openPage || window.parent != window.self) {
+ sWhere += " and 绂佺敤鏍囧織 != '1' and ISNULL(瀹℃牳浜�,'') != ''";
+ return sWhere;
+ }
+ return sWhere;
+ },
+ //鏍规嵁鐢ㄦ埛鑾峰彇鐢ㄦ埛鍏宠仈缁勭粐鐨勮繃婊ゆ潯浠�
+ getOrgIDByUser() {
+ var res = "";
+ axios
+ .get(this.baseURL + "/Xt_User/getOrgIDListByUser", {
+ params: {
+ HModName: this.HModName,
+ user: sessionStorage["HUserName"],
+ HOrgID: this.zuzhiId,
+ },
+ })
+ .then((res) => {
+ let result = res.data;
+ if (result.count == 1) {
+ if (result.data[0].sWhere == "1") {
+ res = " and HUSEORGID = '" + this.zuzhiId + "'";
+ } else {
+ res = result.data[0].sWhere;
+ }
+ }
+ })
+ .catch((error) => {
+ res = " and 1 = 0";
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ return res;
+ },
+ /** 閲嶇疆鎸夐挳鎿嶄綔 */
+ resetQuery() {
+ this.dateRange = [];
+ this.sWhere = "";
+ Object.assign(this.Parameters, {
+ HBillNo: "",
+ HInitTimeCycle: 29,
+ HProjectNumber: "",
+ HCusID: null,
+ HMaterNumber: "",
+ HMaterName: "",
+ ColName1: "",
+ ColName2: "",
+ ColName: "",
+ Comparator1: "",
+ Comparator2: "",
+ Comparator: "",
+ ColContent1: "",
+ ColContent2: "",
+ ColContent: "",
+ });
+ this.riqiChange();
+ this.resetForm("queryForm");
+ this.getList();
+ },
+
+ //閫�鍑�
+ close() {
+ this.tableShow = true;
+ this.openEdit = false;
+ this.handleQuery();
+ },
+ //鎵撳紑鏂板缁勪欢寮圭獥
+ handleAddEdit() {
+ // this.rowForm.HItemID = 0;
+ this.iframeUrl = `/iframe/GyUnitEdit?HInterID=0&OperationType=1`;
+ this.$nextTick(() => {
+ this.openEdit = true;
+ this.editShow = true;
+ });
+ },
+ //鎵撳紑淇敼缁勪欢寮圭獥
+ handleEdit(row, OperationType) {
+ this.iframeUrl = `/iframe/GyUnitEdit?HInterID=${row.HItemID}&OperationType=${OperationType}`;
+ this.$nextTick(() => {
+ this.openEdit = true;
+ this.editShow = true;
+ });
+ },
+ //鍏抽棴缂栬緫椤甸潰
+ editGyClose(val) {
+ this.editShow = false;
+ this.openEdit = false;
+ (this.multiple = true), this.handleQuery();
+ },
+ /** 鍒犻櫎鎸夐挳鎿嶄綔 */
+ handleDelete() {
+ this.$modal
+ .confirm("纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠")
+ .then(() => {
+ if (!this.rowForm.瀹℃牳浜�) {
+ const InterID = this.rowForm.hmainid || this.rowForm.HItemID || this.rowForm.HInterID;
+ axios
+ .get(this.baseURL + "DeltetGy_Unit", {
+ params: {
+ HItemID: InterID,
+ user: sessionStorage["HUserName"],
+ },
+ })
+ .then((res) => {
+ if (res.data.count == 1) {
+ this.handleQuery();
+ this.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+ } else {
+ this.$modal.msgError("閿欒:" + result.code + result.Message);
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ } else {
+ this.$modal.msgError("姝ゆ潯鏁版嵁涓嶆槸鍒涘缓鐘舵��,鏃犳硶鍒犻櫎!");
+ }
+ })
+ .catch(() => {});
+ },
+ // 鍙嶅鏍�/瀹℃牳鏁版嵁
+ set_CheckBill(num, form) {
+ var InterID = form.HItemID || form.HInterID || form.hmainid;
+ //閫昏緫瀹℃牳鏂规硶
+ axios
+ .get(this.baseURL + "/Gy_Unit/AuditGy_Unit", {
+ params: {
+ HInterID: InterID,
+ Type: num,
+ user: sessionStorage["HUserName"],
+ },
+ })
+ .then((res) => {
+ let result = res.data;
+ if (result.code == 1) {
+
+ this.handleQuery();
+ this.$modal.msgError("閿欒:" + result.code + result.Message);
+ } else {
+ this.$modal.msgSuccess("鎿嶄綔鎴愬姛");
+ this.handleQuery();
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+
+
+
+ // 鍙嶇鐢�/绂佺敤鏁版嵁
+ set_De_Stop(num, form) {
+ var InterID = form.HItemID || form.HInterID;
+ //閫昏緫瀹℃牳鏂规硶
+ axios
+ .get(this.baseURL + "/Gy_Unit/StopGy_Unit", {
+ params: {
+ HInterID: InterID,
+ IsStop: num,
+ CurUserName: sessionStorage["HUserName"],
+ },
+ })
+ .then((res) => {
+ let result = res.data;
+ if (result.code == 1) {
+ this.$modal.msgSuccess("鎿嶄綔鎴愬姛");
+ this.handleQuery();
+ } else {
+ this.$modal.msgError("閿欒:" + result.code + result.Message);
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ //瀵煎嚭
+ 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, `gySource_${new Date().getTime()}.xlsx`); // 瀵煎嚭鏂囦欢
+ },
+ handleImport() {
+ this.uploadData = [];
+ this.upload.isUploading = false;
+ this.upload.title = "瀵煎叆";
+ this.upload.open = true;
+ },
+ // 鏂囦欢涓婁紶涓鐞�
+ handleFileUploadProgress(event, file, fileList) {
+ this.upload.isUploading = true;
+ this.uploadTableLoading = true;
+ },
+ // 鏂囦欢涓婁紶鎴愬姛澶勭悊
+ handleFileSuccess(res, file, fileList) {
+ // this.upload.open = false;
+ this.upload.isUploading = true;
+ this.$refs.upload.clearFiles();
+ if (res.code == 1) {
+ this.alluploadList = res.data;
+ this.uploadData = this.getPage(this.uploadPage, this.alluploadList);
+ this.uploadTotal = this.alluploadList.length;
+ this.uploadTableLoading = false;
+ // this.set_AddNew(res.data)
+ } else {
+ this.$alert(
+ "<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" +
+ res.Message +
+ "</div>",
+ "瀵煎叆缁撴灉",
+ { dangerouslyUseHTMLString: true }
+ );
+ }
+ },
+ // 鍋囪鎮ㄦ湁涓�涓粍缁嘔D
+
+
+// 鏂规硶1.1锛氫娇鐢� find 鏂规硶
+ getOrgNameById(id) {
+ const org = this.organizationList.find(item =>
+ item.ID.toString() === id.toString()
+ );
+ return org ? org.Name : ''; // 鍙繑鍥炵粍缁囧悕绉�
+ },
+
+
+ // 鎻愪氦涓婁紶鏂囦欢
+ submitFileForm() {
+ this.$refs.upload.submit();
+ },
+ set_AddNew() {
+ var num = [];
+ for (var i = 0; i < this.uploadData.length; i++) {
+ if (this.uploadData[i] != "") {
+ num.push(this.uploadData[i]);
+ }
+ }
+ var sSubStr = JSON.stringify(num);
+ var sMainSub = sSubStr + "&鍜�" + sessionStorage["HUserName"];
+ axios({
+ method: "post",
+ url: this.baseURL + "/Gy_Source/Gy_Source_btnSave",
+ data: {
+ sMainSub: sMainSub,
+ },
+ })
+ .then((res) => {
+ this.$alert(
+ "<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" +
+ res.data.Message +
+ "</div>",
+ "瀵煎叆缁撴灉",
+ { dangerouslyUseHTMLString: true }
+ );
+ this.upload.open = false;
+ this.handleQuery();
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ uploadDataIndex({ row, rowIndex }) {
+ row.index = rowIndex + 1;
+ },
+ uploadDataDelete(row) {
+ this.$modal
+ .confirm("纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠")
+ .then(() => {
+ const deleteList = [row.index];
+ const data = this.uploadData;
+ this.uploadData = data.filter((item) => {
+ return deleteList.indexOf(item.index) == -1;
+ });
+ })
+ .catch(() => {});
+ },
+ getPage(page, list) {
+ let sindex = (parseInt(page) - 1) * this.uploadPageSize;
+ let eindex = parseInt(page) * this.uploadPageSize;
+ let newList = list.slice(sindex, eindex);
+ console.log(newList);
+ return newList;
+ },
+ currentPage(val) {
+ this.uploadPage = val.page;
+ setTimeout(() => {
+ this.uploadData = this.getPage(this.uploadPage, this.alluploadList);
+ }, 100);
+ },
+ },
+};
+</script>
+<style>
+.xsckdBox .el-date-editor.el-input {
+ width: 100%;
+}
+
+.form-item-inline > .el-form-item__content {
+ display: flex;
+ flex-direction: row;
+ width: 60%;
+}
+</style>
diff --git a/src/views/basic/gyUnit/gyUnitEdit.vue b/src/views/basic/gyUnit/gyUnitEdit.vue
new file mode 100644
index 0000000..3f3166d
--- /dev/null
+++ b/src/views/basic/gyUnit/gyUnitEdit.vue
@@ -0,0 +1,625 @@
+<template>
+ <div v-loading="formLoading" v-if="formShow">
+ <div style="margin-bottom: 10px; border-bottom: 1px solid #f6f6f6">
+ <el-button type="primary" @click="submitForm" :disabled="subDisabled"
+ >淇� 瀛�</el-button
+ >
+ <el-button
+ type="primary"
+ @click="setCheckBill"
+ :disabled="!isAuditable || subDisabled"
+ >瀹� 鏍�</el-button>
+ <el-button type="primary" @click="close">閫� 鍑�</el-button>
+ </div>
+
+ <el-form ref="form" :model="form" :rules="rules" label-width="110px">
+ <el-tabs v-model="activeName" type="card">
+ <el-tab-pane label="鍩烘湰淇℃伅" name="first">
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="浠g爜锛�" prop="HNumber">
+ <el-input
+ v-model="form.HNumber"
+ placeholder="璇疯緭鍏ヨ閲忓崟浣嶄唬鐮�"
+ :disabled="isEditMode && form.HItemID > 0"
+ />
+ <el-input v-model="form.HItemID" type="hidden" />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="鍚嶇О锛�" prop="HName">
+ <el-input
+ v-model="form.HName"
+ placeholder="璇疯緭鍏ヨ閲忓崟浣嶅悕绉�"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="鍔╄鐮侊細">
+ <el-input
+ v-model="form.HHelpCode"
+ placeholder="璇疯緭鍏ュ姪璁扮爜"
+ />
+ </el-form-item>
+ </el-col>
+ </el-row>
+
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="鎹㈢畻姣斾緥锛�" prop="HRate">
+ <el-input
+ v-model="form.HRate"
+ type="number"
+ placeholder="璇疯緭鍏ユ崲绠楁瘮渚�"
+ min="0"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="榛樿鍗曚綅锛�">
+ <el-checkbox v-model="form.HStandard">璁句负榛樿鍗曚綅</el-checkbox>
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="绂佺敤鏍囧織锛�">
+ <el-checkbox v-model="form.HStopflag" disabled>绂佺敤</el-checkbox>
+ </el-form-item>
+ </el-col>
+ </el-row>
+
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="璁¢噺鍗曚綅缁勶細">
+ <div style="white-space: nowrap;">
+ <el-input
+ v-model="form.HUnitGroupName"
+ placeholder="璇烽�夋嫨璁¢噺鍗曚綅缁�"
+ readonly
+ style="width: 200px; display: inline-block;"
+ />
+ <el-input v-model="form.HUnitGroupID" type="hidden" />
+ <el-button
+ type="primary"
+ icon="el-icon-search"
+ @click="selectUnitGroup"
+ style="width: 40px; margin-left: -30px; display: inline-block;"
+ ></el-button>
+ </div>
+ </el-form-item>
+ </el-col>
+ </el-row>
+ <el-row>
+ <el-col :span="24">
+ <el-form-item label="澶囨敞锛�">
+ <el-input
+ v-model="form.HRemark"
+ type="textarea"
+ placeholder="璇疯緭鍏ュ娉�"
+ :rows="3"
+ />
+ </el-form-item>
+ </el-col>
+ </el-row>
+ </el-tab-pane>
+
+ <el-tab-pane label="鍒跺崟淇℃伅" name="second">
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="鍒跺崟浜猴細">
+ <el-input
+ v-model="form.HMakeEmp"
+ readonly
+ :class="{ 'readonly-input': true }"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="鍒跺崟鏃ユ湡锛�">
+ <el-input
+ v-model="form.HMakeDate"
+ readonly
+ :class="{ 'readonly-input': true }"
+ />
+ </el-form-item>
+ </el-col>
+ </el-row>
+
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="瀹℃牳浜猴細">
+ <el-input
+ v-model="form.HCheckEmp"
+ readonly
+ :class="{ 'readonly-input': true }"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="瀹℃牳鏃ユ湡锛�">
+ <el-input
+ v-model="form.HCheckDate"
+ readonly
+ :class="{ 'readonly-input': true }"
+ />
+ </el-form-item>
+ </el-col>
+ </el-row>
+
+ <el-row>
+ <el-col :span="8">
+ <el-form-item label="绂佺敤浜猴細">
+ <el-input
+ v-model="form.HStopEmp"
+ readonly
+ :class="{ 'readonly-input': true }"
+ />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="绂佺敤鏃ユ湡锛�">
+ <el-input
+ v-model="form.HStopDate"
+ readonly
+ :class="{ 'readonly-input': true }"
+ />
+ </el-form-item>
+ </el-col>
+ </el-row>
+ </el-tab-pane>
+ </el-tabs>
+ </el-form>
+
+ <!-- 璁¢噺鍗曚綅缁勯�夋嫨寮圭獥 -->
+ <el-dialog
+ title="璁¢噺鍗曚綅缁勫垪琛�"
+ :visible.sync="unitGroupDialogVisible"
+ width="90%"
+ top="5vh"
+ :close-on-click-modal="false"
+ append-to-body
+ >
+ <div style="height: 70vh;">
+ <iframe
+ :src="unitGroupIframeUrl"
+ frameborder="0"
+ width="100%"
+ height="100%"
+ ></iframe>
+ </div>
+ <span slot="footer" class="dialog-footer">
+ <el-button @click="unitGroupDialogVisible = false">鍙� 娑�</el-button>
+ <el-button type="primary" @click="confirmUnitGroup">纭� 瀹�</el-button>
+ </span>
+ </el-dialog>
+ </div>
+</template>
+
+<script>
+import axios from "axios";
+import dayjs from "dayjs";
+
+export default {
+ name: "GyUnitEdit",
+ components: {},
+ props: {
+ OperationType: { type: Number }, // 1:鏂板, 3:缂栬緫, 2:澶嶅埗
+ linterid: { type: Number }, // 缂栬緫鏃剁殑ID
+ HOrgID: { type: Number }, // 缁勭粐ID
+ },
+ data() {
+ return {
+ formShow: false,
+ formLoading: true,
+ subDisabled: false,
+ isEditMode: false,
+ isAuditable: false,
+ activeName: "first",
+ isIframe: false,
+
+ // 琛ㄥ崟鍙傛暟
+ form: {
+ HItemID: 0,
+ HNumber: "",
+ HName: "",
+ HHelpCode: "",
+ HRate: "1",
+ HStandard: false,
+ HStopflag: false,
+ HRemark: "",
+ HUnitGroupID: "0",
+ HUnitGroupName: "",
+ HMakeEmp: "",
+ HMakeDate: "",
+ HCheckEmp: "",
+ HCheckDate: "",
+ HStopEmp: "",
+ HStopDate: "",
+ HUserName: "",
+ OrganizationID: ""
+ },
+
+ // 璁¢噺鍗曚綅缁勯�夋嫨
+ unitGroupDialogVisible: false,
+ unitGroupIframeUrl: "",
+ selectedUnitGroup: null,
+
+ // 琛ㄥ崟鏍¢獙
+ rules: {
+ HNumber: [
+ { required: true, message: "璁¢噺鍗曚綅浠g爜涓嶈兘涓虹┖", trigger: "blur" },
+ { max: 50, message: "闀垮害涓嶈兘瓒呰繃50涓瓧绗�", trigger: "blur" }
+ ],
+ HName: [
+ { required: true, message: "璁¢噺鍗曚綅鍚嶇О涓嶈兘涓虹┖", trigger: "blur" },
+ { max: 100, message: "闀垮害涓嶈兘瓒呰繃100涓瓧绗�", trigger: "blur" }
+ ],
+ HRate: [
+ { required: true, message: "鎹㈢畻姣斾緥涓嶈兘涓虹┖", trigger: "blur" },
+ {
+ validator: (rule, value, callback) => {
+ if (value === '' || value === null) {
+ callback(new Error('鎹㈢畻姣斾緥涓嶈兘涓虹┖'));
+ } else if (isNaN(value) || parseFloat(value) <= 0) {
+ callback(new Error('璇疯緭鍏ュぇ浜�0鐨勬暟瀛�'));
+ } else {
+ callback();
+ }
+ },
+ trigger: 'blur'
+ }
+ ]
+ },
+
+ baseURL: process.env.VUE_APP_BASE_API || "http://47.96.97.237/API/",
+ user: "admin",
+ organizationID: ""
+ };
+ },
+ created() {
+ this.reset();
+ this.fetchData();
+ this.checkIframe();
+ },
+ mounted() {
+ this.user = sessionStorage["HUserName"] || "admin";
+ this.organizationID = sessionStorage["OrganizationID"] || "";
+ },
+ methods: {
+ // 妫�鏌ユ槸鍚﹀湪iframe涓�
+ checkIframe() {
+ this.isIframe = window.self !== window.top;
+ },
+
+ fetchData() {
+ // 浠嶶RL鑾峰彇鍙傛暟
+ const urlParams = this.getUrlParams();
+ const hID = urlParams.HInterID ? parseInt(urlParams.HInterID) : 0;
+ const opType = urlParams.OperationType ? parseInt(urlParams.OperationType) : 1;
+
+ // 濡傛灉props娌℃湁浼犻�掞紝浣跨敤URL鍙傛暟
+ const operationType = this.OperationType || opType;
+ const linterid = this.linterid || hID;
+
+ if (operationType !== 1 && linterid) {
+ // 缂栬緫鎴栧鍒舵ā寮�
+ this.getDetailData(linterid, operationType);
+ } else {
+ // 鏂板妯″紡
+ this.formShow = true;
+ this.formLoading = false;
+ this.form.HItemID = 0;
+ this.isEditMode = false;
+ this.isAuditable = false;
+ this.setDefaultValues();
+ }
+ },
+
+ // 浠嶶RL鑾峰彇鍙傛暟
+ getUrlParams() {
+ const params = {};
+ const queryString = window.location.search.substring(1);
+ const pairs = queryString.split('&');
+
+ for (let i = 0; i < pairs.length; i++) {
+ const pair = pairs[i].split('=');
+ if (pair.length === 2) {
+ params[pair[0]] = decodeURIComponent(pair[1]);
+ }
+ }
+
+ return params;
+ },
+
+ getDetailData(hID, operationType) {
+ this.formLoading = true;
+ axios
+ .get(this.baseURL + "GetGy_UnitDetail", {
+ params: {
+ HID: hID,
+ },
+ })
+ .then((response) => {
+ let result = response.data;
+ if (result.code == 1) {
+ var data = result.data.h_v_Edit_Gy_UnitList[0];
+ console.log("杩斿洖鐨勬暟鎹�:", data);
+
+ // 澶勭悊甯冨皵鍊�
+ const isStopped = data.绂佺敤鏍囪 === "true";
+ const isStandard = data.榛樿鏍囪 === "true";
+
+ this.form = {
+ HItemID: operationType == 2 ? 0 : data.HItemID, // 澶嶅埗鏃禝D璁句负0
+ HNumber: data.璁¢噺鍗曚綅浠g爜,
+ HName: data.璁¢噺鍗曚綅鍚嶇О,
+ HHelpCode: data.鍔╄浠g爜,
+ HRate: data.鎹㈢畻姣斾緥 || "1",
+ HStandard: isStandard,
+ HStopflag: isStopped,
+ HRemark: data.澶囨敞 || "",
+ HUnitGroupID: data.HUnitGroupID || "0",
+ HUnitGroupName: data.璁¢噺鍗曚綅缁勫悕绉� || "",
+ HMakeEmp: data["鍒涘缓浜�"] || "",
+ HMakeDate: data["鍒涘缓鏃ユ湡"] ? dayjs(data["鍒涘缓鏃ユ湡"]).format("YYYY-MM-DD") : "",
+ HCheckEmp: data["瀹℃牳浜�"] || "",
+ HCheckDate: data["瀹℃牳鏃ユ湡"] ? dayjs(data["瀹℃牳鏃ユ湡"]).format("YYYY-MM-DD") : "",
+ HStopEmp: data["绂佺敤浜�"] || "",
+ HStopDate: data["绂佺敤鏃ユ湡"] ? dayjs(data["绂佺敤鏃ユ湡"]).format("YYYY-MM-DD") : "",
+ HUserName: this.user,
+ OrganizationID: this.organizationID
+ };
+
+ this.isEditMode = operationType === 3;
+ this.isAuditable = !data["瀹℃牳浜�"] && operationType === 3;
+
+ // 濡傛灉鏄凡瀹℃牳鍗曟嵁锛岀鐢ㄤ繚瀛樻寜閽�
+ if (data["瀹℃牳浜�"]) {
+ this.subDisabled = true;
+ }
+ } else {
+ this.$modal.msgError(result.msg || "鑾峰彇鏁版嵁澶辫触");
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ })
+ .finally(() => {
+ this.formShow = true;
+ this.formLoading = false;
+ });
+ },
+
+ // 璁剧疆榛樿鍊�
+ setDefaultValues() {
+ this.form.HMakeEmp = this.user;
+ this.form.HMakeDate = dayjs().format("YYYY-MM-DD");
+ this.form.OrganizationID = this.organizationID;
+ },
+
+ // 閲嶇疆琛ㄥ崟
+ reset() {
+ this.form = {
+ HItemID: 0,
+ HNumber: "",
+ HName: "",
+ HHelpCode: "",
+ HRate: "1",
+ HStandard: false,
+ HStopflag: false,
+ HRemark: "",
+ HUnitGroupID: "0",
+ HUnitGroupName: "",
+ HMakeEmp: "",
+ HMakeDate: "",
+ HCheckEmp: "",
+ HCheckDate: "",
+ HStopEmp: "",
+ HStopDate: "",
+ HUserName: this.user,
+ OrganizationID: this.organizationID
+ };
+ this.subDisabled = false;
+ },
+
+ // 閫夋嫨璁¢噺鍗曚綅缁�
+ selectUnitGroup() {
+ this.unitGroupIframeUrl = `/iframe/GyUnitGroup?type=select`;
+ this.unitGroupDialogVisible = true;
+
+ // 鐩戝惉鏉ヨ嚜iframe鐨勬秷鎭�
+ window.addEventListener('message', this.handleUnitGroupMessage);
+ },
+
+ // 澶勭悊璁¢噺鍗曚綅缁勯�夋嫨娑堟伅
+ handleUnitGroupMessage(event) {
+ if (event.data && event.data.action === 'selectUnitGroup') {
+ this.selectedUnitGroup = event.data.data;
+ }
+ },
+
+ // 纭閫夋嫨璁¢噺鍗曚綅缁�
+ confirmUnitGroup() {
+ if (this.selectedUnitGroup) {
+ this.form.HUnitGroupID = this.selectedUnitGroup.HItemID;
+ this.form.HUnitGroupName = this.selectedUnitGroup.璁¢噺鍗曚綅缁�;
+ }
+ this.unitGroupDialogVisible = false;
+ window.removeEventListener('message', this.handleUnitGroupMessage);
+ },
+
+ // 閫�鍑�
+ close() {
+ if (this.isIframe) {
+ // 鍦╥frame涓紝閫氱煡鐖剁獥鍙e叧闂垨杩斿洖
+ if (window.parent.editGyClose) {
+ window.parent.editGyClose();
+ } else {
+ // 灏濊瘯鍏抽棴iframe
+ try {
+ const index = parent.layer && parent.layer.getFrameIndex ? parent.layer.getFrameIndex(window.name) : null;
+ if (index !== null && index !== undefined) {
+ parent.layer.close(index);
+ } else {
+ // 濡傛灉娌℃湁layer锛屼娇鐢ㄥ叾浠栨柟寮�
+ window.parent.postMessage({ action: 'closeIframe' }, '*');
+ }
+ } catch (e) {
+ console.log("鍏抽棴iframe澶辫触:", e);
+ this.$router.back();
+ }
+ }
+ } else {
+ // 涓嶅湪iframe涓紝浣跨敤璺敱杩斿洖鎴栬烦杞�
+ if (this.$route) {
+ this.$router.back();
+ } else if (this.OperationType === 1) {
+ // 鏂板妯″紡锛岃繑鍥為椤�
+ window.location.href = "/index.html";
+ } else {
+ window.history.back();
+ }
+ }
+ },
+
+ // 鎻愪氦淇濆瓨
+ submitForm() {
+ this.$refs["form"].validate((valid) => {
+ if (valid) {
+ this.subDisabled = true;
+
+ // 鍑嗗鏁版嵁
+ const formData = {
+ ...this.form,
+ HStandard: this.form.HStandard ? "true" : "false",
+ HStopflag: this.form.HStopflag ? "true" : "false",
+ HRate: this.form.HRate.toString(), // 纭繚鏄瓧绗︿覆
+ HUserName: this.user,
+ OrganizationID: this.organizationID
+ };
+
+ // 鏋勫缓涓庡師椤甸潰鐩稿悓鐨勬牸寮�
+ const sMainStr = JSON.stringify(formData);
+ const additionalParams = `${this.user};${this.organizationID};${this.form.HRate}`;
+ const fullData = sMainStr + ';' + additionalParams;
+
+ const requestData = {
+ msg: fullData,
+ };
+
+ axios({
+ method: "POST",
+ url: this.baseURL + "SaveGy_UnitList",
+ data: requestData,
+ headers: {
+ 'Content-Type': 'application/json',
+ },
+ })
+ .then((response) => {
+ if (response.data.count == 1) {
+ this.$modal.msgSuccess(response.data.Message || "淇濆瓨鎴愬姛");
+ this.subDisabled = true;
+ this.form.HItemID = response.data.data; // 鑾峰彇杩斿洖鐨処D
+
+ // 濡傛灉鏄嚜鍔ㄥ鏍革紝鎵ц瀹℃牳
+ if (response.data.Verify === "Y") {
+ this.setCheckBillNoLayer();
+ }
+
+ // 閫氱煡鐖剁粍浠跺埛鏂�
+ if (window.parent && window.parent.handleQuery) {
+ window.parent.handleQuery();
+ }
+
+ } else {
+ this.$modal.msgError(response.data.Message || "淇濆瓨澶辫触");
+ this.subDisabled = false;
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("淇濆瓨澶辫触: " + (error.message || "鏈煡閿欒"));
+ this.subDisabled = false;
+ });
+ } else {
+ this.$modal.msgError("璇锋鏌ヨ〃鍗曟暟鎹�");
+ }
+ });
+ },
+
+ // 瀹℃牳锛堝甫纭妗嗭級
+ setCheckBill() {
+ this.$confirm('纭瑕佸鏍稿悧?', '鎻愮ず', {
+ confirmButtonText: '纭畾',
+ cancelButtonText: '鍙栨秷',
+ type: 'warning'
+ }).then(() => {
+ this.setCheckBillNoLayer();
+ }).catch(() => {
+ // 鐢ㄦ埛鍙栨秷
+ });
+ },
+
+ // 瀹℃牳锛堜笉甯︾‘璁ゆ锛�
+ setCheckBillNoLayer() {
+ if (!this.form.HItemID || this.form.HItemID == 0) {
+ this.$modal.msgError("璇峰厛淇濆瓨鍗曟嵁");
+ return;
+ }
+
+ axios({
+ method: "GET",
+ url: this.baseURL + "Gy_Unit/AuditGy_Unit",
+ params: {
+ HInterID: this.form.HItemID,
+ Type: 1,
+ user: this.user
+ }
+ })
+ .then((response) => {
+ if (response.data.count == 1) {
+ this.$modal.msgSuccess("瀹℃牳鎴愬姛");
+ this.isAuditable = false;
+ this.subDisabled = true;
+
+ // 鏇存柊瀹℃牳淇℃伅
+ this.form.HCheckEmp = this.user;
+ this.form.HCheckDate = dayjs().format("YYYY-MM-DD");
+
+ // 閫氱煡鐖剁粍浠跺埛鏂�
+ if (window.parent && window.parent.handleQuery) {
+ window.parent.handleQuery();
+ }
+ } else {
+ this.$modal.msgError(response.data.Message || "瀹℃牳澶辫触");
+ }
+ })
+ .catch((error) => {
+ this.$modal.msgError("瀹℃牳澶辫触: " + (error.message || "鏈煡閿欒"));
+ });
+ }
+ },
+ beforeDestroy() {
+ // 绉婚櫎浜嬩欢鐩戝惉鍣�
+ window.removeEventListener('message', this.handleUnitGroupMessage);
+ }
+};
+</script>
+
+<style scoped>
+.el-form-item {
+ margin-bottom: 22px;
+}
+
+.el-row {
+ margin-bottom: 10px;
+}
+
+.hidden-input {
+ display: none;
+}
+
+.readonly-input >>> .el-input__inner {
+ background-color: #f5f7fa;
+ color: #909399;
+ cursor: not-allowed;
+}
+</style>
\ No newline at end of file
diff --git a/src/views/basic/gyUnit/gyUnitGroup.vue b/src/views/basic/gyUnit/gyUnitGroup.vue
new file mode 100644
index 0000000..4490d0b
--- /dev/null
+++ b/src/views/basic/gyUnit/gyUnitGroup.vue
@@ -0,0 +1,289 @@
+<template>
+ <div style="padding: 15px; height: 100vh;">
+ <el-card style="margin-bottom: 15px;">
+ <el-form :inline="true" :model="queryForm" class="demo-form-inline">
+ <el-form-item label="杩囨护鍒�">
+ <el-input
+ v-model="queryForm.Value"
+ placeholder="璇疯緭鍏ヨ繃婊ゅ垪"
+ @keyup.enter.native="handleQuery"
+ ></el-input>
+ </el-form-item>
+ <el-form-item>
+ <el-button type="primary" @click="handleQuery">蹇�熸煡璇�</el-button>
+ </el-form-item>
+ </el-form>
+ </el-card>
+
+ <div style="height: calc(100% - 100px);">
+ <el-table
+ ref="mainTable"
+ :data="tableData"
+ stripe
+ border
+ highlight-current-row
+ height="100%"
+ @row-dblclick="handleRowDblclick"
+ @row-click="handleRowClick"
+ :row-class-name="tableRowClassName"
+ >
+ <el-table-column type="radio" width="55">
+ <template slot-scope="scope">
+ <el-radio
+ v-model="selectedRowId"
+ :label="scope.row.HItemID"
+ @change="handleRadioChange(scope.row)"
+ ></el-radio>
+ </template>
+ </el-table-column>
+ <el-table-column prop="HItemID" label="鍗曚綅缁処D" width="150" v-if="false"></el-table-column>
+ <el-table-column prop="璁¢噺鍗曚綅缁勪唬鐮�" label="璁¢噺鍗曚綅缁勪唬鐮�" width="150"></el-table-column>
+ <el-table-column prop="璁¢噺鍗曚綅缁�" label="璁¢噺鍗曚綅缁�" width="150" sortable></el-table-column>
+ </el-table>
+
+ <el-pagination
+ background
+ layout="total, sizes, prev, pager, next"
+ :total="total"
+ :page-sizes="[50, 500, 5000, 50000]"
+ :page-size="pageSize"
+ :current-page="currentPage"
+ @size-change="handleSizeChange"
+ @current-change="handleCurrentChange"
+ style="margin-top: 10px; text-align: right;"
+ >
+ </el-pagination>
+ </div>
+ </div>
+</template>
+
+<script>
+import axios from "axios";
+
+export default {
+ name: "GyUnitGroupSelect",
+ data() {
+ return {
+ queryForm: {
+ Value: "",
+ },
+ tableData: [],
+ selectedRow: null,
+ selectedRowId: null, // 鐢ㄤ簬radio缁戝畾
+ total: 0,
+ currentPage: 1,
+ pageSize: 50,
+ type: "select", // 浠嶶RL鍙傛暟涓幏鍙�
+ baseURL: process.env.VUE_APP_BASE_API || "http://47.96.97.237/API/",
+ };
+ },
+ created() {
+ this.getUrlParams();
+ this.getUnitGroupList();
+ },
+ methods: {
+ // 浠嶶RL鑾峰彇鍙傛暟
+ getUrlParams() {
+ const queryString = window.location.search.substring(1);
+ const pairs = queryString.split('&');
+
+ for (let i = 0; i < pairs.length; i++) {
+ const pair = pairs[i].split('=');
+ if (pair.length === 2) {
+ const key = decodeURIComponent(pair[0]);
+ const value = decodeURIComponent(pair[1]);
+ if (key === 'type') {
+ this.type = value;
+ }
+ }
+ }
+ },
+
+ // 鏌ヨ鏁版嵁
+ handleQuery() {
+ this.currentPage = 1;
+ this.getUnitGroupList();
+ },
+
+ // 鑾峰彇璁¢噺鍗曚綅缁勫垪琛�
+ getUnitGroupList() {
+ axios
+ .get(this.baseURL + "Web/GetUnitGroupList_Json", {
+ params: {
+ Unit: this.queryForm.Value || "",
+ },
+ })
+ .then((response) => {
+ if (response.data && response.data.data) {
+ this.tableData = response.data.data;
+ this.total = response.data.data.length;
+
+ // 閲嶇疆閫変腑鐘舵��
+ this.selectedRow = null;
+ this.selectedRowId = null;
+ } else {
+ this.tableData = [];
+ this.total = 0;
+ }
+ })
+ .catch((error) => {
+ console.error("鑾峰彇璁¢噺鍗曚綅缁勫垪琛ㄥけ璐�:", error);
+ this.$message.error("鑾峰彇鏁版嵁澶辫触");
+ });
+ },
+
+ // 杩斿洖閫夋嫨缁撴灉 - 淇敼杩欓噷纭繚鑳借繑鍥炰俊鎭�
+ handleReturn() {
+ if (!this.selectedRow) {
+ this.$message.warning("璇烽�夋嫨涓�鏉℃暟鎹�");
+ return;
+ }
+
+ // 棣栧厛灏濊瘯閫氳繃postMessage浼犻�掓暟鎹�
+ if (window.parent) {
+ window.parent.postMessage({
+ action: 'selectUnitGroup',
+ data: this.selectedRow
+ }, '*');
+ }
+
+ // 鍚屾椂灏濊瘯璋冪敤鐖剁獥鍙g殑鏂规硶
+ if (window.parent.GetHUnitGroupNameValue) {
+ window.parent.GetHUnitGroupNameValue([this.selectedRow]);
+ }
+
+ // 鍏抽棴褰撳墠绐楀彛
+ this.closeWindow();
+ },
+
+ // 鍙屽嚮琛屼簨浠� - 淇敼杩欓噷纭繚鑳藉叧闂獥鍙�
+ handleRowDblclick(row) {
+ this.selectedRow = row;
+ this.selectedRowId = row.HItemID;
+ this.$refs.mainTable.setCurrentRow(row);
+
+ // 浼犻�掓暟鎹粰鐖剁獥鍙�
+ if (window.parent) {
+ window.parent.postMessage({
+ action: 'selectUnitGroup',
+ data: this.selectedRow
+ }, '*');
+ }
+
+ if (window.parent.GetHUnitGroupNameValue) {
+ window.parent.GetHUnitGroupNameValue([this.selectedRow]);
+ }
+
+ // 鍏抽棴绐楀彛
+ this.closeWindow();
+ },
+
+ // 鍗曞嚮琛屼簨浠�
+ handleRowClick(row) {
+ this.selectedRow = row;
+ this.selectedRowId = row.HItemID;
+ this.$refs.mainTable.setCurrentRow(row);
+ // 浼犻�掓暟鎹粰鐖剁獥鍙�
+ if (window.parent) {
+ window.parent.postMessage({
+ action: 'selectUnitGroup',
+ data: this.selectedRow
+ }, '*');
+ }
+
+ if (window.parent.GetHUnitGroupNameValue) {
+ window.parent.GetHUnitGroupNameValue([this.selectedRow]);
+ }
+ },
+
+ // Radio閫夋嫨鍙樺寲
+ handleRadioChange(row) {
+ this.selectedRow = row;
+ this.$refs.mainTable.setCurrentRow(row);
+ },
+
+ // 鍏抽棴绐楀彛鐨勯�氱敤鏂规硶
+ closeWindow() {
+ try {
+ // 灏濊瘯浣跨敤layer鍏抽棴
+ if (parent.layer) {
+ const index = parent.layer.getFrameIndex(window.name);
+ if (index !== null && index !== undefined) {
+ parent.layer.close(index);
+ return;
+ }
+ }
+
+ // 灏濊瘯浣跨敤window.close
+ if (window.opener || window.parent !== window) {
+ window.close();
+ return;
+ }
+
+ // 灏濊瘯鍙戦�佸叧闂秷鎭�
+ if (window.parent) {
+ window.parent.postMessage({ action: 'closeSelectDialog' }, '*');
+ }
+
+ console.log("鏃犳硶鑷姩鍏抽棴绐楀彛锛岃鎵嬪姩鍏抽棴");
+ } catch (e) {
+ console.log("鍏抽棴绐楀彛澶辫触:", e);
+ }
+ },
+
+ // 璁剧疆琛ㄦ牸琛屾牱寮�
+ tableRowClassName({ row, rowIndex }) {
+ if (this.selectedRow && row.HItemID === this.selectedRow.HItemID) {
+ return 'selected-row';
+ }
+ return '';
+ },
+
+ // 鍒嗛〉澶у皬鏀瑰彉
+ handleSizeChange(val) {
+ this.pageSize = val;
+ this.currentPage = 1;
+ // 杩欓噷鍙互鏍规嵁闇�瑕侀噸鏂板姞杞芥暟鎹�
+ },
+
+ // 褰撳墠椤垫敼鍙�
+ handleCurrentChange(val) {
+ this.currentPage = val;
+ // 杩欓噷鍙互鏍规嵁闇�瑕侀噸鏂板姞杞芥暟鎹�
+ },
+ },
+};
+</script>
+
+<style scoped>
+/* 纭繚琛ㄦ牸鎾戞弧瀹瑰櫒 */
+.demo-form-inline {
+ margin-bottom: 0;
+}
+
+/* 琛ㄦ牸瀹瑰櫒鏍峰紡 */
+.table-container {
+ height: calc(100% - 60px);
+ overflow: auto;
+}
+
+/* 閫変腑琛屾牱寮� */
+.el-table .selected-row {
+ background-color: #f0f9ff !important;
+}
+
+.el-table .selected-row:hover > td {
+ background-color: #e6f7ff !important;
+}
+</style>
+
+<style>
+/* 鍏ㄥ眬鏍峰紡锛岀‘淇濆湪琛ㄦ牸鍐呴儴鐢熸晥 */
+.el-table .cell .el-radio {
+ margin-right: 0;
+}
+
+.el-table .cell .el-radio__label {
+ display: none;
+}
+</style>
\ No newline at end of file
diff --git a/src/views/logistics/transportGPS/Add_Edit_WL_YayBill.vue b/src/views/logistics/transportGPS/Add_Edit_WL_YayBill.vue
new file mode 100644
index 0000000..0e9c73f
--- /dev/null
+++ b/src/views/logistics/transportGPS/Add_Edit_WL_YayBill.vue
@@ -0,0 +1,10 @@
+<template>
+ <div style="padding: 10px;">
+ 2
+</div>
+</template>
+<script>
+ export default {
+ name: 'Add_Edit_WL_YayBill',
+ }
+</script>
\ No newline at end of file
diff --git a/src/views/logistics/transportGPS/WL_YayBill.vue b/src/views/logistics/transportGPS/WL_YayBill.vue
new file mode 100644
index 0000000..7804c82
--- /dev/null
+++ b/src/views/logistics/transportGPS/WL_YayBill.vue
@@ -0,0 +1,912 @@
+<template>
+ <div style="padding: 10px; position: relative;">
+ <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" label-width="78px" class="searchBox">
+ <el-form-item label="寮�濮嬫棩鏈�" style="margin-left: 100px;">
+ <el-date-picker v-model="queryParams.sTime" type="date" placeholder="寮�濮嬫棩鏈�" style="width: 150px;">
+ </el-date-picker>
+ </el-form-item>
+ <el-form-item label="缁撴潫鏃ユ湡">
+ <el-date-picker v-model="queryParams.eTime" type="date" placeholder="缁撴潫鏃ユ湡" style="width: 150px;">
+ </el-date-picker>
+ </el-form-item>
+ <el-form-item label="鏃ユ湡闂撮殧">
+ <el-select v-model="queryParams.HInitTimeCycle" placeholder="璇烽�夋嫨" @change="riqiChange"
+ style="width: 150px;">
+ <el-option v-for="(item, index) in rqsgList" :key="index" :label="item.label" :value="item.value">
+ </el-option>
+ </el-select>
+ </el-form-item>
+ <el-form-item label="鍗曟嵁鍙�" prop="HBillNo">
+ <el-input v-model="queryParams.HBillNo" placeholder="璇疯緭鍏ュ崟鎹彿" @keyup.enter.native="handleQuery" />
+ </el-form-item>
+ <el-form-item label="缁勭粐" prop="HOrgID">
+ <el-select v-model="queryParams.HOrgID" 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 icon="el-icon-circle-close" @click="resetQuery">閲� 缃�</el-button>
+ </el-form-item>
+ <el-collapse v-model="activeSeach">
+ <el-collapse-item title="鏇村" name="1">
+ <el-card class="box-card">
+ <el-form-item label="渚涘簲鍟�" prop="HSupName">
+ <el-input v-model="queryParams.HSupName" placeholder="璇疯緭鍏ヤ緵搴斿晢鍚嶇О"
+ @keyup.enter.native="handleQuery" />
+ </el-form-item>
+ <el-form-item label="鐗╂枡浠g爜" prop="HMaterNumber">
+ <el-input v-model="queryParams.HMaterNumber" placeholder="璇疯緭鍏ョ墿鏂欎唬鐮�"
+ @keyup.enter.native="handleQuery" />
+ </el-form-item>
+ <el-form-item label="鐗╂枡鍚嶇О" prop="HMaterName">
+ <el-input v-model="queryParams.HMaterName" placeholder="璇疯緭鍏ョ墿鏂欏悕绉�"
+ @keyup.enter.native="handleQuery" />
+ </el-form-item>
+ <div slot="header" class="clearfix"><span>杩囨护</span></div>
+ <div>
+ <el-row>
+ <el-form-item label-width="0">
+ <el-row>
+ <el-col :span="7">
+ <el-select v-model="queryParams.ColName1" placeholder="璇烽�夋嫨"
+ @change="riqiChange">
+ <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="璇烽�夋嫨"
+ @change="riqiChange">
+ <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-row>
+ <el-form-item label-width="0">
+ <el-row>
+ <el-col :span="7">
+ <el-select v-model="queryParams.ColName2" placeholder="璇烽�夋嫨"
+ @change="riqiChange">
+ <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="璇烽�夋嫨"
+ @change="riqiChange">
+ <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.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="璇烽�夋嫨" @change="riqiChange">
+ <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="璇烽�夋嫨"
+ @change="riqiChange">
+ <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-document-copy" size="mini" :disabled="single"
+ @click="handleEdit(row = rowForm, OperationType = 1, copyType = 1)">澶嶅埗</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-edit-outline" size="mini" :disabled="single"
+ @click="set_CheckBill(0, form = rowForm)">瀹℃牳</el-button>
+ </el-col>
+ <el-col :span="1.5">
+ <el-button type="primary" icon="el-icon-edit-outline" size="mini" :disabled="single"
+ @click="set_CheckBill(1, form = rowForm)">杩斿鏍�</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-date" size="mini" @click="handleRowHide">闅愯棌鍒楄缃�</el-button>
+ </el-col>
+ <el-col :span="1.5">
+ <el-button type="primary" icon="el-icon-printer" size="mini" @click="get_PrintReport">鎵撳嵃</el-button>
+ </el-col>
+ <el-col :span="1.5">
+ <el-button type="primary" icon="el-icon-printer" size="mini" :disabled="single"
+ @click="get_BarCodeDetail">鏉$爜鏄庣粏</el-button>
+ </el-col>
+ <el-col :span="1.5">
+ <el-button type="primary" icon="el-icon-printer" size="mini" :disabled="single"
+ @click="get_PackStockDetail">鍖呰瀹瑰櫒鍑哄叆搴撴槑缁�</el-button>
+ </el-col>
+ </el-row>
+ <div class="tableBox" v-loading="loading">
+ <el-table :data="tableData" ref="tableData" max-height="710" :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.id" 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">
+ <span v-if="column.property.includes('鏃ユ湡')">{{ parseTime(row[column.property],
+ '{y}-{m}-{d}') }}</span>
+ <el-button type="text" @click="handleEdit(row, OperationType = 3)"
+ v-else-if="column.property == '鍗曟嵁鍙�'">{{
+ row.鍗曟嵁鍙�
+ }}</el-button>
+ <span v-else>{{ row[column.label] }}</span>
+ </div>
+ </template>
+ </el-table-column>
+ </template>
+ </el-table>
+ <!-- 璁板綍鏁般�侀〉鏁般�佸綋鍓嶉〉 -->
+ <pagination v-show="total > 0" :total="total" :page.sync="page" :limit.sync="pageSize"
+ @pagination="handleQuery" />
+ <!-- 鍒楄缃� -->
+ <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="缂栬緫" :visible.sync="openEdit" width="1480px" append-to-body class="xsckdBox"
+ @close="close">
+ <edit :OperationType=OperationType :linterid=this.rowForm.HInterID
+ :HSouceBillType=this.rowForm.HSourceBillType :copyType="copyType" @editClose="editClose"
+ v-if="editShow" />
+ </el-dialog>
+ <!-- 鎵撳嵃 -->
+ <el-dialog title="鎵撳嵃妯℃澘閫夋嫨" :visible.sync="openPrintList" width="800px" append-to-body>
+ <PrintList :linterid=this.rowForm.HInterID :MyMsg=this.rowForm.HInterID :Type='HBillType'
+ :HModName="HModName" @rowEditClose="rowSetClose" v-if="printListShow" />
+ <!-- <div>111</div> -->
+ </el-dialog>
+ <!-- 鏉$爜鏄庣粏 -->
+ <BarCodeDetail :visible.sync="barCodeDetailShow" ref="barcodeDetail" />
+ <!-- 鍖呰瀹瑰櫒鍑哄叆搴撴槑缁� -->
+ <PackStockDetail :visible.sync="packStockDetailShow" ref="packStockDetail" />
+ </div>
+ </div>
+</template>
+
+<script>
+import axios from 'axios'
+import moment from 'moment'; //鏃堕棿鏍煎紡鍖�
+import RowSettings from '@/views/component/rowSettings' //鍒楄缃粍浠�
+import PrintList from '@/views/component/printList' //鎵撳嵃缁勪欢
+import BarCodeDetail from '@/views/component/BarCodeDetail' //鏉$爜鏄庣粏缁勪欢
+import PackStockDetail from '@/views/component/PackStockDetail' //鏉$爜鏄庣粏缁勪欢
+import Edit from '@/views/logistics/transportGPS/Add_Edit_WL_YayBill' //缂栬緫椤甸潰缁勪欢
+
+export default {
+ name: 'WL_YayBill',
+ components: { RowSettings, Edit, PrintList, BarCodeDetail, PackStockDetail },
+ data() {
+ return {
+ baseURL: process.env.VUE_APP_BASE_API, //鍚庣鎺ュ彛鍓嶇紑(鍚庣鏈嶅姟鍣╥p鍦板潃)
+
+ HModName: "Cg_ContractTransportBillMainList",
+ HBillType: "Cg_ContractTransportBillMainList",
+ OperationType: null, //淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
+ copyType: 0, //澶嶅埗鏍囪銆傛墦寮�缂栬緫缁勪欢鏃讹紝鐢ㄤ簬鍖哄垎缂栬緫杩樻槸澶嶅埗
+ HInterID: null,
+ hPriceTypeList: ['鎴愭湰浠�', '缁撶畻浠�'],
+
+ rqsgList: [ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鏁版嵁
+ { label: '浠婂ぉ', value: 0 },
+ { label: '杩戜袱澶�', value: 1 },
+ { label: '杩戜笁澶�', value: 2 },
+ { label: '杩戝洓澶�', value: 3 },
+ { label: '杩戜簲澶�', value: 4 },
+ { label: '杩戝叚澶�', value: 5 },
+ { label: '杩戜竷澶�', value: 6 },
+ { label: '杩�30澶�', value: 29 },
+ { label: '杩戝崐骞�', value: 180 },
+ { label: '杩戜竴骞�', value: 365 },
+ ],
+ organizationList: JSON.parse(sessionStorage.getItem('organizationList')), //缁勭粐鍒楄〃
+ btList: [], //鍒楄〃琛ㄥご瀛楁鍒楄〃
+ 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' },
+ ],
+
+ dialogTitle: '', // 寮圭獥鏍囬
+ title: "", // 寮瑰嚭灞傛爣棰�
+ open: false, // 鏄惁鏄剧ず寮瑰嚭灞�
+ loading: true, // 閬僵灞�
+
+ activeSeach: '',
+ // addBtnShow: false, //缂栬緫缁勪欢瀹瑰櫒鏄剧ず鏍囪
+ editShow: false, //缂栬緫缁勪欢瀹瑰櫒鏄剧ず鏍囪
+ openEdit: false, //缂栬緫缁勪欢鏄剧ず鏍囪
+ openPrintList: false, //鎵撳嵃缁勪欢瀹瑰櫒鏄剧ず鏍囪
+ printListShow: false, //鎵撳嵃缁勪欢鏄剧ず鏍囪
+ openBtnHide: false, //鎸夐挳缁勪欢瀹瑰櫒鏄剧ず鏍囪
+ btnHideShow: false, //鎸夐挳缁勪欢鏄剧ず鏍囪
+ openRowHide: false, //鍒楄缃粍浠舵樉绀烘爣璁�
+ rowHideShow: false, //鍒楄缃粍浠跺鍣ㄦ樉绀烘爣璁�
+ barCodeDetailShow: false, //鏉$爜鏄庣粏缁勪欢瀹瑰櫒鏄剧ず鏍囪
+ packStockDetailShow: false, //鍖呰瀹瑰櫒鍑哄叆搴撴槑缁嗗鍣ㄦ樉绀烘爣璁�
+
+
+
+ // 鏌ヨ鍙傛暟
+ sWhere: '', // 鎷兼帴杩囨护鏉′欢
+ queryParams: { // form鏁版嵁
+ HBillNo: '',
+ HInitTimeCycle: 29,
+ sTime: '',
+ eTime: '',
+ HOrgID: sessionStorage["OrganizationID"] - 0,
+ HSupName: null,
+ HMaterNumber: '',
+ HMaterName: '',
+ ColName1: '',
+ ColName2: '',
+ ColName: '',
+ Comparator1: '',
+ Comparator2: '',
+ Comparator: '',
+ ColContent1: '',
+ ColContent2: '',
+ ColContent: '',
+ },
+
+ page: 1, //page椤电储寮�
+ pageSize: 0, //page椤甸潰璁板綍鏁�
+ total: 0, //璁板綍鍚堣鏁�
+ tableShow: true, // table鏄剧ず鏍囪
+ totalNameList: [], // 闇�瑕佽缃悎璁¤鐨勫垪鏁扮粍
+ tableData: [], // 鍒楄〃鏁版嵁銆傜敤浜巘able鐩戝惉浜嬩欢
+ ids: [], // 閫変腑琛岀殑hmainid鏁扮粍
+ single: true, // 褰撻�変腑鐨勮鏁颁笉涓�1鏃朵负true銆傜敤浜庣鐢ㄧ浉鍏虫搷浣�
+ multiple: true, // 褰撻�変腑鐨勮鏁颁负0鏃朵负true銆傜敤浜庣鐢ㄧ浉鍏虫搷浣�
+ lastSelectedRowIndex: null, // 鐢ㄤ簬璁板綍涓婃鐐瑰嚮鐨勮绱㈠紩
+ lastSelectedRow: null, // 涓婁竴娆¢�変腑鐨勮
+ selectedRow: null, // 褰撳墠閫変腑鐨勮
+ rowForm: {}, // 褰撻�変腑鐨勫彧鏈変竴琛屾椂锛屾洿鏂版暟鎹负璇ラ�変腑鐨勮銆�
+
+ tyResList: [], // 鍒楄〃鏁版嵁锛岀敤浜庡鍑�
+ titleData: ["HInterID", "HEntryID", "HBillStatus", "HMaterID", "HPreventErrMouldID","HOrgID"], // 涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+ btResList: [], // 鍒楄〃琛ㄥご鏁版嵁銆傜敤浜庡垪璁剧疆
+ dataList: [], // option璁板綍銆傜敤浜庡綋option鏁版嵁鏃犳晥鏃讹紝鐢ㄤ簬鍒楄缃�
+ };
+ },
+ created() {
+ this.riqiChange()
+ this.handleQuery();
+ },
+
+ methods: {
+ //#region 璁剧疆琛ㄥご
+ 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)
+ },
+ //#endregion
+
+ //#region 鐐瑰嚮琛�
+ handleRowClick(row, column, event) {
+ this.lastSelectedRow = this.selectedRow; // 璁板綍涓婁竴娆¢�変腑鐨勮
+ this.selectedRow = row; // 璁板綍褰撳墠閫変腑鐨勮
+ this.lastSelectedRowIndex = this.tableData.indexOf(row);
+ this.$refs.tableData.toggleRowSelection(row);
+ },
+ //#endregion
+
+ //#region 閫変腑琛岄珮浜牱寮�
+ rowStyle({ row, rowIndex }) {
+ if (this.ids.includes(row.HInterID)) {
+ return { "background": "#ecf5ff" }
+ }
+ },
+ //#endregion
+
+ //#region 鍙屽嚮琛�
+ handleDblclick(row, column, cell, event) {
+ this.OperationType = 3
+ this.handleEdit()
+ },
+ //#endregion
+
+ //#region 澶氶�夋閫変腑鏁版嵁
+ handleSelectionChange(selection) {
+ // this.rowForm = {}
+ this.ids = selection.map(item => item.HInterID)
+ this.single = selection.length != 1
+ this.multiple = !selection.length
+ if (!this.single) {
+ this.rowForm = selection[0]
+ }
+ },
+ //#endregion
+
+ //#region 鏍规嵁鏃ユ湡闂撮殧锛岃缃紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ riqiChange() {
+ const end = new Date();
+ const start = new Date();
+ start.setTime(start.getTime() - 3600 * 1000 * 24 * this.queryParams.HInitTimeCycle);
+ const yyyyS = start.getFullYear();
+ const mmS = String(start.getMonth() + 1).padStart(2, '0'); // 鏈堜唤鏄粠0寮�濮嬬殑
+ const ddS = String(start.getDate()).padStart(2, '0');
+ const yyyyE = end.getFullYear();
+ const mmE = String(end.getMonth() + 1).padStart(2, '0'); // 鏈堜唤鏄粠0寮�濮嬬殑
+ const ddE = String(end.getDate()).padStart(2, '0');
+ this.queryParams.sTime = yyyyS + '-' + mmS + '-' + ddS
+ this.queryParams.eTime = yyyyE + '-' + mmE + '-' + ddE
+ },
+ //#endregion
+
+ //#region 閲嶇疆
+ resetQuery() {
+ this.sWhere = ''
+ this.queryParams = {
+ HBillNo: '',
+ HInitTimeCycle: 29,
+ HSupName: null,
+ HMaterNumber: '',
+ HMaterName: '',
+ ColName1: '',
+ ColName2: '',
+ ColName: '',
+ Comparator1: '',
+ Comparator2: '',
+ Comparator: '',
+ ColContent1: '',
+ ColContent2: '',
+ ColContent: '',
+ }
+ this.riqiChange()
+ this.resetForm("queryForm")
+ this.handleQuery()
+ },
+ //#endregion
+
+ //#region 蹇�熻繃婊�
+ 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.sTime) {
+ this.queryParams.sTime = moment(this.queryParams.sTime).format('YYYY-MM-DD')
+ this.queryParams.eTime = moment(this.queryParams.eTime).format('YYYY-MM-DD')
+ console.log(this.queryParams.sTime, this.queryParams.eTime)
+ this.sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + this.queryParams.sTime + "'" + " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + this.queryParams.eTime + "'";
+ }
+ if (this.queryParams.HBillNo) {
+ this.sWhere += " and 鍗曟嵁鍙� like '%" + this.queryParams.HBillNo + "%'";
+ }
+ // if (this.queryParams.HOrgID) {
+ // this.sWhere += " and HOrgID = '" + this.queryParams.HOrgID + "'";
+ // }
+ this.getList()
+ },
+ //#endregion
+
+ //#region 鏌ヨ
+ getList() {
+ this.pageSize = 50
+ if (this.pageSize == 0) {
+ this.pageSize = 50
+ }
+ this.tableShow = false
+ this.loading = true
+
+ // 鍒楄〃鏌ヨ
+ axios.get(this.baseURL + '/WLYayBillController/GetListPage', {
+ params: {
+ "sWhere": this.sWhere,
+ "user": sessionStorage["HUserName"],
+ "page": this.page,
+ "size": this.pageSize
+ },
+ }).then(response => {
+ this.tyResList = response.data.data//鎬绘暟鎹�
+ let data1 = response.data
+ let option = []
+ if (data1.code == 1) {
+ this.btResList = data1.list //鍒楄〃琛ㄥご鏁版嵁
+ this.total = data1.count;
+ var data = [];//鍒楀瓧娈垫暟鎹�
+ var col = [];
+ var totalArray = [];
+ //缁欑┖鐨勬暟缁勮祴鍊�
+ for (var key in data1.list) {//寰簭閬嶅巻鏁扮粍
+ data.push({ "id": data1.list[key].ColmCols, "name": data1.list[key].ColmCols, "Type": data1.list[key].ColmType });//浠庢瘡涓璞′腑鎻愬彇鏁版嵁
+ }
+ //鍦ㄥ垪琛ㄥ乏杈规坊鍔犲嬀閫夋
+ col.push({ type: 'checkbox', fixed: 'left', totalRowText: '鍚堣' });
+ for (var i = 0; i < data.length; i++) {//閬嶅巻data鏁扮粍閲嶇殑鏁版嵁
+ if (this.titleData.indexOf(data[i].name) > -1) {//妫�鏌ata銆恑銆�.name鏄惁鍦ㄦ暟缁勪腑 //璁$畻鍒�
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', hide: true }); //闅愯棌id鍒�
+ } else if (totalArray.indexOf(data[i].name) > -1 || (data[i].Type == "Decimal" || data[i].Type == "Int32")) { //璁$畻鍒�
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, totalRow: true, width: 120 });
+ }
+ else {
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200 });
+ }
+ }
+ option.cols = [col]
+ this.dataList = option
+ option.data = data1.data;
+ var result = data1.data;
+ option.data = result;
+ let HModName = this.HModName
+ this.DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, this.dataList);
+ }
+ }).catch(error => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+
+ //#region 鍚堣琛屾暟鎹鐞�
+ 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;
+ },
+ //#endregion
+
+ //#endregion
+
+ //#region 鏂板
+ handleAddEdit() {
+ this.rowForm.HInterID = 0
+ this.editShow = true
+ this.openEdit = true
+ },
+ //#endregion
+
+ //#region 缂栬緫
+ handleEdit(row) {
+ this.rowForm = row
+ this.editShow = true
+ this.openEdit = true
+ },
+ editClose(val) {
+ this.open = val
+ this.editShow = false
+ this.openEdit = val
+ this.handleQuery()
+ },
+ //#endregion
+
+ //#region 鍒犻櫎
+ handleDelete() {
+ this.$modal.confirm('纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠').then(() => {
+ if (this.rowForm.鐘舵�� == "鍒涘缓") {
+ axios.get(this.baseURL + "/Kf_POStockInBill/DeltetKf_POStockInBill", {
+ params: { 'HInterID': this.rowForm.HInterID.toString(), 'user': sessionStorage["HUserName"] }
+ }).then(response => {
+ if (response.data.count == 1) {
+ this.handleQuery()
+ this.$modal.msgSuccess("鍒犻櫎鎴愬姛")
+ } else {
+ this.$modal.msgError("閿欒:" + result.code + result.Message);
+ }
+ }).catch(error => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ } else {
+ this.$modal.msgError("姝ゆ潯鏁版嵁涓嶆槸鍒涘缓鐘舵��,鏃犳硶鍒犻櫎!");
+ }
+ }).catch(() => { })
+ },
+ //#endregion
+
+ //#region 瀹℃牳/鍙嶅鏍�
+ set_CheckBill(num, form) {
+ var InterID = form.hmainid || form.HInterID
+ //閫昏緫瀹℃牳鏂规硶
+ axios.get(this.baseURL + "/Kf_POStockInBill/AuditKf_POStockInBill", {
+ params: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] }
+ }).then(response => {
+ let result = response.data
+ if (result.code == 1) {
+ this.$modal.msgSuccess('鎿嶄綔鎴愬姛');
+ this.handleQuery();
+ }
+ else {
+ this.$modal.msgError("閿欒:" + result.code + result.Message,);
+ }
+ }).catch(error => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ //#endregion
+
+ //#region 鍒楄缃�
+ handleRowHide() {
+ this.rowHideShow = true
+ this.openRowHide = true
+ },
+ rowSetClose(val) {
+ this.rowHideShow = false
+ this.tableShow = true
+ this.openRowHide = val
+ this.handleQuery()
+ },
+ 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.tableData = option.data
+ this.tableShow = true
+ this.loading = false
+ } else {
+ this.btList = dataOption.cols[0]
+ this.btList.map(item => {
+ if (!item.hide) {
+ this.totalNameList.push(item)
+ }
+ })
+ this.tableData = dataOption.data
+ this.tableShow = true
+ this.loading = false
+ }
+ }).catch(error => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ //#endregion
+
+ //#region 鎸夐挳璁剧疆
+ handleBtnHide() {
+ this.btnHideShow = true
+ this.openBtnHide = true
+ },
+ //#endregion
+
+ //#region 瀵煎嚭
+ 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, `Cg_ContractTransportBillMainList_${new Date().getTime()}.xlsx`); // 瀵煎嚭鏂囦欢
+ },
+ //#endregion
+
+ //#region 鎵撳嵃
+ get_PrintReport() {
+ if (this.ids.length != 1) {
+ this.$modal.msgError("璇烽�夋嫨涓�琛屾暟鎹�")
+ } else if (this.rowForm.鐘舵�� != "宸插鏍�" && !this.defaintOperationByCompanyName()) {
+ this.$modal.msgError("鎵撳嵃澶辫触!鍘熷洜锛氬崟鎹姸鎬佷笉涓�'宸插鏍�'鐘舵��!!");
+ } else {
+ axios.get(this.baseURL + "/Kf_SellOutBill/CheckSellOutBill_IsExist", {
+ params: { "HInterID": this.rowForm.HInterID }
+ }).then(response => {
+ var result = response.data
+ if (result.count == 1) {
+ this.printListShow = true
+ this.openPrintList = true
+ // this.$router.push({ path:'/printList', query: { linterid: this.rowForm.hmainid,MyMsg:this.rowForm.hmainid,Type:'Kf_SellOutBillList' }})
+ } else {
+ this.$modal.msgError(result.code + result.Message)
+ }
+ }).catch(error => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+
+
+ }
+ // var content= ['../../BaseSet/SRM_OpenTmpList.html?linterid=' + data[0].hmainid.toString() + '&MyMsg=' + data[0].hmainid.toString() + '&Type=Kf_SellOutBillList', 'yes']
+ },
+ //#endregion
+
+ //#region 鏉$爜鏄庣粏
+ get_BarCodeDetail() {
+ // if (this.selectedRow.length !== 1) {
+ // this.$message.warning('璇烽�夋嫨涓�琛屾暟鎹煡鐪嬫潯鐮佹槑缁嗭紒')
+ // return
+ // }
+ this.barCodeDetailShow = true
+ this.$nextTick(() => {
+ this.$refs.barcodeDetail.open(this.rowForm)
+ })
+ },
+ //#endregion
+
+ //#region 鍖呰瀹瑰櫒鍑哄叆搴撴槑缁�
+ get_PackStockDetail() {
+ // if (this.selectedRow.length !== 1) {
+ // this.$message.warning('璇烽�夋嫨涓�琛屾暟鎹煡鐪嬫潯鐮佹槑缁嗭紒')
+ // return
+ // }
+ this.packStockDetailShow = true
+ this.$nextTick(() => {
+ this.$refs.packStockDetail.open(this.rowForm)
+ })
+ },
+ //#endregion
+
+ //#region 閫�鍑�
+ close() {
+ // this.reset()
+ this.tableShow = true
+ this.openEdit = false
+ this.editShow = false
+ this.handleQuery()
+ },
+ //#endregion
+
+ //#region 鑾峰彇鍏徃鍚嶏紝鏍规嵁鍏徃杩涜瀹氬埗鍖栧紑鍙�
+ defaintOperationByCompanyName() {
+ var result = false;
+ axios.get(this.baseURL + '/Xt_getInfo/getCompanyName').then(response => {
+ var data1 = response.data
+ if (data1.count == 1) {
+ if (data1.data == "姘村姟") {
+ result = true;
+ }
+ }
+ }).catch(error => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ return result;
+ },
+ //#endregion
+ }
+};
+</script>
+<style>
+.xsckdBox .el-date-editor.el-input {
+ width: 100%;
+}
+</style>
diff --git a/src/views/scMould/basicModeling/Gy_MouldFile.vue b/src/views/scMould/basicModeling/Gy_MouldFile.vue
index 7e4fa62..e45f187 100644
--- a/src/views/scMould/basicModeling/Gy_MouldFile.vue
+++ b/src/views/scMould/basicModeling/Gy_MouldFile.vue
@@ -95,9 +95,9 @@
</el-form-item>
</el-col>
<el-col :span="6">
- <el-form-item label="鍗曚綅" prop="HUnitName" v-show="isHide">
+ <el-form-item label="鍗曚綅" prop="HUnitName" v-show="isShow">
<el-input v-model="form.HUnitName" placeholder="璇疯緭鍏ュ崟浣�" disabled>
- <el-button slot="append" icon="el-icon-search"></el-button>
+ <el-button slot="append" icon="el-icon-search" @click="openDataDialog(11)"></el-button>
</el-input>
</el-form-item>
</el-col>
@@ -505,6 +505,7 @@
<GySupplier @deptEmitDb="dbEmitData" @deptEmit="emitData" :openPage="HModName" v-if="gySupplierShow" />
<GyCustomer @deptEmitDb="dbEmitData" @deptEmit="emitData" :openPage="HModName" v-if="gyCustomerShow" />
<GyStockPlace @deptEmitDb="dbEmitData" @deptEmit="emitData" :openPage="HModName" v-if="gyStockPlaceShow" />
+ <GyUnit @deptEmitDb="dbEmitData" @deptEmit="emitData" :openPage="HModName" v-if="gyUnitShow" />
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="deptClickSub">纭� 瀹�</el-button>
<el-button @click="deptClose">鍙� 娑�</el-button>
@@ -527,11 +528,12 @@
import GySupplier from '@/views/basic/gy/gySupplier.vue'
import GyCustomer from '@/views/GyCustomer'
import GyStockPlace from '@/views/basic/gyStockPlace/gyStockPlace.vue'
+import GyUnit from '@/views/basic/gyUnit/gyUnit.vue'
import moment from 'moment';
export default {
name: 'Gy_MouldFile',
- components: { Dept, Warehouse, Material, RowSettings, GyEmployee, GySource, GySupplier, GyCustomer, GyStockPlace },
+ components: { Dept, Warehouse, Material, RowSettings, GyEmployee, GySource, GySupplier, GyCustomer, GyStockPlace,GyUnit },
props: {
OperationType: { type: Number, },
linterid: { type: Number, },
@@ -569,6 +571,7 @@
gySupplierShow: false,
gyCustomerShow: false,
gyStockPlaceShow: false,
+ gyUnitShow: false,
deptform: {},//寮圭獥閫変腑鏁版嵁
openData: false,//鏁版嵁寮圭獥
dialogTitle: '',
@@ -856,6 +859,10 @@
}
this.gyStockPlaceShow = false
this.openData = false
+ } else if (num == 11){
+ this.gyUnitShow= false
+ this.openData = false
+
}
} else {
this.$modal.msgError("璇烽�夋嫨鍗曟潯鏁版嵁!");
@@ -962,7 +969,7 @@
HMouldDotCheckRuleInterID: 0,
HMouldMaintainRuleInterName: '',
HMouldMaintainRuleInterID: 0,
- HBarCode: '',
+ HBarCode: '1',
HMadeSupID: 0,
HMadeSupName: '',
HMouldClass: '',
@@ -1503,6 +1510,7 @@
this.gySupplierShow = false
this.gyCustomerShow = false
this.gyStockPlaceShow = false
+ this.gyUnitShow= false
},
// 鎵撳紑鏁版嵁鍒楄〃寮圭獥
openDataDialog(num, row) {
@@ -1543,6 +1551,10 @@
this.dialogTitle = '浠撲綅鍒楄〃'
this.gyStockPlaceShow = true
this.openData = true
+ } else if (num == 11) {
+ this.dialogTitle = '鍗曚綅鍒楄〃'
+ this.gyUnitShow = true
+ this.openData = true
}
},
}
diff --git a/src/views/scMould/basicModeling/Gy_MouldFileList.vue b/src/views/scMould/basicModeling/Gy_MouldFileList.vue
index ab3efee..01eddec 100644
--- a/src/views/scMould/basicModeling/Gy_MouldFileList.vue
+++ b/src/views/scMould/basicModeling/Gy_MouldFileList.vue
@@ -96,9 +96,9 @@
</el-collapse>
</el-form>
<el-row :gutter="10" class="mb8" style="margin-top: 10px;">
- <el-col :span="1.5">
+ <!-- <el-col :span="1.5">
<el-button type="primary" icon="el-icon-download" size="mini" @click="handleImport">瀵煎叆</el-button>
- </el-col>
+ </el-col> -->
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAddEdit(OperationType = 1)"
id="btn-Add">鏂板</el-button>
@@ -107,10 +107,10 @@
<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-col :span="1.5">
<el-button type="primary" icon="el-icon-edit" size="mini" :disabled="single"
- @click="handleEdit(row = rowForm, OperationType = 2)">澶嶅埗</el-button>
- </el-col>
+ @click="handleEdit(row = rowForm, copyType = 1)">澶嶅埗</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>
@@ -123,14 +123,14 @@
<el-button type="primary" icon="el-icon-edit" size="mini" :disabled="single"
@click="set_CheckBill(1, form = rowForm)">杩斿鏍�</el-button>
</el-col>
- <el-col :span="1.5">
+ <!-- <el-col :span="1.5">
<el-button type="primary" icon="el-icon-edit" size="mini" :disabled="single"
@click="set_De_Stop(0, form = rowForm)">绂佺敤</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-edit" size="mini" :disabled="single"
@click="set_De_Stop(1, form = rowForm)">鍙嶇鐢�</el-button>
- </el-col>
+ </el-col> -->
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-download" size="mini" @click="handleExport">瀵煎嚭</el-button>
</el-col>
@@ -295,7 +295,7 @@
HUSEORGID: sessionStorage["OrganizationID"] - 0,
HName: null,
HNumber: null,
- HMouldTypeID: null,
+ HMouldTypeID: 0,
Comparator1: '',
Comparator2: '',
Comparator: '',
@@ -412,11 +412,9 @@
"user": sessionStorage["HUserName"],
},
}).then(response => {
-
let data1 = response.data
if (data1.count == 1) {
let data = JSON.parse(data1.data)
- console.log(JSON.parse(data1.data))
var liStr = '[';
//閬嶅巻鐢熸垚涓昏彍鍗�
for (var i = 0; i < data.length; i++) {
@@ -438,7 +436,6 @@
this.treeOptions = JSON.parse(liStr);
}
}).catch(error => {
- console.log(error)
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
});
},
@@ -521,77 +518,78 @@
col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200 });
}
}
- option.cols = [[
- { type: 'checkbox', fixed: 'left', totalRowText: '鍚堣琛�' }
- , { field: 'hmainid', title: 'hmainid', sort: true, hide: true }
- , { field: '鏃ユ湡', title: '鏃ユ湡', sort: true }
- , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', sort: true, width: 120 }
- , { field: '鏉$爜缂栧彿', title: '鏉$爜缂栧彿', sort: true, width: 120 }
- , { field: '瀵瑰簲ERP鐗╂枡缂栫爜', title: '鐗╂枡缂栧彿', sort: true, width: 120 }
- , { field: '妯″叿缂栧彿', title: '瀹瑰櫒缂栧彿', sort: true, width: 120 }
- , { field: '妯″叿鍚嶇О', title: '瀹瑰櫒鍚嶇О', sort: true, width: 120 }
- , { field: '妯″叿鍨嬪彿', title: '瀹瑰櫒鍨嬪彿', sort: true, width: 120 }
- , { field: '妯″叿鍝佺被', title: '瀹瑰櫒鍝佺被', sort: true, width: 120 }
- , { field: '妯″叿鐘舵��', title: '瀹瑰櫒鐘舵��', sort: true, width: 120 }
- , { field: '妯″叿鍙敤鐘舵��', title: '妯″叿鍙敤鐘舵��', sort: true, width: 140 }
- , { field: '绌存暟', title: '绌存暟', sort: true, width: 120 }
- , { field: '瀵瑰簲ERP鐗╂枡缂栫爜', title: '瀹瑰櫒ERP鐗╂枡', sort: true, width: 140 }
- , { field: '鐩村緞', title: '鐩村緞', sort: true, width: 120 }
- , { field: '杈呭姪灞炴��', title: '杈呭姪灞炴��', sort: true, width: 120 }
- , { field: '杈呭姪灞炴��2', title: '杈呭姪灞炴��2', sort: true, width: 120 }
- , { field: '鍥惧彿', title: '鍥惧彿', sort: true, width: 120 }
- , { field: '鐢熶骇浜у搧鍨嬪彿', title: '鐢熶骇浜у搧鍨嬪彿', sort: true, width: 120 }
- , { field: 'HUnitID', title: 'HUnitID', hide: true, sort: true, width: 120 }
- , { field: '璁¢噺鍗曚綅浠g爜', title: '璁¢噺鍗曚綅浠g爜', sort: true, width: 120 }
- , { field: '璁¢噺鍗曚綅', title: '璁¢噺鍗曚綅', sort: true, width: 120 }
- , { field: '鍑哄巶鏃ユ湡', title: '鍑哄巶鏃ユ湡', sort: true, width: 120 }
- , { field: '鍑哄巶缂栧彿', title: '鍑哄巶缂栧彿', sort: true, width: 120 }
- , { field: '浣跨敤閮ㄩ棬浠g爜', title: '浣跨敤閮ㄩ棬浠g爜', sort: true, width: 120 }
- , { field: '浣跨敤閮ㄩ棬', title: '浣跨敤閮ㄩ棬', sort: true, width: 120 }
- , { field: 'HSupID', title: 'HSupID', hide: true, sort: true, width: 120 }
- , { field: '渚涘簲鍟嗕唬鐮�', title: '渚涘簲鍟嗕唬鐮�', sort: true, width: 120 }
- , { field: '渚涘簲鍟�', title: '渚涘簲鍟�', sort: true, width: 120 }
- , { field: 'HWhID', title: 'HWhID', hide: true, sort: true, width: 120 }
- , { field: '榛樿浠撳簱', title: '榛樿浠撳簱', sort: true, width: 120 }
- , { field: 'HSPID', title: 'HSPID', hide: true, sort: true, width: 120 }
- , { field: '榛樿浠撲綅', title: '榛樿浠撲綅', sort: true, width: 120 }
- , { field: '鐗堟湰', title: '鐗堟湰', sort: true, width: 120 }
- , { field: '褰撳墠浠撳簱', title: '褰撳墠浠撳簱', sort: true, width: 120 }
- , { field: '褰撳墠浠撲綅', title: '褰撳墠浠撲綅', sort: true, width: 120 }
- , { field: '铏氭嫙浠撶被鍨�', title: '铏氭嫙浠撶被鍨�', sort: true, width: 120 }
- , { field: '铏氭嫙浠�', title: '铏氭嫙浠�', sort: true, width: 120 }
- , { field: '褰撳墠妯″叿瑙勬牸', title: '褰撳墠瀹瑰櫒瑙勬牸', sort: true, width: 140 }
- , { field: '鍒濆妯″叿瑙勬牸', title: '鍒濆瀹瑰櫒瑙勬牸', sort: true, width: 140 }
- , { field: '褰撳墠璁捐瀵垮懡', title: '褰撳墠璁捐瀵垮懡', sort: true, totalRow: true, width: 140 }
- , { field: '鍒濆璁捐瀵垮懡', title: '鍒濆璁捐瀵垮懡', sort: true, totalRow: true, width: 140 }
- , { field: '浣跨敤瀵垮懡', title: '浣跨敤瀵垮懡', sort: true, totalRow: true, width: 120 }
- , { field: '鍓╀綑瀵垮懡', title: '鍓╀綑瀵垮懡', sort: true, totalRow: true, width: 120 }
- , { field: '宸茬敓浜ф暟閲�', title: '宸茬敓浜ф暟閲�', sort: true, totalRow: true, width: 120 }
- , { field: '宸茬敓浜ч噸閲�', title: '宸茬敓浜ч噸閲�', sort: true, totalRow: true, width: 120 }
- , { field: '澶囨敞', title: '澶囨敞', sort: true, width: 120 }
- , { field: '鍏宠仈鏁伴噺', title: '鍏宠仈鏁伴噺', sort: true, totalRow: true, width: 120 }
- , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', sort: true, width: 120 }
- , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', sort: true, width: 120 }
- , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', sort: true, width: 120 }
- , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', sort: true, width: 120 }
- , { field: '淇敼浜�', title: '淇敼浜�', sort: true, width: 120 }
- , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', sort: true, width: 120 }
- , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', sort: true, width: 120 }
- , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', sort: true, width: 120 }
- , { field: '浣滃簾浜�', title: '浣滃簾浜�', sort: true, width: 120 }
- , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', sort: true, width: 120 }
- , { field: 'hbilltype', title: 'hbilltype', hide: true, sort: true, width: 120 }
- , { field: '鍗曟嵁绫诲瀷', title: '鍗曟嵁绫诲瀷', hide: true, sort: true, width: 120 }
- , { field: 'HMoudType', title: 'HMoudType', hide: true, sort: true, width: 120 }
- , { field: 'hsubid', title: 'hsubid', hide: true, sort: true, width: 120 }
- ]]
+ option.cols = [col]
+ // option.cols = [[
+ // { type: 'checkbox', fixed: 'left', totalRowText: '鍚堣琛�' }
+ // , { field: 'hmainid', title: 'hmainid', sort: true, hide: true }
+ // , { field: '鏃ユ湡', title: '鏃ユ湡', sort: true }
+ // , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', sort: true, width: 120 }
+ // , { field: '鏉$爜缂栧彿', title: '鏉$爜缂栧彿', sort: true, width: 120 }
+ // , { field: '瀵瑰簲ERP鐗╂枡缂栫爜', title: '鐗╂枡缂栧彿', sort: true, width: 120 }
+ // , { field: '妯″叿缂栧彿', title: '瀹瑰櫒缂栧彿', sort: true, width: 120 }
+ // , { field: '妯″叿鍚嶇О', title: '瀹瑰櫒鍚嶇О', sort: true, width: 120 }
+ // , { field: '妯″叿鍨嬪彿', title: '瀹瑰櫒鍨嬪彿', sort: true, width: 120 }
+ // , { field: '妯″叿鍝佺被', title: '瀹瑰櫒鍝佺被', sort: true, width: 120 }
+ // , { field: '妯″叿鐘舵��', title: '瀹瑰櫒鐘舵��', sort: true, width: 120 }
+ // , { field: '妯″叿鍙敤鐘舵��', title: '妯″叿鍙敤鐘舵��', sort: true, width: 140 }
+ // , { field: '绌存暟', title: '绌存暟', sort: true, width: 120 }
+ // , { field: '瀵瑰簲ERP鐗╂枡缂栫爜', title: '瀹瑰櫒ERP鐗╂枡', sort: true, width: 140 }
+ // , { field: '鐩村緞', title: '鐩村緞', sort: true, width: 120 }
+ // , { field: '杈呭姪灞炴��', title: '杈呭姪灞炴��', sort: true, width: 120 }
+ // , { field: '杈呭姪灞炴��2', title: '杈呭姪灞炴��2', sort: true, width: 120 }
+ // , { field: '鍥惧彿', title: '鍥惧彿', sort: true, width: 120 }
+ // , { field: '鐢熶骇浜у搧鍨嬪彿', title: '鐢熶骇浜у搧鍨嬪彿', sort: true, width: 120 }
+ // , { field: 'HUnitID', title: 'HUnitID', hide: true, sort: true, width: 120 }
+ // , { field: '璁¢噺鍗曚綅浠g爜', title: '璁¢噺鍗曚綅浠g爜', sort: true, width: 120 }
+ // , { field: '璁¢噺鍗曚綅', title: '璁¢噺鍗曚綅', sort: true, width: 120 }
+ // , { field: '鍑哄巶鏃ユ湡', title: '鍑哄巶鏃ユ湡', sort: true, width: 120 }
+ // , { field: '鍑哄巶缂栧彿', title: '鍑哄巶缂栧彿', sort: true, width: 120 }
+ // , { field: '浣跨敤閮ㄩ棬浠g爜', title: '浣跨敤閮ㄩ棬浠g爜', sort: true, width: 120 }
+ // , { field: '浣跨敤閮ㄩ棬', title: '浣跨敤閮ㄩ棬', sort: true, width: 120 }
+ // , { field: 'HSupID', title: 'HSupID', hide: true, sort: true, width: 120 }
+ // , { field: '渚涘簲鍟嗕唬鐮�', title: '渚涘簲鍟嗕唬鐮�', sort: true, width: 120 }
+ // , { field: '渚涘簲鍟�', title: '渚涘簲鍟�', sort: true, width: 120 }
+ // , { field: 'HWhID', title: 'HWhID', hide: true, sort: true, width: 120 }
+ // , { field: '榛樿浠撳簱', title: '榛樿浠撳簱', sort: true, width: 120 }
+ // , { field: 'HSPID', title: 'HSPID', hide: true, sort: true, width: 120 }
+ // , { field: '榛樿浠撲綅', title: '榛樿浠撲綅', sort: true, width: 120 }
+ // , { field: '鐗堟湰', title: '鐗堟湰', sort: true, width: 120 }
+ // , { field: '褰撳墠浠撳簱', title: '褰撳墠浠撳簱', sort: true, width: 120 }
+ // , { field: '褰撳墠浠撲綅', title: '褰撳墠浠撲綅', sort: true, width: 120 }
+ // , { field: '铏氭嫙浠撶被鍨�', title: '铏氭嫙浠撶被鍨�', sort: true, width: 120 }
+ // , { field: '铏氭嫙浠�', title: '铏氭嫙浠�', sort: true, width: 120 }
+ // , { field: '褰撳墠妯″叿瑙勬牸', title: '褰撳墠瀹瑰櫒瑙勬牸', sort: true, width: 140 }
+ // , { field: '鍒濆妯″叿瑙勬牸', title: '鍒濆瀹瑰櫒瑙勬牸', sort: true, width: 140 }
+ // , { field: '褰撳墠璁捐瀵垮懡', title: '褰撳墠璁捐瀵垮懡', sort: true, totalRow: true, width: 140 }
+ // , { field: '鍒濆璁捐瀵垮懡', title: '鍒濆璁捐瀵垮懡', sort: true, totalRow: true, width: 140 }
+ // , { field: '浣跨敤瀵垮懡', title: '浣跨敤瀵垮懡', sort: true, totalRow: true, width: 120 }
+ // , { field: '鍓╀綑瀵垮懡', title: '鍓╀綑瀵垮懡', sort: true, totalRow: true, width: 120 }
+ // , { field: '宸茬敓浜ф暟閲�', title: '宸茬敓浜ф暟閲�', sort: true, totalRow: true, width: 120 }
+ // , { field: '宸茬敓浜ч噸閲�', title: '宸茬敓浜ч噸閲�', sort: true, totalRow: true, width: 120 }
+ // , { field: '澶囨敞', title: '澶囨敞', sort: true, width: 120 }
+ // , { field: '鍏宠仈鏁伴噺', title: '鍏宠仈鏁伴噺', sort: true, totalRow: true, width: 120 }
+ // , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', sort: true, width: 120 }
+ // , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', sort: true, width: 120 }
+ // , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', sort: true, width: 120 }
+ // , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', sort: true, width: 120 }
+ // , { field: '淇敼浜�', title: '淇敼浜�', sort: true, width: 120 }
+ // , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', sort: true, width: 120 }
+ // , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', sort: true, width: 120 }
+ // , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', sort: true, width: 120 }
+ // , { field: '浣滃簾浜�', title: '浣滃簾浜�', sort: true, width: 120 }
+ // , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', sort: true, width: 120 }
+ // , { field: 'hbilltype', title: 'hbilltype', hide: true, sort: true, width: 120 }
+ // , { field: '鍗曟嵁绫诲瀷', title: '鍗曟嵁绫诲瀷', hide: true, sort: true, width: 120 }
+ // , { field: 'HMoudType', title: 'HMoudType', hide: true, sort: true, width: 120 }
+ // , { field: 'hsubid', title: 'hsubid', hide: true, sort: true, width: 120 }
+ // ]]
this.dataList = option
option.data = data1.data;
var result = data1.data;
option.data = result;
this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
} else {
- this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ this.$modal.msgError(data1.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -851,10 +849,10 @@
this.sWhere += " and " + this.queryParams.ColName2 + " " + com2;
}
if (this.queryParams.HNumber) {
- this.sWhere += " and 鍣ㄥ叿缂栧彿 like '%" + this.queryParams.HNumber + "%'";
+ this.sWhere += " and 妯″叿缂栧彿 like '%" + this.queryParams.HNumber + "%'";
}
if (this.queryParams.HName) {
- this.sWhere += " and 鍣ㄥ叿鍚嶇О like '%" + this.queryParams.HName + "%'";
+ this.sWhere += " and 妯″叿鍚嶇О like '%" + this.queryParams.HName + "%'";
}
if (this.queryParams.HUSEORGID) {
this.sWhere += " and HUSEORGID = '" + this.queryParams.HUSEORGID + "'"
@@ -903,9 +901,10 @@
resetQuery() {
this.sWhere = ''
this.queryParams = {
- HUSEORGID: null,
+ HUSEORGID: sessionStorage["OrganizationID"] - 0,
HName: null,
HNumber: null,
+ HMouldTypeID: 0,
Comparator1: '',
Comparator2: '',
Comparator: '',
diff --git a/src/views/scMould/warehouse/Sc_MouldInRequestBillEdit.vue b/src/views/scMould/warehouse/Sc_MouldInRequestBillEdit.vue
index d9a9927..b912983 100644
--- a/src/views/scMould/warehouse/Sc_MouldInRequestBillEdit.vue
+++ b/src/views/scMould/warehouse/Sc_MouldInRequestBillEdit.vue
@@ -375,6 +375,18 @@
],
HStockOrgID: [
{ required: true, message: "缁勭粐涓嶈兘涓虹┖", trigger: "blur" }
+ ],
+ HEmpName: [
+ { required: true, message: "涓氬姟鍛樹笉鑳戒负绌�", trigger: "blur" }
+ ],
+ HMangerName: [
+ { required: true, message: "涓荤涓嶈兘涓虹┖", trigger: "blur" }
+ ],
+ HSecManagerName: [
+ { required: true, message: "楠屾敹鍛樹笉鑳戒负绌�", trigger: "blur" }
+ ],
+ HKeeperName: [
+ { required: true, message: "淇濈鍛樹笉鑳戒负绌�", trigger: "blur" }
]
}
};
@@ -389,6 +401,8 @@
}).then(response => {
if (response.data.count == 1) {
this.organizationList = response.data.data;//缁勭粐鍒楄〃
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -743,6 +757,8 @@
}
this.formShow = true
this.formLoading = false
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
console.log(error)
diff --git a/src/views/scMould/warehouse/Sc_MouldInRequestBillList.vue b/src/views/scMould/warehouse/Sc_MouldInRequestBillList.vue
index 491827e..d8798d7 100644
--- a/src/views/scMould/warehouse/Sc_MouldInRequestBillList.vue
+++ b/src/views/scMould/warehouse/Sc_MouldInRequestBillList.vue
@@ -457,6 +457,8 @@
option.data = data1.data
this.dataList = option
this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
diff --git a/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillEdit.vue b/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillEdit.vue
index 6d88b3f..3dcbdcd 100644
--- a/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillEdit.vue
+++ b/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillEdit.vue
@@ -428,6 +428,18 @@
],
HStockOutOrgID: [
{ required: true, message: "璋冨嚭缁勭粐涓嶈兘涓虹┖", trigger: "blur" }
+ ],
+ HEmpName: [
+ { required: true, message: "涓氬姟鍛樹笉鑳戒负绌�", trigger: "blur" }
+ ],
+ HMangerName: [
+ { required: true, message: "涓荤涓嶈兘涓虹┖", trigger: "blur" }
+ ],
+ HSecManagerName: [
+ { required: true, message: "楠屾敹鍛樹笉鑳戒负绌�", trigger: "blur" }
+ ],
+ HKeeperName: [
+ { required: true, message: "淇濈鍛樹笉鑳戒负绌�", trigger: "blur" }
]
}
};
@@ -442,6 +454,8 @@
}).then(response => {
if (response.data.count == 1) {
this.organizationList = response.data.data;//缁勭粐鍒楄〃
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -826,6 +840,8 @@
}
this.formShow = true
this.formLoading = false
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
console.log(error)
diff --git a/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillList.vue b/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillList.vue
index 3477a1f..063126d 100644
--- a/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillList.vue
+++ b/src/views/scMould/warehouse/Sc_MouldMoveStockRequestBillList.vue
@@ -447,6 +447,8 @@
option.data = data1.data
this.dataList = option
this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
diff --git a/src/views/scMould/warehouse/Sc_MouldOutRequestBillEdit.vue b/src/views/scMould/warehouse/Sc_MouldOutRequestBillEdit.vue
index 049794a..b293a93 100644
--- a/src/views/scMould/warehouse/Sc_MouldOutRequestBillEdit.vue
+++ b/src/views/scMould/warehouse/Sc_MouldOutRequestBillEdit.vue
@@ -401,6 +401,18 @@
],
HStockOrgID: [
{ required: true, message: "缁勭粐涓嶈兘涓虹┖", trigger: "blur" }
+ ],
+ HEmpName: [
+ { required: true, message: "涓氬姟鍛樹笉鑳戒负绌�", trigger: "blur" }
+ ],
+ HMangerName: [
+ { required: true, message: "涓荤涓嶈兘涓虹┖", trigger: "blur" }
+ ],
+ HSecManagerName: [
+ { required: true, message: "楠屾敹鍛樹笉鑳戒负绌�", trigger: "blur" }
+ ],
+ HKeeperName: [
+ { required: true, message: "淇濈鍛樹笉鑳戒负绌�", trigger: "blur" }
]
}
};
@@ -416,6 +428,8 @@
}).then(response => {
if (response.data.count == 1) {
this.organizationList = response.data.data;//缁勭粐鍒楄〃
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -429,6 +443,8 @@
this.HSourceBillTypes = response.data.data
this.form.HSourceBillType = this.HSourceBillTypes[0].HSourceBillType
this.form.HSourceBillTypeName = this.HSourceBillTypes[0].HSourceBillTypeName
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -834,6 +850,8 @@
}
this.formShow = true
this.formLoading = false
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
console.log(error)
diff --git a/src/views/scMould/warehouse/Sc_MouldOutRequestBillList.vue b/src/views/scMould/warehouse/Sc_MouldOutRequestBillList.vue
index ddd2f69..9befbf0 100644
--- a/src/views/scMould/warehouse/Sc_MouldOutRequestBillList.vue
+++ b/src/views/scMould/warehouse/Sc_MouldOutRequestBillList.vue
@@ -457,6 +457,8 @@
option.data = data1.data
this.dataList = option
this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
diff --git a/src/views/scMould/warehouse/Sc_MouldProdBackBillEdit.vue b/src/views/scMould/warehouse/Sc_MouldProdBackBillEdit.vue
index c1ffe06..dfb6e00 100644
--- a/src/views/scMould/warehouse/Sc_MouldProdBackBillEdit.vue
+++ b/src/views/scMould/warehouse/Sc_MouldProdBackBillEdit.vue
@@ -213,7 +213,7 @@
<el-table-column align="center" label="搴忓彿" type="index" width="80" />
<el-table-column align="center" label="瀹瑰櫒浠g爜" width="120">
<template slot-scope="scope">
- <el-input v-model="scope.row.HMaterCode" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(8, scope.row)"
+ <el-input v-model="scope.row.HMaterNumber" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(8, scope.row)"
@dblclick.native="openDataDialog(8, scope.row)" />
</template>
</el-table-column>
@@ -250,7 +250,7 @@
</el-table-column>
<el-table-column align="center" label="浠撳簱浠g爜" width="120">
<template slot-scope="scope">
- <el-input v-model="scope.row.HWHCode" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(2, scope.row ,eHWHType=2)"
+ <el-input v-model="scope.row.HWHNumber" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(2, scope.row ,eHWHType=2)"
@dblclick.native="openDataDialog(2, scope.row ,eHWHType=2)" />
</template>
</el-table-column>
@@ -496,6 +496,8 @@
}).then(response => {
if (response.data.count == 1) {
this.organizationList = response.data.data;//缁勭粐鍒楄〃
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -509,6 +511,8 @@
this.HSourceBillTypes = response.data.data
this.form.HSourceBillType = this.HSourceBillTypes[0].HSourceBillType
this.form.HSourceBillTypeName = this.HSourceBillTypes[0].HSourceBillTypeName
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -555,8 +559,8 @@
}).then(response => {
if (response.data.count == 1) {
resolve(response.data.data[0]);
- } else {
- this.$modal.msgError("鏈煡璇㈠埌鏁版嵁!");
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -569,6 +573,8 @@
this.form.HSupTypeID = data.HSupTypeID
this.form.HSupID = data.HSupID
this.form.HSupName = data.HSupName
+ this.form.HSecManagerId = data.HSecManagerID
+ this.form.HSecManagerName = data.HSecManagerName
this.form.HDeptID = data.HDeptID
this.form.HDeptName = data.HDeptName
this.form.HStockOrgID = data.HStockOrgID == null ? 0 : data.HStockOrgID
@@ -688,7 +694,7 @@
this.form.HWHNumber = deptRow.浠撳簱浠g爜
}else{
this.editData[this.zbIndex].HWHID = deptRow.HItemID
- this.editData[this.zbIndex].HWHCode = deptRow.浠撳簱浠g爜
+ this.editData[this.zbIndex].HWHNumber = deptRow.浠撳簱浠g爜
this.editData[this.zbIndex].HWHName = deptRow.浠撳簱鍚嶇О
}
this.warehouseShow = false
@@ -967,6 +973,8 @@
}
this.formShow = true
this.formLoading = false
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
console.log(error)
diff --git a/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue b/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue
index eee4293..63b2a18 100644
--- a/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue
+++ b/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue
@@ -129,7 +129,7 @@
</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>
+ @click="handleEdit(row = rowForm, OperationType = 2)">缂栬緫</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-document-copy" size="mini" :disabled="single"
@@ -171,7 +171,7 @@
<el-checkbox v-model="checked" v-if="item.type == 'checkbox'"></el-checkbox>
<div :style="item.style">
<span v-if="column.property.includes('鏃ユ湡')">{{ parseTime(row[column.property], '{y}-{m}-{d}') }}</span>
- <el-button type="text" @click="handleEdit(row, OperationType = 3)"
+ <el-button type="text" @click="handleEdit(row, OperationType = 2)"
v-else-if="column.property == '鍗曟嵁鍙�'">{{
row.鍗曟嵁鍙�
}}</el-button>
@@ -256,7 +256,7 @@
HStatusList: [{name:'鍏ㄩ儴',value:'-1'},{name:'鏈鏍�',value:'0'},{name:'宸插鏍�',value:'1'},{name:'宸插叧闂�',value:'2'}],
addBtnShow: false,
dialogTitle: '',
- OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
+ OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼2锛�
HInterID: null,
baseURL: process.env.VUE_APP_BASE_API,
lastSelectedRowIndex: null, // 鐢ㄤ簬璁板綍涓婃鐐瑰嚮鐨勮绱㈠紩
@@ -428,6 +428,8 @@
option.data = data1.data
this.dataList = option
this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -585,7 +587,7 @@
},
//鍙屽嚮琛�
handleDblclick(row, column, cell, event) {
- this.OperationType = 3
+ this.OperationType = 2
this.handleEdit(row)
},
// 澶氶�夋閫変腑鏁版嵁
diff --git a/src/views/scMould/warehouse/Sc_MouldProdMoveBillEdit.vue b/src/views/scMould/warehouse/Sc_MouldProdMoveBillEdit.vue
index eeac383..a34b084 100644
--- a/src/views/scMould/warehouse/Sc_MouldProdMoveBillEdit.vue
+++ b/src/views/scMould/warehouse/Sc_MouldProdMoveBillEdit.vue
@@ -522,6 +522,9 @@
HSecManagerName: [
{ required: true, message: "楠屾敹鍛樹笉鑳戒负绌�", trigger: "blur" }
],
+ HEmpName: [
+ { required: true, message: "涓氬姟鍛樹笉鑳戒负绌�", trigger: "blur" }
+ ],
HKeeperName: [
{ required: true, message: "淇濈鍛樹笉鑳戒负绌�", trigger: "blur" }
]
@@ -539,6 +542,8 @@
}).then(response => {
if (response.data.count == 1) {
this.organizationList = response.data.data;//缁勭粐鍒楄〃
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -552,6 +557,8 @@
this.HSourceBillTypes = response.data.data
this.form.HSourceBillType = this.HSourceBillTypes[0].HSourceBillType
this.form.HSourceBillTypeName = this.HSourceBillTypes[0].HSourceBillTypeName
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -601,8 +608,8 @@
}).then(response => {
if (response.data.count == 1) {
resolve(response.data.data[0]);
- } else {
- this.$modal.msgError("鏈煡璇㈠埌鏁版嵁!");
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -798,11 +805,11 @@
} else if (num == 9){
if(this.HSPType == 1){
this.editData[this.zbIndex].HSPID = deptRow.HMainID
- this.editData[this.zbIndex].HSPCode = deptRow.浠撲綅浠g爜
+ this.editData[this.zbIndex].HSPNumber = deptRow.浠撲綅浠g爜
this.editData[this.zbIndex].HSPName = deptRow.浠撲綅鍚嶇О
}else{
this.editData[this.zbIndex].HSCSPID = deptRow.HMainID
- this.editData[this.zbIndex].HSCSPCode = deptRow.浠撲綅浠g爜
+ this.editData[this.zbIndex].HSCSPNumber = deptRow.浠撲綅浠g爜
this.editData[this.zbIndex].HSCSPName = deptRow.浠撲綅鍚嶇О
}
this.gyStockPlaceShow = false
@@ -1042,6 +1049,8 @@
}
this.formShow = true
this.formLoading = false
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
console.log(error)
diff --git a/src/views/scMould/warehouse/Sc_MouldProdMoveBillList.vue b/src/views/scMould/warehouse/Sc_MouldProdMoveBillList.vue
index 1c2ea4d..fc5263f 100644
--- a/src/views/scMould/warehouse/Sc_MouldProdMoveBillList.vue
+++ b/src/views/scMould/warehouse/Sc_MouldProdMoveBillList.vue
@@ -129,7 +129,7 @@
</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>
+ @click="handleEdit(row = rowForm, OperationType = 2)">缂栬緫</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-document-copy" size="mini" :disabled="single"
@@ -171,7 +171,7 @@
<el-checkbox v-model="checked" v-if="item.type == 'checkbox'"></el-checkbox>
<div :style="item.style">
<span v-if="column.property.includes('鏃ユ湡')">{{ parseTime(row[column.property], '{y}-{m}-{d}') }}</span>
- <el-button type="text" @click="handleEdit(row, OperationType = 3)"
+ <el-button type="text" @click="handleEdit(row, OperationType = 2)"
v-else-if="column.property == '鍗曟嵁鍙�'">{{
row.鍗曟嵁鍙�
}}</el-button>
@@ -256,7 +256,7 @@
HStatusList: [{name:'鍏ㄩ儴',value:'-1'},{name:'鏈鏍�',value:'0'},{name:'宸插鏍�',value:'1'},{name:'宸插叧闂�',value:'2'}],
addBtnShow: false,
dialogTitle: '',
- OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
+ OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼2锛�
HInterID: null,
baseURL: process.env.VUE_APP_BASE_API,
lastSelectedRowIndex: null, // 鐢ㄤ簬璁板綍涓婃鐐瑰嚮鐨勮绱㈠紩
@@ -359,6 +359,7 @@
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * this.queryParams.HInitTimeCycle);
+ end.setTime(end.getTime() - 3600 * 1000 * 24);
const yyyyS = start.getFullYear();
const mmS = String(start.getMonth() + 1).padStart(2, '0'); // 鏈堜唤鏄粠0寮�濮嬬殑
const ddS = String(start.getDate()).padStart(2, '0');
@@ -427,6 +428,8 @@
option.data = data1.data
this.dataList = option
this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -584,7 +587,7 @@
},
//鍙屽嚮琛�
handleDblclick(row, column, cell, event) {
- this.OperationType = 3
+ this.OperationType = 2
this.handleEdit(row)
},
// 澶氶�夋閫変腑鏁版嵁
diff --git a/src/views/scMould/warehouse/Sc_MouldProdOutBillEdit.vue b/src/views/scMould/warehouse/Sc_MouldProdOutBillEdit.vue
index 1976d07..4aa8b9b 100644
--- a/src/views/scMould/warehouse/Sc_MouldProdOutBillEdit.vue
+++ b/src/views/scMould/warehouse/Sc_MouldProdOutBillEdit.vue
@@ -213,7 +213,7 @@
<el-table-column align="center" label="搴忓彿" type="index" width="80" />
<el-table-column align="center" label="瀹瑰櫒浠g爜" width="120">
<template slot-scope="scope">
- <el-input v-model="scope.row.HMaterCode" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(8, scope.row)"
+ <el-input v-model="scope.row.HMaterNumber" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(8, scope.row)"
@dblclick.native="openDataDialog(8, scope.row)" />
</template>
</el-table-column>
@@ -250,7 +250,7 @@
</el-table-column>
<el-table-column align="center" label="浠撳簱浠g爜" width="120">
<template slot-scope="scope">
- <el-input v-model="scope.row.HWHCode" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(2, scope.row ,eHWHType=2)"
+ <el-input v-model="scope.row.HWHNumber" placeholder="璇疯緭鍏�" @keyup.native.f7="openDataDialog(2, scope.row ,eHWHType=2)"
@dblclick.native="openDataDialog(2, scope.row ,eHWHType=2)" />
</template>
</el-table-column>
@@ -496,6 +496,8 @@
}).then(response => {
if (response.data.count == 1) {
this.organizationList = response.data.data;//缁勭粐鍒楄〃
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -509,6 +511,8 @@
this.HSourceBillTypes = response.data.data
this.form.HSourceBillType = this.HSourceBillTypes[0].HSourceBillType
this.form.HSourceBillTypeName = this.HSourceBillTypes[0].HSourceBillTypeName
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -555,8 +559,8 @@
}).then(response => {
if (response.data.count == 1) {
resolve(response.data.data[0]);
- } else {
- this.$modal.msgError("鏈煡璇㈠埌鏁版嵁!");
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -569,6 +573,8 @@
this.form.HSupTypeID = data.HSupTypeID
this.form.HSupID = data.HSupID
this.form.HSupName = data.HSupName
+ this.form.HSecManagerId = data.HSecManagerID
+ this.form.HSecManagerName = data.HSecManagerName
this.form.HDeptID = data.HDeptID
this.form.HDeptName = data.HDeptName
this.form.HStockOrgID = data.HStockOrgID == null ? 0 : data.HStockOrgID
@@ -688,7 +694,7 @@
this.form.HWHNumber = deptRow.浠撳簱浠g爜
}else{
this.editData[this.zbIndex].HWHID = deptRow.HItemID
- this.editData[this.zbIndex].HWHCode = deptRow.浠撳簱浠g爜
+ this.editData[this.zbIndex].HWHNumber = deptRow.浠撳簱浠g爜
this.editData[this.zbIndex].HWHName = deptRow.浠撳簱鍚嶇О
}
this.warehouseShow = false
@@ -966,6 +972,8 @@
}
this.formShow = true
this.formLoading = false
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
console.log(error)
diff --git a/src/views/scMould/warehouse/Sc_MouldProdOutBillList.vue b/src/views/scMould/warehouse/Sc_MouldProdOutBillList.vue
index 6dd791a..11db684 100644
--- a/src/views/scMould/warehouse/Sc_MouldProdOutBillList.vue
+++ b/src/views/scMould/warehouse/Sc_MouldProdOutBillList.vue
@@ -129,7 +129,7 @@
</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>
+ @click="handleEdit(row = rowForm, OperationType = 2)">缂栬緫</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-document-copy" size="mini" :disabled="single"
@@ -171,7 +171,7 @@
<el-checkbox v-model="checked" v-if="item.type == 'checkbox'"></el-checkbox>
<div :style="item.style">
<span v-if="column.property.includes('鏃ユ湡')">{{ parseTime(row[column.property], '{y}-{m}-{d}') }}</span>
- <el-button type="text" @click="handleEdit(row, OperationType = 3)"
+ <el-button type="text" @click="handleEdit(row, OperationType = 2)"
v-else-if="column.property == '鍗曟嵁鍙�'">{{
row.鍗曟嵁鍙�
}}</el-button>
@@ -256,7 +256,7 @@
HStatusList: [{name:'鍏ㄩ儴',value:'-1'},{name:'鏈鏍�',value:'0'},{name:'宸插鏍�',value:'1'},{name:'宸插叧闂�',value:'2'}],
addBtnShow: false,
dialogTitle: '',
- OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
+ OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼2锛�
HInterID: null,
baseURL: process.env.VUE_APP_BASE_API,
lastSelectedRowIndex: null, // 鐢ㄤ簬璁板綍涓婃鐐瑰嚮鐨勮绱㈠紩
@@ -428,6 +428,8 @@
this.dataList = option
this.DisPlay_HideColumn(this.HModName, sessionStorage["HUserName"], option, this.dataList);
+ }else{
+ this.$modal.msgError(response.data.Message);
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -585,7 +587,7 @@
},
//鍙屽嚮琛�
handleDblclick(row, column, cell, event) {
- this.OperationType = 3
+ this.OperationType = 2
this.handleEdit(row)
},
// 澶氶�夋閫変腑鏁版嵁
--
Gitblit v1.9.1