From b46bc2dba51a3885a68e4c58316b41a31ea16bb2 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期二, 14 二月 2023 13:35:03 +0800
Subject: [PATCH] 1.存货档案修改

---
 src/views/zlgl/gxjybz.vue |   64 +++++++++++++++++++++----------
 1 files changed, 43 insertions(+), 21 deletions(-)

diff --git a/src/views/zlgl/gxjybz.vue b/src/views/zlgl/gxjybz.vue
index bdf6000..5bf522e 100644
--- a/src/views/zlgl/gxjybz.vue
+++ b/src/views/zlgl/gxjybz.vue
@@ -3,8 +3,8 @@
     <div class="body" :style="{height:mainHeight+'px'}">
 
       <div class="bodyTopButtonGroup">
-        <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">鏂板</el-button>
-        <!--        <el-button type="primary" icon="el-icon-upload2" @click="upload">瀵煎叆</el-button>-->
+        <el-button v-waves type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">鏂板</el-button>
+        <!--        <el-button v-waves type="primary" icon="el-icon-upload2" @click="upload">瀵煎叆</el-button>-->
       </div>
       <div class="bodyTopFormGroup">
         <el-form
@@ -12,10 +12,10 @@
           :model="form"
           label-width="100px"
           inline
-          style="display: flex;justify-content: space-between"
+          style="display: flex;"
         >
           <div class="elForm">
-            <el-form-item label-width="70px" label="鏍囧噯浠g爜" style=" display: flex;">
+            <el-form-item label="鏍囧噯浠g爜" style=" display: flex;">
               <el-input v-model="form.stanedcode" placeholder="璇疯緭鍏�" style="width: 200px" />
             </el-form-item>
             <el-form-item label="鏍囧噯鍚嶇О" style=" display: flex;">
@@ -25,9 +25,9 @@
               <el-input v-model="form.staneddescr" style="width: 200px" placeholder="璇疯緭鍏�" />
             </el-form-item>
           </div>
-          <div class="bodySearchReset" :style="{marginLeft:$store.state.app.sidebar.opened?'5%':'10%'}">
-            <el-button type="primary" icon="el-icon-search" @click="search">鏌ヨ</el-button>
-            <el-button type="info" icon="el-icon-refresh" @click="reset">閲嶇疆</el-button>
+          <div class="bodySearchReset" :style="{marginLeft:$store.state.app.sidebar.opened? $store.state.settings.menuIsHorizontal?'15%':'3%':'10%'}">
+            <el-button v-waves type="primary" icon="el-icon-search" @click="search">鏌ヨ</el-button>
+            <el-button v-waves type="info" icon="el-icon-refresh" @click="reset">閲嶇疆</el-button>
           </div>
         </el-form>
         <div
@@ -60,16 +60,19 @@
           />
           <el-table-column
             prop="code"
+            show-tooltip-when-overflow
             label="鏍囧噯浠g爜"
             sortable="custom"
           />
           <el-table-column
             prop="name"
             label="鏍囧噯鍚嶇О"
+            show-tooltip-when-overflow
             sortable="custom"
           />
           <el-table-column
             prop="descr"
+            show-tooltip-when-overflow
             label="鏍囧噯鎻忚堪"
             sortable="custom"
           >
@@ -81,11 +84,13 @@
           <el-table-column
             prop="lm_user"
             label="鍒涘缓浜哄憳"
+            show-tooltip-when-overflow
             sortable="custom"
           />
           <el-table-column
             prop="lm_date"
             label="鍒涘缓鏃堕棿"
+            show-tooltip-when-overflow
             sortable="custom"
           />
           <el-table-column
@@ -98,15 +103,16 @@
                 <el-tooltip class="item" effect="dark" content="鏌ョ湅" placement="top">
                   <i
                     class="el-icon-view"
-                    style="color: #42b983;cursor: pointer;margin-right: 15px;"
+                    style="cursor: pointer;margin-right: 15px;"
+                    :style="{color:$store.state.settings.theme}"
                     @click="check('check',row)"
                   />
                 </el-tooltip>
                 <el-tooltip class="item" effect="dark" content="缂栬緫" placement="top">
-                  <i class="el-icon-edit-outline" @click="edit('edit',row)" />
+                  <i :style="{color:$store.state.settings.theme}" class="el-icon-edit-outline" @click="edit('edit',row)" />
                 </el-tooltip>
                 <el-tooltip v-del-tab-index class="item" effect="dark" content="鍒犻櫎" placement="top">
-                  <i class="el-icon-delete" @click="del(row)" />
+                  <i :style="{color:$store.state.settings.theme}" class="el-icon-delete" @click="del(row)" />
                 </el-tooltip>
               </div>
             </template>
@@ -126,6 +132,7 @@
     </div>
 
     <el-dialog
+      v-el-drag-dialog
       :title="operation==='add'?'鏂板':(operation==='edit'?'缂栬緫':'鏌ョ湅')"
       :visible.sync="dialogVisible"
       width="800px"
@@ -135,7 +142,7 @@
     >
       <!--      @close="handleClose"-->
       <div style="margin-bottom: 10px">
-        <i class="el-icon-s-comment" style="color:#42b983;" /> 鏍囧噯淇℃伅锛�
+        <i class="el-icon-s-comment" :style="{color:$store.state.settings.theme}" /> 鏍囧噯淇℃伅锛�
       </div>
       <el-form
         ref="dialogForm"
@@ -161,10 +168,10 @@
         </el-form-item>
       </el-form>
       <div style="margin-bottom: 10px">
-        <i class="el-icon-s-comment" style="color:#42b983;" /> 妫�楠岄」淇℃伅锛�
+        <i class="el-icon-s-comment" :style="{color:$store.state.settings.theme}" /> 妫�楠岄」淇℃伅锛�
       </div>
       <div style="margin-bottom: 10px">
-        <el-button v-if="operation==='add'||operation==='edit'" type="primary" @click="JYadd">鏂板</el-button>
+        <el-button v-if="operation==='add'||operation==='edit'" v-waves type="primary" @click="JYadd">鏂板</el-button>
       </div>
       <div>
         <el-table
@@ -185,6 +192,7 @@
             fixed
           />
           <el-table-column
+            show-tooltip-when-overflow
             prop="code"
             label="妫�楠屾爣鍑嗙紪鐮�"
           >
@@ -208,6 +216,7 @@
           </el-table-column>
           <el-table-column
             prop="name"
+            show-tooltip-when-overflow
             label="妫�楠屾爣鍑嗗悕绉�"
           >
             <template slot-scope="{row}">
@@ -230,6 +239,7 @@
           </el-table-column>
           <el-table-column
             prop="descr"
+            show-tooltip-when-overflow
             label="妫�楠屾弿杩版弿杩�"
           >
             <template slot-scope="{row}">
@@ -244,10 +254,10 @@
           >
             <template slot-scope="{row}">
               <div class="operationClass">
-                <el-button v-if="row.isVisible===0" type="text" @click="JYedit(row)">缂栬緫</el-button>
-                <el-button v-if="row.isVisible===0" type="text" @click="JYdel(row)">鍒犻櫎</el-button>
-                <el-button v-if="row.isVisible===1" type="text" @click="JYsave(row)">纭畾</el-button>
-                <el-button v-if="row.isVisible===1" type="text" @click="JYcancel(row)">鍙栨秷</el-button>
+                <el-button v-if="row.isVisible===0" v-waves type="text" @click="JYedit(row)">缂栬緫</el-button>
+                <el-button v-if="row.isVisible===0" v-waves type="text" @click="JYdel(row)">鍒犻櫎</el-button>
+                <el-button v-if="row.isVisible===1" v-waves type="text" @click="JYsave(row)">纭畾</el-button>
+                <el-button v-if="row.isVisible===1" v-waves type="text" @click="JYcancel(row)">鍙栨秷</el-button>
               </div>
             </template>
           </el-table-column>
@@ -256,9 +266,16 @@
 
       <span slot="footer" class="dialog-footer">
         <div class="footerButton">
-          <el-button v-if="operation==='check'" @click="dialogVisibleCancel">杩� 鍥�</el-button>
-          <el-button v-if="operation!=='check'" @click="dialogVisibleCancel">鍙� 娑�</el-button>
-          <el-button v-if="operation!=='check'" type="primary" @click="dialogVisibleConfirm">鎻� 浜�</el-button>
+          <el-button v-if="operation==='check'" v-waves @click="dialogVisibleCancel">杩� 鍥�</el-button>
+          <el-button v-if="operation!=='check'" v-waves @click="dialogVisibleCancel">鍙� 娑�</el-button>
+          <el-button
+            v-if="operation!=='check'"
+            v-waves
+            :loading="$store.state.app.buttonIsDisabled"
+            :disabled="$store.state.app.buttonIsDisabled"
+            type="primary"
+            @click="dialogVisibleConfirm"
+          >鎻� 浜�</el-button>
         </div>
       </span>
     </el-dialog>
@@ -274,12 +291,15 @@
   StepCheckStanedSearch
 } from '@/api/zlgl'
 import { validateCode } from '@/utils/global'
+import elDragDialog from '@/directive/el-drag-dialog'
+import waves from '@/directive/waves'
 
 export default {
   name: 'ZJBZ',
   components: {
     Pagination
   },
+  directives: { elDragDialog, waves },
   data() {
     return {
       isIpad: false,
@@ -446,6 +466,7 @@
     dialogVisibleConfirm() {
       this.$refs.dialogForm.validate(valid => {
         if (valid) {
+          this.$store.state.app.buttonIsDisabled = true
           const tableData = []
           this.JYTableData = this.JYTableData.filter(item => item.code !== '')
           this.JYTableData.forEach((item, index) => {
@@ -464,9 +485,10 @@
           }
           AddUpdateStepCheckStaned(this.operation === 'add' ? 'Add' : 'Update', data).then(res => {
             if (res.code === '200') {
-              this.$message.success(this.operation === 'add' ? '娣诲姞鎴愬姛锛�' : '淇敼鎴愬姛锛�')
               this.dialogVisible = false
+              this.$message.success(this.operation === 'add' ? '娣诲姞鎴愬姛锛�' : '淇敼鎴愬姛锛�')
               this.getStepCheckStanedSearch()
+              this.$store.state.app.buttonIsDisabled = false
             } else {
               this.$message.error(this.operation === 'add' ? '娣诲姞澶辫触锛�' : '淇敼澶辫触锛�')
             }

--
Gitblit v1.9.3