请求波司登获取数据·

master
yechenhao 6 years ago
parent a20201a0b7
commit 1ff096754a

@ -174,7 +174,6 @@ public class PoiStoreStaffService {
//导购
wrapper.eq("type", TYPE_SELLER);
//未删除账号
wrapper.eq("deleted", true);
wrapper.ne("user_id", 0);
wrapper.orderByDesc("id");
//返回店铺对应的导购

@ -242,6 +242,7 @@ public class PrivilageAccountServiceImpl extends ServiceImpl<PrivilageAccountDOM
String account = modifyAccountInput.getAccount();
//查询以前的账号名
PrivilageAccountDO privilageAccountDO = privilageAccountDOMapper.selectById(modifyAccountInput.getAccountId());
PrivilageUserDO oldUser = privilageUserDOMapper.selectById(modifyAccountInput.getUserId());
String oldLogin = privilageAccountDO.getLogin();
//修改了账号
if (!oldLogin.equals(modifyAccountInput.getAccount())) {
@ -255,7 +256,7 @@ public class PrivilageAccountServiceImpl extends ServiceImpl<PrivilageAccountDOM
QueryWrapper<PrivilageUserDO> mobileUserQw = new QueryWrapper<>();
mobileUserQw.eq("mobil", mobil).eq("status", "1");
List<PrivilageUserDO> mobileUsers = privilageUserDOMapper.selectList(mobileUserQw);
if (CollectionUtils.isNotEmpty(mobileUsers)) {
if (CollectionUtils.isNotEmpty(mobileUsers) && !oldUser.getMobil().equals(mobil)) {
return AccountEnum.ACCOUNT_MODIFY_STATUS_MOBILE_EXISTS.getType();
}
@ -290,10 +291,14 @@ public class PrivilageAccountServiceImpl extends ServiceImpl<PrivilageAccountDOM
//店长维护用户店铺关系1.店长。4.导购
if (shopId != null && (privilageRoleDO.getCode().equals(RoleEnum.ROLE_CODE_DZ.getRoleCode()) || privilageRoleDO.getCode().equals(RoleEnum.ROLE_CODE_DG.getRoleCode()))) {
QueryWrapper<PoiStoreStaff> oldStaffQw = new QueryWrapper<>();
oldStaffQw.eq("user_id", userId).eq("status", "1").last("limit 1");
PoiStoreStaff oldStaffs = poiStoreStaffDOMapper.selectOne(oldStaffQw);
QueryWrapper<PoiStoreStaff> staffQw = new QueryWrapper<>();
staffQw.eq("staff_code", account).eq("status", "1");
List<PoiStoreStaff> staffs = poiStoreStaffDOMapper.selectList(staffQw);
if (CollectionUtils.isNotEmpty(staffs)) {
if (CollectionUtils.isNotEmpty(staffs) && !oldStaffs.getStaffCode().equals(account)) {
return AccountEnum.ACCOUNT_MODIFY_STATUS_STAFF_EXISTS.getType();
}
privilageDomainService.saveOneShop(userId, modifyAccountInput.getAccount(), shopId, modifyAccountInput.getType());

Loading…
Cancel
Save