Jelajahi Sumber

<el-dialog>全部换成<DialogCom>

jiawuxian 2 tahun lalu
induk
melakukan
4d83e27cf7

+ 2 - 2
src/utils/generator/html.js

@@ -5,13 +5,13 @@ let confGlobal
 let someSpanIsNot24
 
 export function dialogWrapper(str) {
-  return `<el-dialog v-bind="$attrs" v-on="$listeners" @open="onOpen" @close="onClose" title="Dialog Title">
+  return `<DialogCom v-bind="$attrs" v-on="$listeners" @open="onOpen" @close="onClose" title="Dialog Title">
     ${str}
     <div slot="footer">
       <el-button @click="close">取消</el-button>
       <el-button type="primary" @click="handleConfirm">确定</el-button>
     </div>
-  </el-dialog>`
+  </DialogCom>`
 }
 
 export function vueTemplate(str) {

+ 2 - 2
src/views/check/dialog.edit.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="rule-type">
-    <el-dialog
+    <DialogCom
       :title="id ? '编辑检查计划' : '新增检查计划'"
       :visible.sync="isShow"
       width="1500px"
@@ -309,7 +309,7 @@
         <el-button @click="onHide">取消</el-button>
         <el-button type="primary" @click="onSubmit">确定</el-button>
       </div>
-    </el-dialog>
+   </DialogCom>
     <DialogSelect
       ref="DialogSelect"
       :defaultSelect="defaultSelect"

+ 2 - 2
src/views/check/distribute.vue

@@ -1,5 +1,5 @@
 <template>
-  <el-dialog
+  <DialogCom
     title="选择下发机构状态"
     :visible.sync="isShow"
     class="g-dialog-select-safe-check"
@@ -62,7 +62,7 @@
       <el-button @click="onHide">关闭</el-button>
       <el-button type="primary" @click="onSubmit">确定</el-button>
     </div>
-  </el-dialog>
+ </DialogCom>
 </template>
 <script>
 import { listByTypes } from "@/api/system/org.js";

+ 2 - 2
src/views/core/drill/plan/dialog.select.file.vue

@@ -1,5 +1,5 @@
 <template>
-  <el-dialog
+  <DialogCom
     title="选择学习附件"
     :visible.sync="isShow"
     class="g-dialog-select-safe-check"
@@ -62,7 +62,7 @@
       <el-button @click="onHide">关闭</el-button>
       <el-button type="primary" @click="onSubmit">确定</el-button>
     </div>
-  </el-dialog>
+ </DialogCom>
 </template>
 <script>
 import GSearchTable from "@/components/table/gx.search.table.vue";

+ 2 - 2
src/views/core/drill/plan/index.vue

@@ -118,7 +118,7 @@
       </el-col>
     </el-row>
     <!-- 添加或修改教育培训计划对话框 -->
-    <el-dialog :title="title" :visible.sync="open" :before-close="closeDialog"  :close="cancel" width="850px" height="800px" append-to-body>
+    <DialogCom :title="title" :visible.sync="open" :before-close="closeDialog"  :close="cancel" width="850px" height="800px" append-to-body>
       <el-form ref="form" :model="form" :rules="rules" label-width="110px">
         <el-row>
           <el-col :span="24">
@@ -241,7 +241,7 @@
         <el-button type="primary" @click="submitForm">确 定</el-button>
         <el-button @click="cancel">取 消</el-button>
       </div>
-    </el-dialog>
+   </DialogCom>
     <DialogSelectFile
       ref="DialogSelectFile"
       :defaultSelect=defaultSelect

+ 2 - 2
src/views/core/drill/task/dialog.info.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="edu-training-edit">
-    <el-dialog title="教育培训详情" :visible.sync="isShow" width="960px">
+    <DialogCom title="教育培训详情" :visible.sync="isShow" width="960px">
       <div class="page-body">
         <el-form :model="formData" size="small" ref="form" label-position="right" label-width="120px"
                  label-suffix=":">
@@ -109,7 +109,7 @@
       <div slot="footer" class="dialog-footer">
         <el-button @click="onHide">关闭</el-button>
       </div>
-    </el-dialog>
+   </DialogCom>
   </div>
 </template>
 

+ 2 - 2
src/views/core/drill/task/dialog.perform.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="edu-training-edit">
-    <el-dialog :title="'演练登记'" :close="onHide" :visible.sync="isShow" width="960px">
+    <DialogCom :title="'演练登记'" :close="onHide" :visible.sync="isShow" width="960px">
       <div class="page-body">
         <el-form :model="formData" :rules="formDataRules" size="small" ref="form" label-position="right"
           label-width="120px" label-prefix=":">
@@ -78,7 +78,7 @@
         <el-button type="primary" @click="onSave">暂存</el-button>
         <el-button type="primary" @click="onSubmit">提交</el-button>
       </div>
-    </el-dialog>
+   </DialogCom>
   </div>
 </template>
 

+ 2 - 2
src/views/core/message/index.vue

@@ -142,7 +142,7 @@
       />
     </el-col>
     <!-- 添加或修改公告通知对话框 -->
-    <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body @close="handleClose">
+    <DialogCom :title="title" :visible.sync="open" width="800px" append-to-body @close="handleClose">
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">
 
         <el-form-item label="标题" prop="title">
@@ -196,7 +196,7 @@
         <el-button type="primary" v-if="isSubmit" @click="submitForm">确 定</el-button>
         <el-button @click="cancel">取 消</el-button>
       </div>
-    </el-dialog>
+   </DialogCom>
     </el-row>
   </div>
 </template>

+ 4 - 4
src/views/core/send/index.vue

@@ -67,7 +67,7 @@
       @pagination="getList" />
 
     <!-- 添加或修改【请填写功能名称】对话框 -->
-    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+    <DialogCom :title="title" :visible.sync="open" width="500px" append-to-body>
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">
         <el-form-item label="标题" prop="title">
           <el-input v-model="form.title" maxlength="50" placeholder="请输入标题" />
@@ -108,10 +108,10 @@
         <el-button type="primary" @click="submitForm">确 定</el-button>
         <el-button @click="cancel">取 消</el-button>
       </div>
-    </el-dialog>
+   </DialogCom>
 
     <!-- 详情 -->
-    <el-dialog :title="title" :visible.sync="yes" width="500px" append-to-body>
+    <DialogCom :title="title" :visible.sync="yes" width="500px" append-to-body>
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">
         <el-form-item label="标题" prop="title">
           <el-input readonly v-model="form.title" maxlength="50" placeholder="请输入标题" />
@@ -153,7 +153,7 @@
       <!-- <div slot="footer" class="dialog-footer">
         <el-button @click="cancel">取 消</el-button>
       </div> -->
-    </el-dialog>
+   </DialogCom>
   </div>
 </template>
 

+ 2 - 2
src/views/question/list/dialog.vue

@@ -1,5 +1,5 @@
 <template>
-  <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body @close="cancel">
+  <DialogCom :title="title" :visible.sync="open" width="800px" append-to-body @close="cancel">
     <div class="question-dialog-body">
       <el-descriptions :column="2" class="contentArea">
       <el-descriptions-item label="隐患所属机构">{{
@@ -175,7 +175,7 @@
       <el-button type="primary" @click="submitForm" v-if="type!='detail'">确 定</el-button>
       <el-button @click="cancel">取 消</el-button>
     </div>
-  </el-dialog>
+ </DialogCom>
 </template>
 <script>
 import {

+ 2 - 2
src/views/safetyBook/dialog.edit.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="rule-type">
-    <el-dialog
+    <DialogCom
       :title="id ? '编辑安全责任书' : '新增安全责任书'"
       :visible.sync="isShow"
       @close="onHide"
@@ -67,7 +67,7 @@
         <el-button @click="isShow = false">取消</el-button>
         <el-button type="primary" @click="onSubmit">确定</el-button>
       </div>
-    </el-dialog>
+   </DialogCom>
     <DialogSelect ref="DialogSelect" @success="getSign"></DialogSelect>
   </div>
 </template>

+ 2 - 2
src/views/safetyBook/dialog.sign.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="rule-type">
-    <el-dialog
+    <DialogCom
       :title="id ? '编辑' : '新增'"
       :visible.sync="isShow"
       @close="onHide"
@@ -52,7 +52,7 @@
         <el-button @click="isShow = false">取消</el-button>
         <el-button type="primary" @click="onSubmit">确定</el-button>
       </div>
-    </el-dialog>
+    </DialogCom>
     <UserSelector ref="UserSelector" @select="onUserSelect"></UserSelector>
   </div>
 </template>

+ 2 - 2
src/views/safetycheck/rule/dialog.edit.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="rule-type">
-    <el-dialog
+    <DialogCom
       :title="id ? '编辑检查内容库' : '新增检查内容库'"
       :visible.sync="isShow"
       @close="onHide"
@@ -72,7 +72,7 @@
         <el-button @click="isShow=false">取消</el-button>
         <el-button type="primary" @click="onSubmit">确定</el-button>
       </div>
-    </el-dialog>
+    </DialogCom>
   </div>
 </template>
 

+ 2 - 2
src/views/safetycheck/ruleManager/dialog.editItem.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="rule-type">
-    <el-dialog
+    <DialogCom
       :title="!formData.id ? '新增检查项' : '编辑检查项'"
       :visible.sync="dialogVisible"
       width="50%"
@@ -58,7 +58,7 @@
         <el-button @click="dialogVisible = false">取 消</el-button>
         <el-button type="primary" @click="onSubmit()">保 存</el-button>
       </div>
-    </el-dialog>
+    </DialogCom>
     <EditPoint
       ref="editDialog"
       @submit="onPointSubmit"

+ 2 - 2
src/views/safetycheck/ruleManager/dialog.editPoint.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="rule-type">
-    <el-dialog
+    <DialogCom
       width="600px"
       :title="index >= 0 ? '编辑检查内容' : '新增检查内容'"
       :visible.sync="dataVisible"
@@ -82,7 +82,7 @@
           index >= 0 ? "保 存" : "添 加"
         }}</el-button>
       </div>
-    </el-dialog>
+    </DialogCom>
   </div>
 </template>