Просмотр исходного кода

[系统][删除]:删除已经不使用的verifycoupon相关文件

release_toaliyun_real
hupeng 7 лет назад
Родитель
Сommit
a887ab3765
9 измененных файлов: 0 добавлений и 575 удалений
  1. +0
    -82
      mallinkAdmin/src/main/java/com/simple/controller/WxCouponVerifyController.java
  2. +0
    -1
      mallinkCApi/src/main/java/com/simple/controller/WxCouponController.java
  3. +0
    -71
      mallinkCApi/src/main/java/com/simple/controller/WxCouponVerifyController.java
  4. +0
    -201
      mallinkService/src/main/java/com/simple/domain/po/WxCouponVerify.java
  5. +0
    -17
      mallinkService/src/main/java/com/simple/mapper/WxCouponVerifyMapper.java
  6. +0
    -48
      mallinkService/src/main/java/com/simple/service/WxCouponVerifyService.java
  7. +0
    -54
      mallinkService/src/main/java/com/simple/service/impl/WxCouponVerifyServiceImpl.java
  8. +0
    -3
      mallinkService/src/main/java/com/simple/service/impl/WxRefundOrderServiceImpl.java
  9. +0
    -98
      mallinkService/src/main/resources/mapper/WxCouponVerifyMapper.xml

+ 0
- 82
mallinkAdmin/src/main/java/com/simple/controller/WxCouponVerifyController.java Просмотреть файл

@@ -1,82 +0,0 @@
package com.simple.controller;

import com.simple.domain.po.MallUserInfo;
import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.Assert;
import org.springframework.web.bind.annotation.*;

import com.github.pagehelper.PageInfo;
import com.simple.common.Result;
import com.simple.common.ResultData;

import com.simple.domain.po.WxCouponVerify;
import com.simple.service.WxCouponVerifyService;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;

@RestController
@RequestMapping("wxCouponVerify")
public class WxCouponVerifyController extends BaseController
{
@Autowired
private WxCouponVerifyService wxCouponVerifyService;

private Logger logger = Logger.getLogger(WxCouponVerifyController.class);
@ApiOperation("分页列表接口")
@GetMapping("list")
@ApiImplicitParams({
@ApiImplicitParam(name="pageNum",value="页数",dataType="int", paramType = "query",required=true),
@ApiImplicitParam(name="pageSize",value="每页条数",dataType="int", paramType = "query",required=true)})
public ResultData list(@ModelAttribute WxCouponVerify wxCouponVerify,Integer pageNum, Integer pageSize) {
if (null == wxCouponVerify) wxCouponVerify = new WxCouponVerify();
final PageInfo<WxCouponVerify> page = wxCouponVerifyService.listAsPage(wxCouponVerify, pageNum, pageSize);
return new ResultData(page);
}

@ApiOperation("新增接口")
@PostMapping("add")
public ResultData add(@RequestBody WxCouponVerify wxCouponVerify) {
//Assert.notNull(wxCouponVerify.getName(), "角色名不能为空");
//Assert.isTrue(!checkUnique(sysRole.getName(), null), "重复的角色名");
wxCouponVerifyService.saveOrUpdate(wxCouponVerify);
return new ResultData();
}

@ApiOperation("根据id更新接口")
@PostMapping("update")
public ResultData update(@RequestBody WxCouponVerify wxCouponVerify) {
wxCouponVerifyService.saveOrUpdate(wxCouponVerify);
return new ResultData();
}

@ApiOperation("根据id删除接口")
@GetMapping("/del")
@ApiImplicitParam(name="id",value="id",dataType="Long", paramType = "query",required=true)
public ResultData delete(Long id) {
wxCouponVerifyService.deleteById(id);
return new ResultData(Result.SUCCESS, "删除成功", null);
}
@ApiOperation("根据id查询接口")
@GetMapping("/findById")
@ApiImplicitParam(name="id",value="id",dataType="Long", paramType = "query",required=true)
public ResultData findById(Long id) {
return new ResultData(Result.SUCCESS,"查询成功",wxCouponVerifyService.getById(id));
}

@ApiOperation("根据id更新接口")
@PostMapping("verify")
public ResultData verify(@RequestBody WxCouponVerify wxCouponVerify) {
MallUserInfo user =getUser();
wxCouponVerify.setBUserId(user.getId());
wxCouponVerify.setTenantId(user.getTenantId());
wxCouponVerifyService.saveOrUpdate(wxCouponVerify);
return new ResultData();
}
}

+ 0
- 1
mallinkCApi/src/main/java/com/simple/controller/WxCouponController.java Просмотреть файл

@@ -42,5 +42,4 @@ public class WxCouponController extends BaseController {
return new ResultData(Result.SUCCESS, "查询成功", wxCouponService.getById(id));
}


}

+ 0
- 71
mallinkCApi/src/main/java/com/simple/controller/WxCouponVerifyController.java Просмотреть файл

@@ -1,71 +0,0 @@
package com.simple.controller;

import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.Assert;
import org.springframework.web.bind.annotation.*;

import com.github.pagehelper.PageInfo;
import com.simple.common.Result;
import com.simple.common.ResultData;

import com.simple.domain.po.WxCouponVerify;
import com.simple.service.WxCouponVerifyService;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;

@RestController
@RequestMapping("wxCouponVerify")
public class WxCouponVerifyController extends BaseController
{
@Autowired
private WxCouponVerifyService wxCouponVerifyService;

private Logger logger = Logger.getLogger(WxCouponVerifyController.class);
@ApiOperation("分页列表接口")
@GetMapping("list")
@ApiImplicitParams({
@ApiImplicitParam(name="pageNum",value="页数",dataType="int", paramType = "query",required=true),
@ApiImplicitParam(name="pageSize",value="每页条数",dataType="int", paramType = "query",required=true)})
public ResultData list(@ModelAttribute WxCouponVerify wxCouponVerify,Integer pageNum, Integer pageSize) {
if (null == wxCouponVerify) wxCouponVerify = new WxCouponVerify();
final PageInfo<WxCouponVerify> page = wxCouponVerifyService.listAsPage(wxCouponVerify, pageNum, pageSize);
return new ResultData(page);
}

@ApiOperation("新增接口")
@PostMapping("add")
public ResultData add(@RequestBody WxCouponVerify wxCouponVerify) {
//Assert.notNull(wxCouponVerify.getName(), "角色名不能为空");
//Assert.isTrue(!checkUnique(sysRole.getName(), null), "重复的角色名");
wxCouponVerifyService.saveOrUpdate(wxCouponVerify);
return new ResultData();
}

@ApiOperation("根据id更新接口")
@PostMapping("update")
public ResultData update(@RequestBody WxCouponVerify wxCouponVerify) {
wxCouponVerifyService.saveOrUpdate(wxCouponVerify);
return new ResultData();
}

@ApiOperation("根据id删除接口")
@GetMapping("/del")
@ApiImplicitParam(name="id",value="id",dataType="Long", paramType = "query",required=true)
public ResultData delete(Long id) {
wxCouponVerifyService.deleteById(id);
return new ResultData(Result.SUCCESS, "删除成功", null);
}
@ApiOperation("根据id查询接口")
@GetMapping("/findById")
@ApiImplicitParam(name="id",value="id",dataType="Long", paramType = "query",required=true)
public ResultData findById(Long id) {
return new ResultData(Result.SUCCESS,"查询成功",wxCouponVerifyService.getById(id));
}
}

+ 0
- 201
mallinkService/src/main/java/com/simple/domain/po/WxCouponVerify.java Просмотреть файл

@@ -1,201 +0,0 @@
package com.simple.domain.po;

import javax.persistence.*;
import java.util.*;
import java.math.*;
import javax.persistence.Transient;
import java.util.List;
import javax.persistence.Id;
import java.io.Serializable;

@Table(name = "wx_coupon_verify")
public class WxCouponVerify implements Serializable {
private static final long serialVersionUID = 1L;
@Id
protected Long id;
@Transient
protected List<String> ids;
@Transient
protected String sortColumns;
public Long getId() {
return id;
}

public void setId(Long id) {
this.id = id;
}
public String getSortColumns() {
return sortColumns;
}
public List<String> getIds() {
return ids;
}
public void setIds(List<String> ids) {
this.ids = ids;
}
/*租户ID**/
@io.swagger.annotations.ApiModelProperty(value="租户ID",name="tenantId")
private String tenantId;
/*coupon id**/
@io.swagger.annotations.ApiModelProperty(value="coupon id",name="couponId")
private Long couponId;
/*订单id**/
@io.swagger.annotations.ApiModelProperty(value="订单id",name="orderId")
private Long orderId;
/*c端用户id**/
@io.swagger.annotations.ApiModelProperty(value="c端用户id",name="cUserId")
private Long cUserId;
/*购买日期/领取日期**/
@io.swagger.annotations.ApiModelProperty(value="购买日期/领取日期",name="buyDate")
private Date buyDate;
/*截止日期**/
@io.swagger.annotations.ApiModelProperty(value="截止日期",name="limitDate")
private Date limitDate;
/*c状态(0:default,1:未支付,2:已支付/已领取,3:已使用,4:已退回/已退券)**/
@io.swagger.annotations.ApiModelProperty(value="c状态(0:default,1:未支付,2:已支付/已领取,3:已使用,4:已退回/已退券)",name="cStatus")
private Integer cStatus;
/*b端用户id**/
@io.swagger.annotations.ApiModelProperty(value="b端用户id",name="bUserId")
private Long bUserId;
/*核销日期**/
@io.swagger.annotations.ApiModelProperty(value="核销日期",name="verificationDate")
private Date verificationDate;
/*核销状态(0:未核销,1:已核销)**/
@io.swagger.annotations.ApiModelProperty(value="核销状态(0:未核销,1:已核销)",name="verificationStatus")
private Integer verificationStatus;
public String getTenantId() {
return tenantId;
}
public void setTenantId(String _tenantId) {
tenantId = _tenantId;
}
public Long getCouponId() {
return couponId;
}
public void setCouponId(Long _couponId) {
couponId = _couponId;
}
public Long getOrderId() {
return orderId;
}
public void setOrderId(Long _orderId) {
orderId = _orderId;
}
public Long getCUserId() {
return cUserId;
}
public void setCUserId(Long _cUserId) {
cUserId = _cUserId;
}
public Date getBuyDate() {
return buyDate;
}
public void setBuyDate(Date _buyDate) {
buyDate = _buyDate;
}
public Date getLimitDate() {
return limitDate;
}
public void setLimitDate(Date _limitDate) {
limitDate = _limitDate;
}
public Integer getCStatus() {
return cStatus;
}
public void setCStatus(Integer _cStatus) {
cStatus = _cStatus;
}
public Long getBUserId() {
return bUserId;
}
public void setBUserId(Long _bUserId) {
bUserId = _bUserId;
}
public Date getVerificationDate() {
return verificationDate;
}
public void setVerificationDate(Date _verificationDate) {
verificationDate = _verificationDate;
}
public Integer getVerificationStatus() {
return verificationStatus;
}
public void setVerificationStatus(Integer _verificationStatus) {
verificationStatus = _verificationStatus;
}



public static enum Field
{
Id_ASC("`id` ASC"),Id_DESC("`id` DESC")
,TenantId_ASC("`tenantId` ASC"),TenantId_DESC("`tenantId` DESC")
,CouponId_ASC("`couponId` ASC"),CouponId_DESC("`couponId` DESC")
,OrderId_ASC("`orderId` ASC"),OrderId_DESC("`orderId` DESC")
,CUserId_ASC("`cUserId` ASC"),CUserId_DESC("`cUserId` DESC")
,BuyDate_ASC("`buyDate` ASC"),BuyDate_DESC("`buyDate` DESC")
,LimitDate_ASC("`limitDate` ASC"),LimitDate_DESC("`limitDate` DESC")
,CStatus_ASC("`cStatus` ASC"),CStatus_DESC("`cStatus` DESC")
,BUserId_ASC("`bUserId` ASC"),BUserId_DESC("`bUserId` DESC")
,VerificationDate_ASC("`verificationDate` ASC"),VerificationDate_DESC("`verificationDate` DESC")
,VerificationStatus_ASC("`verificationStatus` ASC"),VerificationStatus_DESC("`verificationStatus` DESC")
;
private String value;
Field(String value){
this.value = value;
}
public String getValue() {
return value;
}
public void setCol(String value) {
this.value = value;
}
@Override
public String toString() {
return this.getValue();
}
}
public void setSortColumns(WxCouponVerify.Field... fields)
{
if (fields == null || fields.length == 0) {
return;
}
for (int k = 0; k < fields.length; k++) {
if (fields[k] == null) {
return;
}
}
StringBuilder sb = new StringBuilder(fields[0].toString());
for (int k = 1; k < fields.length; k++) {
sb.append(",");
sb.append(fields[k].toString());
}
}
public void setSortColumns(String sortColumns)
{
if (sortColumns == null || "".equals(sortColumns.trim())) {
return;
}
if (sortColumns.contains(",")) {
String[] cols = sortColumns.split(",");
java.util.List<Field> fList = new java.util.ArrayList();
for (int k = 0; k < cols.length; k++) {
fList.add(Field.valueOf(cols[k]));
}
this.setSortColumns(fList.toArray(new Field[fList.size()]));
} else {
this.setSortColumns(Field.valueOf(sortColumns));
}
}
}

+ 0
- 17
mallinkService/src/main/java/com/simple/mapper/WxCouponVerifyMapper.java Просмотреть файл

@@ -1,17 +0,0 @@
package com.simple.mapper;

import java.util.*;
import com.simple.common.CommonMapper;
import org.apache.ibatis.annotations.Param;
import com.simple.domain.po.WxCouponVerify;

public interface WxCouponVerifyMapper extends CommonMapper<WxCouponVerify, String> {

List<WxCouponVerify> findList(WxCouponVerify wxCouponVerify);

}

+ 0
- 48
mallinkService/src/main/java/com/simple/service/WxCouponVerifyService.java Просмотреть файл

@@ -1,48 +0,0 @@
package com.simple.service;

import java.util.*;
import com.github.pagehelper.PageInfo;
import com.simple.domain.po.WxCouponVerify;

public interface WxCouponVerifyService {

/**
* 根据实体查询分页列表
*
* @param record
* @param offset
* @param limit
* @return
*/
PageInfo<WxCouponVerify> listAsPage(WxCouponVerify record, Integer pageIndex, Integer pageSize);
/**
* 根据Id获得实体
*
* @param id
* @return
*/
WxCouponVerify getById(Long id);
/**
* 保存或更新实体
*
* @param record
*/
void saveOrUpdate(WxCouponVerify record);

/**
* 根据Id删除实体
*
* @param id
*/
void deleteById(Long id);

}

+ 0
- 54
mallinkService/src/main/java/com/simple/service/impl/WxCouponVerifyServiceImpl.java Просмотреть файл

@@ -1,54 +0,0 @@
package com.simple.service.impl;

import java.util.*;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.simple.domain.po.WxCouponVerify;
import com.simple.mapper.WxCouponVerifyMapper;
import com.simple.service.WxCouponVerifyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.simple.common.IdWorker;

@Service
public class WxCouponVerifyServiceImpl implements WxCouponVerifyService {
@Autowired
WxCouponVerifyMapper wxCouponVerifyMapper;


@Override
public PageInfo<WxCouponVerify> listAsPage(WxCouponVerify record, Integer pageIndex, Integer pageSize) {
return PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxCouponVerifyMapper.findList(record));
}

@Override
public WxCouponVerify getById(Long id) {
return wxCouponVerifyMapper.selectByPrimaryKey(id);
}

@Override
public void saveOrUpdate(WxCouponVerify record) {
if (record.getId() == null) {
//record.setId(UUID.randomUUID().toString().replaceAll("-", ""));
final IdWorker idWorker = IdWorker.get();
record.setId(idWorker.nextId());
wxCouponVerifyMapper.insertSelective(record);
} else {
wxCouponVerifyMapper.updateByPrimaryKeySelective(record);
}
}

@Override
public void deleteById(Long id) {
wxCouponVerifyMapper.deleteByPrimaryKey(id);
}
}

+ 0
- 3
mallinkService/src/main/java/com/simple/service/impl/WxRefundOrderServiceImpl.java Просмотреть файл

@@ -41,9 +41,6 @@ public class WxRefundOrderServiceImpl implements WxRefundOrderService {
@Autowired
WxRefundOrderMapper wxRefundOrderMapper;

@Autowired
WxCouponVerifyMapper wxCouponVerifyMapper;

@Autowired
WxOrderMapper wxOrderMapper;



+ 0
- 98
mallinkService/src/main/resources/mapper/WxCouponVerifyMapper.xml Просмотреть файл

@@ -1,98 +0,0 @@
<?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.simple.mapper.WxCouponVerifyMapper">
<resultMap id="BaseResultMap" type="com.simple.domain.po.WxCouponVerify">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId" />
<result column="coupon_id" jdbcType="BIGINT" property="couponId" />
<result column="order_id" jdbcType="BIGINT" property="orderId" />
<result column="c_user_id" jdbcType="BIGINT" property="cUserId" />
<result column="buy_date" jdbcType="TIMESTAMP" property="buyDate" />
<result column="limit_date" jdbcType="TIMESTAMP" property="limitDate" />
<result column="c_status" jdbcType="INTEGER" property="cStatus" />
<result column="b_user_id" jdbcType="BIGINT" property="bUserId" />
<result column="verification_date" jdbcType="TIMESTAMP" property="verificationDate" />
<result column="verification_status" jdbcType="INTEGER" property="verificationStatus" />
</resultMap>
<sql id="allColumns">
`id`,`tenant_id`,`coupon_id`,`order_id`,`c_user_id`,`buy_date`,`limit_date`,`c_status`,`b_user_id`,`verification_date`,`verification_status`
</sql>

<sql id="dynamicWhereConditions">
where 1 = 1
<if test=" null != id ">
and `id` = #{id}
</if>
<if test=" null != tenantId ">
and `tenant_id` like concat('%', #{tenantId},'%')
</if>
<if test=" null != couponId ">
and `coupon_id` = #{couponId}
</if>
<if test=" null != orderId ">
and `order_id` = #{orderId}
</if>
<if test=" null != cUserId ">
and `c_user_id` = #{cUserId}
</if>
<if test=" null != buyDate ">
and `buy_date` = #{buyDate}
</if>
<if test=" null != limitDate ">
and `limit_date` = #{limitDate}
</if>
<if test=" null != cStatus ">
and `c_status` = #{cStatus}
</if>
<if test=" null != bUserId ">
and `b_user_id` = #{bUserId}
</if>
<if test=" null != verificationDate ">
and `verification_date` = #{verificationDate}
</if>
<if test=" null != verificationStatus ">
and `verification_status` = #{verificationStatus}
</if>
<if test=" null != ids ">
and id in
<foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
#{idItem}
</foreach>
</if>
<if test=" null != sortColumns"> order by ${sortColumns} </if>
</sql>
<select id="findList" parameterType="com.simple.domain.po.WxCouponVerify" resultMap="BaseResultMap">
select <include refid="allColumns" /> from wx_coupon_verify
<include refid="dynamicWhereConditions" />
</select>
</mapper>

Загрузка…
Отмена
Сохранить