parent
aabf4510e0
commit
7e0b7e4b2a
|
|
@ -1,6 +1,7 @@
|
|||
package com.xjs.srb.core.controller;
|
||||
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
import org.springframework.stereotype.Controller;
|
||||
|
|
@ -15,6 +16,7 @@ import org.springframework.stereotype.Controller;
|
|||
*/
|
||||
@Controller
|
||||
@RequestMapping("/core/borrowInfo")
|
||||
@Api(tags = "尚融宝-借款信息管理")
|
||||
public class BorrowInfoController {
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,71 @@
|
|||
package com.xjs.srb.core.controller.admin;
|
||||
|
||||
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.xjs.srb.core.entity.IntegralGrade;
|
||||
import com.xjs.srb.core.service.IIntegralGradeService;
|
||||
import com.xjs.web.MyBaseController;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 积分等级表 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author xiejs
|
||||
* @since 2022-02-28
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/admin/core/integralGrade")
|
||||
@Api(tags = "尚融宝-积分管理")
|
||||
public class IntegralGradeController extends MyBaseController<IntegralGrade> {
|
||||
|
||||
@Autowired
|
||||
private IIntegralGradeService integralGradeService;
|
||||
|
||||
@GetMapping("/list")
|
||||
@ApiOperation("获取积分等级列表")
|
||||
@RequiresPermissions("srb:integralGrade:list")
|
||||
public AjaxResult listAll() {
|
||||
return AjaxResult.success(integralGradeService.list());
|
||||
}
|
||||
|
||||
@DeleteMapping("/remove/{id}")
|
||||
@ApiOperation("根据id删除积分等级")
|
||||
@RequiresPermissions("srb:integralGrade:remove")
|
||||
@Log(title = "融-积分管理", businessType = BusinessType.DELETE)
|
||||
public AjaxResult removeId(@PathVariable Long id) {
|
||||
return toAjax(integralGradeService.removeById(id));
|
||||
}
|
||||
|
||||
@GetMapping("get/{id}")
|
||||
@ApiOperation("根据id获取积分等级")
|
||||
@RequiresPermissions("srb:integralGrade:query")
|
||||
public AjaxResult getById(@PathVariable Long id) {
|
||||
return AjaxResult.success(integralGradeService.getById(id));
|
||||
}
|
||||
|
||||
@PutMapping("update")
|
||||
@ApiOperation("根据id更新积分等级")
|
||||
@RequiresPermissions("srb:integralGrade:update")
|
||||
public AjaxResult updateById(IntegralGrade integralGrade) {
|
||||
return toAjax(integralGradeService.updateById(integralGrade));
|
||||
}
|
||||
|
||||
@PostMapping("save")
|
||||
@ApiOperation("保存积分等级")
|
||||
@RequiresPermissions("srb:integralGrade:save")
|
||||
public AjaxResult save(IntegralGrade integralGrade) {
|
||||
return toAjax(integralGradeService.save(integralGrade));
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
package com.xjs.srb.core.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 积分等级表
|
||||
* </p>
|
||||
*
|
||||
* @author xiejs
|
||||
* @since 2022-02-28
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("integral_grade")
|
||||
@ApiModel(value = "IntegralGrade对象", description = "积分等级表")
|
||||
public class IntegralGrade implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("编号")
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("积分区间开始")
|
||||
private Integer integralStart;
|
||||
|
||||
@ApiModelProperty("积分区间结束")
|
||||
private Integer integralEnd;
|
||||
|
||||
@ApiModelProperty("借款额度")
|
||||
private BigDecimal borrowAmount;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("逻辑删除(1:已删除,0:未删除)")
|
||||
@TableLogic
|
||||
private Boolean isDeleted;
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
package com.xjs.srb.core.mapper;
|
||||
|
||||
import com.xjs.srb.core.entity.IntegralGrade;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 积分等级表 Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author xiejs
|
||||
* @since 2022-02-28
|
||||
*/
|
||||
public interface IntegralGradeMapper extends BaseMapper<IntegralGrade> {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
package com.xjs.srb.core.service;
|
||||
|
||||
import com.xjs.srb.core.entity.IntegralGrade;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 积分等级表 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author xiejs
|
||||
* @since 2022-02-28
|
||||
*/
|
||||
public interface IIntegralGradeService extends IService<IntegralGrade> {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
package com.xjs.srb.core.service.impl;
|
||||
|
||||
import com.xjs.srb.core.entity.IntegralGrade;
|
||||
import com.xjs.srb.core.mapper.IntegralGradeMapper;
|
||||
import com.xjs.srb.core.service.IIntegralGradeService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 积分等级表 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author xiejs
|
||||
* @since 2022-02-28
|
||||
*/
|
||||
@Service
|
||||
public class IntegralGradeServiceImpl extends ServiceImpl<IntegralGradeMapper, IntegralGrade> implements IIntegralGradeService {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.xjs.srb.core.mapper.IntegralGradeMapper">
|
||||
|
||||
</mapper>
|
||||
|
|
@ -26,7 +26,7 @@ public class CodeGenerator {
|
|||
.pathInfo(Collections.singletonMap(OutputFile.mapperXml, "D:\\Dev\\IdeaPerject\\GitHub\\RuoYi-Cloud\\xjs-business\\xjs-business-srb\\srb-service-core\\src\\main\\resources\\mapper")); // 设置mapperXml生成路径
|
||||
})
|
||||
.strategyConfig(builder -> {
|
||||
builder.addInclude("borrow_info")
|
||||
builder.addInclude("integral_grade")
|
||||
.entityBuilder()
|
||||
.enableLombok()
|
||||
.logicDeleteColumnName("is_deleted")
|
||||
|
|
|
|||
Loading…
Reference in New Issue