From 3a5a215d8f617828b7b168b836234c34962f0085 Mon Sep 17 00:00:00 2001
From: chenhaozhe <cgz@hz-kingdee.com>
Date: 星期二, 02 十二月 2025 15:57:58 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-VUEUI
---
src/views/component/PackStockDetail/index.vue | 335 ++++++++++++++++++++++++++++++
src/views/GyCustomer/index.vue | 33 +-
src/views/system/user/Xt_UserGroupList.vue | 13
src/views/KCGL/MoveStockBill/Kf_MoveStockBillList.vue | 22 +
src/views/gyMaterial/GyMaterial.vue | 43 ++-
src/views/system/user/Xt_UserGroupEdit.vue | 41 ++-
src/views/GyCustomer/CustomerEdit/index.vue | 138 ++++++++---
7 files changed, 532 insertions(+), 93 deletions(-)
diff --git a/src/views/GyCustomer/CustomerEdit/index.vue b/src/views/GyCustomer/CustomerEdit/index.vue
index 5fb9f44..6433895 100644
--- a/src/views/GyCustomer/CustomerEdit/index.vue
+++ b/src/views/GyCustomer/CustomerEdit/index.vue
@@ -119,15 +119,15 @@
<el-tab-pane label="鍏朵粬淇℃伅" name="other">
- <el-form ref="formOther" :model="formData" label-width="100px">
+ <el-form ref="formOther" :model="formData" :rules="rules" label-width="100px">
<el-row :gutter="20">
<el-col :span="12">
- <el-form-item label="鑱旂郴浜�">
+ <el-form-item label="鑱旂郴浜�" prop="HLinkMan">
<el-input v-model="formData.HLinkMan" placeholder="璇疯緭鍏ヨ仈绯讳汉"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
- <el-form-item label="鑱旂郴鐢佃瘽">
+ <el-form-item label="鑱旂郴鐢佃瘽" prop="HLinkPhone">
<el-input v-model="formData.HLinkPhone" placeholder="璇疯緭鍏ヨ仈绯荤數璇�"></el-input>
</el-form-item>
</el-col>
@@ -148,7 +148,7 @@
<el-row :gutter="20">
<el-col :span="12">
- <el-form-item label="鍦板潃">
+ <el-form-item label="鍦板潃" prop="HAddress">
<el-input v-model="formData.HAddress" placeholder="璇疯緭鍏ュ湴鍧�"></el-input>
</el-form-item>
</el-col>
@@ -220,7 +220,7 @@
</el-form-item>
</el-col>
<el-col :span="12">
- <el-form-item label="鍦板尯">
+ <el-form-item label="鍦板尯" prop="HAreaID">
<el-input
v-model="formData.HAreaName"
placeholder="璇烽�夋嫨鍦板尯"
@@ -280,7 +280,7 @@
<el-row :gutter="20">
<el-col :span="12">
- <el-form-item label="瀹㈡埛鐘舵��">
+ <el-form-item label="瀹㈡埛鐘舵��" prop="HCusStatus">
<el-select v-model="formData.HCusStatus" placeholder="璇烽�夋嫨瀹㈡埛鐘舵��" style="width: 100%">
<el-option label="娼滃湪" value="101"></el-option>
<el-option label="鍚堟牸" value="102"></el-option>
@@ -548,6 +548,7 @@
this.initData()
this.loadOrganizations()
this.handleOperationType()
+ this.setConditionalRules()
},
methods: {
initData() {
@@ -708,44 +709,95 @@
},
// 淇濆瓨
- handleSave() {
- this.$refs.form.validate(valid => {
- if (valid) {
- if (!this.validateForm()) {
- return
- }
-
- const formData = { ...this.formData }
- formData.HStopflag = formData.HStopflag ? 'true' : 'false'
-
- let url = `${this.baseURL}/Gy_Customer/AddBill`
- let params = { oMain: JSON.stringify(formData) + ';' + this.user }
-
- if (this.operationType === 3) {
- // 缂栬緫淇濆瓨
- url = `${this.baseURL}/Gy_Customer/AddBill1`
- params = {
- oMain: JSON.stringify(formData) + ';' + this.linterid + ';' + this.user + ';Gy_Customer_Edit'
- }
- }
-
- axios.post(url, params)
- .then(response => {
- if (response.data.count === 1) {
- this.$modal.msgSuccess(response.data.Message)
- this.saveDisabled = true
- this.saveConfig()
- this.openEdit = false
- this.$emit('editClose', true)
- } else {
- this.$modal.msgError(response.data.Message)
- }
- })
- .catch(error => {
- this.$modal.msgError('淇濆瓨澶辫触!')
- })
- }
+ async handleSave() {
+ const validMain = await new Promise(resolve => {
+ this.$refs.form.validate(valid => resolve(valid))
})
+
+ let validOther = true
+ if (this.$refs.formOther) {
+ validOther = await new Promise(resolve => {
+ this.$refs.formOther.validate(valid => resolve(valid))
+ })
+ }
+
+ if (validMain && validOther) {
+ if (!this.validateForm()) {
+ return
+ }
+
+ const formData = { ...this.formData }
+ formData.HStopflag = formData.HStopflag ? 'true' : 'false'
+
+ let url = `${this.baseURL}/Gy_Customer/AddBill`
+ let params = { oMain: JSON.stringify(formData) + ';' + this.user }
+
+ if (this.operationType === 3) {
+ // 缂栬緫淇濆瓨
+ url = `${this.baseURL}/Gy_Customer/AddBill1`
+ params = {
+ oMain: JSON.stringify(formData) + ';' + this.linterid + ';' + this.user + ';Gy_Customer_Edit'
+ }
+ }
+
+ axios.post(url, params)
+ .then(response => {
+ if (response.data.count === 1) {
+ this.$modal.msgSuccess(response.data.Message)
+ this.saveDisabled = true
+ this.saveConfig()
+ this.openEdit = false
+ this.$emit('editClose', true)
+ } else {
+ this.$modal.msgError(response.data.Message)
+ }
+ })
+ .catch(error => {
+ this.$modal.msgError('淇濆瓨澶辫触!')
+ })
+ }
+ },
+
+ setConditionalRules() {
+ this.rules.HLinkMan = [
+ { validator: this.validateRequiredIfAdd, trigger: 'blur', message: '璇疯緭鍏ヨ仈绯讳汉' }
+ ]
+
+ this.rules.HLinkPhone = [
+ { validator: this.validateRequiredIfAdd, trigger: 'blur', message: '璇疯緭鍏ヨ仈绯荤數璇�' }
+ ]
+
+ this.rules.HAddress = [
+ { validator: this.validateRequiredIfAdd, trigger: 'blur', message: '璇疯緭鍏ュ湴鍧�' }
+ ]
+
+ this.rules.HAreaID = [
+ { validator: this.validateRequiredIfAdd, trigger: 'change', message: '璇烽�夋嫨鍦板尯' }
+ ]
+
+ this.rules.HCusStatus = [
+ { validator: this.validateRequiredIfAdd, trigger: 'change', message: '璇烽�夋嫨瀹㈡埛鐘舵��' }
+ ]
+ },
+
+ validateRequiredIfAdd(rule, value, callback) {
+ if (this.operationType !== 1) {
+ return callback()
+ }
+
+ if (value === null || value === undefined) {
+ return callback(new Error(rule.message || '璇ラ」涓哄繀濉�'))
+ }
+
+ if (typeof value === 'string' && value.trim() === '') {
+ return callback(new Error(rule.message || '璇ラ」涓哄繀濉�'))
+ }
+
+ if (value === '0') {
+ return callback(new Error(rule.message || '璇ラ」涓哄繀濉�'))
+ }
+
+ return callback()
},
// 琛ㄥ崟楠岃瘉
diff --git a/src/views/GyCustomer/index.vue b/src/views/GyCustomer/index.vue
index 06f328a..e14f775 100644
--- a/src/views/GyCustomer/index.vue
+++ b/src/views/GyCustomer/index.vue
@@ -29,14 +29,14 @@
<el-row>
<el-col :span="7">
<el-select v-model="queryParams.ColName" placeholder="璇烽�夋嫨" style="width: 100%">
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option v-for="(item, index) in visibleColumns" :key="index" :label="item.title"
:value="item.field"></el-option>
</el-select>
</el-col>
<el-col :span="6" style="padding: 0 10px">
<el-select v-model="queryParams.Comparator" placeholder="璇烽�夋嫨" style="width: 100%">
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option v-for="(item, index) in comparatorList" :key="index" :label="item.label"
:value="item.value"></el-option>
</el-select>
@@ -51,14 +51,14 @@
<el-row>
<el-col :span="7">
<el-select v-model="queryParams.ColName1" placeholder="璇烽�夋嫨" style="width: 100%">
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option v-for="(item, index) in visibleColumns" :key="index" :label="item.title"
:value="item.field"></el-option>
</el-select>
</el-col>
<el-col :span="6" style="padding: 0 10px">
<el-select v-model="queryParams.Comparator1" placeholder="璇烽�夋嫨" style="width: 100%">
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option v-for="(item, index) in comparatorList" :key="index" :label="item.label"
:value="item.value"></el-option>
</el-select>
@@ -73,14 +73,14 @@
<el-row>
<el-col :span="7">
<el-select v-model="queryParams.ColName2" placeholder="璇烽�夋嫨" style="width: 100%">
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option v-for="(item, index) in visibleColumns" :key="index" :label="item.title"
:value="item.field"></el-option>
</el-select>
</el-col>
<el-col :span="6" style="padding: 0 10px">
<el-select v-model="queryParams.Comparator2" placeholder="璇烽�夋嫨" style="width: 100%">
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option v-for="(item, index) in comparatorList" :key="index" :label="item.label"
:value="item.value"></el-option>
</el-select>
@@ -301,12 +301,12 @@
HNumber: null,
HName: null,
HNumber2: null,
- ColName: "0",
- ColName1: "0",
- ColName2: "0",
- Comparator: "0",
- Comparator1: "0",
- Comparator2: "0",
+ ColName: "",
+ ColName1: "",
+ ColName2: "",
+ Comparator: "",
+ Comparator1: "",
+ Comparator2: "",
ColContent: "",
ColContent1: "",
ColContent2: "",
@@ -739,6 +739,13 @@
},
handleRefresh() {
+ if (this.$refs.tableData && this.$refs.tableData.clearSelection) {
+ this.$refs.tableData.clearSelection();
+ }
+ this.selectedRow = null;
+ this.ids = [];
+ this.single = true;
+ this.multiple = true;
this.getList();
},
@@ -798,7 +805,7 @@
rowStyle({ row, rowIndex }) {
if (this.ids.includes(row.hmainid)) {
- return { background: "#ecf5ff" };
+ return { };
}
},
diff --git a/src/views/KCGL/MoveStockBill/Kf_MoveStockBillList.vue b/src/views/KCGL/MoveStockBill/Kf_MoveStockBillList.vue
index 9daa2b3..c8c32ca 100644
--- a/src/views/KCGL/MoveStockBill/Kf_MoveStockBillList.vue
+++ b/src/views/KCGL/MoveStockBill/Kf_MoveStockBillList.vue
@@ -141,6 +141,9 @@
<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"
@@ -186,6 +189,8 @@
</el-dialog>
<!-- 鏉$爜鏄庣粏 -->
<BarCodeDetail :visible.sync="barCodeDetailShow" ref="barcodeDetail"/>
+ <!-- 鍖呰瀹瑰櫒鍑哄叆搴撴槑缁� -->
+ <PackStockDetail :visible.sync="packStockDetailShow" ref="packStockDetail"/>
</div>
</div>
</template>
@@ -196,11 +201,12 @@
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/KCGL/MoveStockBill/Kf_MoveStockBillEdit.vue' //缂栬緫椤甸潰缁勪欢
export default {
name: 'Kf_MoveStockBillList',
- components: { RowSettings, Edit, PrintList,BarCodeDetail },
+ components: { RowSettings, Edit, PrintList,BarCodeDetail,PackStockDetail },
data() {
return {
baseURL: process.env.VUE_APP_BASE_API, //鍚庣鎺ュ彛鍓嶇紑(鍚庣鏈嶅姟鍣╥p鍦板潃)
@@ -252,6 +258,7 @@
openRowHide: false, //鍒楄缃粍浠舵樉绀烘爣璁�
rowHideShow: false, //鍒楄缃粍浠跺鍣ㄦ樉绀烘爣璁�
barCodeDetailShow: false, //鏉$爜鏄庣粏缁勪欢瀹瑰櫒鏄剧ず鏍囪
+ packStockDetailShow:false, //鍖呰瀹瑰櫒鍑哄叆搴撴槑缁嗗鍣ㄦ樉绀烘爣璁�
@@ -834,6 +841,19 @@
},
//#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()
diff --git a/src/views/component/PackStockDetail/index.vue b/src/views/component/PackStockDetail/index.vue
new file mode 100644
index 0000000..2509806
--- /dev/null
+++ b/src/views/component/PackStockDetail/index.vue
@@ -0,0 +1,335 @@
+<template>
+ <div class="barcode-detail">
+ <el-dialog
+ :visible.sync="dialogVisible"
+ title="鍖呰瀹瑰櫒鍑哄叆搴撹褰曡〃"
+ width="90%"
+ top="5vh"
+ :close-on-click-modal="false"
+ @closed="handleClosed"
+ >
+ <el-card>
+ <div class="dialog-content">
+ <el-form :model="formData" label-width="100px" class="form-container">
+ <el-row :gutter="20">
+ <el-col :span="8">
+ <el-form-item label="鍗曟嵁鍐呯爜">
+ <el-input v-model="formData.HInterID" disabled />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="鍗曟嵁鍙�">
+ <el-input v-model="formData.HBillNo" disabled />
+ </el-form-item>
+ </el-col>
+ <el-col :span="8">
+ <el-form-item label="鍗曟嵁绫诲瀷">
+ <el-input v-model="formData.HBillType" disabled />
+ </el-form-item>
+ </el-col>
+ </el-row>
+ </el-form>
+
+ <div class="table-toolbar">
+ <el-button size="mini" @click="handleColumnSetting">
+ <i class="el-icon-setting"></i> 鍒楄缃�
+ </el-button>
+ </div>
+
+ <el-table
+ ref="mainTable"
+ :data="tableData"
+ border
+ stripe
+ style="width: 100%"
+ :loading="loading"
+ @selection-change="handleSelectionChange"
+ show-summary
+ :summary-method="getSummaries"
+ >
+ <el-table-column type="selection" width="55" fixed="left" />
+ <el-table-column
+ v-for="column in tableColumns"
+ :key="column.field"
+ :prop="column.field"
+ :label="column.title"
+ :width="column.width"
+ :align="column.align"
+ :fixed="column.fixed"
+ :sortable="column.sortable"
+ :show-overflow-tooltip="true"
+ >
+ <template v-if="column.editable" #default="scope">
+ <el-input
+ v-model="scope.row[column.field]"
+ size="mini"
+ />
+ </template>
+ </el-table-column>
+ </el-table>
+ </div>
+ </el-card>
+ </el-dialog>
+
+ <el-dialog
+ :visible.sync="columnDialogVisible"
+ title="闅愯棌鍒楄缃�"
+ width="50%"
+ >
+ <div class="column-setting">
+ <el-checkbox-group v-model="selectedColumns">
+ <el-checkbox
+ v-for="column in allColumns"
+ :key="column.field"
+ :label="column.field"
+ >
+ {{ column.title }}
+ </el-checkbox>
+ </el-checkbox-group>
+ </div>
+ <div slot="footer">
+ <el-button @click="columnDialogVisible = false">鍙栨秷</el-button>
+ <el-button type="primary" @click="applyColumnSettings">纭畾</el-button>
+ </div>
+ </el-dialog>
+ </div>
+</template>
+
+<script>
+import axios from 'axios'
+
+export default {
+ name: 'BarCodeDetail',
+ data() {
+ return {
+ formData: { //鐢ㄤ簬鏌ヨ鐨勫弬鏁�
+ HInterID: '',
+ HBillNo: '',
+ HBillType: ''
+ },
+ loading: false, //椤甸潰鍔犺浇鍔ㄧ敾鏄剧ず鏍囪
+ dialogVisible: false, //鍖呰瀹瑰櫒鍑哄叆搴撴槑缁嗘暟鎹樉绀烘爣璁�
+ columnDialogVisible: false, //鍒楄缃寜閽樉绀烘爣璁�
+
+ tableData: [], //琛ㄦ牸鏁版嵁
+ tableColumns: [], //琛ㄦ牸鍒楁暟鎹�
+ allColumns: [],
+ selectedColumns: [],
+ selectedRows: [],
+ baseURL: process.env.VUE_APP_BASE_URL || "http://47.96.97.237/API/"
+ }
+ },
+ methods: {
+ //#region 椤甸潰鍒濆鍖�
+ open(record) {
+ if (!record) {
+ this.$message.warning('璇烽�夋嫨瑕佹煡鐪嬫潯鐮佹槑缁嗙殑鍗曟嵁')
+ return
+ }
+
+ const hmainid = record.hmainid || record.HInterID
+ const billNo = record.鍗曟嵁鍙� || record.HBillNo
+
+
+ let billTypeDesc = ''
+ switch (record.鍗曟嵁绫诲瀷 || '') {
+ case '1201': billTypeDesc = '澶栬喘鍏ュ簱鍗�'; break
+ case '1202': billTypeDesc = '浜у搧鍏ュ簱鍗�'; break
+ case '1203': billTypeDesc = '鍏跺畠鍏ュ簱鍗�'; break
+ case '1204': billTypeDesc = '鐢熶骇棰嗘枡'; break
+ case '1205': billTypeDesc = '閿�鍞嚭搴�'; break
+ case '1206': billTypeDesc = '鍏跺畠鍑哄簱鍗�'; break
+ case '1207': billTypeDesc = '鐩存帴璋冩嫧鍗�'; break
+ case '1210': billTypeDesc = '濮斿鍔犲伐鍏ュ簱鍗�'; break
+ case '1211': billTypeDesc = '濮斿鍔犲伐鍑哄簱鍗�'; break
+ default: billTypeDesc = record.鍗曟嵁绫诲瀷 || ''
+ }
+
+ this.formData = {
+ HInterID: hmainid,
+ HBillNo: billNo,
+ HBillType: billTypeDesc
+ }
+
+ this.dialogVisible = true
+ this.$nextTick(() => {
+ this.loadData(hmainid, record.鍗曟嵁绫诲瀷 || '', billNo)
+ })
+ },
+ //#endregion
+
+ //#region 鏌ヨ鏁版嵁
+ async loadData(HInterID, HBillType, HBillNo) {
+ this.loading = true
+ try {
+ const sWhere = " and hmainid = " + `${HInterID}` ;
+
+ const url = `${this.baseURL}/Kf_ICStockInOutBill/Kf_PackStockDetailQuery`
+ const params = { sWhere }
+
+ const response = await axios.get(url, { params })
+ const data = response.data
+
+ if (data && data.list) {
+ this.generateTableColumns(data.list)
+ this.tableData = data.data || []
+ this.applyColumnSettingsFromStorage()
+ } else {
+ this.$message.error('鑾峰彇鍖呰瀹瑰櫒鍑哄叆搴撴槑缁嗘暟鎹け璐�')
+ }
+ } catch (error) {
+ console.error('鍔犺浇鍖呰瀹瑰櫒鍑哄叆搴撴槑缁嗗け璐�:', error)
+ this.$message.error('鍔犺浇鍖呰瀹瑰櫒鍑哄叆搴撴槑缁嗗け璐�')
+ } finally {
+ this.loading = false
+ }
+ },
+ //#endregion
+
+ //#region 鏍规嵁琛ㄦ牸鍒楁暟鎹繘琛岃繘涓�姝ュ鐞�
+ generateTableColumns(columnList) {
+ const columns = []
+ const allColumns = []
+
+
+ columns.push({
+ type: 'selection',
+ width: 55,
+ fixed: 'left'
+ })
+
+ columnList.forEach((item, index) => {
+ const colName = item.ColmCols
+ let columnConfig = {
+ field: colName,
+ title: colName,
+ width: 200,
+ align: 'center',
+ sortable: true
+ }
+
+
+ switch (colName) {
+ case 'HItemID':
+ columnConfig.hide = true
+ break
+ case '鏁伴噺':
+ columnConfig.total = true
+ break
+ }
+
+ columns.push(columnConfig)
+ allColumns.push({ ...columnConfig })
+ })
+
+ this.tableColumns = columns
+ this.allColumns = allColumns
+ this.selectedColumns = allColumns.map(col => col.field)
+ },
+ //#endregion
+
+ //#region 鑾峰彇閫変腑琛屾暟鎹�
+ handleSelectionChange(selection) {
+ this.selectedRows = selection
+ },
+ //#endregion
+
+ //#region 鍒楄缃�
+ handleColumnSetting() {
+ this.columnDialogVisible = true
+ },
+
+ applyColumnSettings() {
+ this.tableColumns = [
+ this.tableColumns[0],
+ ...this.allColumns.filter(col => this.selectedColumns.includes(col.field))
+ ]
+ this.columnDialogVisible = false
+
+
+ this.saveColumnSettings()
+ },
+
+ applyColumnSettingsFromStorage() {
+
+ },
+
+
+ saveColumnSettings() {
+
+ },
+
+ //#endregion
+
+ //#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 (!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] = ''
+ }
+ })
+
+ return sums
+ },
+ //#endregion
+
+ //#region 椤甸潰鍏抽棴鏂规硶
+ handleClosed() {
+ this.tableData = []
+ this.tableColumns = []
+ this.selectedRows = []
+ }
+ //#endregion
+ }
+}
+</script>
+
+<style scoped>
+.barcode-detail {
+ font-family: "Microsoft YaHei", sans-serif;
+}
+
+.form-container {
+ margin-bottom: 16px;
+}
+
+.table-toolbar {
+ margin-bottom: 12px;
+}
+
+.column-setting {
+ max-height: 400px;
+ overflow-y: auto;
+}
+
+.column-setting .el-checkbox {
+ display: block;
+ margin-bottom: 8px;
+}
+
+:deep(.el-dialog__body) {
+ padding: 10px 20px;
+}
+
+:deep(.el-card__body) {
+ padding: 12px;
+}
+</style>
\ No newline at end of file
diff --git a/src/views/gyMaterial/GyMaterial.vue b/src/views/gyMaterial/GyMaterial.vue
index f5b0936..3b24fb6 100644
--- a/src/views/gyMaterial/GyMaterial.vue
+++ b/src/views/gyMaterial/GyMaterial.vue
@@ -78,7 +78,7 @@
placeholder="璇烽�夋嫨"
style="width: 100%"
>
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="" label=""></el-option> -->
<el-option
v-for="(item, index) in visibleColumns"
:key="index"
@@ -93,7 +93,7 @@
placeholder="璇烽�夋嫨"
style="width: 100%"
>
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option
v-for="(item, index) in comparatorList"
:key="index"
@@ -120,7 +120,7 @@
placeholder="璇烽�夋嫨"
style="width: 100%"
>
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option
v-for="(item, index) in visibleColumns"
:key="index"
@@ -135,7 +135,7 @@
placeholder="璇烽�夋嫨"
style="width: 100%"
>
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option
v-for="(item, index) in comparatorList"
:key="index"
@@ -162,7 +162,7 @@
placeholder="璇烽�夋嫨"
style="width: 100%"
>
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option
v-for="(item, index) in visibleColumns"
:key="index"
@@ -177,7 +177,7 @@
placeholder="璇烽�夋嫨"
style="width: 100%"
>
- <el-option value="0" label=""></el-option>
+ <!-- <el-option value="0" label=""></el-option> -->
<el-option
v-for="(item, index) in comparatorList"
:key="index"
@@ -642,12 +642,12 @@
HModel: null,
HOrgID: null,
HProject: null,
- ColName: "0",
- ColName1: "0",
- ColName2: "0",
- Comparator: "0",
- Comparator1: "0",
- Comparator2: "0",
+ ColName: "",
+ ColName1: "",
+ ColName2: "",
+ Comparator: "",
+ Comparator1: "",
+ Comparator2: "",
ColContent: "",
ColContent1: "",
ColContent2: "",
@@ -713,7 +713,9 @@
.then((response) => {
let data = response.data.data[0];
this.user = data.Czymc;
+
this.getOrganizations();
+ this.queryParams.HOrgID = data.HUSEORGID;
this.getTreeData();
this.getProjectOptions();
this.getList();
@@ -730,9 +732,9 @@
.then((response) => {
if (response.data.count == 1) {
this.organizationOptions = response.data.data;
- if (this.organizationOptions.length > 0) {
- this.queryParams.HOrgID = this.organizationOptions[0].ID;
- }
+ // if (this.organizationOptions.length > 0) {
+ // this.queryParams.HOrgID = this.organizationOptions[0].ID;
+ // }
}
})
.catch((error) => {
@@ -1128,6 +1130,14 @@
},
handleRefresh() {
+ // 鍒锋柊鏃舵竻闄よ〃鏍奸�夋嫨骞堕噸缃浉鍏崇姸鎬侊紝淇濊瘉澶嶅埗/缂栬緫/鍒犻櫎/瀹℃牳绛夋寜閽绂佺敤
+ if (this.$refs.tableData && this.$refs.tableData.clearSelection) {
+ this.$refs.tableData.clearSelection();
+ }
+ this.selectedRow = null;
+ this.ids = [];
+ this.single = true;
+ this.multiple = true;
this.getList();
},
@@ -1224,7 +1234,8 @@
// 琛屾牱寮�
rowStyle({ row, rowIndex }) {
if (this.ids.includes(row.hmainid)) {
- return { background: "#ecf5ff" };
+ return { };
+ // background: "#ecf5ff"
}
},
diff --git a/src/views/system/user/Xt_UserGroupEdit.vue b/src/views/system/user/Xt_UserGroupEdit.vue
index a970543..661c4bc 100644
--- a/src/views/system/user/Xt_UserGroupEdit.vue
+++ b/src/views/system/user/Xt_UserGroupEdit.vue
@@ -6,7 +6,7 @@
<!-- <el-button @click="cancel">鍙� 娑�</el-button> -->
</div>
<div style="margin: 10px; font-size: 28px; font-weight: bold; text-align: center;">鏂板/缂栬緫鐢ㄦ埛淇℃伅</div>
- <el-form ref="form" :model="form" :rules="rules" label-width="128px">
+ <el-form ref="form" :model="form" label-width="128px">
<el-tabs v-model="activeName" type="card">
<el-tab-pane label="鍩烘湰淇℃伅" name="first">
<el-row>
@@ -74,7 +74,7 @@
components: {},
props: {
OperationType: { type: Number, },
- linterid: {},
+ linterid: {type: Number},
},
data() {
return {
@@ -97,20 +97,25 @@
};
},
created() {
+
this.getdata()
},
methods: {
//#region 椤甸潰鍒濆鍖�
getdata() {
- this.formShow = false
- this.formLoading = true
- this.getUserGroup()
- if ((this.OperationType == 1 && this.copyType != 1) || (!this.OperationType && !this.copyType)) {
- this.handleAdd()
- } else if (this.OperationType == 3 || this.copyType == 1) {
- this.$nextTick(() => {
- this.handleUpdate()
- })
+ try {
+ this.formShow = false
+ this.formLoading = true
+ this.getUserGroup()
+ if ((this.OperationType == 1 && this.copyType != 1) || (!this.OperationType && !this.copyType)) {
+ this.handleAdd()
+ } else if (this.OperationType == 3 || this.copyType == 1) {
+ this.$nextTick(() => {
+ this.handleUpdate()
+ })
+ }
+ } catch (err) {
+ console.error('Error ', err)
}
},
@@ -179,6 +184,7 @@
handleUpdate() {
this.reset()
let rowHmainid = this.linterid
+ console.log("缂栬緫鐢ㄦ埛ID",rowHmainid)
axios.get(this.baseURL + "/Xt_User/EditUser", {
params: { 'HID': rowHmainid }
}).then(response => {
@@ -238,16 +244,20 @@
//#endregion
//#region 鑾峰彇瀛愯〃鏁版嵁
- getUserGroup() {
+ async getUserGroup() {
//瑙掕壊鍒楄〃
- axios.get(this.baseURL + '/Xt_UserGroup/list', {
+ axios.get(this.baseURL + '/Xt_User/list', {
params: {
sWhere: '',
+ user: sessionStorage["HUserName"],
},
}).then(response => {
let data1 = response.data
if (data1.code == 1) {
+ console.log(data1)
this.editData = data1.data
+ console.log("zhiwei",this.editData)
+ //this.get_DisplayUserGroupInfoList()
}
}).catch(error => {
this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
@@ -256,14 +266,15 @@
//#endregion
- get_DisplayUserGroupInfoList() {
- var sWhere = "and UserId='" + this.linterid + "'";
+ async get_DisplayUserGroupInfoList() {
+ var sWhere = "and GroupId='" + this.linterid + "'";
axios.get(this.baseURL + '/Xt_UserGroup/UserGroupInfoList', {
params: {
sWhere: sWhere,
},
}).then(response => {
let data1 = response.data
+ console.log(data1)
if (data1.count == 1) {
if (data1.data.length > 0)
if (this.editData.length > 0) {
diff --git a/src/views/system/user/Xt_UserGroupList.vue b/src/views/system/user/Xt_UserGroupList.vue
index a0a7808..ad09d74 100644
--- a/src/views/system/user/Xt_UserGroupList.vue
+++ b/src/views/system/user/Xt_UserGroupList.vue
@@ -148,11 +148,11 @@
</el-dialog>
<!-- 缂栬緫 -->
<el-dialog title="缂栬緫" :visible.sync="openEdit" width="1480px" append-to-body class="xsckdBox" @close="close">
- <edit :OperationType=OperationType :linterid="this.rowForm.hmainid" @editClose="editClose" v-if="editShow" />
+ <edit :OperationType="OperationType" :linterid="this.rowForm.HGroupID" @editClose="editClose" v-if="editShow" />
</el-dialog>
<!-- 鏉冮檺 -->
<el-dialog title="瑙掕壊鏉冮檺" :visible.sync="openQuery" width="1480px" append-to-body class="xsckdBox">
- <Query HSouceBillType="js" @editQueryClose="editQueryClose" :linterid=this.rowForm.HGroupID v-if="queryShow" />
+ <Query HSouceBillType="js" @editQueryClose="editQueryClose" :linterid="this.rowForm.HGroupID" v-if="queryShow" />
</el-dialog>
</div>
</div>
@@ -282,7 +282,7 @@
//#region 閫変腑琛岄珮浜牱寮�
rowStyle({ row, rowIndex }) {
if (this.ids.includes(row.hmainid)) {
- return { "background": "#ecf5ff" }
+ return { }
}
},
//#endregion
@@ -290,7 +290,7 @@
//#region 鍙屽嚮琛�
handleDblclick(row, column, cell, event) {
this.OperationType = 3
- this.handleEdit()
+ this.handleEdit(row)
},
//#endregion
@@ -519,7 +519,9 @@
//#region 鏂板
handleAddEdit() {
- this.rowForm.hmainid = 0
+ this.OperationType = 1
+ this.rowForm.HGroupID = 0
+ console.log(' OperationType=', this.OperationType, 'rowForm.HGroupID=', this.rowForm.HGroupID)
this.editShow = true
this.openEdit = true
},
@@ -528,6 +530,7 @@
//#region 缂栬緫
handleEdit(row) {
this.rowForm = row
+ console.log('OperationType=', this.OperationType, 'rowForm=', this.rowForm)
this.editShow = true
this.openEdit = true
},
--
Gitblit v1.9.1