mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-09-23 05:46:40 +08:00
commit
835076c301
29
.gitignore
vendored
29
.gitignore
vendored
@ -1,6 +1,31 @@
|
|||||||
|
HELP.md
|
||||||
|
target/
|
||||||
|
!.mvn/wrapper/maven-wrapper.jar
|
||||||
|
!**/src/main/**
|
||||||
|
!**/src/test/**
|
||||||
|
|
||||||
|
### STS ###
|
||||||
|
.apt_generated
|
||||||
|
.classpath
|
||||||
|
.factorypath
|
||||||
|
.project
|
||||||
|
.settings
|
||||||
|
.springBeans
|
||||||
|
.sts4-cache
|
||||||
|
|
||||||
|
### IntelliJ IDEA ###
|
||||||
|
.idea
|
||||||
|
*.iws
|
||||||
*.iml
|
*.iml
|
||||||
|
*.ipr
|
||||||
|
|
||||||
**/target/
|
### NetBeans ###
|
||||||
|
/nbproject/private/
|
||||||
|
/nbbuild/
|
||||||
|
/dist/
|
||||||
|
/nbdist/
|
||||||
|
/.nb-gradle/
|
||||||
|
build/
|
||||||
|
|
||||||
**/node_modules/
|
### VS Code ###
|
||||||
|
.vscode/
|
||||||
|
@ -85,6 +85,10 @@ public class ResponseDTO<T> {
|
|||||||
return new ResponseDTO<T>(codeConst, msg);
|
return new ResponseDTO<T>(codeConst, msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static <T> ResponseDTO<T> wrapMsg(ResponseCodeConst codeConst, String msg) {
|
||||||
|
return new ResponseDTO<T>(codeConst, msg);
|
||||||
|
}
|
||||||
|
|
||||||
public String getMsg() {
|
public String getMsg() {
|
||||||
return msg;
|
return msg;
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,8 @@ import net.lab1024.smartadmin.common.domain.BaseEnum;
|
|||||||
import javax.validation.ConstraintValidator;
|
import javax.validation.ConstraintValidator;
|
||||||
import javax.validation.ConstraintValidatorContext;
|
import javax.validation.ConstraintValidatorContext;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 枚举类校验器
|
* 枚举类校验器
|
||||||
@ -15,9 +17,9 @@ import java.util.List;
|
|||||||
public class EnumValidator implements ConstraintValidator<CheckEnum, Object> {
|
public class EnumValidator implements ConstraintValidator<CheckEnum, Object> {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 枚举类的类对象
|
* 枚举类实例集合
|
||||||
*/
|
*/
|
||||||
private Class<? extends BaseEnum> enumClass;
|
private List<Object> enumValList;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 是否必须
|
* 是否必须
|
||||||
@ -27,8 +29,9 @@ public class EnumValidator implements ConstraintValidator<CheckEnum, Object> {
|
|||||||
@Override
|
@Override
|
||||||
public void initialize(CheckEnum constraintAnnotation) {
|
public void initialize(CheckEnum constraintAnnotation) {
|
||||||
// 获取注解传入的枚举类对象
|
// 获取注解传入的枚举类对象
|
||||||
enumClass = constraintAnnotation.enumClazz();
|
|
||||||
required = constraintAnnotation.required();
|
required = constraintAnnotation.required();
|
||||||
|
Class<? extends BaseEnum> enumClass = constraintAnnotation.enumClazz();
|
||||||
|
enumValList = Stream.of(enumClass.getEnumConstants()).map(BaseEnum::getValue).collect(Collectors.toList());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -44,7 +47,7 @@ public class EnumValidator implements ConstraintValidator<CheckEnum, Object> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 校验是否为合法的枚举值
|
// 校验是否为合法的枚举值
|
||||||
return this.hasEnum(value);
|
return enumValList.contains(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -58,23 +61,11 @@ public class EnumValidator implements ConstraintValidator<CheckEnum, Object> {
|
|||||||
// 必须的情况下 list 不能为空
|
// 必须的情况下 list 不能为空
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
for (Object obj : list) {
|
// 校验是否重复
|
||||||
boolean hasEnum = this.hasEnum(obj);
|
long count = list.stream().distinct().count();
|
||||||
if (!hasEnum) {
|
if (count != list.size()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
return enumValList.containsAll(list);
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean hasEnum(Object value) {
|
|
||||||
// 校验是否为合法的枚举值
|
|
||||||
BaseEnum[] enums = enumClass.getEnumConstants();
|
|
||||||
for (BaseEnum baseEnum : enums) {
|
|
||||||
if (baseEnum.getValue().equals(value)) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
package net.lab1024.smartadmin.config;
|
package net.lab1024.smartadmin.config;
|
||||||
|
|
||||||
import com.github.xiaoymin.knife4j.spring.annotations.EnableKnife4j;
|
import com.github.xiaoymin.knife4j.spring.annotations.EnableKnife4j;
|
||||||
import net.lab1024.smartadmin.constant.SwaggerTagConst;
|
|
||||||
import com.google.common.base.Optional;
|
import com.google.common.base.Optional;
|
||||||
import com.google.common.base.Predicate;
|
import com.google.common.base.Predicate;
|
||||||
import com.google.common.base.Predicates;
|
import com.google.common.base.Predicates;
|
||||||
@ -9,6 +8,8 @@ import com.google.common.collect.Lists;
|
|||||||
import com.google.common.collect.Maps;
|
import com.google.common.collect.Maps;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import net.lab1024.smartadmin.constant.SwaggerTagConst;
|
||||||
|
import net.lab1024.smartadmin.interceptor.SmartAuthenticationInterceptor;
|
||||||
import org.springframework.beans.BeansException;
|
import org.springframework.beans.BeansException;
|
||||||
import org.springframework.beans.factory.config.BeanDefinition;
|
import org.springframework.beans.factory.config.BeanDefinition;
|
||||||
import org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
|
import org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
|
||||||
@ -23,8 +24,10 @@ import org.springframework.web.bind.annotation.ResponseBody;
|
|||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
import springfox.documentation.RequestHandler;
|
import springfox.documentation.RequestHandler;
|
||||||
import springfox.documentation.builders.ApiInfoBuilder;
|
import springfox.documentation.builders.ApiInfoBuilder;
|
||||||
|
import springfox.documentation.builders.ParameterBuilder;
|
||||||
import springfox.documentation.builders.PathSelectors;
|
import springfox.documentation.builders.PathSelectors;
|
||||||
import springfox.documentation.builders.RequestHandlerSelectors;
|
import springfox.documentation.builders.RequestHandlerSelectors;
|
||||||
|
import springfox.documentation.schema.ModelRef;
|
||||||
import springfox.documentation.service.*;
|
import springfox.documentation.service.*;
|
||||||
import springfox.documentation.spi.DocumentationType;
|
import springfox.documentation.spi.DocumentationType;
|
||||||
import springfox.documentation.spi.service.contexts.SecurityContext;
|
import springfox.documentation.spi.service.contexts.SecurityContext;
|
||||||
@ -89,9 +92,9 @@ public class SmartSwaggerDynamicGroupConfig implements EnvironmentAware, BeanDef
|
|||||||
|
|
||||||
private String groupName = "default";
|
private String groupName = "default";
|
||||||
|
|
||||||
private List<String> groupList = Lists.newArrayList();
|
private final List<String> groupList = Lists.newArrayList();
|
||||||
|
|
||||||
private Map<String, List<String>> groupMap = Maps.newHashMap();
|
private final Map<String, List<String>> groupMap = Maps.newHashMap();
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setEnvironment(Environment environment) {
|
public void setEnvironment(Environment environment) {
|
||||||
@ -137,6 +140,16 @@ public class SmartSwaggerDynamicGroupConfig implements EnvironmentAware, BeanDef
|
|||||||
}
|
}
|
||||||
|
|
||||||
private Docket baseDocket() {
|
private Docket baseDocket() {
|
||||||
|
// 配置全局参数 token
|
||||||
|
ParameterBuilder tokenPar = new ParameterBuilder();
|
||||||
|
Parameter parameter = tokenPar.name(SmartAuthenticationInterceptor.TOKEN_NAME)
|
||||||
|
.description("token")
|
||||||
|
.modelRef(new ModelRef("string"))
|
||||||
|
.parameterType("header")
|
||||||
|
.defaultValue("")
|
||||||
|
.required(false)
|
||||||
|
.build();
|
||||||
|
|
||||||
// 请求类型过滤规则
|
// 请求类型过滤规则
|
||||||
Predicate<RequestHandler> controllerPredicate = getControllerPredicate();
|
Predicate<RequestHandler> controllerPredicate = getControllerPredicate();
|
||||||
// controller 包路径
|
// controller 包路径
|
||||||
@ -151,7 +164,8 @@ public class SmartSwaggerDynamicGroupConfig implements EnvironmentAware, BeanDef
|
|||||||
.build()
|
.build()
|
||||||
.apiInfo(this.serviceApiInfo())
|
.apiInfo(this.serviceApiInfo())
|
||||||
.securitySchemes(securitySchemes())
|
.securitySchemes(securitySchemes())
|
||||||
.securityContexts(securityContexts());
|
.securityContexts(securityContexts())
|
||||||
|
.globalOperationParameters(Lists.newArrayList(parameter));
|
||||||
}
|
}
|
||||||
|
|
||||||
private List<ApiKey> securitySchemes() {
|
private List<ApiKey> securitySchemes() {
|
||||||
@ -219,6 +233,4 @@ public class SmartSwaggerDynamicGroupConfig implements EnvironmentAware, BeanDef
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -36,7 +36,7 @@ import java.util.List;
|
|||||||
@Component
|
@Component
|
||||||
public class SmartAuthenticationInterceptor extends HandlerInterceptorAdapter {
|
public class SmartAuthenticationInterceptor extends HandlerInterceptorAdapter {
|
||||||
|
|
||||||
private static final String TOKEN_NAME = "x-access-token";
|
public static final String TOKEN_NAME = "x-access-token";
|
||||||
|
|
||||||
@Value("${access-control-allow-origin}")
|
@Value("${access-control-allow-origin}")
|
||||||
private String accessControlAllowOrigin;
|
private String accessControlAllowOrigin;
|
||||||
|
@ -59,15 +59,15 @@ public class DepartmentController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "删除部门", notes = "删除部门")
|
@ApiOperation(value = "删除部门", notes = "删除部门")
|
||||||
@PostMapping("/department/delete/{departmentId}")
|
@PostMapping("/department/delete/{deptId}")
|
||||||
public ResponseDTO<String> delDepartment(@PathVariable("departmentId") Long departmentId) {
|
public ResponseDTO<String> delDepartment(@PathVariable Long deptId) {
|
||||||
return departmentService.delDepartment(departmentId);
|
return departmentService.delDepartment(deptId);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "获取部门信息", notes = "获取部门")
|
@ApiOperation(value = "获取部门信息", notes = "获取部门")
|
||||||
@GetMapping("/department/query/{departmentId}")
|
@GetMapping("/department/query/{deptId}")
|
||||||
public ResponseDTO<DepartmentVO> getDepartment(@PathVariable("departmentId") Long departmentId) {
|
public ResponseDTO<DepartmentVO> getDepartment(@PathVariable Long deptId) {
|
||||||
return departmentService.getDepartmentById(departmentId);
|
return departmentService.getDepartmentById(deptId);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "查询部门列表", notes = "查询部门列表")
|
@ApiOperation(value = "查询部门列表", notes = "查询部门列表")
|
||||||
@ -78,21 +78,21 @@ public class DepartmentController {
|
|||||||
|
|
||||||
|
|
||||||
@ApiOperation(value = "上下移动")
|
@ApiOperation(value = "上下移动")
|
||||||
@GetMapping("/department/upOrDown/{departmentId}/{swapId}")
|
@GetMapping("/department/upOrDown/{deptId}/{swapId}")
|
||||||
public ResponseDTO<String> upOrDown(@PathVariable("departmentId") Long departmentId,@PathVariable("swapId") Long swapId) {
|
public ResponseDTO<String> upOrDown(@PathVariable Long deptId, @PathVariable Long swapId) {
|
||||||
return departmentService.upOrDown(departmentId,swapId);
|
return departmentService.upOrDown(deptId, swapId);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "升级")
|
@ApiOperation(value = "升级")
|
||||||
@GetMapping("/department/upgrade/{departmentId}")
|
@GetMapping("/department/upgrade/{deptId}")
|
||||||
public ResponseDTO<String> upgrade(@PathVariable("departmentId") Long departmentId) {
|
public ResponseDTO<String> upgrade(@PathVariable Long deptId) {
|
||||||
return departmentService.upgrade(departmentId);
|
return departmentService.upgrade(deptId);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "降级")
|
@ApiOperation(value = "降级")
|
||||||
@GetMapping("/department/downgrade/{departmentId}/{preId}")
|
@GetMapping("/department/downgrade/{deptId}/{preId}")
|
||||||
public ResponseDTO<String> downgrade(@PathVariable("departmentId") Long departmentId,@PathVariable("preId") Long preId) {
|
public ResponseDTO<String> downgrade(@PathVariable Long deptId, @PathVariable Long preId) {
|
||||||
return departmentService.downgrade(departmentId,preId);
|
return departmentService.downgrade(deptId, preId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -19,14 +19,13 @@ import java.util.List;
|
|||||||
@Mapper
|
@Mapper
|
||||||
public interface DepartmentDao extends BaseMapper<DepartmentEntity> {
|
public interface DepartmentDao extends BaseMapper<DepartmentEntity> {
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据部门id,查询此部门子部门的数量
|
* 根据部门id,查询此部门直接子部门的数量
|
||||||
*
|
*
|
||||||
* @param departmentId
|
* @param deptId
|
||||||
* @return int 子部门的数量
|
* @return int 子部门的数量
|
||||||
*/
|
*/
|
||||||
Integer countSubDepartment(@Param("departmentId") Long departmentId);
|
Integer countSubDepartment(@Param("deptId") Long deptId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取全部部门列表
|
* 获取全部部门列表
|
||||||
|
@ -14,7 +14,7 @@ public class DepartmentResponseCodeConst extends ResponseCodeConst {
|
|||||||
/**
|
/**
|
||||||
* 部门不存在 1001
|
* 部门不存在 1001
|
||||||
*/
|
*/
|
||||||
public static final DepartmentResponseCodeConst DEPT_NOT_EXISTS = new DepartmentResponseCodeConst(2001, "部门不存在!");
|
public static final DepartmentResponseCodeConst DEPT_NOT_EXISTS = new DepartmentResponseCodeConst(2001, "部门不存在");
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 当前部门有子级部门 不能删除 10003
|
* 当前部门有子级部门 不能删除 10003
|
||||||
|
@ -165,23 +165,27 @@ public class DepartmentService {
|
|||||||
* 1、需要判断当前部门是否有子部门,有子部门则不允许删除
|
* 1、需要判断当前部门是否有子部门,有子部门则不允许删除
|
||||||
* 2、需要判断当前部门是否有员工,有员工则不能删除
|
* 2、需要判断当前部门是否有员工,有员工则不能删除
|
||||||
*
|
*
|
||||||
* @param departmentId
|
* @param deptId
|
||||||
* @return AjaxResult<String>
|
* @return
|
||||||
*/
|
*/
|
||||||
@Transactional(rollbackFor = Exception.class)
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public ResponseDTO<String> delDepartment(Long departmentId) {
|
public ResponseDTO<String> delDepartment(Long deptId) {
|
||||||
|
DepartmentEntity departmentEntity = departmentDao.selectById(deptId);
|
||||||
|
if (null == departmentEntity) {
|
||||||
|
return ResponseDTO.wrap(DepartmentResponseCodeConst.DEPT_NOT_EXISTS);
|
||||||
|
}
|
||||||
// 是否有子级部门
|
// 是否有子级部门
|
||||||
int subDepartmentNum = departmentDao.countSubDepartment(departmentId);
|
int subDepartmentNum = departmentDao.countSubDepartment(deptId);
|
||||||
if (subDepartmentNum > 0) {
|
if (subDepartmentNum > 0) {
|
||||||
return ResponseDTO.wrap(DepartmentResponseCodeConst.CANNOT_DEL_DEPARTMENT_WITH_CHILD);
|
return ResponseDTO.wrap(DepartmentResponseCodeConst.CANNOT_DEL_DEPARTMENT_WITH_CHILD);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 是否有员工
|
// 是否有未删除员工
|
||||||
int employeeNum = employeeDao.countByDepartmentId(departmentId);
|
int employeeNum = employeeDao.countByDepartmentId(deptId, false);
|
||||||
if (employeeNum > 0) {
|
if (employeeNum > 0) {
|
||||||
return ResponseDTO.wrap(DepartmentResponseCodeConst.CANNOT_DEL_DEPARTMENT_WITH_EMPLOYEE);
|
return ResponseDTO.wrap(DepartmentResponseCodeConst.CANNOT_DEL_DEPARTMENT_WITH_EMPLOYEE);
|
||||||
}
|
}
|
||||||
departmentDao.deleteById(departmentId);
|
departmentDao.deleteById(deptId);
|
||||||
return ResponseDTO.succ();
|
return ResponseDTO.succ();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -278,5 +282,4 @@ public class DepartmentService {
|
|||||||
departmentDao.updateById(departmentEntity);
|
departmentDao.updateById(departmentEntity);
|
||||||
return ResponseDTO.succ();
|
return ResponseDTO.succ();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -34,6 +34,7 @@ public interface EmployeeDao extends BaseMapper<EmployeeEntity> {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 不带分页查询员工列表
|
* 不带分页查询员工列表
|
||||||
|
*
|
||||||
* @param queryDTO
|
* @param queryDTO
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@ -84,10 +85,11 @@ public interface EmployeeDao extends BaseMapper<EmployeeEntity> {
|
|||||||
/**
|
/**
|
||||||
* 获取某个部门员工数
|
* 获取某个部门员工数
|
||||||
*
|
*
|
||||||
* @param departmentId
|
* @param depId
|
||||||
|
* @param deleteFlag 可以null
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
Integer countByDepartmentId(@Param("departmentId") Long departmentId);
|
Integer countByDepartmentId(@Param("depId") Long depId, @Param("deleteFlag") Boolean deleteFlag);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取一批员工
|
* 获取一批员工
|
||||||
@ -99,6 +101,7 @@ public interface EmployeeDao extends BaseMapper<EmployeeEntity> {
|
|||||||
|
|
||||||
|
|
||||||
EmployeeDTO getEmployeeById(@Param("id") Long employeeId);
|
EmployeeDTO getEmployeeById(@Param("id") Long employeeId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取某个部门的员工
|
* 获取某个部门的员工
|
||||||
*
|
*
|
||||||
@ -128,6 +131,7 @@ public interface EmployeeDao extends BaseMapper<EmployeeEntity> {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询所有员工
|
* 查询所有员工
|
||||||
|
*
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
List<EmployeeVO> selectAll();
|
List<EmployeeVO> selectAll();
|
||||||
|
@ -42,7 +42,6 @@ public class LoginController {
|
|||||||
return loginService.login(loginForm, request);
|
return loginService.login(loginForm, request);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@GetMapping("/session/get")
|
@GetMapping("/session/get")
|
||||||
@ApiOperation(value = "获取session", notes = "获取session")
|
@ApiOperation(value = "获取session", notes = "获取session")
|
||||||
@NoValidPrivilege
|
@NoValidPrivilege
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
package net.lab1024.smartadmin.util;
|
package net.lab1024.smartadmin.util;
|
||||||
|
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
import java.math.RoundingMode;
|
import java.math.RoundingMode;
|
||||||
import java.text.NumberFormat;
|
import java.text.NumberFormat;
|
||||||
@ -34,12 +35,15 @@ public class SmartBigDecimalUtil {
|
|||||||
public static BigDecimal add(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal add(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.add(num2), PRICE_DECIMAL_POINT);
|
return setScale(num1.add(num2), PRICE_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal multiply(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal multiply(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.multiply(num2), PRICE_DECIMAL_POINT);
|
return setScale(num1.multiply(num2), PRICE_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal subtract(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal subtract(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.subtract(num2), PRICE_DECIMAL_POINT);
|
return setScale(num1.subtract(num2), PRICE_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal divide(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal divide(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.divide(num2, RoundingMode.HALF_UP), PRICE_DECIMAL_POINT);
|
return setScale(num1.divide(num2, RoundingMode.HALF_UP), PRICE_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
@ -53,12 +57,15 @@ public class SmartBigDecimalUtil {
|
|||||||
public static BigDecimal add(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal add(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.add(num2), SIX_PRICE_DECIMAL_POINT);
|
return setScale(num1.add(num2), SIX_PRICE_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal multiply(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal multiply(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.multiply(num2), SIX_PRICE_DECIMAL_POINT);
|
return setScale(num1.multiply(num2), SIX_PRICE_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal subtract(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal subtract(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.subtract(num2), SIX_PRICE_DECIMAL_POINT);
|
return setScale(num1.subtract(num2), SIX_PRICE_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal divide(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal divide(BigDecimal num1, BigDecimal num2) {
|
||||||
return num1.divide(num2, PRICE_DECIMAL_POINT, RoundingMode.HALF_UP);
|
return num1.divide(num2, PRICE_DECIMAL_POINT, RoundingMode.HALF_UP);
|
||||||
}
|
}
|
||||||
@ -72,12 +79,15 @@ public class SmartBigDecimalUtil {
|
|||||||
public static BigDecimal add(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal add(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.add(num2), WEIGHT_DECIMAL_POINT);
|
return setScale(num1.add(num2), WEIGHT_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal multiply(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal multiply(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.multiply(num2), WEIGHT_DECIMAL_POINT);
|
return setScale(num1.multiply(num2), WEIGHT_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal subtract(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal subtract(BigDecimal num1, BigDecimal num2) {
|
||||||
return setScale(num1.subtract(num2), WEIGHT_DECIMAL_POINT);
|
return setScale(num1.subtract(num2), WEIGHT_DECIMAL_POINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static BigDecimal divide(BigDecimal num1, BigDecimal num2) {
|
public static BigDecimal divide(BigDecimal num1, BigDecimal num2) {
|
||||||
return num1.divide(num2, WEIGHT_DECIMAL_POINT, RoundingMode.HALF_UP);
|
return num1.divide(num2, WEIGHT_DECIMAL_POINT, RoundingMode.HALF_UP);
|
||||||
}
|
}
|
||||||
@ -227,7 +237,7 @@ public class SmartBigDecimalUtil {
|
|||||||
if (num1 == null || num2 == null) {
|
if (num1 == null || num2 == null) {
|
||||||
return BigDecimal.ZERO;
|
return BigDecimal.ZERO;
|
||||||
}
|
}
|
||||||
if (num2.equals(Integer.valueOf(0))) {
|
if (num2.equals(0)) {
|
||||||
return BigDecimal.ZERO;
|
return BigDecimal.ZERO;
|
||||||
}
|
}
|
||||||
BigDecimal bigDecimalNum1 = new BigDecimal(num1);
|
BigDecimal bigDecimalNum1 = new BigDecimal(num1);
|
||||||
@ -283,8 +293,7 @@ public class SmartBigDecimalUtil {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public static BigDecimal convertTenThousand(BigDecimal num, int point) {
|
public static BigDecimal convertTenThousand(BigDecimal num, int point) {
|
||||||
BigDecimal decimal = num.divide(new BigDecimal(10000), point, RoundingMode.HALF_UP);
|
return num.divide(new BigDecimal(10000), point, RoundingMode.HALF_UP);
|
||||||
return decimal;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -300,4 +309,25 @@ public class SmartBigDecimalUtil {
|
|||||||
return BigDecimal.ZERO.subtract(num);
|
return BigDecimal.ZERO.subtract(num);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 比较 num1,num2 返回最大的值
|
||||||
|
*
|
||||||
|
* @param num1
|
||||||
|
* @param num2
|
||||||
|
* @return BigDecimal
|
||||||
|
*/
|
||||||
|
public static BigDecimal max(BigDecimal num1, BigDecimal num2) {
|
||||||
|
return num1.compareTo(num2) > 0 ? num1 : num2;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 比较 num1,num2 返回最小的值
|
||||||
|
*
|
||||||
|
* @param num1
|
||||||
|
* @param num2
|
||||||
|
* @return BigDecimal
|
||||||
|
*/
|
||||||
|
public static BigDecimal min(BigDecimal num1, BigDecimal num2) {
|
||||||
|
return num1.compareTo(num2) < 0 ? num1 : num2;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -18,15 +18,6 @@
|
|||||||
d.create_time
|
d.create_time
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="countSubDepartment" resultType="integer">
|
|
||||||
SELECT
|
|
||||||
count(1)
|
|
||||||
FROM
|
|
||||||
t_department
|
|
||||||
WHERE
|
|
||||||
parent_id = #{departmentId}
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="listAll" resultMap="DepartmentVO">
|
<select id="listAll" resultMap="DepartmentVO">
|
||||||
SELECT
|
SELECT
|
||||||
<include refid="baseSql"></include>,
|
<include refid="baseSql"></include>,
|
||||||
@ -50,5 +41,14 @@
|
|||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
<select id="countSubDepartment" resultType="java.lang.Integer">
|
||||||
|
SELECT
|
||||||
|
count(1)
|
||||||
|
FROM
|
||||||
|
t_department
|
||||||
|
WHERE
|
||||||
|
parent_id = #{deptId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
@ -124,7 +124,10 @@
|
|||||||
FROM
|
FROM
|
||||||
t_employee e
|
t_employee e
|
||||||
WHERE
|
WHERE
|
||||||
e.department_id = #{departmentId}
|
e.department_id = #{depId}
|
||||||
|
<if test="deleteFlag != null">
|
||||||
|
AND e.is_delete = #{deleteFlag}
|
||||||
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
@ -30,7 +30,7 @@ CREATE TABLE IF NOT EXISTS `t_department` (
|
|||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||||
PRIMARY KEY (`id`),
|
PRIMARY KEY (`id`),
|
||||||
KEY `parent_id` (`parent_id`)
|
KEY `parent_id` (`parent_id`)
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=26 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='部门表';
|
) ENGINE=InnoDB AUTO_INCREMENT=26 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='部门表';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_department 的数据:~4 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_department 的数据:~4 rows (大约)
|
||||||
DELETE FROM `t_department`;
|
DELETE FROM `t_department`;
|
||||||
@ -154,7 +154,7 @@ CREATE TABLE IF NOT EXISTS `t_employee` (
|
|||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||||
`is_delete` int NOT NULL DEFAULT '0' COMMENT '是否删除0否 1是',
|
`is_delete` int NOT NULL DEFAULT '0' COMMENT '是否删除0否 1是',
|
||||||
PRIMARY KEY (`id`)
|
PRIMARY KEY (`id`)
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=40 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='员工表';
|
) ENGINE=InnoDB AUTO_INCREMENT=40 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='员工表';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_employee 的数据:~28 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_employee 的数据:~28 rows (大约)
|
||||||
DELETE FROM `t_employee`;
|
DELETE FROM `t_employee`;
|
||||||
@ -207,7 +207,7 @@ CREATE TABLE IF NOT EXISTS `t_file` (
|
|||||||
PRIMARY KEY (`id`) USING BTREE,
|
PRIMARY KEY (`id`) USING BTREE,
|
||||||
KEY `module_id_module_type` (`module_id`,`module_type`) USING BTREE,
|
KEY `module_id_module_type` (`module_id`,`module_type`) USING BTREE,
|
||||||
KEY `module_type` (`module_type`) USING BTREE
|
KEY `module_type` (`module_type`) USING BTREE
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=26 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC;
|
) ENGINE=InnoDB AUTO_INCREMENT=26 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC;
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_file 的数据:~23 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_file 的数据:~23 rows (大约)
|
||||||
DELETE FROM `t_file`;
|
DELETE FROM `t_file`;
|
||||||
@ -248,7 +248,7 @@ CREATE TABLE IF NOT EXISTS `t_heart_beat_record` (
|
|||||||
`process_start_time` datetime DEFAULT NULL COMMENT '进程开启时间',
|
`process_start_time` datetime DEFAULT NULL COMMENT '进程开启时间',
|
||||||
`heart_beat_time` datetime DEFAULT NULL COMMENT '心跳时间',
|
`heart_beat_time` datetime DEFAULT NULL COMMENT '心跳时间',
|
||||||
PRIMARY KEY (`id`) USING BTREE
|
PRIMARY KEY (`id`) USING BTREE
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC;
|
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC;
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_heart_beat_record 的数据:~2 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_heart_beat_record 的数据:~2 rows (大约)
|
||||||
DELETE FROM `t_heart_beat_record`;
|
DELETE FROM `t_heart_beat_record`;
|
||||||
@ -274,7 +274,7 @@ CREATE TABLE IF NOT EXISTS `t_id_generator` (
|
|||||||
`update_time` datetime DEFAULT NULL,
|
`update_time` datetime DEFAULT NULL,
|
||||||
`create_time` datetime NOT NULL,
|
`create_time` datetime NOT NULL,
|
||||||
UNIQUE KEY `key_name` (`key_name`) USING BTREE
|
UNIQUE KEY `key_name` (`key_name`) USING BTREE
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC COMMENT='id生成器定义表';
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='id生成器定义表';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_id_generator 的数据:~2 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_id_generator 的数据:~2 rows (大约)
|
||||||
DELETE FROM `t_id_generator`;
|
DELETE FROM `t_id_generator`;
|
||||||
@ -293,7 +293,7 @@ CREATE TABLE IF NOT EXISTS `t_id_generator_record` (
|
|||||||
`day` int NOT NULL,
|
`day` int NOT NULL,
|
||||||
`last_number` int NOT NULL,
|
`last_number` int NOT NULL,
|
||||||
PRIMARY KEY (`generator_id`,`year`,`month`,`day`) USING BTREE
|
PRIMARY KEY (`generator_id`,`year`,`month`,`day`) USING BTREE
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC COMMENT='id_generator记录表';
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='id_generator记录表';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_id_generator_record 的数据:~5 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_id_generator_record 的数据:~5 rows (大约)
|
||||||
DELETE FROM `t_id_generator_record`;
|
DELETE FROM `t_id_generator_record`;
|
||||||
@ -400,7 +400,7 @@ CREATE TABLE IF NOT EXISTS `t_order_operate_log` (
|
|||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||||
PRIMARY KEY (`id`) USING BTREE,
|
PRIMARY KEY (`id`) USING BTREE,
|
||||||
KEY `order_id_order_type` (`order_id`,`order_type`) USING BTREE
|
KEY `order_id_order_type` (`order_id`,`order_type`) USING BTREE
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC COMMENT='各种单据操作记录\r\n';
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='各种单据操作记录\r\n';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_order_operate_log 的数据:~0 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_order_operate_log 的数据:~0 rows (大约)
|
||||||
DELETE FROM `t_order_operate_log`;
|
DELETE FROM `t_order_operate_log`;
|
||||||
@ -720,7 +720,7 @@ CREATE TABLE IF NOT EXISTS `t_reload_item` (
|
|||||||
`update_time` datetime DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP,
|
`update_time` datetime DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP,
|
||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
PRIMARY KEY (`tag`)
|
PRIMARY KEY (`tag`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_reload_item 的数据:~0 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_reload_item 的数据:~0 rows (大约)
|
||||||
DELETE FROM `t_reload_item`;
|
DELETE FROM `t_reload_item`;
|
||||||
@ -738,7 +738,7 @@ CREATE TABLE IF NOT EXISTS `t_reload_result` (
|
|||||||
`result` tinyint unsigned NOT NULL COMMENT '是否成功 ',
|
`result` tinyint unsigned NOT NULL COMMENT '是否成功 ',
|
||||||
`exception` text,
|
`exception` text,
|
||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_reload_result 的数据:~127 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_reload_result 的数据:~127 rows (大约)
|
||||||
DELETE FROM `t_reload_result`;
|
DELETE FROM `t_reload_result`;
|
||||||
@ -938,7 +938,7 @@ CREATE TABLE IF NOT EXISTS `t_role_employee` (
|
|||||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
|
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
|
||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||||
PRIMARY KEY (`id`)
|
PRIMARY KEY (`id`)
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=214 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='角色员工功能表';
|
) ENGINE=InnoDB AUTO_INCREMENT=214 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='角色员工功能表';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_role_employee 的数据:~25 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_role_employee 的数据:~25 rows (大约)
|
||||||
DELETE FROM `t_role_employee`;
|
DELETE FROM `t_role_employee`;
|
||||||
@ -980,7 +980,7 @@ CREATE TABLE IF NOT EXISTS `t_role_privilege` (
|
|||||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
|
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
|
||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||||
PRIMARY KEY (`id`)
|
PRIMARY KEY (`id`)
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=10835 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='角色权限功能表';
|
) ENGINE=InnoDB AUTO_INCREMENT=10835 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='角色权限功能表';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_role_privilege 的数据:~322 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_role_privilege 的数据:~322 rows (大约)
|
||||||
DELETE FROM `t_role_privilege`;
|
DELETE FROM `t_role_privilege`;
|
||||||
@ -1322,7 +1322,7 @@ CREATE TABLE IF NOT EXISTS `t_system_config` (
|
|||||||
`update_time` datetime DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '上次修改时间',
|
`update_time` datetime DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '上次修改时间',
|
||||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||||
PRIMARY KEY (`id`)
|
PRIMARY KEY (`id`)
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=20 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC;
|
) ENGINE=InnoDB AUTO_INCREMENT=20 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC;
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_system_config 的数据:~8 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_system_config 的数据:~8 rows (大约)
|
||||||
DELETE FROM `t_system_config`;
|
DELETE FROM `t_system_config`;
|
||||||
@ -1354,7 +1354,7 @@ CREATE TABLE IF NOT EXISTS `t_user_login_log` (
|
|||||||
PRIMARY KEY (`id`),
|
PRIMARY KEY (`id`),
|
||||||
KEY `customer_id` (`user_id`) USING BTREE,
|
KEY `customer_id` (`user_id`) USING BTREE,
|
||||||
KEY `auditor_id` (`remote_browser`) USING BTREE
|
KEY `auditor_id` (`remote_browser`) USING BTREE
|
||||||
) ENGINE=InnoDB AUTO_INCREMENT=1743 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='用户登录日志';
|
) ENGINE=InnoDB AUTO_INCREMENT=1743 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='用户登录日志';
|
||||||
|
|
||||||
-- 正在导出表 smart-admin-dev.t_user_login_log 的数据:~122 rows (大约)
|
-- 正在导出表 smart-admin-dev.t_user_login_log 的数据:~122 rows (大约)
|
||||||
DELETE FROM `t_user_login_log`;
|
DELETE FROM `t_user_login_log`;
|
||||||
|
Loading…
Reference in New Issue
Block a user