TASK:mixi;

This commit is contained in:
shahaibo
2024-04-26 15:38:54 +08:00
parent efa448ec0e
commit 51d73952f4
4 changed files with 12 additions and 6 deletions

View File

@@ -69,7 +69,7 @@ public enum RolePermissionResourceEnum {
/**
* Mi-Tu 报表
*/
REPORT_EXPORTING("Report Exporting","REPORT-EXPORTING",null,null,null,11),
REPORT_EXPORTING("Report Exporting","REPORT_EXPORTING",null,null,null,11),
;
/**

View File

@@ -58,7 +58,7 @@ public class MiTuExportScheduledTask {
// weeklySellThrReport();
// WeeklyHeavyStockReport();
// QuarterlyProductGroupingReport();
customerTypeAnalysis();
// customerTypeAnalysis();
// getBestSell();
}

View File

@@ -10,9 +10,9 @@ import javax.validation.constraints.NotBlank;
@ApiModel("app登入")
public class AppAccountLoginDTO {
@NotBlank(message = "User Phone cannot be empty!")
@ApiModelProperty("用户手机")
private String userPhone;
@NotBlank(message = "User Account cannot be empty!")
@ApiModelProperty("用户")
private String userAccount;
@NotBlank(message = "password cannot be empty!")
@ApiModelProperty("密码")

View File

@@ -224,7 +224,7 @@ public class AccountService extends ServiceImpl<AccountMapper, TAccount>{
}
@Transactional
public AppAccountLoginVO appLogin(AppAccountLoginDTO accountLoginDTO) {
TAccount tAccount = getOneByPhone(accountLoginDTO.getUserPhone());
TAccount tAccount = getOneByAccount(accountLoginDTO.getUserAccount());
Assert.notNull(tAccount,"User not registered!");
Assert.isTrue(accountLoginDTO.getPassword().equals(tAccount.getUserPassword()), "Password error!");
@@ -298,6 +298,12 @@ public class AccountService extends ServiceImpl<AccountMapper, TAccount>{
queryWrapper.eq(TAccount.APP_USER, 1);
return accountMapper.selectOne(queryWrapper);
}
private TAccount getOneByAccount(String account) {
QueryWrapper<TAccount> queryWrapper = new QueryWrapper<>();
queryWrapper.lambda().eq(TAccount::getUserAccount, account);
queryWrapper.lambda().eq(TAccount::getAppUser, 1);
return accountMapper.selectOne(queryWrapper);
}
public Boolean existByRoleId(Long roleId) {
QueryWrapper<TAccount> queryWrapper = new QueryWrapper<>();
queryWrapper.eq(TAccount.ROLE_ID,roleId);