From ef561e204ee6fd7df25477b456b0d466b026550e Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期一, 30 一月 2023 15:28:32 +0800
Subject: [PATCH] 1.tagView标签新增可拖动功能

---
 src/views/sbgl/djbz.vue |   42 ++++++++++++++++++++++++++++++++----------
 1 files changed, 32 insertions(+), 10 deletions(-)

diff --git a/src/views/sbgl/djbz.vue b/src/views/sbgl/djbz.vue
index 0bf8b9e..b425029 100644
--- a/src/views/sbgl/djbz.vue
+++ b/src/views/sbgl/djbz.vue
@@ -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="鏍囧噯缂栫爜" style=" display: flex;">
+            <el-form-item label="鏍囧噯缂栫爜" style=" display: flex;">
               <el-input v-model="form.checkstandcode" placeholder="璇疯緭鍏�" style="width: 200px" />
             </el-form-item>
             <el-form-item label="鏍囧噯鍚嶇О" style=" display: flex;">
@@ -32,7 +32,10 @@
               </el-select>
             </el-form-item>
           </div>
-          <div class="bodySearchReset" :style="{marginLeft:$store.state.app.sidebar.opened?'5%':'10%'}">
+          <div
+            class="bodySearchReset"
+            :style="{marginLeft:$store.state.app.sidebar.opened? $store.state.settings.menuIsHorizontal?'15%':'3%':'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>
@@ -115,7 +118,12 @@
             sortable="custom"
           >
             <template slot-scope="{row}">
-              <i v-if="row.is_checkeqp==='Y'" :style="{color:$store.state.settings.theme}" class="el-icon-share" @click="checkeqpClick(row)" />
+              <i
+                v-if="row.is_checkeqp==='Y'"
+                :style="{color:$store.state.settings.theme}"
+                class="el-icon-share"
+                @click="checkeqpClick(row)"
+              />
               <i
                 v-if="row.is_checkeqp==='N'"
                 class="el-icon-share"
@@ -145,7 +153,11 @@
             <template slot-scope="{row}">
               <div class="operationClass">
                 <el-tooltip class="item" effect="dark" content="缂栬緫" placement="top">
-                  <i :style="{color:$store.state.settings.theme}" 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 :style="{color:$store.state.settings.theme}" class="el-icon-delete" @click="del(row)" />
@@ -168,6 +180,7 @@
     </div>
 
     <el-dialog
+      v-el-drag-dialog
       :title="operation==='add'?'鏂板':'缂栬緫'"
       :visible.sync="dialogVisible"
       width="800px"
@@ -359,6 +372,7 @@
 
     <!--    鍏宠仈璁惧-->
     <el-dialog
+      v-el-drag-dialog
       title="鍏宠仈璁惧"
       :visible.sync="dialogVisibleEqp"
       width="800px"
@@ -470,12 +484,14 @@
 } from '@/api/sbgl'
 import $ from 'jquery'
 import { validateCode } from '@/utils/global'
+import elDragDialog from '@/directive/el-drag-dialog'
 
 export default {
   name: 'Zzjg',
   components: {
     Pagination, ImportPicker
   },
+  directives: { elDragDialog },
   data() {
     return {
       mainHeight: 0,
@@ -692,6 +708,10 @@
     },
     // 瀵硅瘽妗嗙‘璁�
     dialogVisibleConfirm() {
+      if (this.tableDataDialog.length === 0) {
+        return this.$message.info('璁惧鍏宠仈鐐规椤逛俊鎭笉鑳戒负绌猴紒')
+      }
+
       this.$refs.dialogForm.validate(valid => {
         if (valid) {
           this.$store.state.app.buttonIsDisabled = true
@@ -1267,23 +1287,25 @@
   justify-content: center;
 }
 
-.tableFixed{
-  ::v-deep .el-table__fixed-right{
+.tableFixed {
+  ::v-deep .el-table__fixed-right {
     height: 100% !important;
   }
-  ::v-deep .el-table__fixed{
+
+  ::v-deep .el-table__fixed {
     height: 100% !important;
   }
 }
 </style>
 <style>
-.osloading{
+.osloading {
   font-size: 26px !important;
 }
 
-.el-loading-text{
+.el-loading-text {
   font-size: 26px !important;
 }
+
 .el-table .custom-row {
   background: #f8f8fa;
 }

--
Gitblit v1.9.3