17 changed files with 1140 additions and 1 deletions
@ -1 +1 @@ |
|||
Subproject commit 201e33eb2576b5358359b57b55d97cfce2b535dc |
|||
Subproject commit ba9218dd49c0443007e925385cec5660dae9d8a2 |
@ -0,0 +1,94 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.controller; |
|||
|
|||
import com.elink.esua.epdc.commons.tools.page.PageData; |
|||
import com.elink.esua.epdc.commons.tools.utils.ExcelUtils; |
|||
import com.elink.esua.epdc.commons.tools.utils.Result; |
|||
import com.elink.esua.epdc.commons.tools.validator.AssertUtils; |
|||
import com.elink.esua.epdc.commons.tools.validator.ValidatorUtils; |
|||
import com.elink.esua.epdc.commons.tools.validator.group.AddGroup; |
|||
import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup; |
|||
import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup; |
|||
import com.elink.esua.epdc.dto.PointsAdjustmentTypeDTO; |
|||
import com.elink.esua.epdc.excel.PointsAdjustmentTypeExcel; |
|||
import com.elink.esua.epdc.service.PointsAdjustmentTypeService; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.web.bind.annotation.*; |
|||
|
|||
import javax.servlet.http.HttpServletResponse; |
|||
import java.util.List; |
|||
import java.util.Map; |
|||
|
|||
|
|||
/** |
|||
* 积分调整类型分值管理表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@RestController |
|||
@RequestMapping("pointsadjustmenttype") |
|||
public class PointsAdjustmentTypeController { |
|||
|
|||
@Autowired |
|||
private PointsAdjustmentTypeService pointsAdjustmentTypeService; |
|||
|
|||
@GetMapping("page") |
|||
public Result<PageData<PointsAdjustmentTypeDTO>> page(@RequestParam Map<String, Object> params){ |
|||
PageData<PointsAdjustmentTypeDTO> page = pointsAdjustmentTypeService.page(params); |
|||
return new Result<PageData<PointsAdjustmentTypeDTO>>().ok(page); |
|||
} |
|||
|
|||
@GetMapping("{id}") |
|||
public Result<PointsAdjustmentTypeDTO> get(@PathVariable("id") String id){ |
|||
PointsAdjustmentTypeDTO data = pointsAdjustmentTypeService.get(id); |
|||
return new Result<PointsAdjustmentTypeDTO>().ok(data); |
|||
} |
|||
|
|||
@PostMapping |
|||
public Result save(@RequestBody PointsAdjustmentTypeDTO dto){ |
|||
//效验数据
|
|||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
|||
pointsAdjustmentTypeService.save(dto); |
|||
return new Result(); |
|||
} |
|||
|
|||
@PutMapping |
|||
public Result update(@RequestBody PointsAdjustmentTypeDTO dto){ |
|||
//效验数据
|
|||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
|||
pointsAdjustmentTypeService.update(dto); |
|||
return new Result(); |
|||
} |
|||
|
|||
@DeleteMapping |
|||
public Result delete(@RequestBody String[] ids){ |
|||
//效验数据
|
|||
AssertUtils.isArrayEmpty(ids, "id"); |
|||
pointsAdjustmentTypeService.delete(ids); |
|||
return new Result(); |
|||
} |
|||
|
|||
@GetMapping("export") |
|||
public void export(@RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception { |
|||
List<PointsAdjustmentTypeDTO> list = pointsAdjustmentTypeService.list(params); |
|||
ExcelUtils.exportExcelToTarget(response, null, list, PointsAdjustmentTypeExcel.class); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,97 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.controller; |
|||
|
|||
import com.elink.esua.epdc.commons.tools.page.PageData; |
|||
import com.elink.esua.epdc.commons.tools.security.user.SecurityUser; |
|||
import com.elink.esua.epdc.commons.tools.utils.ExcelUtils; |
|||
import com.elink.esua.epdc.commons.tools.utils.Result; |
|||
import com.elink.esua.epdc.commons.tools.validator.AssertUtils; |
|||
import com.elink.esua.epdc.commons.tools.validator.ValidatorUtils; |
|||
import com.elink.esua.epdc.commons.tools.validator.group.AddGroup; |
|||
import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup; |
|||
import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup; |
|||
import com.elink.esua.epdc.dto.PointsIntegralAdjustmentCheckDTO; |
|||
import com.elink.esua.epdc.excel.PointsIntegralAdjustmentCheckExcel; |
|||
import com.elink.esua.epdc.service.PointsIntegralAdjustmentCheckService; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.web.bind.annotation.*; |
|||
|
|||
import javax.servlet.http.HttpServletResponse; |
|||
import java.util.List; |
|||
import java.util.Map; |
|||
|
|||
|
|||
/** |
|||
* 积分调整审核表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@RestController |
|||
@RequestMapping("pointsintegraladjustmentcheck") |
|||
public class PointsIntegralAdjustmentCheckController { |
|||
|
|||
@Autowired |
|||
private PointsIntegralAdjustmentCheckService pointsIntegralAdjustmentCheckService; |
|||
|
|||
@GetMapping("page") |
|||
public Result<PageData<PointsIntegralAdjustmentCheckDTO>> page(@RequestParam Map<String, Object> params){ |
|||
PageData<PointsIntegralAdjustmentCheckDTO> page = pointsIntegralAdjustmentCheckService.page(params); |
|||
return new Result<PageData<PointsIntegralAdjustmentCheckDTO>>().ok(page); |
|||
} |
|||
|
|||
@GetMapping("{id}") |
|||
public Result<PointsIntegralAdjustmentCheckDTO> get(@PathVariable("id") String id){ |
|||
PointsIntegralAdjustmentCheckDTO data = pointsIntegralAdjustmentCheckService.get(id); |
|||
return new Result<PointsIntegralAdjustmentCheckDTO>().ok(data); |
|||
} |
|||
|
|||
@PostMapping |
|||
public Result save(@RequestBody PointsIntegralAdjustmentCheckDTO dto){ |
|||
//效验数据
|
|||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
|||
dto.setWorkUserId(SecurityUser.getUserId().toString()); |
|||
pointsIntegralAdjustmentCheckService.save(dto); |
|||
return new Result(); |
|||
} |
|||
|
|||
@PutMapping |
|||
public Result update(@RequestBody PointsIntegralAdjustmentCheckDTO dto){ |
|||
//效验数据
|
|||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
|||
dto.setWorkUserId(SecurityUser.getUserId().toString()); |
|||
pointsIntegralAdjustmentCheckService.update(dto); |
|||
return new Result(); |
|||
} |
|||
|
|||
@DeleteMapping |
|||
public Result delete(@RequestBody String[] ids){ |
|||
//效验数据
|
|||
AssertUtils.isArrayEmpty(ids, "id"); |
|||
pointsIntegralAdjustmentCheckService.delete(ids); |
|||
return new Result(); |
|||
} |
|||
|
|||
@GetMapping("export") |
|||
public void export(@RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception { |
|||
List<PointsIntegralAdjustmentCheckDTO> list = pointsIntegralAdjustmentCheckService.list(params); |
|||
ExcelUtils.exportExcelToTarget(response, null, list, PointsIntegralAdjustmentCheckExcel.class); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,33 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.dao; |
|||
|
|||
import com.elink.esua.epdc.commons.mybatis.dao.BaseDao; |
|||
import com.elink.esua.epdc.entity.PointsAdjustmentTypeEntity; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
|
|||
/** |
|||
* 积分调整类型分值管理表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Mapper |
|||
public interface PointsAdjustmentTypeDao extends BaseDao<PointsAdjustmentTypeEntity> { |
|||
|
|||
} |
@ -0,0 +1,33 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.dao; |
|||
|
|||
import com.elink.esua.epdc.commons.mybatis.dao.BaseDao; |
|||
import com.elink.esua.epdc.entity.PointsIntegralAdjustmentCheckEntity; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
|
|||
/** |
|||
* 积分调整审核表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Mapper |
|||
public interface PointsIntegralAdjustmentCheckDao extends BaseDao<PointsIntegralAdjustmentCheckEntity> { |
|||
|
|||
} |
@ -0,0 +1,61 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.entity; |
|||
|
|||
import com.baomidou.mybatisplus.annotation.TableName; |
|||
|
|||
import com.elink.esua.epdc.commons.mybatis.entity.BaseEpdcEntity; |
|||
import lombok.Data; |
|||
import lombok.EqualsAndHashCode; |
|||
|
|||
import java.util.Date; |
|||
|
|||
/** |
|||
* 积分调整类型分值管理表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Data |
|||
@EqualsAndHashCode(callSuper=false) |
|||
@TableName("epdc_points_adjustment_type") |
|||
public class PointsAdjustmentTypeEntity extends BaseEpdcEntity { |
|||
|
|||
private static final long serialVersionUID = 1L; |
|||
|
|||
/** |
|||
* 行为调整类型code |
|||
*/ |
|||
private String adjustmentTypeCode; |
|||
|
|||
/** |
|||
* 行为调整类型名称 |
|||
*/ |
|||
private String adjustmentTypeName; |
|||
|
|||
/** |
|||
* 分数 |
|||
*/ |
|||
private Integer point; |
|||
|
|||
/** |
|||
* 备注 |
|||
*/ |
|||
private String remark; |
|||
|
|||
} |
@ -0,0 +1,111 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.entity; |
|||
|
|||
import com.baomidou.mybatisplus.annotation.TableName; |
|||
|
|||
import com.elink.esua.epdc.commons.mybatis.entity.BaseEpdcEntity; |
|||
import lombok.Data; |
|||
import lombok.EqualsAndHashCode; |
|||
|
|||
import java.util.Date; |
|||
|
|||
/** |
|||
* 积分调整审核表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Data |
|||
@EqualsAndHashCode(callSuper=false) |
|||
@TableName("epdc_points_integral_adjustment_check") |
|||
public class PointsIntegralAdjustmentCheckEntity extends BaseEpdcEntity { |
|||
|
|||
private static final long serialVersionUID = 1L; |
|||
|
|||
/** |
|||
* 用户ID |
|||
*/ |
|||
private String userId; |
|||
|
|||
/** |
|||
* 用户昵称 |
|||
*/ |
|||
private String nickName; |
|||
|
|||
/** |
|||
* 姓名 |
|||
*/ |
|||
private String realName; |
|||
|
|||
/** |
|||
* 用户头像 |
|||
*/ |
|||
private String faceImg; |
|||
|
|||
/** |
|||
* 性别(0-女,1-男) |
|||
*/ |
|||
private String sex; |
|||
|
|||
/** |
|||
* 出生日期 |
|||
*/ |
|||
private Date birthday; |
|||
|
|||
/** |
|||
* 手机号 |
|||
*/ |
|||
private String mobile; |
|||
|
|||
/** |
|||
* 用户当前积分 |
|||
*/ |
|||
private Integer points; |
|||
|
|||
/** |
|||
* 调整原因 |
|||
*/ |
|||
private String adjustReason; |
|||
|
|||
/** |
|||
* 积分操作类型(0:减;1:加) |
|||
*/ |
|||
private String operationType; |
|||
|
|||
/** |
|||
* 积分调整值 |
|||
*/ |
|||
private Integer operatePoints; |
|||
|
|||
/** |
|||
* 积分调整类型编码 |
|||
*/ |
|||
private String pointOperateTypeCode; |
|||
|
|||
/** |
|||
* 积分调整类型名称 |
|||
*/ |
|||
private String pointOperateTypeName; |
|||
|
|||
/** |
|||
* 工作人员ID |
|||
*/ |
|||
private String workUserId; |
|||
|
|||
} |
@ -0,0 +1,68 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.excel; |
|||
|
|||
import cn.afterturn.easypoi.excel.annotation.Excel; |
|||
import lombok.Data; |
|||
|
|||
import java.util.Date; |
|||
|
|||
/** |
|||
* 积分调整类型分值管理表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Data |
|||
public class PointsAdjustmentTypeExcel { |
|||
|
|||
@Excel(name = "ID") |
|||
private String id; |
|||
|
|||
@Excel(name = "行为调整类型code") |
|||
private String adjustmentTypeCode; |
|||
|
|||
@Excel(name = "行为调整类型名称") |
|||
private String adjustmentTypeName; |
|||
|
|||
@Excel(name = "分数") |
|||
private Integer point; |
|||
|
|||
@Excel(name = "备注") |
|||
private String remark; |
|||
|
|||
@Excel(name = "乐观锁") |
|||
private Integer revision; |
|||
|
|||
@Excel(name = "逻辑删除标识") |
|||
private String delFlag; |
|||
|
|||
@Excel(name = "创建人") |
|||
private String createdBy; |
|||
|
|||
@Excel(name = "创建时间") |
|||
private Date createdTime; |
|||
|
|||
@Excel(name = "更新人") |
|||
private String updatedBy; |
|||
|
|||
@Excel(name = "更新时间") |
|||
private Date updatedTime; |
|||
|
|||
|
|||
} |
@ -0,0 +1,98 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.excel; |
|||
|
|||
import cn.afterturn.easypoi.excel.annotation.Excel; |
|||
import lombok.Data; |
|||
|
|||
import java.util.Date; |
|||
|
|||
/** |
|||
* 积分调整审核表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Data |
|||
public class PointsIntegralAdjustmentCheckExcel { |
|||
|
|||
@Excel(name = "ID") |
|||
private String id; |
|||
|
|||
@Excel(name = "用户ID") |
|||
private String userId; |
|||
|
|||
@Excel(name = "用户昵称") |
|||
private String nickName; |
|||
|
|||
@Excel(name = "姓名") |
|||
private String realName; |
|||
|
|||
@Excel(name = "用户头像") |
|||
private String faceImg; |
|||
|
|||
@Excel(name = "性别(0-女,1-男)") |
|||
private String sex; |
|||
|
|||
@Excel(name = "出生日期") |
|||
private Date birthday; |
|||
|
|||
@Excel(name = "手机号") |
|||
private String mobile; |
|||
|
|||
@Excel(name = "用户当前积分") |
|||
private Integer points; |
|||
|
|||
@Excel(name = "调整原因") |
|||
private String adjustReason; |
|||
|
|||
@Excel(name = "积分操作类型(0:减;1:加)") |
|||
private String operationType; |
|||
|
|||
@Excel(name = "积分调整值") |
|||
private Integer operatePoints; |
|||
|
|||
@Excel(name = "积分调整类型编码") |
|||
private String pointOperateTypeCode; |
|||
|
|||
@Excel(name = "积分调整类型名称") |
|||
private String pointOperateTypeName; |
|||
|
|||
@Excel(name = "工作人员ID") |
|||
private String workUserId; |
|||
|
|||
@Excel(name = "乐观锁") |
|||
private Integer revision; |
|||
|
|||
@Excel(name = "逻辑删除标识") |
|||
private String delFlag; |
|||
|
|||
@Excel(name = "创建人") |
|||
private String createdBy; |
|||
|
|||
@Excel(name = "创建时间") |
|||
private Date createdTime; |
|||
|
|||
@Excel(name = "更新人") |
|||
private String updatedBy; |
|||
|
|||
@Excel(name = "更新时间") |
|||
private Date updatedTime; |
|||
|
|||
|
|||
} |
@ -0,0 +1,47 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.redis; |
|||
|
|||
import com.elink.esua.epdc.commons.tools.redis.RedisUtils; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 积分调整类型分值管理表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Component |
|||
public class PointsAdjustmentTypeRedis { |
|||
@Autowired |
|||
private RedisUtils redisUtils; |
|||
|
|||
public void delete(Object[] ids) { |
|||
|
|||
} |
|||
|
|||
public void set(){ |
|||
|
|||
} |
|||
|
|||
public String get(String id){ |
|||
return null; |
|||
} |
|||
|
|||
} |
@ -0,0 +1,47 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.redis; |
|||
|
|||
import com.elink.esua.epdc.commons.tools.redis.RedisUtils; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* 积分调整审核表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Component |
|||
public class PointsIntegralAdjustmentCheckRedis { |
|||
@Autowired |
|||
private RedisUtils redisUtils; |
|||
|
|||
public void delete(Object[] ids) { |
|||
|
|||
} |
|||
|
|||
public void set(){ |
|||
|
|||
} |
|||
|
|||
public String get(String id){ |
|||
return null; |
|||
} |
|||
|
|||
} |
@ -0,0 +1,95 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.service; |
|||
|
|||
import com.elink.esua.epdc.commons.mybatis.service.BaseService; |
|||
import com.elink.esua.epdc.commons.tools.page.PageData; |
|||
import com.elink.esua.epdc.dto.PointsAdjustmentTypeDTO; |
|||
import com.elink.esua.epdc.entity.PointsAdjustmentTypeEntity; |
|||
|
|||
import java.util.List; |
|||
import java.util.Map; |
|||
|
|||
/** |
|||
* 积分调整类型分值管理表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
public interface PointsAdjustmentTypeService extends BaseService<PointsAdjustmentTypeEntity> { |
|||
|
|||
/** |
|||
* 默认分页 |
|||
* |
|||
* @param params |
|||
* @return PageData<PointsAdjustmentTypeDTO> |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
PageData<PointsAdjustmentTypeDTO> page(Map<String, Object> params); |
|||
|
|||
/** |
|||
* 默认查询 |
|||
* |
|||
* @param params |
|||
* @return java.util.List<PointsAdjustmentTypeDTO> |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
List<PointsAdjustmentTypeDTO> list(Map<String, Object> params); |
|||
|
|||
/** |
|||
* 单条查询 |
|||
* |
|||
* @param id |
|||
* @return PointsAdjustmentTypeDTO |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
PointsAdjustmentTypeDTO get(String id); |
|||
|
|||
/** |
|||
* 默认保存 |
|||
* |
|||
* @param dto |
|||
* @return void |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
void save(PointsAdjustmentTypeDTO dto); |
|||
|
|||
/** |
|||
* 默认更新 |
|||
* |
|||
* @param dto |
|||
* @return void |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
void update(PointsAdjustmentTypeDTO dto); |
|||
|
|||
/** |
|||
* 批量删除 |
|||
* |
|||
* @param ids |
|||
* @return void |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
void delete(String[] ids); |
|||
} |
@ -0,0 +1,95 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.service; |
|||
|
|||
import com.elink.esua.epdc.commons.mybatis.service.BaseService; |
|||
import com.elink.esua.epdc.commons.tools.page.PageData; |
|||
import com.elink.esua.epdc.dto.PointsIntegralAdjustmentCheckDTO; |
|||
import com.elink.esua.epdc.entity.PointsIntegralAdjustmentCheckEntity; |
|||
|
|||
import java.util.List; |
|||
import java.util.Map; |
|||
|
|||
/** |
|||
* 积分调整审核表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
public interface PointsIntegralAdjustmentCheckService extends BaseService<PointsIntegralAdjustmentCheckEntity> { |
|||
|
|||
/** |
|||
* 默认分页 |
|||
* |
|||
* @param params |
|||
* @return PageData<PointsIntegralAdjustmentCheckDTO> |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
PageData<PointsIntegralAdjustmentCheckDTO> page(Map<String, Object> params); |
|||
|
|||
/** |
|||
* 默认查询 |
|||
* |
|||
* @param params |
|||
* @return java.util.List<PointsIntegralAdjustmentCheckDTO> |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
List<PointsIntegralAdjustmentCheckDTO> list(Map<String, Object> params); |
|||
|
|||
/** |
|||
* 单条查询 |
|||
* |
|||
* @param id |
|||
* @return PointsIntegralAdjustmentCheckDTO |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
PointsIntegralAdjustmentCheckDTO get(String id); |
|||
|
|||
/** |
|||
* 默认保存 |
|||
* |
|||
* @param dto |
|||
* @return void |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
void save(PointsIntegralAdjustmentCheckDTO dto); |
|||
|
|||
/** |
|||
* 默认更新 |
|||
* |
|||
* @param dto |
|||
* @return void |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
void update(PointsIntegralAdjustmentCheckDTO dto); |
|||
|
|||
/** |
|||
* 批量删除 |
|||
* |
|||
* @param ids |
|||
* @return void |
|||
* @author generator |
|||
* @date 2022-03-31 |
|||
*/ |
|||
void delete(String[] ids); |
|||
} |
@ -0,0 +1,104 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.service.impl; |
|||
|
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.elink.esua.epdc.commons.mybatis.service.impl.BaseServiceImpl; |
|||
import com.elink.esua.epdc.commons.tools.page.PageData; |
|||
import com.elink.esua.epdc.commons.tools.utils.ConvertUtils; |
|||
import com.elink.esua.epdc.commons.tools.constant.FieldConstant; |
|||
import com.elink.esua.epdc.dao.PointsAdjustmentTypeDao; |
|||
import com.elink.esua.epdc.dto.PointsAdjustmentTypeDTO; |
|||
import com.elink.esua.epdc.entity.PointsAdjustmentTypeEntity; |
|||
import com.elink.esua.epdc.redis.PointsAdjustmentTypeRedis; |
|||
import com.elink.esua.epdc.service.PointsAdjustmentTypeService; |
|||
import org.apache.commons.lang3.StringUtils; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Service; |
|||
import org.springframework.transaction.annotation.Transactional; |
|||
|
|||
import java.util.Arrays; |
|||
import java.util.List; |
|||
import java.util.Map; |
|||
|
|||
/** |
|||
* 积分调整类型分值管理表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Service |
|||
public class PointsAdjustmentTypeServiceImpl extends BaseServiceImpl<PointsAdjustmentTypeDao, PointsAdjustmentTypeEntity> implements PointsAdjustmentTypeService { |
|||
|
|||
@Autowired |
|||
private PointsAdjustmentTypeRedis pointsAdjustmentTypeRedis; |
|||
|
|||
@Override |
|||
public PageData<PointsAdjustmentTypeDTO> page(Map<String, Object> params) { |
|||
IPage<PointsAdjustmentTypeEntity> page = baseDao.selectPage( |
|||
getPage(params, FieldConstant.CREATED_TIME, false), |
|||
getWrapper(params) |
|||
); |
|||
return getPageData(page, PointsAdjustmentTypeDTO.class); |
|||
} |
|||
|
|||
@Override |
|||
public List<PointsAdjustmentTypeDTO> list(Map<String, Object> params) { |
|||
List<PointsAdjustmentTypeEntity> entityList = baseDao.selectList(getWrapper(params)); |
|||
|
|||
return ConvertUtils.sourceToTarget(entityList, PointsAdjustmentTypeDTO.class); |
|||
} |
|||
|
|||
private QueryWrapper<PointsAdjustmentTypeEntity> getWrapper(Map<String, Object> params){ |
|||
String id = (String)params.get(FieldConstant.ID_HUMP); |
|||
|
|||
QueryWrapper<PointsAdjustmentTypeEntity> wrapper = new QueryWrapper<>(); |
|||
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
|||
|
|||
return wrapper; |
|||
} |
|||
|
|||
@Override |
|||
public PointsAdjustmentTypeDTO get(String id) { |
|||
PointsAdjustmentTypeEntity entity = baseDao.selectById(id); |
|||
return ConvertUtils.sourceToTarget(entity, PointsAdjustmentTypeDTO.class); |
|||
} |
|||
|
|||
@Override |
|||
@Transactional(rollbackFor = Exception.class) |
|||
public void save(PointsAdjustmentTypeDTO dto) { |
|||
PointsAdjustmentTypeEntity entity = ConvertUtils.sourceToTarget(dto, PointsAdjustmentTypeEntity.class); |
|||
insert(entity); |
|||
} |
|||
|
|||
@Override |
|||
@Transactional(rollbackFor = Exception.class) |
|||
public void update(PointsAdjustmentTypeDTO dto) { |
|||
PointsAdjustmentTypeEntity entity = ConvertUtils.sourceToTarget(dto, PointsAdjustmentTypeEntity.class); |
|||
updateById(entity); |
|||
} |
|||
|
|||
@Override |
|||
@Transactional(rollbackFor = Exception.class) |
|||
public void delete(String[] ids) { |
|||
// 逻辑删除(@TableLogic 注解)
|
|||
baseDao.deleteBatchIds(Arrays.asList(ids)); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,104 @@ |
|||
/** |
|||
* Copyright 2018 人人开源 https://www.renren.io
|
|||
* <p> |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU General Public License as published by |
|||
* the Free Software Foundation, either version 3 of the License, or |
|||
* (at your option) any later version. |
|||
* <p> |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU General Public License for more details. |
|||
* <p> |
|||
* You should have received a copy of the GNU General Public License |
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
*/ |
|||
|
|||
package com.elink.esua.epdc.service.impl; |
|||
|
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.elink.esua.epdc.commons.mybatis.service.impl.BaseServiceImpl; |
|||
import com.elink.esua.epdc.commons.tools.page.PageData; |
|||
import com.elink.esua.epdc.commons.tools.utils.ConvertUtils; |
|||
import com.elink.esua.epdc.commons.tools.constant.FieldConstant; |
|||
import com.elink.esua.epdc.dao.PointsIntegralAdjustmentCheckDao; |
|||
import com.elink.esua.epdc.dto.PointsIntegralAdjustmentCheckDTO; |
|||
import com.elink.esua.epdc.entity.PointsIntegralAdjustmentCheckEntity; |
|||
import com.elink.esua.epdc.redis.PointsIntegralAdjustmentCheckRedis; |
|||
import com.elink.esua.epdc.service.PointsIntegralAdjustmentCheckService; |
|||
import org.apache.commons.lang3.StringUtils; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Service; |
|||
import org.springframework.transaction.annotation.Transactional; |
|||
|
|||
import java.util.Arrays; |
|||
import java.util.List; |
|||
import java.util.Map; |
|||
|
|||
/** |
|||
* 积分调整审核表 |
|||
* |
|||
* @author elink elink@elink-cn.com |
|||
* @since v1.0.0 2022-03-31 |
|||
*/ |
|||
@Service |
|||
public class PointsIntegralAdjustmentCheckServiceImpl extends BaseServiceImpl<PointsIntegralAdjustmentCheckDao, PointsIntegralAdjustmentCheckEntity> implements PointsIntegralAdjustmentCheckService { |
|||
|
|||
@Autowired |
|||
private PointsIntegralAdjustmentCheckRedis pointsIntegralAdjustmentCheckRedis; |
|||
|
|||
@Override |
|||
public PageData<PointsIntegralAdjustmentCheckDTO> page(Map<String, Object> params) { |
|||
IPage<PointsIntegralAdjustmentCheckEntity> page = baseDao.selectPage( |
|||
getPage(params, FieldConstant.CREATED_TIME, false), |
|||
getWrapper(params) |
|||
); |
|||
return getPageData(page, PointsIntegralAdjustmentCheckDTO.class); |
|||
} |
|||
|
|||
@Override |
|||
public List<PointsIntegralAdjustmentCheckDTO> list(Map<String, Object> params) { |
|||
List<PointsIntegralAdjustmentCheckEntity> entityList = baseDao.selectList(getWrapper(params)); |
|||
|
|||
return ConvertUtils.sourceToTarget(entityList, PointsIntegralAdjustmentCheckDTO.class); |
|||
} |
|||
|
|||
private QueryWrapper<PointsIntegralAdjustmentCheckEntity> getWrapper(Map<String, Object> params){ |
|||
String id = (String)params.get(FieldConstant.ID_HUMP); |
|||
|
|||
QueryWrapper<PointsIntegralAdjustmentCheckEntity> wrapper = new QueryWrapper<>(); |
|||
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
|||
|
|||
return wrapper; |
|||
} |
|||
|
|||
@Override |
|||
public PointsIntegralAdjustmentCheckDTO get(String id) { |
|||
PointsIntegralAdjustmentCheckEntity entity = baseDao.selectById(id); |
|||
return ConvertUtils.sourceToTarget(entity, PointsIntegralAdjustmentCheckDTO.class); |
|||
} |
|||
|
|||
@Override |
|||
@Transactional(rollbackFor = Exception.class) |
|||
public void save(PointsIntegralAdjustmentCheckDTO dto) { |
|||
PointsIntegralAdjustmentCheckEntity entity = ConvertUtils.sourceToTarget(dto, PointsIntegralAdjustmentCheckEntity.class); |
|||
insert(entity); |
|||
} |
|||
|
|||
@Override |
|||
@Transactional(rollbackFor = Exception.class) |
|||
public void update(PointsIntegralAdjustmentCheckDTO dto) { |
|||
PointsIntegralAdjustmentCheckEntity entity = ConvertUtils.sourceToTarget(dto, PointsIntegralAdjustmentCheckEntity.class); |
|||
updateById(entity); |
|||
} |
|||
|
|||
@Override |
|||
@Transactional(rollbackFor = Exception.class) |
|||
public void delete(String[] ids) { |
|||
// 逻辑删除(@TableLogic 注解)
|
|||
baseDao.deleteBatchIds(Arrays.asList(ids)); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,21 @@ |
|||
<?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.elink.esua.epdc.dao.PointsAdjustmentTypeDao"> |
|||
|
|||
<resultMap type="com.elink.esua.epdc.entity.PointsAdjustmentTypeEntity" id="pointsAdjustmentTypeMap"> |
|||
<result property="id" column="ID"/> |
|||
<result property="adjustmentTypeCode" column="ADJUSTMENT_TYPE_CODE"/> |
|||
<result property="adjustmentTypeName" column="ADJUSTMENT_TYPE_NAME"/> |
|||
<result property="point" column="POINT"/> |
|||
<result property="remark" column="REMARK"/> |
|||
<result property="revision" column="REVISION"/> |
|||
<result property="delFlag" column="DEL_FLAG"/> |
|||
<result property="createdBy" column="CREATED_BY"/> |
|||
<result property="createdTime" column="CREATED_TIME"/> |
|||
<result property="updatedBy" column="UPDATED_BY"/> |
|||
<result property="updatedTime" column="UPDATED_TIME"/> |
|||
</resultMap> |
|||
|
|||
|
|||
</mapper> |
@ -0,0 +1,31 @@ |
|||
<?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.elink.esua.epdc.dao.PointsIntegralAdjustmentCheckDao"> |
|||
|
|||
<resultMap type="com.elink.esua.epdc.entity.PointsIntegralAdjustmentCheckEntity" id="pointsIntegralAdjustmentCheckMap"> |
|||
<result property="id" column="ID"/> |
|||
<result property="userId" column="USER_ID"/> |
|||
<result property="nickName" column="NICK_NAME"/> |
|||
<result property="realName" column="REAL_NAME"/> |
|||
<result property="faceImg" column="FACE_IMG"/> |
|||
<result property="sex" column="SEX"/> |
|||
<result property="birthday" column="BIRTHDAY"/> |
|||
<result property="mobile" column="MOBILE"/> |
|||
<result property="points" column="POINTS"/> |
|||
<result property="adjustReason" column="ADJUST_REASON"/> |
|||
<result property="operationType" column="OPERATION_TYPE"/> |
|||
<result property="operatePoints" column="OPERATE_POINTS"/> |
|||
<result property="pointOperateTypeCode" column="POINT_OPERATE_TYPE_CODE"/> |
|||
<result property="pointOperateTypeName" column="POINT_OPERATE_TYPE_NAME"/> |
|||
<result property="workUserId" column="WORK_USER_ID"/> |
|||
<result property="revision" column="REVISION"/> |
|||
<result property="delFlag" column="DEL_FLAG"/> |
|||
<result property="createdBy" column="CREATED_BY"/> |
|||
<result property="createdTime" column="CREATED_TIME"/> |
|||
<result property="updatedBy" column="UPDATED_BY"/> |
|||
<result property="updatedTime" column="UPDATED_TIME"/> |
|||
</resultMap> |
|||
|
|||
|
|||
</mapper> |
Loading…
Reference in new issue