From 17efddc6a667670dca682bf36b51a43e99615e6d Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期三, 16 十月 2024 15:59:38 +0800
Subject: [PATCH] 代码初始化

---
 admin/src/components/common/GlobalWindow.vue |   43 +++++++++++++++++++++++++++++++++++--------
 1 files changed, 35 insertions(+), 8 deletions(-)

diff --git a/admin/src/components/common/GlobalWindow.vue b/admin/src/components/common/GlobalWindow.vue
index d59bd50..4ae9ce1 100644
--- a/admin/src/components/common/GlobalWindow.vue
+++ b/admin/src/components/common/GlobalWindow.vue
@@ -8,18 +8,21 @@
     :close-on-press-escape="false"
     :wrapper-closable="false"
     :append-to-body="true"
+    :modal="true"
     @close="close"
   >
     <div slot="title" class="window__header">
       <span class="header__btn-back" @click="close"><i class="el-icon-arrow-left"></i></span>{{title}}
+      <!-- {{title}} -->
     </div>
     <div class="window__body">
       <slot></slot>
     </div>
     <div v-if="withFooter" class="window__footer">
       <slot name="footer">
-        <el-button @click="confirm" :loading="confirmWorking" type="primary">纭畾</el-button>
-        <el-button @click="close">鍙栨秷</el-button>
+        <el-button v-if="showConfirm" @click="confirm" :loading="confirmWorking" type="primary">{{text}}</el-button>
+        <slot name="btns" />
+        <el-button @click="close">{{ backText }}</el-button>
       </slot>
     </div>
   </el-drawer>
@@ -31,17 +34,30 @@
   props: {
     width: {
       type: String,
-      default: '36%'
+      default: '100%'
     },
     // 鏄惁鍖呭惈搴曢儴鎿嶄綔
     withFooter: {
       type: Boolean,
       default: true
     },
+    // 鎻愪氦鎸夐挳鏂囧瓧
+    text: {
+      type: String,
+      default: '纭畾'
+    },
+    backText: {
+      type: String,
+      default: '杩斿洖'
+    },
     // 纭鎸夐挳loading鐘舵��
     confirmWorking: {
       type: Boolean,
       default: false
+    },
+    showConfirm: {
+      type: Boolean,
+      default: true
     },
     // 鏍囬
     title: {
@@ -59,6 +75,7 @@
       this.$emit('confirm')
     },
     close () {
+      this.$emit('close')
       this.$emit('update:visible', false)
     }
   }
@@ -70,11 +87,16 @@
 // 杈撳叆妗嗛珮搴�
 $input-height: 32px;
 .global-window {
+  top: 56px !important;
+  left: 250px !important;
   // 澶撮儴鏍囬
-  /deep/ .el-drawer__header {
+  ::v-deep .el-drawer__header {
     padding: 0 10px 0 0;
     line-height: 40px;
     border-bottom: 1px solid #eee;
+    // text-align: center;
+    font-weight: 500;
+    color: #222;
     // 杩斿洖鎸夐挳
     .header__btn-back {
       display: inline-block;
@@ -90,7 +112,7 @@
     }
   }
   // 涓讳綋
-  /deep/ .el-drawer__body {
+  ::v-deep .el-drawer__body {
     display: flex;
     flex-direction: column;
     position: absolute;
@@ -98,15 +120,20 @@
     bottom: 0;
     width: 100%;
     overflow: hidden;
+    // background-color: #f7f7f7;
     // 鍐呭
     .window__body {
+      // width: 1100px;
+      // margin: 0 auto;
+      // background-color: #fff;
+      width: 100%;
       height: 100%;
       overflow-y: auto;
       padding: 12px 16px;
       // 鏍囩
-      .el-form-item__label {
-        float: none;
-      }
+      // .el-form-item__label {
+      //   float: none;
+      // }
       // 鍏冪礌瀹藉害涓�100%
       .el-form-item__content > *{
         width: 100%;

--
Gitblit v1.9.3