From 0effee74b176638329d6d378de44293219fd8de2 Mon Sep 17 00:00:00 2001
From: RuoYi <yzz_ivy@163.com>
Date: 星期一, 21 十一月 2022 18:57:42 +0800
Subject: [PATCH] 消除控制台出现的警告信息
---
src/views/system/config/index.vue | 14 -
src/views/system/role/index.vue | 28 ---
src/views/monitor/job/index.vue | 35 ----
src/views/system/dept/index.vue | 22 --
src/views/system/post/index.vue | 16 -
src/views/monitor/cache/list.vue | 15 +
src/views/system/user/profile/userAvatar.vue | 114 ++++++++-------
src/views/monitor/online/index.vue | 7
src/views/monitor/operlog/index.vue | 7
src/views/system/menu/index.vue | 23 --
src/views/system/user/index.vue | 28 ---
src/views/tool/gen/genInfoForm.vue | 2
src/views/system/role/authUser.vue | 7
src/views/tool/gen/index.vue | 37 ----
src/views/system/dict/data.vue | 16 -
src/views/system/role/selectUser.vue | 2
src/views/monitor/job/log.vue | 7
src/views/system/notice/index.vue | 14 -
src/views/system/dict/index.vue | 16 -
19 files changed, 116 insertions(+), 294 deletions(-)
diff --git a/src/views/monitor/cache/list.vue b/src/views/monitor/cache/list.vue
index e1ed9ea..1cc5357 100644
--- a/src/views/monitor/cache/list.vue
+++ b/src/views/monitor/cache/list.vue
@@ -7,7 +7,8 @@
<span>缂撳瓨鍒楄〃</span>
<el-button
style="float: right; padding: 3px 0"
- type="text"
+ link
+ type="primary"
icon="Refresh"
@click="refreshCacheNames()"
></el-button>
@@ -48,7 +49,8 @@
>
<template #default="scope">
<el-button
- type="text"
+ link
+ type="primary"
icon="Delete"
@click="handleClearCacheName(scope.row)"
></el-button>
@@ -64,7 +66,8 @@
<span>閿悕鍒楄〃</span>
<el-button
style="float: right; padding: 3px 0"
- type="text"
+ link
+ type="primary"
icon="Refresh"
@click="refreshCacheKeys()"
></el-button>
@@ -97,7 +100,8 @@
>
<template #default="scope">
<el-button
- type="text"
+ link
+ type="primary"
icon="Delete"
@click="handleClearCacheKey(scope.row)"
></el-button>
@@ -113,7 +117,8 @@
<span>缂撳瓨鍐呭</span>
<el-button
style="float: right; padding: 3px 0"
- type="text"
+ link
+ type="primary"
icon="Refresh"
@click="handleClearCacheAll()"
>娓呯悊鍏ㄩ儴</el-button
diff --git a/src/views/monitor/job/index.vue b/src/views/monitor/job/index.vue
index b93e9df..519760d 100644
--- a/src/views/monitor/job/index.vue
+++ b/src/views/monitor/job/index.vue
@@ -111,44 +111,19 @@
<el-table-column label="鎿嶄綔" align="center" width="200" class-name="small-padding fixed-width">
<template #default="scope">
<el-tooltip content="淇敼" placement="top">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['monitor:job:edit']"
- ></el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['monitor:job:edit']"></el-button>
</el-tooltip>
<el-tooltip content="鍒犻櫎" placement="top">
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['monitor:job:remove']"
- ></el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['monitor:job:remove']"></el-button>
</el-tooltip>
<el-tooltip content="鎵ц涓�娆�" placement="top">
- <el-button
- type="text"
- icon="CaretRight"
- @click="handleRun(scope.row)"
- v-hasPermi="['monitor:job:changeStatus']"
- ></el-button>
+ <el-button link type="primary" icon="CaretRight" @click="handleRun(scope.row)" v-hasPermi="['monitor:job:changeStatus']"></el-button>
</el-tooltip>
<el-tooltip content="浠诲姟璇︾粏" placement="top">
- <el-button
- type="text"
- icon="View"
- @click="handleView(scope.row)"
- v-hasPermi="['monitor:job:query']"
- ></el-button>
+ <el-button link type="primary" icon="View" @click="handleView(scope.row)" v-hasPermi="['monitor:job:query']"></el-button>
</el-tooltip>
<el-tooltip content="璋冨害鏃ュ織" placement="top">
- <el-button
- type="text"
- icon="Operation"
- @click="handleJobLog(scope.row)"
- v-hasPermi="['monitor:job:query']"
- ></el-button>
+ <el-button link type="primary" icon="Operation" @click="handleJobLog(scope.row)" v-hasPermi="['monitor:job:query']"></el-button>
</el-tooltip>
</template>
</el-table-column>
diff --git a/src/views/monitor/job/log.vue b/src/views/monitor/job/log.vue
index 6ab1c58..803dbbd 100644
--- a/src/views/monitor/job/log.vue
+++ b/src/views/monitor/job/log.vue
@@ -119,12 +119,7 @@
</el-table-column>
<el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="View"
- @click="handleView(scope.row)"
- v-hasPermi="['monitor:job:query']"
- >璇︾粏</el-button>
+ <el-button link type="primary" icon="View" @click="handleView(scope.row)" v-hasPermi="['monitor:job:query']">璇︾粏</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/monitor/online/index.vue b/src/views/monitor/online/index.vue
index 4e34135..2b51340 100644
--- a/src/views/monitor/online/index.vue
+++ b/src/views/monitor/online/index.vue
@@ -48,12 +48,7 @@
</el-table-column>
<el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Delete"
- @click="handleForceLogout(scope.row)"
- v-hasPermi="['monitor:online:forceLogout']"
- >寮洪��</el-button>
+ <el-button link type="primary" icon="Delete" @click="handleForceLogout(scope.row)" v-hasPermi="['monitor:online:forceLogout']">寮洪��</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/monitor/operlog/index.vue b/src/views/monitor/operlog/index.vue
index 950ea0b..077f20a 100644
--- a/src/views/monitor/operlog/index.vue
+++ b/src/views/monitor/operlog/index.vue
@@ -121,12 +121,7 @@
</el-table-column>
<el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="View"
- @click="handleView(scope.row, scope.index)"
- v-hasPermi="['monitor:operlog:query']"
- >璇︾粏</el-button>
+ <el-button link type="primary" icon="View" @click="handleView(scope.row, scope.index)" v-hasPermi="['monitor:operlog:query']">璇︾粏</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/config/index.vue b/src/views/system/config/index.vue
index 9a05e6c..064b36a 100644
--- a/src/views/system/config/index.vue
+++ b/src/views/system/config/index.vue
@@ -115,18 +115,8 @@
</el-table-column>
<el-table-column label="鎿嶄綔" align="center" width="150" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:config:edit']"
- >淇敼</el-button>
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:config:remove']"
- >鍒犻櫎</el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:config:edit']" >淇敼</el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:config:remove']">鍒犻櫎</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/dept/index.vue b/src/views/system/dept/index.vue
index 1b2dc44..889867d 100644
--- a/src/views/system/dept/index.vue
+++ b/src/views/system/dept/index.vue
@@ -69,25 +69,9 @@
</el-table-column>
<el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:dept:edit']"
- >淇敼</el-button>
- <el-button
- type="text"
- icon="Plus"
- @click="handleAdd(scope.row)"
- v-hasPermi="['system:dept:add']"
- >鏂板</el-button>
- <el-button
- v-if="scope.row.parentId != 0"
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:dept:remove']"
- >鍒犻櫎</el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:dept:edit']">淇敼</el-button>
+ <el-button link type="primary" icon="Plus" @click="handleAdd(scope.row)" v-hasPermi="['system:dept:add']">鏂板</el-button>
+ <el-button v-if="scope.row.parentId != 0" link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:dept:remove']">鍒犻櫎</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/dict/data.vue b/src/views/system/dict/data.vue
index a8fa6ef..6960f2e 100644
--- a/src/views/system/dict/data.vue
+++ b/src/views/system/dict/data.vue
@@ -108,20 +108,10 @@
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
- <el-table-column label="鎿嶄綔" align="center" width="150" class-name="small-padding fixed-width">
+ <el-table-column label="鎿嶄綔" align="center" width="160" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:dict:edit']"
- >淇敼</el-button>
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:dict:remove']"
- >鍒犻櫎</el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:dict:edit']">淇敼</el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:dict:remove']">鍒犻櫎</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/dict/index.vue b/src/views/system/dict/index.vue
index d1f5d8a..33fa3c9 100644
--- a/src/views/system/dict/index.vue
+++ b/src/views/system/dict/index.vue
@@ -123,20 +123,10 @@
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
- <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
+ <el-table-column label="鎿嶄綔" align="center" width="160" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:dict:edit']"
- >淇敼</el-button>
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:dict:remove']"
- >鍒犻櫎</el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:dict:edit']">淇敼</el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:dict:remove']">鍒犻櫎</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/menu/index.vue b/src/views/system/menu/index.vue
index 3dd26be..533ad73 100644
--- a/src/views/system/menu/index.vue
+++ b/src/views/system/menu/index.vue
@@ -74,26 +74,11 @@
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
- <el-table-column label="鎿嶄綔" align="center" width="200" class-name="small-padding fixed-width">
+ <el-table-column label="鎿嶄綔" align="center" width="210" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:menu:edit']"
- >淇敼</el-button>
- <el-button
- type="text"
- icon="Plus"
- @click="handleAdd(scope.row)"
- v-hasPermi="['system:menu:add']"
- >鏂板</el-button>
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:menu:remove']"
- >鍒犻櫎</el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:menu:edit']">淇敼</el-button>
+ <el-button link type="primary" icon="Plus" @click="handleAdd(scope.row)" v-hasPermi="['system:menu:add']">鏂板</el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:menu:remove']">鍒犻櫎</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/notice/index.vue b/src/views/system/notice/index.vue
index 2bcd877..35e15c1 100644
--- a/src/views/system/notice/index.vue
+++ b/src/views/system/notice/index.vue
@@ -95,18 +95,8 @@
</el-table-column>
<el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:notice:edit']"
- >淇敼</el-button>
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:notice:remove']"
- >鍒犻櫎</el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:notice:edit']">淇敼</el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:notice:remove']" >鍒犻櫎</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/post/index.vue b/src/views/system/post/index.vue
index 729bee7..aee6034 100644
--- a/src/views/system/post/index.vue
+++ b/src/views/system/post/index.vue
@@ -93,20 +93,10 @@
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
- <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
+ <el-table-column label="鎿嶄綔" width="180" align="center" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:post:edit']"
- >淇敼</el-button>
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:post:remove']"
- >鍒犻櫎</el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:post:edit']">淇敼</el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:post:remove']">鍒犻櫎</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/role/authUser.vue b/src/views/system/role/authUser.vue
index 55ff5b2..de3efd8 100644
--- a/src/views/system/role/authUser.vue
+++ b/src/views/system/role/authUser.vue
@@ -75,12 +75,7 @@
</el-table-column>
<el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template #default="scope">
- <el-button
- type="text"
- icon="CircleClose"
- @click="cancelAuthUser(scope.row)"
- v-hasPermi="['system:role:remove']"
- >鍙栨秷鎺堟潈</el-button>
+ <el-button link type="primary" icon="CircleClose" @click="cancelAuthUser(scope.row)" v-hasPermi="['system:role:remove']">鍙栨秷鎺堟潈</el-button>
</template>
</el-table-column>
</el-table>
diff --git a/src/views/system/role/index.vue b/src/views/system/role/index.vue
index 1f83a11..e446ded 100644
--- a/src/views/system/role/index.vue
+++ b/src/views/system/role/index.vue
@@ -116,36 +116,16 @@
<el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template #default="scope">
<el-tooltip content="淇敼" placement="top" v-if="scope.row.roleId !== 1">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:role:edit']"
- ></el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:role:edit']"></el-button>
</el-tooltip>
<el-tooltip content="鍒犻櫎" placement="top" v-if="scope.row.roleId !== 1">
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:role:remove']"
- ></el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:role:remove']"></el-button>
</el-tooltip>
<el-tooltip content="鏁版嵁鏉冮檺" placement="top" v-if="scope.row.roleId !== 1">
- <el-button
- type="text"
- icon="CircleCheck"
- @click="handleDataScope(scope.row)"
- v-hasPermi="['system:role:edit']"
- ></el-button>
+ <el-button link type="primary" icon="CircleCheck" @click="handleDataScope(scope.row)" v-hasPermi="['system:role:edit']"></el-button>
</el-tooltip>
<el-tooltip content="鍒嗛厤鐢ㄦ埛" placement="top" v-if="scope.row.roleId !== 1">
- <el-button
- type="text"
- icon="User"
- @click="handleAuthUser(scope.row)"
- v-hasPermi="['system:role:edit']"
- ></el-button>
+ <el-button link type="primary" icon="User" @click="handleAuthUser(scope.row)" v-hasPermi="['system:role:edit']"></el-button>
</el-tooltip>
</template>
</el-table-column>
diff --git a/src/views/system/role/selectUser.vue b/src/views/system/role/selectUser.vue
index 0a6a412..fb9e362 100644
--- a/src/views/system/role/selectUser.vue
+++ b/src/views/system/role/selectUser.vue
@@ -7,6 +7,7 @@
v-model="queryParams.userName"
placeholder="璇疯緭鍏ョ敤鎴峰悕绉�"
clearable
+ style="width: 200px"
@keyup.enter="handleQuery"
/>
</el-form-item>
@@ -15,6 +16,7 @@
v-model="queryParams.phonenumber"
placeholder="璇疯緭鍏ユ墜鏈哄彿鐮�"
clearable
+ style="width: 200px"
@keyup.enter="handleQuery"
/>
</el-form-item>
diff --git a/src/views/system/user/index.vue b/src/views/system/user/index.vue
index 9d12a17..641f77b 100644
--- a/src/views/system/user/index.vue
+++ b/src/views/system/user/index.vue
@@ -154,36 +154,16 @@
<el-table-column label="鎿嶄綔" align="center" width="150" class-name="small-padding fixed-width">
<template #default="scope">
<el-tooltip content="淇敼" placement="top" v-if="scope.row.userId !== 1">
- <el-button
- type="text"
- icon="Edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:user:edit']"
- ></el-button>
+ <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:user:edit']"></el-button>
</el-tooltip>
<el-tooltip content="鍒犻櫎" placement="top" v-if="scope.row.userId !== 1">
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:user:remove']"
- ></el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:user:remove']"></el-button>
</el-tooltip>
<el-tooltip content="閲嶇疆瀵嗙爜" placement="top" v-if="scope.row.userId !== 1">
- <el-button
- type="text"
- icon="Key"
- @click="handleResetPwd(scope.row)"
- v-hasPermi="['system:user:resetPwd']"
- ></el-button>
+ <el-button link type="primary" icon="Key" @click="handleResetPwd(scope.row)" v-hasPermi="['system:user:resetPwd']"></el-button>
</el-tooltip>
<el-tooltip content="鍒嗛厤瑙掕壊" placement="top" v-if="scope.row.userId !== 1">
- <el-button
- type="text"
- icon="CircleCheck"
- @click="handleAuthRole(scope.row)"
- v-hasPermi="['system:user:edit']"
- ></el-button>
+ <el-button link type="primary" icon="CircleCheck" @click="handleAuthRole(scope.row)" v-hasPermi="['system:user:edit']"></el-button>
</el-tooltip>
</template>
</el-table-column>
diff --git a/src/views/system/user/profile/userAvatar.vue b/src/views/system/user/profile/userAvatar.vue
index 81f9e44..343968b 100644
--- a/src/views/system/user/profile/userAvatar.vue
+++ b/src/views/system/user/profile/userAvatar.vue
@@ -1,9 +1,10 @@
<template>
- <div class="user-info-head" @click="editCropper()"><img :src="options.img" title="鐐瑰嚮涓婁紶澶村儚" class="img-circle img-lg" /></div>
- <el-dialog :title="title" v-model="open" width="800px" append-to-body @opened="modalOpened" @close="closeDialog">
- <el-row>
- <el-col :xs="24" :md="12" :style="{height: '350px'}">
- <vue-cropper
+ <div class="user-info-head" @click="editCropper()">
+ <img :src="options.img" title="鐐瑰嚮涓婁紶澶村儚" class="img-circle img-lg" />
+ <el-dialog :title="title" v-model="open" width="800px" append-to-body @opened="modalOpened" @close="closeDialog">
+ <el-row>
+ <el-col :xs="24" :md="12" :style="{ height: '350px' }">
+ <vue-cropper
ref="cropper"
:img="options.img"
:info="true"
@@ -14,50 +15,56 @@
:outputType="options.outputType"
@realTime="realTime"
v-if="visible"
- />
- </el-col>
- <el-col :xs="24" :md="12" :style="{height: '350px'}">
- <div class="avatar-upload-preview">
- <img :src="options.previews.url" :style="options.previews.img"/>
- </div>
- </el-col>
- </el-row>
- <br/>
- <el-row>
- <el-col :lg="2" :md="2">
- <el-upload action="#" :http-request="requestUpload" :show-file-list="false" :before-upload="beforeUpload">
- <el-button>
- 閫夋嫨
- <el-icon class="el-icon--right"><Upload /></el-icon>
- </el-button>
- </el-upload>
- </el-col>
- <el-col :lg="{span: 1, offset: 2}" :md="2">
- <el-button icon="Plus" @click="changeScale(1)"></el-button>
- </el-col>
- <el-col :lg="{span: 1, offset: 1}" :md="2">
- <el-button icon="Minus" @click="changeScale(-1)"></el-button>
- </el-col>
- <el-col :lg="{span: 1, offset: 1}" :md="2">
- <el-button icon="RefreshLeft" @click="rotateLeft()"></el-button>
- </el-col>
- <el-col :lg="{span: 1, offset: 1}" :md="2">
- <el-button icon="RefreshRight" @click="rotateRight()"></el-button>
- </el-col>
- <el-col :lg="{span: 2, offset: 6}" :md="2">
- <el-button type="primary" @click="uploadImg()">鎻� 浜�</el-button>
- </el-col>
- </el-row>
- </el-dialog>
+ />
+ </el-col>
+ <el-col :xs="24" :md="12" :style="{ height: '350px' }">
+ <div class="avatar-upload-preview">
+ <img :src="options.previews.url" :style="options.previews.img" />
+ </div>
+ </el-col>
+ </el-row>
+ <br />
+ <el-row>
+ <el-col :lg="2" :md="2">
+ <el-upload
+ action="#"
+ :http-request="requestUpload"
+ :show-file-list="false"
+ :before-upload="beforeUpload"
+ >
+ <el-button>
+ 閫夋嫨
+ <el-icon class="el-icon--right"><Upload /></el-icon>
+ </el-button>
+ </el-upload>
+ </el-col>
+ <el-col :lg="{ span: 1, offset: 2 }" :md="2">
+ <el-button icon="Plus" @click="changeScale(1)"></el-button>
+ </el-col>
+ <el-col :lg="{ span: 1, offset: 1 }" :md="2">
+ <el-button icon="Minus" @click="changeScale(-1)"></el-button>
+ </el-col>
+ <el-col :lg="{ span: 1, offset: 1 }" :md="2">
+ <el-button icon="RefreshLeft" @click="rotateLeft()"></el-button>
+ </el-col>
+ <el-col :lg="{ span: 1, offset: 1 }" :md="2">
+ <el-button icon="RefreshRight" @click="rotateRight()"></el-button>
+ </el-col>
+ <el-col :lg="{ span: 2, offset: 6 }" :md="2">
+ <el-button type="primary" @click="uploadImg()">鎻� 浜�</el-button>
+ </el-col>
+ </el-row>
+ </el-dialog>
+ </div>
</template>
<script setup>
import "vue-cropper/dist/index.css";
import { VueCropper } from "vue-cropper";
import { uploadAvatar } from "@/api/system/user";
-import useUserStore from '@/store/modules/user'
+import useUserStore from "@/store/modules/user";
-const userStore = useUserStore()
+const userStore = useUserStore();
const { proxy } = getCurrentInstance();
const open = ref(false);
@@ -71,34 +78,33 @@
autoCropWidth: 200, // 榛樿鐢熸垚鎴浘妗嗗搴�
autoCropHeight: 200, // 榛樿鐢熸垚鎴浘妗嗛珮搴�
fixedBox: true, // 鍥哄畾鎴浘妗嗗ぇ灏� 涓嶅厑璁告敼鍙�
- outputType:"png", // 榛樿鐢熸垚鎴浘涓篜NG鏍煎紡
+ outputType: "png", // 榛樿鐢熸垚鎴浘涓篜NG鏍煎紡
previews: {} //棰勮鏁版嵁
});
/** 缂栬緫澶村儚 */
function editCropper() {
open.value = true;
-};
+}
/** 鎵撳紑寮瑰嚭灞傜粨鏉熸椂鐨勫洖璋� */
function modalOpened() {
visible.value = true;
-};
+}
/** 瑕嗙洊榛樿涓婁紶琛屼负 */
-function requestUpload() {
-};
+function requestUpload() {}
/** 鍚戝乏鏃嬭浆 */
function rotateLeft() {
proxy.$refs.cropper.rotateLeft();
-};
+}
/** 鍚戝彸鏃嬭浆 */
function rotateRight() {
proxy.$refs.cropper.rotateRight();
-};
+}
/** 鍥剧墖缂╂斁 */
function changeScale(num) {
num = num || 1;
proxy.$refs.cropper.changeScale(num);
-};
+}
/** 涓婁紶棰勫鐞� */
function beforeUpload(file) {
if (file.type.indexOf("image/") == -1) {
@@ -110,7 +116,7 @@
options.img = reader.result;
};
}
-};
+}
/** 涓婁紶鍥剧墖 */
function uploadImg() {
proxy.$refs.cropper.getCropBlob(data => {
@@ -124,16 +130,16 @@
visible.value = false;
});
});
-};
+}
/** 瀹炴椂棰勮 */
function realTime(data) {
options.previews = data;
-};
+}
/** 鍏抽棴绐楀彛 */
function closeDialog() {
options.img = userStore.avatar;
options.visible = false;
-};
+}
</script>
<style lang='scss' scoped>
diff --git a/src/views/tool/gen/genInfoForm.vue b/src/views/tool/gen/genInfoForm.vue
index 1a45ec1..520ebc7 100644
--- a/src/views/tool/gen/genInfoForm.vue
+++ b/src/views/tool/gen/genInfoForm.vue
@@ -226,7 +226,7 @@
import { listMenu } from "@/api/system/menu";
const subColumns = ref([]);
-const menuOptions = ref({});
+const menuOptions = ref([]);
const { proxy } = getCurrentInstance();
const props = defineProps({
diff --git a/src/views/tool/gen/index.vue b/src/views/tool/gen/index.vue
index 3020e9b..c0bc943 100644
--- a/src/views/tool/gen/index.vue
+++ b/src/views/tool/gen/index.vue
@@ -107,44 +107,19 @@
<el-table-column label="鎿嶄綔" align="center" width="330" class-name="small-padding fixed-width">
<template #default="scope">
<el-tooltip content="棰勮" placement="top">
- <el-button
- type="text"
- icon="View"
- @click="handlePreview(scope.row)"
- v-hasPermi="['tool:gen:preview']"
- ></el-button>
+ <el-button link type="primary" icon="View" @click="handlePreview(scope.row)" v-hasPermi="['tool:gen:preview']"></el-button>
</el-tooltip>
<el-tooltip content="缂栬緫" placement="top">
- <el-button
- type="text"
- icon="Edit"
- @click="handleEditTable(scope.row)"
- v-hasPermi="['tool:gen:edit']"
- ></el-button>
+ <el-button link type="primary" icon="Edit" @click="handleEditTable(scope.row)" v-hasPermi="['tool:gen:edit']"></el-button>
</el-tooltip>
<el-tooltip content="鍒犻櫎" placement="top">
- <el-button
- type="text"
- icon="Delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['tool:gen:remove']"
- ></el-button>
+ <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['tool:gen:remove']"></el-button>
</el-tooltip>
<el-tooltip content="鍚屾" placement="top">
- <el-button
- type="text"
- icon="Refresh"
- @click="handleSynchDb(scope.row)"
- v-hasPermi="['tool:gen:edit']"
- ></el-button>
+ <el-button link type="primary" icon="Refresh" @click="handleSynchDb(scope.row)" v-hasPermi="['tool:gen:edit']"></el-button>
</el-tooltip>
<el-tooltip content="鐢熸垚浠g爜" placement="top">
- <el-button
- type="text"
- icon="Download"
- @click="handleGenTable(scope.row)"
- v-hasPermi="['tool:gen:code']"
- ></el-button>
+ <el-button link type="primary" icon="Download" @click="handleGenTable(scope.row)" v-hasPermi="['tool:gen:code']"></el-button>
</el-tooltip>
</template>
</el-table-column>
@@ -157,7 +132,7 @@
@pagination="getList"
/>
<!-- 棰勮鐣岄潰 -->
- <el-dialog :title="preview.title" v-model="preview.open" width="80%" top="5vh" append-to-body custom-class="scrollbar">
+ <el-dialog :title="preview.title" v-model="preview.open" width="80%" top="5vh" append-to-body class="scrollbar">
<el-tabs v-model="preview.activeName">
<el-tab-pane
v-for="(value, key) in preview.data"
--
Gitblit v1.9.3