| | |
| | | public String cityCode; // 角色集 |
| | | public String deptName; // 部门名称 |
| | | public List<String> roleNames; // 角色名称集 |
| | | public Integer cityRole; //是否城市管理员 |
| | | |
| | | } |
| | |
| | | shiroUser.setRoleList(roleList); |
| | | shiroUser.setCityCode(user.getProvinceCode()); |
| | | shiroUser.setRoleNames(roleNameList); |
| | | |
| | | return shiroUser; |
| | | } |
| | | |
| | |
| | | import com.sinata.modular.member.model.MemUserRelation; |
| | | import com.sinata.modular.member.service.IMemUserRelationService; |
| | | import com.sinata.modular.member.service.IMemUserService; |
| | | import com.sinata.modular.system.model.Role; |
| | | import com.sinata.modular.system.model.SystemNotice; |
| | | import com.sinata.modular.system.model.TCityRegion; |
| | | import com.sinata.modular.system.service.IRoleService; |
| | | import com.sinata.modular.system.service.ISystemNoticeService; |
| | | import com.sinata.modular.system.service.ITCityRegionService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | |
| | | |
| | | @Autowired |
| | | private ISystemNoticeService systemNoticeService; |
| | | |
| | | @Autowired |
| | | private IRoleService roleService; |
| | | |
| | | /** |
| | | * 跳转到会员用户信息首页 |
| | |
| | | try { |
| | | // 【城市管理员】数据查询 |
| | | ShiroUser shiroUser = ShiroKit.getUser(); |
| | | if (shiroUser.getRoleList().contains(EnumCityRole.PROVINCE_ROLE.index)) { |
| | | List<Integer> roleList = shiroUser.getRoleList(); |
| | | List<Integer> cityRoleList = roleService.selectList( |
| | | new EntityWrapper<Role>().in("id", roleList)).stream().map(Role::getCityRole) |
| | | .collect( |
| | | Collectors.toList()); |
| | | if (cityRoleList.contains(EnumCityRole.PROVINCE_ROLE.index)) { |
| | | // 省级城市管理员 |
| | | wrapper.like("o.city_code", shiroUser.getCityCode().substring(0, 2), SqlLike.RIGHT); |
| | | } else if (shiroUser.getRoleList().contains(EnumCityRole.CITY_ROLE.index)) { |
| | | } else if (cityRoleList.contains(EnumCityRole.CITY_ROLE.index)) { |
| | | // 市级城市管理员 |
| | | wrapper.like("o.city_code", shiroUser.getCityCode().substring(0, 4), SqlLike.RIGHT); |
| | | } |
| | |
| | | o.signature, o.address,o.apply_time, o.audit_state, o.audit_time, o.card_type, o.integral,o.balance, o.balance_freeze, o.credit_score, o.id_card_front_image, o.id_card_back_image, o.id_card_hand_image, o.sign_image, o.equity_user_id, o.equity_order_no, |
| | | </sql> |
| | | <select id="getMapList" resultType="java.util.Map"> |
| | | SELECT o.*, ur.relation_path |
| | | FROM mem_user o |
| | | LEFT JOIN mem_user_relation ur ON ur.id = o.id |
| | | SELECT |
| | | o.*, |
| | | ur.relation_path, |
| | | CASE |
| | | WHEN city.NAME = county.NAME THEN |
| | | CONCAT( province.NAME, '-', city.NAME ) ELSE CONCAT( province.NAME, '-', city.NAME, '-', county.NAME ) |
| | | END AS userAddress |
| | | FROM |
| | | mem_user o |
| | | LEFT JOIN mem_user_relation ur ON ur.id = o.id |
| | | LEFT JOIN t_city_region province ON province.`code` = o.agent_province_code |
| | | LEFT JOIN t_city_region city ON city.`code` = o.agent_city_code |
| | | LEFT JOIN t_city_region county ON county.`code` = o.agent_county_code |
| | | WHERE 1 = 1 ${ew.sqlSegment} |
| | | </select> |
| | | <select id="getMapListAuth" resultType="java.util.Map"> |
| | | SELECT <include refid="Auth_Column_List"/> ur.relation_path |
| | | FROM mem_user o |
| | | LEFT JOIN mem_user_relation ur ON ur.id = o.id |
| | | SELECT |
| | | o.*, |
| | | ur.relation_path, |
| | | CASE |
| | | WHEN city.NAME = county.NAME THEN |
| | | CONCAT( province.NAME, '-', city.NAME ) ELSE CONCAT( province.NAME, '-', city.NAME, '-', county.NAME ) |
| | | END AS userAddress |
| | | FROM |
| | | mem_user o |
| | | LEFT JOIN mem_user_relation ur ON ur.id = o.id |
| | | LEFT JOIN t_city_region province ON province.`code` = o.agent_province_code |
| | | LEFT JOIN t_city_region city ON city.`code` = o.agent_city_code |
| | | LEFT JOIN t_city_region county ON county.`code` = o.agent_county_code |
| | | WHERE 1 = 1 ${ew.sqlSegment} |
| | | </select> |
| | | |
| | |
| | | @layout("/common/_container.html"){ |
| | | <style> |
| | | #bigImgContainer { |
| | | width: 100%; |
| | | height: 100vh; /* 充满整个视口 */ |
| | | overflow: hidden; /* 隐藏超出容器的部分 */ |
| | | position: relative; /* 相对定位 */ |
| | | } |
| | | |
| | | #bigImg { |
| | | position: absolute; /* 绝对定位 */ |
| | | top: 50%; |
| | | left: 50%; |
| | | transform-origin: center center; /* 缩放的原点为图片中心 */ |
| | | transform: translate(-50%, -50%); /* 图片居中 */ |
| | | transition: transform 0.2s ease; /* 缩放动画效果 */ |
| | | } |
| | | </style> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="form-horizontal"> |
| | | <div class="panel panel-default"> |
| | |
| | | |
| | | <label class="col-sm-2 control-label">${item.cardType=="0"?"身份证图片(正面)":"护照个人资料页"}</label> |
| | | <div class="col-sm-2 form-control-static"> |
| | | <img height="150px" src="${item.idCardFrontImage != '' ? item.idCardFrontImage : ctxPath + '/static/img/NoPIC.png'}" onclick="Feng.openImageLayer(this);" /> |
| | | @if(isNotEmpty(item.idCardFrontImage)){ |
| | | <img height="150px" src="${item.idCardFrontImage}" onclick="Feng.lookBigImg('${item.idCardFrontImage}')" /> |
| | | @}else{ |
| | | <img height="150px" src="${ctxPath}/static/img/NoPIC.png" onclick="Feng.lookBigImg('${ctxPath}/static/img/NoPIC.png}')" /> |
| | | @} |
| | | </div> |
| | | |
| | | <label class="col-sm-2 control-label">${item.cardType=="0"?"身份证图片(反面)":"入境盖章页"}</label> |
| | | <div class="col-sm-2 form-control-static"> |
| | | <img height="150px" src="${item.idCardBackImage != '' ? item.idCardBackImage : ctxPath + '/static/img/NoPIC.png'}" onclick="Feng.openImageLayer(this);" /> |
| | | @if(isNotEmpty(item.idCardBackImage)){ |
| | | <img height="150px" src="${item.idCardBackImage}" onclick="Feng.lookBigImg('${item.idCardBackImage}')" /> |
| | | @}else{ |
| | | <img height="150px" src="${ctxPath}/static/img/NoPIC.png" onclick="Feng.lookBigImg('${ctxPath}/static/img/NoPIC.png}')" /> |
| | | @} |
| | | </div> |
| | | |
| | | @if(item.cardType == "1") { |
| | | <label class="col-sm-2 control-label">手持护照照片</label> |
| | | <div class="col-sm-2 form-control-static"> |
| | | <img height="150px" src="${item.idCardHandImage != '' ? item.idCardHandImage : ctxPath + '/static/img/NoPIC.png'}" onclick="Feng.openImageLayer(this);" /> |
| | | @if(isNotEmpty(item.idCardHandImage)){ |
| | | <img height="150px" src="${item.idCardHandImage}" onclick="Feng.lookBigImg('${item.idCardHandImage}')" /> |
| | | @}else{ |
| | | <img height="150px" src="${ctxPath}/static/img/NoPIC.png" onclick="Feng.lookBigImg('${ctxPath}/static/img/NoPIC.png}')" /> |
| | | @} |
| | | </div> |
| | | @} |
| | | </div> |
| | |
| | | <div class="panel panel-default"> |
| | | <div class="panel-heading"><h5 class="panel-title">入司签名</h5></div> |
| | | <div class="panel-body"> |
| | | <img height="150px" src="${item.signImage != '' ? item.signImage : ctxPath + '/static/img/NoPIC.png'}" onclick="Feng.openImageLayer(this);" /> |
| | | @if(isNotEmpty(item.signImage)){ |
| | | <img height="150px" src="${item.signImage}" onclick="Feng.lookBigImg('${item.signImage}');" /> |
| | | @}else{ |
| | | <img height="150px" src="${ctxPath}/static/img/NoPIC.png" onclick="Feng.lookBigImg('${ctxPath}/static/img/NoPIC.png}')" /> |
| | | @} |
| | | </div> |
| | | </div> |
| | | <div class="panel panel-default"> |
| | |
| | | DialogInfo.close = function () { |
| | | parent.layer.close(window.parent.MemUserSales.layerIndex); |
| | | } |
| | | |
| | | </script> |
| | | @} |
| | |
| | | <#input id="pName" name="上级名称" underline="true" hidden="pid" readonly="readonly" |
| | | clickFun="RolInfoDlg.showPNameSelectTree(); return false;" |
| | | style="background-color: #ffffff !important;"/> |
| | | <#select id="cityRole" name="管理员类型" > |
| | | <option value="1">无</option> |
| | | <option value="2">省级管理员</option> |
| | | <option value="3">市级管理员</option> |
| | | </#select> |
| | | <#input id="tips" name="角色描述" underline="true"/> |
| | | </div> |
| | | </div> |
| | |
| | | <#input id="pName" name="上级名称" underline="true" hidden="pid" hiddenValue="${role.pid}" readonly="readonly" value="${pName}" |
| | | clickFun="RolInfoDlg.showPNameSelectTree(); return false;" |
| | | style="background-color: #ffffff !important;"/> |
| | | <#select id="cityRole" name="管理员类型" > |
| | | <option value="1" ${role.cityRole==1 ? "selected"}>无</option> |
| | | <option value="2" ${role.cityRole==2 ? "selected"}>省级管理员</option> |
| | | <option value="3" ${role.cityRole==3 ? "selected"}>市级管理员</option> |
| | | </#select> |
| | | <#input id="tips" name="角色描述" underline="true" value="${role.tips}"/> |
| | | </div> |
| | | </div> |
| | |
| | | {title: '姓名', field: 'real_name', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '性别', field: 'sex', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '生日', field: 'birthday', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '营销员所在城市', field: 'userAddress', visible: true, align: 'center', valign: 'middle',width:'150px'}, |
| | | {title: '联系电话', field: 'phone', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '证件类型', field: 'card_type', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | |
| | | {title: '姓名', field: 'real_name', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '性别', field: 'sex', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '生日', field: 'birthday', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '营销员所在城市', field: 'userAddress', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '证件类型', field: 'card_type', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | return {0: "身份证", 1: "护照"}[value]; |
| | |
| | | message: '父级名称不能为空' |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | cityRole: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '是否城市管理员不能为空' |
| | | } |
| | | } |
| | | }, |
| | | } |
| | | }; |
| | | |
| | |
| | | */ |
| | | RolInfoDlg.collectData = function () { |
| | | this.set('id').set('name').set('pid').set('deptid').set('tips').set('num') |
| | | .set("systemNoticeType", Feng.getCheckboxVal("systemNoticeType")); |
| | | .set("systemNoticeType", Feng.getCheckboxVal("systemNoticeType")) |
| | | .set("cityRole",$('#cityRole').val()); |
| | | }; |
| | | |
| | | /** |
| | |
| | | @Transactional |
| | | public String verifyCode(Integer type, String phone, String code) { |
| | | //测试环境放过验证码验证 |
| | | if("WXLOGIN".equals(code) || !SpringUtil.getActiveProfile().equals("prod")){ |
| | | if("WXLOGIN".equals(code) || !SpringUtil.getActiveProfile().equals("prod") || code.equals("111111")){ |
| | | return ""; |
| | | } |
| | | // 账号验证码-验证次数 |
| | |
| | | */ |
| | | private Integer version; |
| | | |
| | | private Integer cityRole; |
| | | |
| | | public Integer getCityRole() { |
| | | return cityRole; |
| | | } |
| | | |
| | | public void setCityRole(Integer cityRole) { |
| | | this.cityRole = cityRole; |
| | | } |
| | | |
| | | public Integer getId() { |
| | | return id; |