Merge branch 'dev-cq' of http://192.168.0.56:3000/bonus/devicesmgt into dev-cq

This commit is contained in:
BianLzhaoMin 2024-06-12 09:05:30 +08:00
commit 6b5eadb963
2 changed files with 19 additions and 3 deletions

View File

@ -45,10 +45,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</select>
<select id="getMaUserList" resultType="com.bonus.sgzb.base.domain.MaintenanceGang">
SELECT su.user_id as userId, su.nick_name as userName FROM `sys_user` su
LEFT JOIN sys_user_role sur ON su.user_id = sur.user_id
SELECT DISTINCT
su.user_id AS userId,
su.nick_name AS userName
FROM
`sys_user` su
LEFT JOIN sys_user_role sur ON su.user_id = sur.user_id
LEFT JOIN sys_role sr ON sr.role_id = sur.role_id
WHERE sr.role_id = '102' AND su.del_flag = '0'
WHERE
sr.role_id in (133,134)
AND su.del_flag = '0'
<if test="userName != null and userName != ''">
AND su.nick_name like concat('%', #{userName}, '%')
</if>

View File

@ -257,6 +257,7 @@
:class="{ disabled: uploadDisabled }"
:on-preview="handlePictureCardPreview"
:on-remove="handleRemove"
:before-upload="beforeUpload"
>
<!-- <img v-if="imageUrl" :src="uploadUrl+imageUrl" style="width: 140px;height: 140px;" class="avatar"> -->
<i class="el-icon-plus avatar-uploader-icon"></i>
@ -300,6 +301,7 @@
:on-preview="handlePictureCardPreview"
:class="{ disabled: uploadDisabled }"
:on-remove="handleRemove"
:before-upload="beforeUpload"
>
<!-- <img v-if="imageUrl" :src="uploadUrl+imageUrl" style="width: 140px;height: 140px;" class="avatar"> -->
<i class="el-icon-plus avatar-uploader-icon"></i>
@ -1020,6 +1022,14 @@ export default {
this.$store.dispatch('dict/cleanDict')
})
},
//
beforeUpload(file) {
const isLt5M = file.size / 1024 / 1024 < 5
if (!isLt5M) {
this.$message.error('上传图片大小不能超过 5MB!')
}
return isLt5M
},
},
}
</script>