From 2d49f2a56e7b8a0a828ddd9b2763ad5c006dc9bc Mon Sep 17 00:00:00 2001
From: RuoYi <yzz_ivy@163.com>
Date: Mon, 18 Sep 2023 15:05:23 +0800
Subject: [PATCH] 优化菜单管理类型为按钮状态可选
---
ruoyi-ui/src/views/system/user/profile/userAvatar.vue | 11 ++++-------
1 files changed, 4 insertions(+), 7 deletions(-)
diff --git a/ruoyi-ui/src/views/system/user/profile/userAvatar.vue b/ruoyi-ui/src/views/system/user/profile/userAvatar.vue
index 8d3195b..de69e47 100644
--- a/ruoyi-ui/src/views/system/user/profile/userAvatar.vue
+++ b/ruoyi-ui/src/views/system/user/profile/userAvatar.vue
@@ -12,6 +12,7 @@
:autoCropWidth="options.autoCropWidth"
:autoCropHeight="options.autoCropHeight"
:fixedBox="options.fixedBox"
+ :outputType="options.outputType"
@realTime="realTime"
v-if="visible"
/>
@@ -60,11 +61,6 @@
export default {
components: { VueCropper },
- props: {
- user: {
- type: Object
- }
- },
data() {
return {
// 是否显示弹出层
@@ -78,7 +74,8 @@
autoCrop: true, // 是否默认生成截图框
autoCropWidth: 200, // 默认生成截图框宽度
autoCropHeight: 200, // 默认生成截图框高度
- fixedBox: true // 固定截图框大小 不允许改变
+ fixedBox: true, // 固定截图框大小 不允许改变
+ outputType:"png" // 默认生成截图为PNG格式
},
previews: {},
resizeHandler: null
@@ -138,7 +135,7 @@
formData.append("avatarfile", data);
uploadAvatar(formData).then(response => {
this.open = false;
- this.options.img = response.imgUrl;
+ this.options.img = process.env.VUE_APP_BASE_API + response.imgUrl;
store.commit('SET_AVATAR', this.options.img);
this.$modal.msgSuccess("修改成功");
this.visible = false;
--
Gitblit v1.9.3