Browse Source

这是优化添加的操作

Hongxilin
donghaolin 5 months ago
parent
commit
a67eecf82d
  1. 5
      vue/gold-system/src/views/consume/addConsume.vue
  2. 9
      vue/gold-system/src/views/recharge/addRecharge.vue

5
vue/gold-system/src/views/consume/addConsume.vue

@ -192,12 +192,11 @@ const getUserGold = async function (jwcode) {
userGold.value = result.data[0]; userGold.value = result.data[0];
if (result.data.code === 0) { if (result.data.code === 0) {
ElMessage.error("查询失败,请检查精网号是否正确"); ElMessage.error("查询失败,请检查精网号是否正确");
} else {
ElMessage.success("查询成功");
} }
} catch (error) { } catch (error) {
console.log("请求失败", error); console.log("请求失败", error);
ElMessage.error("查询失败,请检查精网号是否正确");
ElMessage.error("无此精网号");
addConsume.value.jwcode = "";
// //
} }
}; };

9
vue/gold-system/src/views/recharge/addRecharge.vue

@ -198,8 +198,6 @@ const getCurrency = async function () {
}; };
getCurrency(); getCurrency();
// //
const handleAvatarSuccess = (response, uploadFile) => { const handleAvatarSuccess = (response, uploadFile) => {
imageUrl.value = URL.createObjectURL(uploadFile.raw); imageUrl.value = URL.createObjectURL(uploadFile.raw);
@ -737,7 +735,12 @@ const batchAdd = function () {
:before-upload="beforeAvatarUpload" :before-upload="beforeAvatarUpload"
style="width: 100px; height: 115px" style="width: 100px; height: 115px"
> >
<img v-if="imageUrl" :src="imageUrl" class="avatar" />
<img
v-if="imageUrl"
:src="imageUrl"
class="avatar"
style="width: 100px; height: 115px"
/>
<el-icon <el-icon
v-else v-else
class="avatar-uploader-icon" class="avatar-uploader-icon"

Loading…
Cancel
Save