提交 42527d26 作者: 张小凤

PackageName(update)

上级 4301216a
package com.mmc.oms.common;
import com.alibaba.fastjson.JSONArray;
import com.mmc.oms.common.json.JsonUtil;
import com.mmc.oms.jwt.JwtConstant;
import com.mmc.oms.model.dto.BaseAccountDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.stereotype.Component;
import org.springframework.util.CollectionUtils;
import org.springframework.util.StringUtils;
import java.util.*;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
import java.util.concurrent.TimeUnit;
/**
......@@ -73,7 +75,7 @@ public class AuthHandler {
String key = RedisConstant.getCompanyChildKey(companyId);
if (stringRedisTemplate.hasKey(key)) {
String json = stringRedisTemplate.opsForValue().get(key);
if(!StringUtils.isEmpty(json)) {
if (!StringUtils.isEmpty(json)) {
List<Integer> list = JSONArray.parseArray(json, Integer.class);
return list;
}
......
package com.mmc.oms.common;
/**
* @Author small
* @Date 2023/5/24 14:03
* @Version 1.0
*/
public class CouponConstants {
/**
* --------优惠券常量------------
*/
/** 优惠券类型—打折券 */
public static final Integer COUPON_TYPE_DISCOUNT = 1;
/** 优惠券类型—减免券 */
public static final Integer COUPON_TYPE_REDUCED = 2;
/** 优惠券类型—无门槛 */
public static final Integer COUPON_TYPE_NO_THRESHOLD = 3;
/** 优惠券使用类型—vip */
public static final Integer COUPON_USR_TYPE_VIP = 1;
/** 优惠券使用类型—品牌券 */
public static final Integer COUPON_USR_TYPE_BRAND = 2;
/** 优惠券有效期时间方式-固定时间 */
public static final Integer COUPON_USE_TIME_FIXED = 0;
/** 优惠券有效期时间方式-领取当日起 */
public static final Integer COUPON_USE_TIME_THE_DAY = 1;
/** 优惠券有效期时间方式-领取次日起 */
public static final Integer COUPON_USE_TIME_NEXT_DAY = 2;
/** 优惠券发放方式—手动领取 */
public static final Integer COUPON_ISSUE_TYPE_RECEIVE = 1;
/** 优惠券发放方式—系统发放 */
public static final Integer COUPON_ISSUE_TYPE_INITIATIVE =2;
/** 优惠券发放方式—批量导入用户 */
public static final Integer COUPON_ISSUE_TYPE_IMPORT = 3;
/** 优惠券使用类型—活动裂变券 */
public static final Integer COUPON_USR_TYPE_ACTIVITY = 4;
/** 用户标签-新人 */
public static final Integer USER_LABEL_NEW_PEOPLE = 1;
/** 用户标签-实名认证 */
public static final Integer USER_LABEL_REAL_NAME_AUTHENTICATION = 2;
/** 用户标签-企业认证 */
public static final Integer USER_LABEL_ENTERPRISE_CERTIFICATION = 3;
/**
* --------用户优惠券常量----------------
*/
/** 用户优惠券获取方式—用户领取 */
public static final String STORE_COUPON_USER_TYPE_GET = "receive";
/** 用户优惠券获取方式—后台发放 */
public static final String STORE_COUPON_USER_TYPE_SEND = "send";
/** 用户优惠券获取方式—赠送 */
public static final String STORE_COUPON_USER_TYPE_PRESENTED = "presented";
/** 用户优惠券获取方式—获赠 */
public static final String STORE_COUPON_USER_TYPE_ACQUIRE = "acquire";
/** 用户优惠券获取方式—兑换 */
public static final String STORE_COUPON_USER_TYPE_EXCHANGE = "exchange";
/** 用户优惠券获取方式—活动领取 */
public static final String STORE_COUPON_USER_TYPE_ACTIVITY = "activity";
/** 用户优惠券状态—未使用 */
public static final Integer STORE_COUPON_USER_STATUS_USABLE = 0;
/** 用户优惠券状态—已使用 */
public static final Integer STORE_COUPON_USER_STATUS_USED = 1;
/** 用户优惠券状态—已失效 */
public static final Integer STORE_COUPON_USER_STATUS_LAPSED = 2;
/** 用户优惠券状态—已转赠 */
public static final Integer STORE_COUPON_USER_STATUS_PRESENTED = 3;
/** 用户优惠券状态—使用中 */
public static final Integer STORE_COUPON_USER_STATUS_IN_USE = 4;
}
......@@ -401,7 +401,8 @@ public enum ResultEnum implements BaseErrorInfoInterface {
REFUND_FAILED("2015", "退款失败,请联系客服"),
NO_PERMISSION_TEMPORARILY("2016", "当前账号没有权限,只有后台账号拥有权限"),
THERE_IS_NO_SUCH_ORDER("2017", "没有当前订单,请输入正确的订单编号"),
THE_TOKEN_CANNOT_BE_NULL("2018", "token不能为null");
THE_TOKEN_CANNOT_BE_NULL("2018", "token不能为null"),
THE_CURRENT_ACCOUNT_CANNOT_PLACE_ORDERS("2019", "后台管理账号不能下单");
/**
* 错误码
......
package com.mmc.oms.common.coupon;
/**
* @Author small
* @Date 2023/5/24 14:03
* @Version 1.0
*/
public class CouponConstants {
/**
* --------优惠券常量------------
*/
/**
* 优惠券类型—打折券
*/
public static final Integer COUPON_TYPE_DISCOUNT = 1;
/**
* 优惠券类型—减免券
*/
public static final Integer COUPON_TYPE_REDUCED = 2;
/**
* 优惠券类型—无门槛
*/
public static final Integer COUPON_TYPE_NO_THRESHOLD = 3;
/**
* 优惠券使用类型—vip
*/
public static final Integer COUPON_USR_TYPE_VIP = 1;
/**
* 优惠券使用类型—品牌券
*/
public static final Integer COUPON_USR_TYPE_BRAND = 2;
/**
* 优惠券有效期时间方式-固定时间
*/
public static final Integer COUPON_USE_TIME_FIXED = 0;
/**
* 优惠券有效期时间方式-领取当日起
*/
public static final Integer COUPON_USE_TIME_THE_DAY = 1;
/**
* 优惠券有效期时间方式-领取次日起
*/
public static final Integer COUPON_USE_TIME_NEXT_DAY = 2;
/**
* 优惠券发放方式—手动领取
*/
public static final Integer COUPON_ISSUE_TYPE_RECEIVE = 1;
/**
* 优惠券发放方式—系统发放
*/
public static final Integer COUPON_ISSUE_TYPE_INITIATIVE = 2;
/**
* 优惠券发放方式—批量导入用户
*/
public static final Integer COUPON_ISSUE_TYPE_IMPORT = 3;
/**
* 优惠券使用类型—活动裂变券
*/
public static final Integer COUPON_USR_TYPE_ACTIVITY = 4;
/**
* 用户标签-新人
*/
public static final Integer USER_LABEL_NEW_PEOPLE = 1;
/**
* 用户标签-实名认证
*/
public static final Integer USER_LABEL_REAL_NAME_AUTHENTICATION = 2;
/**
* 用户标签-企业认证
*/
public static final Integer USER_LABEL_ENTERPRISE_CERTIFICATION = 3;
/**
* --------用户优惠券常量----------------
*/
/**
* 用户优惠券获取方式—用户领取
*/
public static final String STORE_COUPON_USER_TYPE_GET = "receive";
/**
* 用户优惠券获取方式—后台发放
*/
public static final String STORE_COUPON_USER_TYPE_SEND = "send";
/**
* 用户优惠券获取方式—赠送
*/
public static final String STORE_COUPON_USER_TYPE_PRESENTED = "presented";
/**
* 用户优惠券获取方式—获赠
*/
public static final String STORE_COUPON_USER_TYPE_ACQUIRE = "acquire";
/**
* 用户优惠券获取方式—兑换
*/
public static final String STORE_COUPON_USER_TYPE_EXCHANGE = "exchange";
/**
* 用户优惠券获取方式—活动领取
*/
public static final String STORE_COUPON_USER_TYPE_ACTIVITY = "activity";
/**
* 用户优惠券状态—未使用
*/
public static final Integer STORE_COUPON_USER_STATUS_USABLE = 0;
/**
* 用户优惠券状态—已使用
*/
public static final Integer STORE_COUPON_USER_STATUS_USED = 1;
/**
* 用户优惠券状态—已失效
*/
public static final Integer STORE_COUPON_USER_STATUS_LAPSED = 2;
/**
* 用户优惠券状态—已转赠
*/
public static final Integer STORE_COUPON_USER_STATUS_PRESENTED = 3;
/**
* 用户优惠券状态—使用中
*/
public static final Integer STORE_COUPON_USER_STATUS_IN_USE = 4;
}
package com.mmc.oms.common;
package com.mmc.oms.common.coupon;
/**
* @Author small
......@@ -7,9 +7,9 @@ package com.mmc.oms.common;
*/
public interface CouponType {
//打折券
public static final Integer DISCOUNT_COUPONS=1;
public static final Integer DISCOUNT_COUPONS = 1;
//减免卷
public static final Integer REDUCTION_ROLLS=2;
public static final Integer REDUCTION_ROLLS = 2;
//无门槛
public static final Integer NO_THRESHOLD=3;
public static final Integer NO_THRESHOLD = 3;
}
package com.mmc.oms.common;
package com.mmc.oms.common.coupon;
import cn.afterturn.easypoi.excel.annotation.Excel;
import cn.afterturn.easypoi.excel.annotation.ExcelTarget;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
......@@ -23,7 +22,7 @@ import java.util.Date;
@ExcelTarget("couponUserExcel")
public class CouponUserExcel implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@Excel(name = "优惠券id", orderNum = "1", width = 25)
private Integer couponId;
......
package com.mmc.oms.common;
package com.mmc.oms.common.json;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray;
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
import com.mmc.oms.model.dto.OrderInfoDTO;
import com.mmc.oms.model.dto.order.OrderInfoDTO;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Component;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.publicinterface;
/**
* @Author small
......
package com.mmc.oms.common;
package com.mmc.oms.common.result;
import com.mmc.oms.model.qo.BaseInfoQO;
import io.swagger.annotations.ApiModelProperty;
......
package com.mmc.oms.common;
package com.mmc.oms.common.result;
import com.alibaba.fastjson.JSONObject;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.BaseErrorInfoInterface;
import com.mmc.oms.common.ResultEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -71,9 +72,8 @@ public class ResultBody<T> implements Serializable {
/**
* 成功
*
* **/
public static ResultBody success1(ResultEnum enums){
**/
public static ResultBody success1(ResultEnum enums) {
ResultBody rb = new ResultBody();
rb.setCode("200");
rb.setMessage(enums.getResultMsg());
......
package com.mmc.oms.common;
package com.mmc.oms.common.status;
/**
* @Author small
......@@ -21,9 +21,7 @@ public enum TranStatusDic {
TKSQ("700", "退款申请中", "待退款完成"),
CLOSE("999", "订单关闭", "订单关闭")
;
CLOSE("999", "订单关闭", "订单关闭");
private String status;
private String waiting;
......
package com.mmc.oms.common;
package com.mmc.oms.common.util;
import java.util.Random;
......
package com.mmc.oms.common;
package com.mmc.oms.common.util;
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
......@@ -25,7 +25,7 @@ public class KdnExpressUtil {
// 请求url, 正式环境地址
private static String ReqURL = "https://api.kdniao.com/Ebusiness/EbusinessOrderHandle.aspx";
//订阅推送请求url, 正式环境地址
private static String KdApiSearchMonitorPushReqURL="https://api.kdniao.com/api/dist";
private static String KdApiSearchMonitorPushReqURL = "https://api.kdniao.com/api/dist";
public static void main(String[] args) {
try {
......@@ -104,6 +104,7 @@ public class KdnExpressUtil {
/**
* 物流跟踪接口(增值版)
*
* @param callbackTag-表示端口及订单:端口/订单号
* @param shipperCode-快递公司编码
* @param logisticCode-快递编号
......@@ -111,24 +112,24 @@ public class KdnExpressUtil {
* @return
* @throws Exception
*/
public static String kdApiSearchMonitorPush(String callbackTag, String shipperCode, String logisticCode, String customerName) throws Exception{
public static String kdApiSearchMonitorPush(String callbackTag, String shipperCode, String logisticCode, String customerName) throws Exception {
// 组装应用级参数
String RequestData= "{"+
"'Callback':'"+callbackTag+"',"+
"'ShipperCode':'"+shipperCode+"',"+
"'LogisticCode':'"+logisticCode+"',"+
"'CustomerName':'"+customerName+"',"+
String RequestData = "{" +
"'Callback':'" + callbackTag + "'," +
"'ShipperCode':'" + shipperCode + "'," +
"'LogisticCode':'" + logisticCode + "'," +
"'CustomerName':'" + customerName + "'," +
"}";
// 组装系统级参数
Map<String,String> params = new HashMap<String,String>();
Map<String, String> params = new HashMap<String, String>();
params.put("RequestData", urlEncoder(RequestData, "UTF-8"));
params.put("EBusinessID", EBusinessID);
params.put("RequestType", "8005");//在途监控订阅接口指令8008/地图版订阅接口指令8005
String dataSign=encrypt(RequestData, ApiKey, "UTF-8");
String dataSign = encrypt(RequestData, ApiKey, "UTF-8");
params.put("DataSign", urlEncoder(dataSign, "UTF-8"));
params.put("DataType", "2");
// 以form表单形式提交post请求,post请求体中包含了应用级参数和系统级参数
String result=sendPost(KdApiSearchMonitorPushReqURL, params);
String result = sendPost(KdApiSearchMonitorPushReqURL, params);
//根据公司业务处理返回的信息......
return result;
......@@ -174,8 +175,8 @@ public class KdnExpressUtil {
/**
* 电商Sign签名生成 content 内容 keyValue ApiKey charset 编码方式
*
* @throws UnsupportedEncodingException ,Exception
* @return DataSign签名
* @throws UnsupportedEncodingException ,Exception
*/
@SuppressWarnings("unused")
private static String encrypt(String content, String keyValue, String charset)
......
package com.mmc.oms.common;
package com.mmc.oms.common.util;
import java.text.ParseException;
import java.text.SimpleDateFormat;
......@@ -160,17 +160,18 @@ public class TDateUtil {
/**
* 某天个时间加 N 小时
*
* @param now
* @param num
* @return
*/
public static Date addHourTime(Date now,int num){
public static Date addHourTime(Date now, int num) {
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Date date = null;
try {
Calendar calendar = Calendar.getInstance();
calendar.setTime(now);
calendar.add(Calendar.HOUR,num);
calendar.add(Calendar.HOUR, num);
String last = format.format(calendar.getTime());
date = getDate(last, "yyyy-MM-dd HH:mm:ss");
} catch (Exception e) {
......@@ -480,7 +481,7 @@ public class TDateUtil {
*/
public static Date getLastYearTodayDate() {
Calendar instance = Calendar.getInstance();
instance.add(Calendar.YEAR,-1);
instance.add(Calendar.YEAR, -1);
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
String s = format.format(instance.getTime());
return getDate(s, "yyyy-MM-dd");
......@@ -488,12 +489,13 @@ public class TDateUtil {
/**
* 获取昨天的日期
*
* @param type
* @return
*/
public static String getYesterdayDateByType(String type){
public static String getYesterdayDateByType(String type) {
Calendar instance = Calendar.getInstance();
instance.add(Calendar.DAY_OF_MONTH,-1);
instance.add(Calendar.DAY_OF_MONTH, -1);
Date time = instance.getTime();
SimpleDateFormat format = new SimpleDateFormat(type);
return format.format(time);
......@@ -517,49 +519,51 @@ public class TDateUtil {
/**
* 间隔天数
*
* @param startTime
* @param endTime
* @return
*/
public static int isolateDayNum(String startTime, String endTime){
public static int isolateDayNum(String startTime, String endTime) {
Date startDate = getDate(startTime, "yyyy-MM-dd");
Date endDate = getDate(endTime, "yyyy-MM-dd");
long differentMillis = endDate.getTime() - startDate.getTime();
long dayNum = differentMillis/(1000*60*60*24);
return (int)dayNum;
long dayNum = differentMillis / (1000 * 60 * 60 * 24);
return (int) dayNum;
}
/**
* 获取某月最后一天的时间
*
* @param yearMonth
* @return
*/
public static String getLastDateTimeOfMonth(String yearMonth){
public static String getLastDateTimeOfMonth(String yearMonth) {
SimpleDateFormat format0 = new SimpleDateFormat("yyyy-MM");
SimpleDateFormat format1 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Calendar instance = Calendar.getInstance();
try {
Date parse = format0.parse(yearMonth);
instance.setTime(parse);
instance.set(Calendar.DAY_OF_MONTH, instance.getActualMaximum(Calendar.DAY_OF_MONTH));
instance.set(Calendar.DAY_OF_MONTH, instance.getActualMaximum(Calendar.DAY_OF_MONTH));
instance.set(Calendar.HOUR_OF_DAY, 23);
instance.set(Calendar.MINUTE, 59);
instance.set(Calendar.SECOND, 59);
String format = format1.format(instance.getTime());
return format;
} catch (Exception e){
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
public static Date getStrToDate(String str){
public static Date getStrToDate(String str) {
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy年MM月dd日");
Date date = null;
try {
if (str==null){
if (str == null) {
date = null;
}else {
} else {
date = dateFormat.parse(str);
}
} catch (ParseException e) {
......@@ -568,7 +572,7 @@ public class TDateUtil {
return date;
}
public static int getStageByDate(Date date){
public static int getStageByDate(Date date) {
Calendar instance = Calendar.getInstance();
instance.setTime(date);
//当前时间
......@@ -584,22 +588,22 @@ public class TDateUtil {
Date parse4 = dateFormat.parse("00:00:00");
//A:05:00-11:00 | B:11:00-17:00 | C:00:00-05:00,17:00-00:00
if (currentTime.after(parse4) && currentTime.before(parse1) ) {
if (currentTime.after(parse4) && currentTime.before(parse1)) {
return 3;
}else if (currentTime.after(parse1) && currentTime.before(parse2)) {
} else if (currentTime.after(parse1) && currentTime.before(parse2)) {
return 1;
}else if(currentTime.after(parse2) && currentTime.before(parse3)){
} else if (currentTime.after(parse2) && currentTime.before(parse3)) {
return 2;
}else if(currentTime.after(parse3) && currentTime.after(parse4)){
} else if (currentTime.after(parse3) && currentTime.after(parse4)) {
return 4;
}
}catch (Exception e){
} catch (Exception e) {
e.printStackTrace();
}
return 0;
}
public static String getCurrentYear(){
public static String getCurrentYear() {
Calendar date = Calendar.getInstance();
String year = String.valueOf(date.get(Calendar.YEAR));
return year;
......
......@@ -5,8 +5,8 @@ import com.mmc.oms.common.AuthHandler;
import com.mmc.oms.common.BizException;
import com.mmc.oms.common.ResultEnum;
import com.mmc.oms.jwt.JwtConstant;
import com.mmc.oms.model.dto.BaseAccountDTO;
import com.mmc.oms.model.dto.CurrentUserDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.dto.user.CurrentUserDTO;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.StringRedisTemplate;
......@@ -25,6 +25,7 @@ public abstract class BaseController {
@Autowired
private StringRedisTemplate stringRedisTemplate;
/**
* 获取当前用户
*
......@@ -44,10 +45,10 @@ public abstract class BaseController {
public BaseAccountDTO getCurrentAccount(HttpServletRequest request) {
String token = request.getHeader("token");
String json = stringRedisTemplate.opsForValue().get(token);
if (StringUtils.isBlank(json)){
if (StringUtils.isBlank(json)) {
throw new BizException(ResultEnum.LOGIN_ACCOUNT_STATUS_ERROR);
}
BaseAccountDTO baseAccountDTO= JSONObject.parseObject(json, BaseAccountDTO.class);
BaseAccountDTO baseAccountDTO = JSONObject.parseObject(json, BaseAccountDTO.class);
return baseAccountDTO;
}
......
package com.mmc.oms.controller;
import com.mmc.oms.common.*;
import com.mmc.oms.model.dto.CouponActivityDTO;
import com.mmc.oms.model.dto.CouponDTO;
import com.mmc.oms.model.dto.CouponUserDTO;
import com.mmc.oms.model.dto.CouponViewDTO;
import com.mmc.oms.common.publicinterface.*;
import com.mmc.oms.common.result.PageResult;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.dto.coupon.CouponActivityDTO;
import com.mmc.oms.model.dto.coupon.CouponDTO;
import com.mmc.oms.model.dto.coupon.CouponUserDTO;
import com.mmc.oms.model.dto.coupon.CouponViewDTO;
import com.mmc.oms.model.qo.CouponInfoQO;
import com.mmc.oms.model.qo.CouponUserInfoQO;
import com.mmc.oms.model.qo.ProductCouponQO;
import com.mmc.oms.model.vo.CouponInfoActivityVO;
import com.mmc.oms.model.vo.CouponInfoVO;
import com.mmc.oms.model.vo.coupon.CouponInfoActivityVO;
import com.mmc.oms.model.vo.coupon.CouponInfoVO;
import com.mmc.oms.service.CouponBackService;
import io.swagger.annotations.*;
import org.springframework.validation.annotation.Validated;
......@@ -36,17 +38,17 @@ public class CouponBackController {
@ApiOperation(value = "V1.0.1--新增优惠券")
@ApiResponses({ @ApiResponse(code = 200, message = "OK", response = CouponDTO.class)})
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponDTO.class)})
@PostMapping("/save")
public ResultBody<CouponDTO> saveCouponInfo(@RequestParam(value = "file",required = false) MultipartFile file
, @RequestBody CouponInfoVO couponInfoVO){
return couponBackService.saveCouponBackInfo(couponInfoVO,file);
public ResultBody<CouponDTO> saveCouponInfo(@RequestParam(value = "file", required = false) MultipartFile file
, @RequestBody CouponInfoVO couponInfoVO) {
return couponBackService.saveCouponBackInfo(couponInfoVO, file);
}
@ApiOperation(value = "V1.0.1--新增裂变优惠券")
@ApiResponses({ @ApiResponse(code = 200, message = "OK")})
@ApiResponses({@ApiResponse(code = 200, message = "OK")})
@PostMapping("/saveActivity")
public ResultBody saveActivityCouponInfo(@Validated(Insert.class) @RequestBody CouponInfoActivityVO couponInfoActivityVO){
public ResultBody saveActivityCouponInfo(@Validated(Insert.class) @RequestBody CouponInfoActivityVO couponInfoActivityVO) {
return couponBackService.saveActivityCouponInfo(couponInfoActivityVO);
}
......@@ -70,7 +72,7 @@ public class CouponBackController {
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponActivityDTO.class)})
@GetMapping("/getActivityCouponPullDown")
public ResultBody<CouponActivityDTO> getActivityCouponPullDown(@ApiParam(value = "活动类型: 1裂变活动 2普通活动", required = true)
@RequestParam(required = true, value = "type") Integer type) {
@RequestParam(required = true, value = "type") Integer type) {
return couponBackService.getActivityCouponPullDown(type);
}
......@@ -81,7 +83,7 @@ public class CouponBackController {
@ApiParam(value = "id", required = true)
@RequestParam(required = true, value = "id") Integer id,
@ApiParam(value = "数量", required = true)
@RequestParam(required = true, value = "count") Integer count){
@RequestParam(required = true, value = "count") Integer count) {
return couponBackService.increaseCouponCount(id, count);
}
......@@ -90,24 +92,24 @@ public class CouponBackController {
@PostMapping("/shutDown")
public ResultBody shutDown(@Validated(Update.class)
@ApiParam(value = "id", required = true)
@RequestParam(required = true, value = "id") Integer id){
@RequestParam(required = true, value = "id") Integer id) {
return couponBackService.shutDown(id);
}
@ApiOperation(value = "V1.0.1--获取优惠券使用数据")
@ApiResponses({@ApiResponse(code = 200, message = "OK",response = CouponViewDTO.class)})
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponViewDTO.class)})
@GetMapping("/getData")
public ResultBody<CouponViewDTO> getViewData(@Validated(Query.class)
@ApiParam(value = "id", required = true)
@RequestParam(required = true, value = "id") Integer id){
@ApiParam(value = "id", required = true)
@RequestParam(required = true, value = "id") Integer id) {
return couponBackService.couponViewData(id);
}
@ApiOperation(value = "V1.0.1--获取优惠券明细列表")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponUserDTO.class)})
@PostMapping("/getUserCouponList")
public ResultBody<CouponUserDTO> getCouponUserList(@Validated(Page.class) @RequestBody CouponUserInfoQO couponUserInfoQO){
public ResultBody<CouponUserDTO> getCouponUserList(@Validated(Page.class) @RequestBody CouponUserInfoQO couponUserInfoQO) {
return couponBackService.getCouponUserList(couponUserInfoQO);
}
......@@ -115,59 +117,60 @@ public class CouponBackController {
@ApiResponses({@ApiResponse(code = 200, message = "OK")})
@PostMapping("/downloadCouponUserList")
public void downloadCouponUserList(@Validated(value = {Others.class}) @RequestBody CouponUserInfoQO couponUserInfoQO,
HttpServletResponse response){
HttpServletResponse response) {
try {
couponBackService.downloadCouponUserList(response,couponUserInfoQO);
couponBackService.downloadCouponUserList(response, couponUserInfoQO);
} catch (IOException e) {
e.printStackTrace();
}
}
@ApiOperation(value = "feign-获取优惠券详情",hidden = true)
@ApiOperation(value = "feign-获取优惠券详情", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponDTO.class)})
@GetMapping("/feignByIds")
public List<CouponDTO> feignByIds(@RequestParam List<Integer> ids){
public List<CouponDTO> feignByIds(@RequestParam List<Integer> ids) {
return couponBackService.feignByIds(ids);
}
@ApiOperation(value = "feign-获取裂变优惠券详情",hidden = true)
@ApiOperation(value = "feign-获取裂变优惠券详情", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponActivityDTO.class)})
@GetMapping("/feignGetActivity")
public CouponActivityDTO feignGetCouponActivityById(@RequestParam Integer id) {
return couponBackService.getCouponActivityById(id);
}
@ApiOperation(value = "feign-获取裂变优惠券详情-批量",hidden = true)
@ApiOperation(value = "feign-获取裂变优惠券详情-批量", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponActivityDTO.class)})
@PostMapping("/feignGetActivityList")
public List<CouponActivityDTO> feignGetCouponActivityByList(@RequestBody List<Integer> id) {
return couponBackService.getCouponActivityList(id);
}
@ApiOperation(value = "feign-优惠券定时修改状态",hidden = true)
@ApiOperation(value = "feign-优惠券定时修改状态", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK")})
@GetMapping("/feignExpireCoupon")
public void feignExpireCoupon() {
couponBackService.overdueCouponTask();
}
@ApiOperation(value = "feign-根据用户标签获取对应优惠券",hidden = true)
@ApiOperation(value = "feign-根据用户标签获取对应优惠券", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponDTO.class)})
@GetMapping("/feignGetCouponType")
public List<CouponDTO> feignGetCouponType(@RequestParam Integer type) {
public List<CouponDTO> feignGetCouponType(@RequestParam Integer type) {
return couponBackService.feignGetCouponType(type);
}
@ApiOperation(value = "V2.3.2——商品优惠券普通活动列表")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponDTO.class)})
@PostMapping("/ordinaryActivities")
public ResultBody<PageResult<CouponDTO>> ordinaryActivities(@Validated(Page.class) @RequestBody ProductCouponQO productCouponQO) {
public ResultBody<PageResult<CouponDTO>> ordinaryActivities(@Validated(Page.class) @RequestBody ProductCouponQO productCouponQO) {
return couponBackService.ordinaryActivities(productCouponQO);
}
@ApiOperation(value = "V2.3.2——商品优惠券裂变活动列表")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponDTO.class)})
@PostMapping("/fissionActivity")
public ResultBody<PageResult<PageResult>> fissionActivity(@Validated(Page.class) @RequestBody ProductCouponQO productCouponQO) {
public ResultBody<PageResult<PageResult>> fissionActivity(@Validated(Page.class) @RequestBody ProductCouponQO productCouponQO) {
return couponBackService.fissionActivity(productCouponQO);
}
}
package com.mmc.oms.controller;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.common.Update;
import com.mmc.oms.model.dto.*;
import com.mmc.oms.model.vo.CouponUserExchangeVO;
import com.mmc.oms.model.vo.CouponUserVO;
import com.mmc.oms.common.publicinterface.Update;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.dto.coupon.CouponListDTO;
import com.mmc.oms.model.dto.coupon.CouponUsageDetailsDTO;
import com.mmc.oms.model.dto.coupon.CouponUserDTO;
import com.mmc.oms.model.dto.coupon.CouponUserOrderDTO;
import com.mmc.oms.model.dto.goods.AppGoodsInfoDTO;
import com.mmc.oms.model.dto.order.OrderCouponDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.vo.coupon.CouponUserExchangeVO;
import com.mmc.oms.model.vo.coupon.CouponUserVO;
import com.mmc.oms.service.CouponUserService;
import io.swagger.annotations.*;
import org.springframework.validation.annotation.Validated;
......@@ -33,7 +39,7 @@ public class CouponUserController extends BaseController {
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponUserDTO.class)})
@GetMapping("/checkMyCoupon")
public ResultBody getMyCoupon(@ApiParam(value = "状态 1:已使用, 2:已失效,3:已转赠")
@RequestParam(value = "status",required = false) Integer status,
@RequestParam(value = "status", required = false) Integer status,
@ApiParam(value = "页码", required = true)
@RequestParam(value = "pageNo") Integer pageNo,
@ApiParam(value = "每页显示数", required = true)
......@@ -62,7 +68,7 @@ public class CouponUserController extends BaseController {
@ApiParam(value = "用户uid", required = true)
@RequestParam(value = "uid") String uid,
HttpServletRequest request) {
return couponUserService.presentedCoupon(id, uid,this.getCurrentAccount(request));
return couponUserService.presentedCoupon(id, uid, this.getCurrentAccount(request));
}
......@@ -80,14 +86,14 @@ public class CouponUserController extends BaseController {
}
@ApiOperation(value = "feign-根据订单品牌获取可用优惠券",hidden = true)
@ApiOperation(value = "feign-根据订单品牌获取可用优惠券", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponUserOrderDTO.class)})
@GetMapping("/feignCoupons")
public List<CouponUserOrderDTO> couponByOrder(@ApiParam(value = "品牌id 搜索品牌指定优惠卷", required = true)
@RequestParam(value = "primaryKey") List<Integer> primaryKey,
@ApiParam(value = "用户id", required = true)
@RequestParam Integer uid) {
return couponUserService.getUsableCoupon(primaryKey,uid);
return couponUserService.getUsableCoupon(primaryKey, uid);
}
......@@ -113,7 +119,7 @@ public class CouponUserController extends BaseController {
return couponUserService.feignExchangeCoupon(couponUserExchangeVO);
}
@ApiOperation(value = "feign-领取优惠券",hidden = true)
@ApiOperation(value = "feign-领取优惠券", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK")})
@GetMapping("/feignReceive")
public ResultBody feignReceive(@ApiParam(value = "优惠券id", required = true)
......@@ -128,7 +134,7 @@ public class CouponUserController extends BaseController {
return couponUserService.receiveCoupon(id, countDTO);
}
@ApiOperation(value = "feign-根据优惠券id查询优惠券",hidden = true)
@ApiOperation(value = "feign-根据优惠券id查询优惠券", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK")})
@PostMapping("/feignListUserCouponsByIds")
@ApiIgnore
......@@ -144,14 +150,14 @@ public class CouponUserController extends BaseController {
return couponUserService.feignOrderCoupon(orderId);
}
@ApiOperation(value = "feign-优惠券定时过期",hidden = true)
@ApiOperation(value = "feign-优惠券定时过期", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK")})
@GetMapping("/feignExpire")
public void feignExpire() {
couponUserService.overdueTask();
}
@ApiOperation(value = "feign-优惠券回退",hidden = true)
@ApiOperation(value = "feign-优惠券回退", hidden = true)
@ApiResponses({@ApiResponse(code = 200, message = "OK")})
@PostMapping("/feignRollbackCoupons")
public Boolean feignRollbackCoupons(@RequestBody List<OrderCouponDTO> orderCouponDTOS) {
......@@ -181,10 +187,10 @@ public class CouponUserController extends BaseController {
@ApiImplicitParam(name = "useType", required = false, value = "1vip券, 2品牌券"),
})
@GetMapping("/couponMerchandise")
public ResultBody couponMerchandise(@RequestParam(value = "couponId",required = false) Integer couponId,
@RequestParam(value = "productName",required = false) String productName,
@RequestParam(value = "useType",required = false) Integer useType) {
return couponUserService.couponMerchandise(couponId,productName,useType);
public ResultBody couponMerchandise(@RequestParam(value = "couponId", required = false) Integer couponId,
@RequestParam(value = "productName", required = false) String productName,
@RequestParam(value = "useType", required = false) Integer useType) {
return couponUserService.couponMerchandise(couponId, productName, useType);
}
@ApiOperation(value = "V2.3.2-优惠券使用明细 ")
......@@ -193,7 +199,7 @@ public class CouponUserController extends BaseController {
})
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = CouponUsageDetailsDTO.class)})
@GetMapping("/couponUsageDetails")
public ResultBody couponUsageDetails(@RequestParam(value = "uid",required = true) Integer uid) {
public ResultBody couponUsageDetails(@RequestParam(value = "uid", required = true) Integer uid) {
return couponUserService.couponUsageDetails(uid);
}
......
package com.mmc.oms.controller;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.model.dto.*;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.dto.kdn.KdnDicDTO;
import com.mmc.oms.model.dto.order.ExpressInfoDTO;
import com.mmc.oms.model.dto.order.OrderInfoDTO;
import com.mmc.oms.model.dto.order.OrderReceiptDTO;
import com.mmc.oms.model.dto.transtatus.TranStatusDicDTO;
import com.mmc.oms.service.OrderLogisticsService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
......
package com.mmc.oms.controller;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.model.vo.OrderRefundVO;
import com.mmc.oms.model.vo.RefundYesOrNoVO;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.vo.order.OrderRefundVO;
import com.mmc.oms.model.vo.order.RefundYesOrNoVO;
import com.mmc.oms.service.OrderRefundService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
......
package com.mmc.oms.controller;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.common.Send;
import com.mmc.oms.common.Take;
import com.mmc.oms.model.dto.OrderInfoDTO;
import com.mmc.oms.common.publicinterface.Send;
import com.mmc.oms.common.publicinterface.Take;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.dto.order.OrderInfoDTO;
import com.mmc.oms.model.qo.OrderInfoQO;
import com.mmc.oms.model.vo.LeaseOrderVO;
import com.mmc.oms.model.vo.OrderStatusVO;
import com.mmc.oms.model.vo.OrderVcuVO;
import com.mmc.oms.model.vo.ReturnWareVO;
import com.mmc.oms.model.vo.order.LeaseOrderVO;
import com.mmc.oms.model.vo.order.OrderStatusVO;
import com.mmc.oms.model.vo.order.OrderVcuVO;
import com.mmc.oms.model.vo.order.ReturnWareVO;
import com.mmc.oms.service.RentalOrdersService;
import io.swagger.annotations.*;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -31,7 +31,7 @@ public class RentalOrdersController extends BaseController {
@ApiOperation(value = "租赁-下单")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = OrderInfoDTO.class)})
@PostMapping("feignAddLease")
public OrderInfoDTO feignAddLease(HttpServletRequest request, @RequestBody LeaseOrderVO param) {
public ResultBody<OrderInfoDTO> feignAddLease(HttpServletRequest request, @RequestBody LeaseOrderVO param) {
return rentalOrdersService.feignAddLease(this.getCurrentAccount(request), param);
}
......
package com.mmc.oms.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.mmc.oms.entity.CouponDO;
import com.mmc.oms.entity.ProductInformationDo;
import com.mmc.oms.entity.coupon.CouponDO;
import com.mmc.oms.entity.order.ProductInformationDo;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
......
package com.mmc.oms.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.mmc.oms.entity.CouponUsageDetailsDO;
import com.mmc.oms.entity.CouponUserDO;
import com.mmc.oms.entity.GoodsInfoDO;
import com.mmc.oms.model.dto.CouponUserDTO;
import com.mmc.oms.entity.coupon.CouponUsageDetailsDO;
import com.mmc.oms.entity.coupon.CouponUserDO;
import com.mmc.oms.entity.goods.GoodsInfoDO;
import com.mmc.oms.model.dto.coupon.CouponUserDTO;
import com.mmc.oms.model.qo.CouponUserInfoQO;
import com.mmc.oms.model.vo.CouponUserVO;
import com.mmc.oms.model.vo.coupon.CouponUserVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
......@@ -35,7 +35,7 @@ public interface CouponUserDao extends BaseMapper<CouponUserDO> {
List<Integer> merchandise(Integer couponId);
List<GoodsInfoDO> couponMerchandise(List<Integer> merchandise,String productName);
List<GoodsInfoDO> couponMerchandise(List<Integer> merchandise, String productName);
List<CouponUsageDetailsDO> couponUsageDetails(Integer uid);
......
package com.mmc.oms.dao;
import com.mmc.oms.entity.*;
import com.mmc.oms.entity.order.*;
import com.mmc.oms.entity.transtatus.TranStatusDicDO;
import com.mmc.oms.model.qo.OrderInfoQO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
......@@ -46,7 +47,7 @@ public interface OrderLogisticsDao {
List<OrderInfoDO> listPcOrderInfo(OrderInfoQO param);
int countOrderInfo(String tranStatus,List<Integer> companys);
int countOrderInfo(String tranStatus, List<Integer> companys);
List<ExpressInfoDO> listExpressInfo();
......@@ -68,5 +69,5 @@ public interface OrderLogisticsDao {
Integer getOrderInfoCountToYesterday(@Param("day") Integer day, @Param("date") Date date);
Integer getOrderInfoCount(@Param("day") Integer day,@Param("date")Date date);
Integer getOrderInfoCount(@Param("day") Integer day, @Param("date") Date date);
}
package com.mmc.oms.dao;
import com.mmc.oms.entity.OrderRefundDO;
import com.mmc.oms.entity.OrderVcuDO;
import com.mmc.oms.entity.order.OrderRefundDO;
import com.mmc.oms.entity.order.OrderVcuDO;
import org.apache.ibatis.annotations.Mapper;
/**
......
package com.mmc.oms.dao;
import com.mmc.oms.entity.*;
import com.mmc.oms.entity.coupon.CouponDO;
import com.mmc.oms.entity.coupon.CouponUserDO;
import com.mmc.oms.entity.order.*;
import com.mmc.oms.model.qo.OrderInfoQO;
import com.mmc.oms.model.vo.OrderStatusVO;
import com.mmc.oms.model.vo.order.OrderStatusVO;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.coupon;
import lombok.EqualsAndHashCode;
import lombok.Getter;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.coupon;
import com.baomidou.mybatisplus.annotation.*;
import com.mmc.oms.common.CouponConstants;
import com.mmc.oms.model.dto.CouponActivityDTO;
import com.mmc.oms.model.dto.CouponDTO;
import com.mmc.oms.model.dto.CouponListDTO;
import com.mmc.oms.model.vo.CouponInfoActivityVO;
import com.mmc.oms.model.vo.CouponInfoVO;
import com.mmc.oms.common.coupon.CouponConstants;
import com.mmc.oms.model.dto.coupon.CouponActivityDTO;
import com.mmc.oms.model.dto.coupon.CouponDTO;
import com.mmc.oms.model.dto.coupon.CouponListDTO;
import com.mmc.oms.model.vo.coupon.CouponInfoActivityVO;
import com.mmc.oms.model.vo.coupon.CouponInfoVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
......@@ -27,13 +27,13 @@ import java.util.Date;
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("coupon")
@ApiModel(value="Coupon对象", description="优惠券表")
@ApiModel(value = "Coupon对象", description = "优惠券表")
public class CouponDO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "优惠券ID")
@TableId(value = "id",type = IdType.AUTO)
@TableId(value = "id", type = IdType.AUTO)
private Integer id;
@ApiModelProperty(value = "优惠券名称")
......@@ -109,7 +109,7 @@ public class CouponDO implements Serializable {
@ApiModelProperty(value = "是否多次核销 0单次核销 1多次核销")
private Boolean verificationType;
@TableField(value = "create_time",fill = FieldFill.INSERT_UPDATE)
@TableField(value = "create_time", fill = FieldFill.INSERT_UPDATE)
@ApiModelProperty(value = "创建时间")
private Date createTime;
......@@ -120,15 +120,14 @@ public class CouponDO implements Serializable {
private Integer parentId;
@ApiModelProperty(value = "分享者-分享人数")
private Integer peopleNumber ;
private Integer peopleNumber;
@ApiModelProperty(value = "批量导入文件url")
private String fileUrl ;
private String fileUrl;
@TableField(exist = false)
@ApiModelProperty(value = "已领取的数量")
private String quantityClaimed ;
private String quantityClaimed;
public CouponDTO bilIdCouponDTO() {
......@@ -190,7 +189,7 @@ public class CouponDO implements Serializable {
}
@Tolerate
public CouponDO(CouponInfoActivityVO couponInfoActivityVO){
public CouponDO(CouponInfoActivityVO couponInfoActivityVO) {
this.couponName = couponInfoActivityVO.getCouponName();
this.useType = couponInfoActivityVO.getUseType();
this.primaryKey = couponInfoActivityVO.getPrimaryKey();
......@@ -212,7 +211,7 @@ public class CouponDO implements Serializable {
}
@Tolerate
public CouponDO(CouponInfoActivityVO couponInfoActivityVO, Integer type){
public CouponDO(CouponInfoActivityVO couponInfoActivityVO, Integer type) {
this.couponName = couponInfoActivityVO.getCouponName();
this.useType = couponInfoActivityVO.getBeSharedUseType();
this.primaryKey = couponInfoActivityVO.getBeSharedPrimaryKey();
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.coupon;
import com.mmc.oms.model.dto.CouponUsageDetailsDTO;
import com.mmc.oms.model.dto.coupon.CouponUsageDetailsDTO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.coupon;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.mmc.oms.common.CouponConstants;
import com.mmc.oms.model.dto.CouponUserDTO;
import com.mmc.oms.model.dto.CouponUserOrderDTO;
import com.mmc.oms.model.vo.CouponUserExchangeVO;
import com.mmc.oms.model.vo.CouponUserVO;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.coupon.CouponConstants;
import com.mmc.oms.model.dto.coupon.CouponUserDTO;
import com.mmc.oms.model.dto.coupon.CouponUserOrderDTO;
import com.mmc.oms.model.vo.coupon.CouponUserExchangeVO;
import com.mmc.oms.model.vo.coupon.CouponUserVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.goods;
import com.mmc.oms.model.dto.AppGoodsInfoDTO;
import com.mmc.oms.model.dto.GoodsInfoListDTO;
import com.mmc.oms.model.dto.GoodsRcdDTO;
import com.mmc.oms.model.dto.TypeGoodsInfoDTO;
import com.mmc.oms.model.vo.CategoryParamAndValueVO;
import com.mmc.oms.model.vo.GoodsAddVO;
import com.mmc.oms.model.vo.MallGoodsAddVO;
import com.mmc.oms.model.dto.goods.AppGoodsInfoDTO;
import com.mmc.oms.model.dto.goods.GoodsInfoListDTO;
import com.mmc.oms.model.dto.goods.GoodsRcdDTO;
import com.mmc.oms.model.dto.goods.TypeGoodsInfoDTO;
import com.mmc.oms.model.vo.category.CategoryParamAndValueVO;
import com.mmc.oms.model.vo.goods.GoodsAddVO;
import com.mmc.oms.model.vo.goods.MallGoodsAddVO;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
......@@ -68,6 +68,7 @@ public class GoodsInfoDO implements Serializable {
// private GoodsConfigExportDO goodsConfigExport;// 功能清单
private Integer buyNum;// 购买数量
private String directoryName;
/**
* 辅助字段-end
*/
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.model.dto.ExpressInfoDTO;
import com.mmc.oms.model.dto.order.ExpressInfoDTO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.model.dto.KdnDicDTO;
import com.mmc.oms.model.dto.kdn.KdnDicDTO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.common.CodeUtil;
import com.mmc.oms.common.TranStatusDic;
import com.mmc.oms.model.dto.OrderInfoDTO;
import com.mmc.oms.model.vo.LeaseOrderVO;
import com.mmc.oms.common.status.TranStatusDic;
import com.mmc.oms.common.util.CodeUtil;
import com.mmc.oms.model.dto.order.OrderInfoDTO;
import com.mmc.oms.model.vo.order.LeaseOrderVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -20,188 +20,188 @@ import java.util.Date;
@AllArgsConstructor
@NoArgsConstructor
public class OrderInfoDO implements Serializable {
private static final long serialVersionUID = 6544149196885009444L;
private Integer id;
private static final long serialVersionUID = 6544149196885009444L;
private Integer id;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "商品id")
private Integer wareInfoId;
@ApiModelProperty(value = "商品id")
private Integer wareInfoId;
@ApiModelProperty(value = "商品id")
private String wareNo;
@ApiModelProperty(value = "商品id")
private String wareNo;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品图片")
private String wareImg;
@ApiModelProperty(value = "商品图片")
private String wareImg;
@ApiModelProperty(value = "套餐id")
private Integer skuInfoId;
@ApiModelProperty(value = "套餐id")
private Integer skuInfoId;
@ApiModelProperty(value = "套餐名称")
private String skuTitle;
@ApiModelProperty(value = "套餐名称")
private String skuTitle;
@ApiModelProperty(value = "购买用户id")
private Integer repoAccountId;
@ApiModelProperty(value = "购买用户id")
private Integer repoAccountId;
@ApiModelProperty(value = "购买用户uid")
private String uid;
@ApiModelProperty(value = "购买用户uid")
private String uid;
@ApiModelProperty(value = "用买用户的名称")
private String buyerName;
@ApiModelProperty(value = "用买用户的名称")
private String buyerName;
@ApiModelProperty(value = "用买用户的手机号")
private String buyerPhone;
@ApiModelProperty(value = "用买用户的手机号")
private String buyerPhone;
@ApiModelProperty(value = "用买用户单价 元/天")
private BigDecimal unitPrice;
@ApiModelProperty(value = "用买用户单价 元/天")
private BigDecimal unitPrice;
@ApiModelProperty(value = "用买商品数量")
private Integer wareNum;
@ApiModelProperty(value = "用买商品数量")
private Integer wareNum;
@ApiModelProperty(value = "应付金额")
private BigDecimal shouldPay;
@ApiModelProperty(value = "实付金额")
private BigDecimal actualPay;
@ApiModelProperty(value = "0 租赁 100 购买")
private Integer orderType;
@ApiModelProperty(value = "押金")
private BigDecimal deposit;
@ApiModelProperty(value = "租金总金额")
private BigDecimal rentPrice;
@ApiModelProperty(value = "租期开始日期")
private Date startDate;
@ApiModelProperty(value = "租期结束日期")
private Date endDate;
@ApiModelProperty(value = "付款天数")
private Integer payDay;
@ApiModelProperty(value = "交易订单状态 查订单状态字典")
private String tranStatus;
@ApiModelProperty(value = "减库方式")
private Integer exWare;
@ApiModelProperty(value = "用户备注")
private String remark;
@ApiModelProperty(value = "平台备注")
private String pfRemark;
@ApiModelProperty(value = "关闭原因")
private String shutReason;
@ApiModelProperty(value = "交易编号")
private String payNo;
@ApiModelProperty(value = "付款时间")
private Date payTime;
@ApiModelProperty(value = "发货时间")
private Date sendWareTime;
private Integer rcdCompanyId;
private Date createTime;
private Date updateTime;
private Date returnTime;
@ApiModelProperty(value = "优惠券id", example = "221")
private Integer couponId;
@ApiModelProperty(value = "规格id", example = "1")
private Integer specsId;
@ApiModelProperty(value = "余额", example = "4")
private BigDecimal balance;
/**
* 辅助字段
*
* @return
*/
private OrderReceiptDO receipt;
public OrderInfoDTO buildOrderInfoDTO() {
return OrderInfoDTO.builder()
.id(this.id)
.orderNo(this.orderNo)
.wareInfoId(this.wareInfoId)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.skuInfoId(this.skuInfoId)
.skuTitle(this.skuTitle)
.repoAccountId(this.repoAccountId)
.uid(this.uid)
.buyerName(this.buyerName)
.buyerPhone(this.buyerPhone)
.unitPrice(this.unitPrice)
.wareNum(this.wareNum)
.shouldPay(this.shouldPay)
.actualPay(this.actualPay)
.orderType(this.orderType)
.deposit(this.deposit)
.rentPrice(this.rentPrice)
.startDate(this.startDate)
.endDate(this.endDate)
.payDay(this.payDay)
.tranStatus(this.tranStatus)
.createTime(this.createTime)
.payTime(this.payTime)
.payNo(this.payNo)
.wareImg(this.wareImg)
.pfRemark(this.pfRemark)
.shutReason(this.shutReason)
.remark(this.remark)
.receipt(this.receipt == null ? null : receipt.buildOrderReceiptDTO())
.exWare(this.exWare)
.sendWareTime(this.sendWareTime)
.returnTime(this.returnTime)
.couponId(this.couponId)
.specsId(this.specsId)
.balance(this.balance)
.build();
}
public OrderInfoDO(LeaseOrderVO lease) {
this.orderNo = CodeUtil.createRepoOrderNo();
this.wareInfoId = lease.getWareInfoId();
this.wareNo = lease.getWareNo();
this.wareTitle = lease.getWareTitle();
this.wareImg = lease.getWareImg();
this.skuInfoId = lease.getSkuInfoId();
this.skuTitle = lease.getSkuTitle();
this.repoAccountId = lease.getRepoAccountId();
this.uid = lease.getUid();
this.buyerName = lease.getBuyerName();
this.buyerPhone = lease.getBuyerPhone();
this.unitPrice = lease.getUnitPrice();
this.wareNum = lease.getWareNum();
this.shouldPay = lease.getShouldPay();
this.actualPay = lease.getActualPay();
this.orderType = lease.getOrderType();
this.deposit = lease.getDeposit();
this.rentPrice = lease.getRentPrice();
this.startDate = lease.getStartDate();
this.endDate = lease.getEndDate();
this.payDay = lease.getPayDay();
this.exWare = lease.getExWare();
this.tranStatus = lease.getTranStatus();
this.remark = lease.getRemark();
this.createTime = lease.getCreateTime();
this.rcdCompanyId = lease.getRcdCompanyId();
this.returnTime = lease.getReturnDate();
this.couponId = lease.getCouponId();
this.specsId = lease.getSpecsId();
this.tranStatus = TranStatusDic.INIT.getStatus();
}
@ApiModelProperty(value = "应付金额")
private BigDecimal shouldPay;
@ApiModelProperty(value = "实付金额")
private BigDecimal actualPay;
@ApiModelProperty(value = "0 租赁 100 购买")
private Integer orderType;
@ApiModelProperty(value = "押金")
private BigDecimal deposit;
@ApiModelProperty(value = "租金总金额")
private BigDecimal rentPrice;
@ApiModelProperty(value = "租期开始日期")
private Date startDate;
@ApiModelProperty(value = "租期结束日期")
private Date endDate;
@ApiModelProperty(value = "付款天数")
private Integer payDay;
@ApiModelProperty(value = "交易订单状态 查订单状态字典")
private String tranStatus;
@ApiModelProperty(value = "减库方式")
private Integer exWare;
@ApiModelProperty(value = "用户备注")
private String remark;
@ApiModelProperty(value = "平台备注")
private String pfRemark;
@ApiModelProperty(value = "关闭原因")
private String shutReason;
@ApiModelProperty(value = "交易编号")
private String payNo;
@ApiModelProperty(value = "付款时间")
private Date payTime;
@ApiModelProperty(value = "发货时间")
private Date sendWareTime;
private Integer rcdCompanyId;
private Date createTime;
private Date updateTime;
private Date returnTime;
@ApiModelProperty(value = "优惠券id", example = "221")
private Integer couponId;
@ApiModelProperty(value = "规格id", example = "1")
private Integer specsId;
@ApiModelProperty(value = "余额", example = "4")
private BigDecimal balance;
/**
* 辅助字段
*
* @return
*/
private OrderReceiptDO receipt;
public OrderInfoDTO buildOrderInfoDTO() {
return OrderInfoDTO.builder()
.id(this.id)
.orderNo(this.orderNo)
.wareInfoId(this.wareInfoId)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.skuInfoId(this.skuInfoId)
.skuTitle(this.skuTitle)
.repoAccountId(this.repoAccountId)
.uid(this.uid)
.buyerName(this.buyerName)
.buyerPhone(this.buyerPhone)
.unitPrice(this.unitPrice)
.wareNum(this.wareNum)
.shouldPay(this.shouldPay)
.actualPay(this.actualPay)
.orderType(this.orderType)
.deposit(this.deposit)
.rentPrice(this.rentPrice)
.startDate(this.startDate)
.endDate(this.endDate)
.payDay(this.payDay)
.tranStatus(this.tranStatus)
.createTime(this.createTime)
.payTime(this.payTime)
.payNo(this.payNo)
.wareImg(this.wareImg)
.pfRemark(this.pfRemark)
.shutReason(this.shutReason)
.remark(this.remark)
.receipt(this.receipt == null ? null : receipt.buildOrderReceiptDTO())
.exWare(this.exWare)
.sendWareTime(this.sendWareTime)
.returnTime(this.returnTime)
.couponId(this.couponId)
.specsId(this.specsId)
.balance(this.balance)
.build();
}
public OrderInfoDO(LeaseOrderVO lease) {
this.orderNo = CodeUtil.createRepoOrderNo();
this.wareInfoId = lease.getWareInfoId();
this.wareNo = lease.getWareNo();
this.wareTitle = lease.getWareTitle();
this.wareImg = lease.getWareImg();
this.skuInfoId = lease.getSkuInfoId();
this.skuTitle = lease.getSkuTitle();
this.repoAccountId = lease.getRepoAccountId();
this.uid = lease.getUid();
this.buyerName = lease.getBuyerName();
this.buyerPhone = lease.getBuyerPhone();
this.unitPrice = lease.getUnitPrice();
this.wareNum = lease.getWareNum();
this.shouldPay = lease.getShouldPay();
this.actualPay = lease.getActualPay();
this.orderType = lease.getOrderType();
this.deposit = lease.getDeposit();
this.rentPrice = lease.getRentPrice();
this.startDate = lease.getStartDate();
this.endDate = lease.getEndDate();
this.payDay = lease.getPayDay();
this.exWare = lease.getExWare();
this.tranStatus = lease.getTranStatus();
this.remark = lease.getRemark();
this.createTime = lease.getCreateTime();
this.rcdCompanyId = lease.getRcdCompanyId();
this.returnTime = lease.getReturnDate();
this.couponId = lease.getCouponId();
this.specsId = lease.getSpecsId();
this.tranStatus = TranStatusDic.INIT.getStatus();
}
}
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.model.dto.OrderReceiptDTO;
import com.mmc.oms.model.vo.OrderReceiptVO;
import com.mmc.oms.model.dto.order.OrderReceiptDTO;
import com.mmc.oms.model.vo.order.OrderReceiptVO;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
......@@ -18,69 +18,69 @@ import java.util.Date;
@AllArgsConstructor
@NoArgsConstructor
public class OrderReceiptDO implements Serializable {
private static final long serialVersionUID = 7590192330910329668L;
private Integer id;
private Integer orderInfoId;
private Integer receiptMethod;
private String takeName;
private String takePhone;
private String region;
private String detailAddress;
private String repoName;
private String repoAddress;
private String bookPhone;
private String sendExCode;
private String sendExNo;
private String sendAddress;
private Integer renMethod;
private String renPhone;
private String renName;
private String renExCode;
private String renExNo;
private String renAddress;
private String exName;
private static final long serialVersionUID = 7590192330910329668L;
private Integer id;
private Integer orderInfoId;
private Integer receiptMethod;
private String takeName;
private String takePhone;
private String region;
private String detailAddress;
private String repoName;
private String repoAddress;
private String bookPhone;
private String sendExCode;
private String sendExNo;
private String sendAddress;
private Integer renMethod;
private String renPhone;
private String renName;
private String renExCode;
private String renExNo;
private String renAddress;
private String exName;
private String renRepoName;
private String renRepoAddr;
private String renRepoPhone;
private String renRepoName;
private String renRepoAddr;
private String renRepoPhone;
private Date createTime;
private Date createTime;
public OrderReceiptDO(OrderReceiptVO d) {
this.orderInfoId = d.getOrderInfoId();
this.receiptMethod = d.getReceiptMethod();
this.takeName = d.getTakeName();
this.takePhone = d.getTakePhone();
this.region = d.getRegion();
this.detailAddress = d.getDetailAddress();
this.repoName = d.getRepoName();
this.repoAddress = d.getRepoAddress();
this.bookPhone = d.getBookPhone();
}
public OrderReceiptDO(OrderReceiptVO d) {
this.orderInfoId = d.getOrderInfoId();
this.receiptMethod = d.getReceiptMethod();
this.takeName = d.getTakeName();
this.takePhone = d.getTakePhone();
this.region = d.getRegion();
this.detailAddress = d.getDetailAddress();
this.repoName = d.getRepoName();
this.repoAddress = d.getRepoAddress();
this.bookPhone = d.getBookPhone();
}
public OrderReceiptDTO buildOrderReceiptDTO() {
return OrderReceiptDTO.builder()
.id(this.id)
.receiptMethod(this.receiptMethod)
.takeName(this.takeName)
.takePhone(this.takePhone)
.region(this.region)
.detailAddress(this.detailAddress)
.repoName(this.repoName)
.repoAddress(this.repoAddress)
.bookPhone(this.bookPhone)
.sendExCode(this.sendExCode)
.sendExNo(this.sendExNo)
.sendAddress(this.sendAddress)
.renMethod(this.renMethod)
.renPhone(this.renPhone)
.renName(this.renName)
.renExCode(this.renExCode)
.renExNo(this.renExNo)
.renAddress(this.renAddress)
.renRepoName(this.renRepoName)
.renRepoAddr(this.renRepoAddr)
.renRepoPhone(this.renRepoPhone)
.build();
}
public OrderReceiptDTO buildOrderReceiptDTO() {
return OrderReceiptDTO.builder()
.id(this.id)
.receiptMethod(this.receiptMethod)
.takeName(this.takeName)
.takePhone(this.takePhone)
.region(this.region)
.detailAddress(this.detailAddress)
.repoName(this.repoName)
.repoAddress(this.repoAddress)
.bookPhone(this.bookPhone)
.sendExCode(this.sendExCode)
.sendExNo(this.sendExNo)
.sendAddress(this.sendAddress)
.renMethod(this.renMethod)
.renPhone(this.renPhone)
.renName(this.renName)
.renExCode(this.renExCode)
.renExNo(this.renExNo)
.renAddress(this.renAddress)
.renRepoName(this.renRepoName)
.renRepoAddr(this.renRepoAddr)
.renRepoPhone(this.renRepoPhone)
.build();
}
}
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.model.dto.OrderRefundDTO;
import com.mmc.oms.model.dto.order.OrderRefundDTO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.model.dto.OrderStatusDTO;
import com.mmc.oms.model.dto.order.OrderStatusDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.model.dto.OrderVcuDTO;
import com.mmc.oms.model.dto.order.OrderVcuDTO;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import io.swagger.annotations.ApiModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.order;
import com.mmc.oms.model.dto.RepoCashDTO;
import com.mmc.oms.model.dto.repo.RepoCashDTO;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
......@@ -20,53 +20,53 @@ import java.util.Date;
@AllArgsConstructor
@NoArgsConstructor
public class RepoCashDO implements Serializable {
private static final long serialVersionUID = -7930603317037474755L;
private Integer id;
private Integer repoAccountId;
private String uid;
private String accountName;
private Integer orderInfoId;
private String orderNo;
private Integer skuInfoId;
private String skuTitle;
private Integer wareInfoId;
private String wareNo;
private String wareTitle;
private String payNo;
private Integer payMethod;
private BigDecimal amtPaid;
private BigDecimal cashAmt;
private Date payTime;
private String refundNo;
private String voucher;
private String remark;
private Integer createUser;
private Date createTime;
private Integer updateUser;
private Date updateTime;
private static final long serialVersionUID = -7930603317037474755L;
private Integer id;
private Integer repoAccountId;
private String uid;
private String accountName;
private Integer orderInfoId;
private String orderNo;
private Integer skuInfoId;
private String skuTitle;
private Integer wareInfoId;
private String wareNo;
private String wareTitle;
private String payNo;
private Integer payMethod;
private BigDecimal amtPaid;
private BigDecimal cashAmt;
private Date payTime;
private String refundNo;
private String voucher;
private String remark;
private Integer createUser;
private Date createTime;
private Integer updateUser;
private Date updateTime;
public RepoCashDTO buildRepoCashDTO() {
return RepoCashDTO.builder()
.id(this.id)
.repoAccountId(this.repoAccountId)
.uid(this.uid)
.accountName(this.accountName)
.orderInfoId(this.orderInfoId)
.orderNo(this.orderNo)
.skuInfoId(this.skuInfoId)
.skuTitle(this.skuTitle)
.wareInfoId(this.wareInfoId)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.payNo(this.payNo)
.payMethod(this.payMethod)
.amtPaid(this.amtPaid)
.refundNo(this.refundNo)
.createUser(this.createUser)
.voucher(StringUtils.isBlank(this.voucher) ? null : Arrays.asList(this.voucher.split(",")))
.cashAmt(this.cashAmt)
.payTime(this.payTime)
.remark(this.remark)
.build();
}
public RepoCashDTO buildRepoCashDTO() {
return RepoCashDTO.builder()
.id(this.id)
.repoAccountId(this.repoAccountId)
.uid(this.uid)
.accountName(this.accountName)
.orderInfoId(this.orderInfoId)
.orderNo(this.orderNo)
.skuInfoId(this.skuInfoId)
.skuTitle(this.skuTitle)
.wareInfoId(this.wareInfoId)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.payNo(this.payNo)
.payMethod(this.payMethod)
.amtPaid(this.amtPaid)
.refundNo(this.refundNo)
.createUser(this.createUser)
.voucher(StringUtils.isBlank(this.voucher) ? null : Arrays.asList(this.voucher.split(",")))
.cashAmt(this.cashAmt)
.payTime(this.payTime)
.remark(this.remark)
.build();
}
}
package com.mmc.oms.entity;
package com.mmc.oms.entity.transtatus;
import com.mmc.oms.model.dto.TranStatusDicDTO;
import com.mmc.oms.model.dto.transtatus.TranStatusDicDTO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
......
package com.mmc.oms.entity;
package com.mmc.oms.entity.ware;
import com.mmc.oms.model.dto.WareImgDTO;
import com.mmc.oms.model.vo.WareImgVO;
import com.mmc.oms.model.dto.ware.WareImgDTO;
import com.mmc.oms.model.vo.ware.WareImgVO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
......@@ -16,26 +16,26 @@ import java.util.Date;
@AllArgsConstructor
@NoArgsConstructor
public class WareImgDO implements Serializable {
private static final long serialVersionUID = -1711990559893951800L;
private Integer id;
private Integer wareInfoId;
private String imgUrl;
private Integer imgType;
private Integer deleted;
private Date createTime;
private static final long serialVersionUID = -1711990559893951800L;
private Integer id;
private Integer wareInfoId;
private String imgUrl;
private Integer imgType;
private Integer deleted;
private Date createTime;
public WareImgDTO buildWareImgDTO() {
return WareImgDTO.builder()
.id(this.id)
.wareInfoId(this.wareInfoId)
.imgType(this.imgType)
.imgUrl(this.imgUrl)
.build();
}
public WareImgDTO buildWareImgDTO() {
return WareImgDTO.builder()
.id(this.id)
.wareInfoId(this.wareInfoId)
.imgType(this.imgType)
.imgUrl(this.imgUrl)
.build();
}
public WareImgDO(WareImgVO d) {
this.id = d.getId();
this.imgUrl = d.getImgUrl();
this.imgType = d.getImgType();
}
public WareImgDO(WareImgVO d) {
this.id = d.getId();
this.imgUrl = d.getImgUrl();
this.imgType = d.getImgType();
}
}
package com.mmc.oms.entity;
package com.mmc.oms.entity.ware;
import com.mmc.oms.model.dto.AppletWareInfoDTO;
import com.mmc.oms.model.dto.WareInfoDTO;
import com.mmc.oms.model.dto.WareInfoFirstPageDTO;
import com.mmc.oms.model.dto.WareInfoItemDTO;
import com.mmc.oms.model.vo.WareInfoVO;
import com.mmc.oms.model.dto.ware.AppletWareInfoDTO;
import com.mmc.oms.model.dto.ware.WareInfoDTO;
import com.mmc.oms.model.dto.ware.WareInfoFirstPageDTO;
import com.mmc.oms.model.dto.ware.WareInfoItemDTO;
import com.mmc.oms.model.vo.ware.WareInfoVO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
......@@ -25,148 +25,152 @@ import java.util.stream.Collectors;
@AllArgsConstructor
@NoArgsConstructor
public class WareInfoDO implements Serializable {
private static final long serialVersionUID = 5530961803742843304L;
private Integer id;
private String wareNo;
private String wareTitle;
private Integer wareTypeId;
private Integer wareStatus;
private Integer payStatus;
private BigDecimal minDeposit;
private BigDecimal maxDeposit;
private BigDecimal minRent;
private BigDecimal maxRent;
private Integer totalStock;
private Integer totalSale;
private Integer skuNum;
private String tags;
private Integer deleted;
private Date createTime;
private Date updateTime;
private Integer pid;
private static final long serialVersionUID = 5530961803742843304L;
private Integer id;
private String wareNo;
private String wareTitle;
private Integer wareTypeId;
private Integer wareStatus;
private Integer payStatus;
private BigDecimal minDeposit;
private BigDecimal maxDeposit;
private BigDecimal minRent;
private BigDecimal maxRent;
private Integer totalStock;
private Integer totalSale;
private Integer skuNum;
private String tags;
private Integer deleted;
private Date createTime;
private Date updateTime;
private Integer pid;
/** 辅助字段-start */
private List<WareImgDO> wareImgs;
// private List<WareVideoDO> wareVideos;
private WarePropDO warePropDO;
private String wareDetailContent;
// private WareDetailDO wareDetailDO;
// private List<SkuInfoDO> skuInfoDOList;
/**
* 辅助字段-start
*/
private List<WareImgDO> wareImgs;
// private List<WareVideoDO> wareVideos;
private WarePropDO warePropDO;
private String wareDetailContent;
// private WareDetailDO wareDetailDO;
// private List<SkuInfoDO> skuInfoDOList;
/** 辅助字段-end */
public WareInfoDTO buildWareInfoDTO() {
return WareInfoDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.payStatus(this.payStatus)
.minDeposit(this.minDeposit)
.maxDeposit(this.maxDeposit)
.minRent(this.minRent)
.maxRent(this.maxRent)
.totalStock(this.totalStock)
.totalSale(this.totalSale)
.skuNum(this.skuNum)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(
d -> {
return d.buildWareImgDTO();
})
.collect(Collectors.toList()))
.warePropDTO(this.warePropDO == null ? null : warePropDO.buildWarePropDTO())
.wareDetailContent(this.wareDetailContent)
.build();
}
/**
* 辅助字段-end
*/
public WareInfoDTO buildWareInfoDTO() {
return WareInfoDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.payStatus(this.payStatus)
.minDeposit(this.minDeposit)
.maxDeposit(this.maxDeposit)
.minRent(this.minRent)
.maxRent(this.maxRent)
.totalStock(this.totalStock)
.totalSale(this.totalSale)
.skuNum(this.skuNum)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(
d -> {
return d.buildWareImgDTO();
})
.collect(Collectors.toList()))
.warePropDTO(this.warePropDO == null ? null : warePropDO.buildWarePropDTO())
.wareDetailContent(this.wareDetailContent)
.build();
}
public WareInfoItemDTO buildWareInfoItemDTO() {
return WareInfoItemDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.minDeposit(this.minDeposit)
.minRent(this.minRent)
.totalStock(this.totalStock)
.totalSale(this.totalSale)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(
d -> {
return d.buildWareImgDTO();
})
.collect(Collectors.toList()))
.propInfoId(this.warePropDO.getPropInfoId())
.createTime(this.createTime)
.build();
}
public WareInfoItemDTO buildWareInfoItemDTO() {
return WareInfoItemDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.minDeposit(this.minDeposit)
.minRent(this.minRent)
.totalStock(this.totalStock)
.totalSale(this.totalSale)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(
d -> {
return d.buildWareImgDTO();
})
.collect(Collectors.toList()))
.propInfoId(this.warePropDO.getPropInfoId())
.createTime(this.createTime)
.build();
}
public AppletWareInfoDTO buildAppletWareInfoDTO() {
return AppletWareInfoDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.payStatus(this.payStatus)
.minDeposit(this.minDeposit)
.minRent(this.minRent)
.totalStock(this.totalStock)
.totalSale(this.totalSale)
.skuNum(this.skuNum)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(
d -> {
return d.buildWareImgDTO();
})
.collect(Collectors.toList()))
.build();
}
public AppletWareInfoDTO buildAppletWareInfoDTO() {
return AppletWareInfoDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.payStatus(this.payStatus)
.minDeposit(this.minDeposit)
.minRent(this.minRent)
.totalStock(this.totalStock)
.totalSale(this.totalSale)
.skuNum(this.skuNum)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(
d -> {
return d.buildWareImgDTO();
})
.collect(Collectors.toList()))
.build();
}
public WareInfoFirstPageDTO buildWareInfoFirstPageDTO() {
return WareInfoFirstPageDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.minDeposit(this.minDeposit)
.minRent(this.minRent)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(WareImgDO::buildWareImgDTO)
.collect(Collectors.toList()))
.warePropDTO(this.warePropDO == null ? null : warePropDO.buildWarePropDTO())
.build();
}
public WareInfoFirstPageDTO buildWareInfoFirstPageDTO() {
return WareInfoFirstPageDTO.builder()
.id(this.id)
.wareNo(this.wareNo)
.wareTitle(this.wareTitle)
.wareTypeId(this.wareTypeId)
.wareStatus(this.wareStatus)
.minDeposit(this.minDeposit)
.minRent(this.minRent)
.tags(StringUtils.isEmpty(this.tags) ? null : Arrays.asList(this.tags.split(",")))
.wareImgs(
CollectionUtils.isEmpty(this.wareImgs)
? null
: this.wareImgs.stream()
.map(WareImgDO::buildWareImgDTO)
.collect(Collectors.toList()))
.warePropDTO(this.warePropDO == null ? null : warePropDO.buildWarePropDTO())
.build();
}
public WareInfoDO(WareInfoVO wareInfoVO) {
this.id = wareInfoVO.getId();
this.wareTitle = wareInfoVO.getWareTitle();
this.wareTypeId = wareInfoVO.getWareTypeId();
this.wareStatus = wareInfoVO.getWareStatus();
this.payStatus = wareInfoVO.getPayStatus();
this.minDeposit = wareInfoVO.getMinDeposit();
this.minRent = wareInfoVO.getMinRent();
this.minRent = wareInfoVO.getMinRent();
this.totalStock = wareInfoVO.getTotalStock();
this.skuNum = wareInfoVO.getSkuNum();
this.tags = wareInfoVO.getTags();
}
public WareInfoDO(WareInfoVO wareInfoVO) {
this.id = wareInfoVO.getId();
this.wareTitle = wareInfoVO.getWareTitle();
this.wareTypeId = wareInfoVO.getWareTypeId();
this.wareStatus = wareInfoVO.getWareStatus();
this.payStatus = wareInfoVO.getPayStatus();
this.minDeposit = wareInfoVO.getMinDeposit();
this.minRent = wareInfoVO.getMinRent();
this.minRent = wareInfoVO.getMinRent();
this.totalStock = wareInfoVO.getTotalStock();
this.skuNum = wareInfoVO.getSkuNum();
this.tags = wareInfoVO.getTags();
}
}
package com.mmc.oms.entity;
package com.mmc.oms.entity.ware;
import com.mmc.oms.model.dto.WarePropDTO;
import com.mmc.oms.model.dto.ware.WarePropDTO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
......@@ -24,7 +24,7 @@ public class WarePropDO implements Serializable {
private String propPoster;
private Date createTime;
public WarePropDTO buildWarePropDTO(){
public WarePropDTO buildWarePropDTO() {
return WarePropDTO.builder().id(this.id).wareInfoId(this.wareInfoId).propInfoId(this.propInfoId).propPoster(this.propPoster).createTime(this.createTime).build();
}
}
package com.mmc.oms.filter;
import com.alibaba.fastjson2.JSON;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.common.ResultEnum;
import com.mmc.oms.common.Tenant;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.config.Audience;
import com.mmc.oms.config.TenantContext;
import com.mmc.oms.model.dto.UserAccountDTO;
import com.mmc.oms.model.dto.user.UserAccountDTO;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.ArrayUtils;
import org.springframework.beans.factory.annotation.Autowired;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.company;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -23,8 +23,8 @@ public class CompanyCacheDTO implements Serializable {
private Integer id;
@ApiModelProperty(value = "单位名称")
private String company;
@ApiModelProperty(value = "是否为管理单位:0否 1是",hidden = true)
@ApiModelProperty(value = "是否为管理单位:0否 1是", hidden = true)
private Integer manage;
@ApiModelProperty(value = "当前单位ID+子级单位ID的集合",hidden = true)
@ApiModelProperty(value = "当前单位ID+子级单位ID的集合", hidden = true)
private List<Integer> companys;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.company;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.company;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -28,8 +27,8 @@ public class CompanySimpleDTO implements Serializable {
private String company;
@ApiModelProperty(value = "账号类型:0合伙人 1员工")
private Integer userType;
@ApiModelProperty(value = "是否为管理单位:0否 1是",hidden = true)
@ApiModelProperty(value = "是否为管理单位:0否 1是", hidden = true)
private Integer manage;
@ApiModelProperty(value = "当前单位ID+子级单位ID的集合",hidden = true)
@ApiModelProperty(value = "当前单位ID+子级单位ID的集合", hidden = true)
private List<Integer> companys;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.io.Serializable;
import java.math.BigDecimal;
......@@ -24,7 +25,7 @@ import java.util.Date;
public class CouponActivityDTO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "优惠券ID")
private Integer id;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;
......@@ -24,7 +23,7 @@ import java.util.Date;
public class CouponDTO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "优惠券ID")
private Integer id;
......@@ -102,5 +101,5 @@ public class CouponDTO implements Serializable {
private String fileUrl;
@ApiModelProperty(value = "已领取的数量")
private String quantityClaimed ;
private String quantityClaimed;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;
......@@ -23,7 +22,7 @@ import java.util.Date;
//@ApiModel(value="CouponList对象", description="小程序优惠券表")
public class CouponListDTO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "优惠券ID")
private Integer id;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.coupon;
import cn.afterturn.easypoi.excel.annotation.ExcelTarget;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
......@@ -36,7 +34,7 @@ public class CouponUserDTO implements Serializable {
@ApiModelProperty(value = "优惠券id")
private Integer couponId;
@JsonSerialize(using= ToStringSerializer.class)
@JsonSerialize(using = ToStringSerializer.class)
@ApiModelProperty(value = "订单id")
private Long cid;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;
......@@ -24,7 +23,7 @@ import java.util.List;
@AllArgsConstructor
public class CouponUserOrderDTO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "id")
private Integer id;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
......@@ -15,7 +14,7 @@ import java.io.Serializable;
//@ApiModel(value="用户优惠券使用数据", description="用户优惠券使用数据DTO")
public class CouponViewDTO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "总发行量")
private Integer couponTotal;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.flyer;
import com.mmc.oms.common.FlyerAccountType;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.flyer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.flyer;
import com.mmc.oms.model.dto.order.OrderTaskDTO;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.flyer;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModelProperty;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.goods;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.goods;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.goods;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.goods;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.kdn;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.kdn;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.model.dto.order.ExpStationsDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import com.mmc.oms.entity.RepoCashDO;
import com.mmc.oms.entity.order.RepoCashDO;
import com.mmc.oms.model.dto.kdn.KdnExpDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -21,139 +22,139 @@ import java.util.List;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.OrderInfoDTO", description = "云仓订单DTO")
public class OrderInfoDTO implements Serializable {
private static final long serialVersionUID = 1572467108563651846L;
private static final long serialVersionUID = 1572467108563651846L;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "创建时间")
private Date createTime;
@ApiModelProperty(value = "创建时间")
private Date createTime;
@ApiModelProperty(value = "商品ID")
private Integer wareInfoId;
@ApiModelProperty(value = "商品ID")
private Integer wareInfoId;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品图片")
private String wareImg;
@ApiModelProperty(value = "商品图片")
private String wareImg;
@ApiModelProperty(value = "套餐(sku)ID")
private Integer skuInfoId;
@ApiModelProperty(value = "套餐(sku)ID")
private Integer skuInfoId;
@ApiModelProperty(value = "套餐(sku)名称")
private String skuTitle;
@ApiModelProperty(value = "套餐(sku)名称")
private String skuTitle;
@ApiModelProperty(value = "购买用户ID")
private Integer repoAccountId;
@ApiModelProperty(value = "购买用户ID")
private Integer repoAccountId;
@ApiModelProperty(value = "用户UID")
private String uid;
@ApiModelProperty(value = "用户UID")
private String uid;
@ApiModelProperty(value = "买家name")
private String buyerName;
@ApiModelProperty(value = "买家name")
private String buyerName;
@ApiModelProperty(value = "买家电话")
private String buyerPhone;
@ApiModelProperty(value = "买家电话")
private String buyerPhone;
@ApiModelProperty(value = "单价")
private BigDecimal unitPrice;
@ApiModelProperty(value = "单价")
private BigDecimal unitPrice;
@ApiModelProperty(value = "购买的商品数量")
private Integer wareNum;
@ApiModelProperty(value = "购买的商品数量")
private Integer wareNum;
@ApiModelProperty(value = "应付款金额")
private BigDecimal shouldPay;
@ApiModelProperty(value = "应付款金额")
private BigDecimal shouldPay;
@ApiModelProperty(value = "实收款金额")
private BigDecimal actualPay;
@ApiModelProperty(value = "实收款金额")
private BigDecimal actualPay;
@ApiModelProperty(value = "订单类型:0租赁 100购买")
private Integer orderType;
@ApiModelProperty(value = "订单类型:0租赁 100购买")
private Integer orderType;
@ApiModelProperty(value = "押金")
private BigDecimal deposit;
@ApiModelProperty(value = "押金")
private BigDecimal deposit;
@ApiModelProperty(value = "租金总金额")
private BigDecimal rentPrice;
@ApiModelProperty(value = "租金总金额")
private BigDecimal rentPrice;
@ApiModelProperty(value = "租约开始日")
private Date startDate;
@ApiModelProperty(value = "租约开始日")
private Date startDate;
@ApiModelProperty(value = "租约结束日")
private Date endDate;
@ApiModelProperty(value = "租约结束日")
private Date endDate;
@ApiModelProperty(value = "付款天数")
private Integer payDay;
@ApiModelProperty(value = "付款天数")
private Integer payDay;
@ApiModelProperty(value = "交易状态:查订单状态字典")
private String tranStatus;
@ApiModelProperty(value = "交易状态:查订单状态字典")
private String tranStatus;
@ApiModelProperty(value = "减库方式 0:买家拍下减库存 1:卖家付款减库存")
private Integer exWare;
@ApiModelProperty(value = "减库方式 0:买家拍下减库存 1:卖家付款减库存")
private Integer exWare;
@ApiModelProperty(value = "用户备注")
private String remark;
@ApiModelProperty(value = "用户备注")
private String remark;
@ApiModelProperty(value = "平台人员备注")
private String pfRemark;
@ApiModelProperty(value = "平台人员备注")
private String pfRemark;
@ApiModelProperty(value = "关闭原因")
private String shutReason;
@ApiModelProperty(value = "关闭原因")
private String shutReason;
@ApiModelProperty(value = "交易编号")
private String payNo;
@ApiModelProperty(value = "交易编号")
private String payNo;
@ApiModelProperty(value = "支付时间/付款时间")
private Date payTime;
@ApiModelProperty(value = "支付时间/付款时间")
private Date payTime;
@ApiModelProperty(value = "发货时间")
private Date sendWareTime;
@ApiModelProperty(value = "发货时间")
private Date sendWareTime;
@ApiModelProperty(value = "物流信息/收货地址信息")
private OrderReceiptDTO receipt;
@ApiModelProperty(value = "物流信息/收货地址信息")
private OrderReceiptDTO receipt;
@ApiModelProperty(value = "退款单详情信息,无则为null")
private OrderRefundDTO orderRefund;
@ApiModelProperty(value = "退款单详情信息,无则为null")
private OrderRefundDTO orderRefund;
@ApiModelProperty(value = "发货-物流动态,无则为null")
private KdnExpDTO express;
@ApiModelProperty(value = "发货-物流动态,无则为null")
private KdnExpDTO express;
@ApiModelProperty(value = "退货-物流动态,无则为null")
private KdnExpDTO refundExpress;
@ApiModelProperty(value = "退货-物流动态,无则为null")
private KdnExpDTO refundExpress;
@ApiModelProperty(value = "质检详情,无则为null")
private List<OrderVcuDTO> vcus;
@ApiModelProperty(value = "质检详情,无则为null")
private List<OrderVcuDTO> vcus;
@ApiModelProperty(value = "归还时间")
private Date returnTime;
@ApiModelProperty(value = "归还时间")
private Date returnTime;
@ApiModelProperty(value = "优惠券id", example = "221")
private Integer couponId;
@ApiModelProperty(value = "优惠券id", example = "221")
private Integer couponId;
@ApiModelProperty(value = "规格id", example = "1")
private Integer specsId;
@ApiModelProperty(value = "规格id", example = "1")
private Integer specsId;
@ApiModelProperty(value = "余额", example = "4")
private BigDecimal balance;
@ApiModelProperty(value = "余额", example = "4")
private BigDecimal balance;
public RepoCashDO buildRepoCashDO() {
return RepoCashDO.builder()
.uid(this.uid)
.accountName(this.buyerName)
.orderInfoId(this.id)
.orderNo(this.orderNo)
.skuInfoId(this.skuInfoId)
.skuTitle(this.skuTitle)
.wareInfoId(this.wareInfoId)
.wareTitle(this.wareTitle)
.wareNo(this.wareNo)
.build();
}
public RepoCashDO buildRepoCashDO() {
return RepoCashDO.builder()
.uid(this.uid)
.accountName(this.buyerName)
.orderInfoId(this.id)
.orderNo(this.orderNo)
.skuInfoId(this.skuInfoId)
.skuTitle(this.skuTitle)
.wareInfoId(this.wareInfoId)
.wareTitle(this.wareTitle)
.wareNo(this.wareNo)
.build();
}
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -17,68 +17,68 @@ import java.io.Serializable;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.OrderReceiptDTO", description = "订单收货信息DTO")
public class OrderReceiptDTO implements Serializable {
private static final long serialVersionUID = -6212026509857770276L;
private static final long serialVersionUID = -6212026509857770276L;
@ApiModelProperty(value = "地址ID")
private Integer id;
@ApiModelProperty(value = "地址ID")
private Integer id;
@ApiModelProperty(value = "收货方式:0邮寄 1门店地址")
private Integer receiptMethod;
@ApiModelProperty(value = "收货方式:0邮寄 1门店地址")
private Integer receiptMethod;
@ApiModelProperty(value = "0-收货人姓名")
private String takeName;
@ApiModelProperty(value = "0-收货人姓名")
private String takeName;
@ApiModelProperty(value = "0-收货人电话")
private String takePhone;
@ApiModelProperty(value = "0-收货人电话")
private String takePhone;
@ApiModelProperty(value = "0-收货区域")
private String region;
@ApiModelProperty(value = "0-收货区域")
private String region;
@ApiModelProperty(value = "0-收获详细地址")
private String detailAddress;
@ApiModelProperty(value = "0-收获详细地址")
private String detailAddress;
@ApiModelProperty(value = "1-门店名称")
private String repoName;
@ApiModelProperty(value = "1-门店名称")
private String repoName;
@ApiModelProperty(value = "1-门店详细地址")
private String repoAddress;
@ApiModelProperty(value = "1-门店详细地址")
private String repoAddress;
@ApiModelProperty(value = "1-预留手机号")
private String bookPhone;
@ApiModelProperty(value = "1-预留手机号")
private String bookPhone;
@ApiModelProperty(value = "发货-物流公司码")
private String sendExCode;
@ApiModelProperty(value = "发货-物流公司码")
private String sendExCode;
@ApiModelProperty(value = "发货-物流单号")
private String sendExNo;
@ApiModelProperty(value = "发货-物流单号")
private String sendExNo;
@ApiModelProperty(value = "发货地址")
private String sendAddress;
@ApiModelProperty(value = "发货地址")
private String sendAddress;
@ApiModelProperty(value = "退还货方式:0邮寄 1门店地址")
private Integer renMethod;
@ApiModelProperty(value = "退还货方式:0邮寄 1门店地址")
private Integer renMethod;
@ApiModelProperty(value = "退还货-收货电话")
private String renPhone;
@ApiModelProperty(value = "退还货-收货电话")
private String renPhone;
@ApiModelProperty(value = "退还货-收货人")
private String renName;
@ApiModelProperty(value = "退还货-收货人")
private String renName;
@ApiModelProperty(value = "退还货-物流公司码")
private String renExCode;
@ApiModelProperty(value = "退还货-物流公司码")
private String renExCode;
@ApiModelProperty(value = "退还货-物流单号")
private String renExNo;
@ApiModelProperty(value = "退还货-物流单号")
private String renExNo;
@ApiModelProperty(value = "退还货-地址")
private String renAddress;
@ApiModelProperty(value = "退还货-地址")
private String renAddress;
@ApiModelProperty(value = "退还货-门店名称")
private String renRepoName;
@ApiModelProperty(value = "退还货-门店名称")
private String renRepoName;
@ApiModelProperty(value = "退还货-门店地址")
private String renRepoAddr;
@ApiModelProperty(value = "退还货-门店地址")
private String renRepoAddr;
@ApiModelProperty(value = "退还货-门店联系电话")
private String renRepoPhone;
@ApiModelProperty(value = "退还货-门店联系电话")
private String renRepoPhone;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import com.mmc.oms.model.dto.repo.RepoCashDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -20,44 +21,44 @@ import java.util.List;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.OrderRefundDTO", description = "退款单DTO")
public class OrderRefundDTO implements Serializable {
private static final long serialVersionUID = -6124933008580173589L;
private static final long serialVersionUID = -6124933008580173589L;
@ApiModelProperty(value = "退款单ID")
private Integer id;
@ApiModelProperty(value = "退款单ID")
private Integer id;
@ApiModelProperty(value = "订单ID")
private Integer orderInfoId;
@ApiModelProperty(value = "订单ID")
private Integer orderInfoId;
@ApiModelProperty(value = "退款单号")
private String refundNo;
@ApiModelProperty(value = "退款单号")
private String refundNo;
@ApiModelProperty(value = "退款单状态:查字典")
private Integer refundStatus;
@ApiModelProperty(value = "退款单状态:查字典")
private Integer refundStatus;
@ApiModelProperty(value = "应退款金额")
private BigDecimal shouldRefund;
@ApiModelProperty(value = "应退款金额")
private BigDecimal shouldRefund;
@ApiModelProperty(value = "实际退款金额")
private BigDecimal actualRefund;
@ApiModelProperty(value = "实际退款金额")
private BigDecimal actualRefund;
@ApiModelProperty(value = "退款理由")
private String reason;
@ApiModelProperty(value = "退款理由")
private String reason;
@ApiModelProperty(value = "创建时间/申请时间")
private Date createTime;
@ApiModelProperty(value = "创建时间/申请时间")
private Date createTime;
@ApiModelProperty(value = "退款-设备情况(图片&视频)")
private OrderVcuDTO orderVcu;
@ApiModelProperty(value = "退款-设备情况(图片&视频)")
private OrderVcuDTO orderVcu;
@ApiModelProperty(value = "订单信息")
private OrderInfoDTO orderInfo;
@ApiModelProperty(value = "订单信息")
private OrderInfoDTO orderInfo;
@ApiModelProperty(value = "退款协商历史")
private List<RefundLogDTO> rlogs;
@ApiModelProperty(value = "退款协商历史")
private List<RefundLogDTO> rlogs;
@ApiModelProperty(value = "退款流水信息")
private RepoCashDTO refundCash;
@ApiModelProperty(value = "退款流水信息")
private RepoCashDTO refundCash;
@ApiModelProperty(value = "平台备注")
private String pfRemark;
@ApiModelProperty(value = "平台备注")
private String pfRemark;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import com.mmc.oms.model.dto.flyer.FlyerAccountDTO;
import com.mmc.oms.model.dto.flyer.FlyerOrderTaskDTO;
import com.mmc.oms.model.dto.user.UserAccountDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -140,7 +143,7 @@ public class OrderTaskDTO implements Serializable {
@ApiModelProperty(value = "平台上传附件预览效果")
private String platformPreview;
@ApiModelProperty(value = "文案描述")
private String copywriting;
private String copywriting;
@ApiModelProperty(value = "子任务列表")
private List<OrderTaskDTO> children;
@ApiModelProperty(value = "子订单信息")
......@@ -160,7 +163,7 @@ public class OrderTaskDTO implements Serializable {
this.userPhoneNum = wx.getPhoneNum();
}
public FlyerOrderTaskDTO buildFlyerOrderTaskDTO(){
public FlyerOrderTaskDTO buildFlyerOrderTaskDTO() {
return FlyerOrderTaskDTO.builder().orderId(this.id).orderNo(this.orderNo).orderName(this.orderName).build();
}
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.order;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.model.dto.ware.WagTermDetailDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -92,7 +92,7 @@ public class TaskFlyerCostDTO implements Serializable {
this.payPersent = BigDecimal.ZERO;
}
if(this.hotSudy == null) {
if (this.hotSudy == null) {
this.hotSudy = BigDecimal.ZERO;
}
}
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.repo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.repo;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -20,70 +20,70 @@ import java.util.List;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.RepoBannerDTO", description = "现金流水DTO")
public class RepoCashDTO implements Serializable {
private static final long serialVersionUID = 4569221850373256579L;
private static final long serialVersionUID = 4569221850373256579L;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "用户ID", hidden = true)
private Integer repoAccountId;
@ApiModelProperty(value = "用户ID", hidden = true)
private Integer repoAccountId;
@ApiModelProperty(value = "用户UID", hidden = true)
private String uid;
@ApiModelProperty(value = "用户UID", hidden = true)
private String uid;
@ApiModelProperty(value = "用户名", hidden = true)
private String accountName;
@ApiModelProperty(value = "用户名", hidden = true)
private String accountName;
@ApiModelProperty(value = "订单ID", hidden = true)
private Integer orderInfoId;
@ApiModelProperty(value = "订单ID", hidden = true)
private Integer orderInfoId;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "skuID", hidden = true)
private Integer skuInfoId;
@ApiModelProperty(value = "skuID", hidden = true)
private Integer skuInfoId;
@ApiModelProperty(value = "sku标题", hidden = true)
private String skuTitle;
@ApiModelProperty(value = "sku标题", hidden = true)
private String skuTitle;
@ApiModelProperty(value = "商品ID", hidden = true)
private Integer wareInfoId;
@ApiModelProperty(value = "商品ID", hidden = true)
private Integer wareInfoId;
@ApiModelProperty(value = "商品编号", hidden = true)
private String wareNo;
@ApiModelProperty(value = "商品编号", hidden = true)
private String wareNo;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "流水编号")
private String payNo;
@ApiModelProperty(value = "流水编号")
private String payNo;
@ApiModelProperty(value = "流水类型:查字典")
private Integer payMethod;
@ApiModelProperty(value = "流水类型:查字典")
private Integer payMethod;
@ApiModelProperty(value = "变动金额")
private BigDecimal amtPaid;
@ApiModelProperty(value = "变动金额")
private BigDecimal amtPaid;
@ApiModelProperty(value = "当前余额")
private BigDecimal cashAmt;
@ApiModelProperty(value = "当前余额")
private BigDecimal cashAmt;
@ApiModelProperty(value = "支付时间")
private Date payTime;
@ApiModelProperty(value = "支付时间")
private Date payTime;
@ApiModelProperty(value = "退款流水编号")
private String refundNo;
@ApiModelProperty(value = "退款流水编号")
private String refundNo;
@ApiModelProperty(value = "凭证")
private List<String> voucher;
@ApiModelProperty(value = "凭证")
private List<String> voucher;
@ApiModelProperty(value = "备注")
private String remark;
@ApiModelProperty(value = "备注")
private String remark;
@ApiModelProperty(value = "操作人账号")
private String opNo;
@ApiModelProperty(value = "操作人账号")
private String opNo;
@ApiModelProperty(value = "操作人姓名")
private String opName;
@ApiModelProperty(value = "操作人姓名")
private String opName;
private Integer createUser;
private Integer createUser;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.repo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.transtatus;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.user;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.user;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.user;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.user;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.user;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.model.dto.company.CompanySimpleDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.user;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -18,50 +18,50 @@ import java.util.List;
@AllArgsConstructor
@NoArgsConstructor
public class AppletWareInfoDTO implements Serializable {
private static final long serialVersionUID = -8861604532607064616L;
private static final long serialVersionUID = -8861604532607064616L;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品名称")
private String wareName;
@ApiModelProperty(value = "商品名称")
private String wareName;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "减库方式")
private Integer payStatus;
@ApiModelProperty(value = "减库方式")
private Integer payStatus;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "总库存数量")
private Integer totalStock;
@ApiModelProperty(value = "总库存数量")
private Integer totalStock;
@ApiModelProperty(value = "总销量")
private Integer totalSale;
@ApiModelProperty(value = "总销量")
private Integer totalSale;
@ApiModelProperty(value = "sku数量")
private Integer skuNum;
@ApiModelProperty(value = "sku数量")
private Integer skuNum;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
@ApiModelProperty(value = "商品图片集合")
private List<WareImgDTO> wareImgs;
@ApiModelProperty(value = "商品图片集合")
private List<WareImgDTO> wareImgs;
@ApiModelProperty(value = "商品视频集合")
private List<WareVideoDTO> wareVideos;
@ApiModelProperty(value = "商品视频集合")
private List<WareVideoDTO> wareVideos;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -17,17 +17,17 @@ import java.io.Serializable;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.WareImgDTO", description = "商品图片DTO")
public class WareImgDTO implements Serializable {
private static final long serialVersionUID = 1195966760401573468L;
private static final long serialVersionUID = 1195966760401573468L;
@ApiModelProperty(value = "图片ID")
private Integer id;
@ApiModelProperty(value = "图片ID")
private Integer id;
@ApiModelProperty(value = "商品ID")
private Integer wareInfoId;
@ApiModelProperty(value = "商品ID")
private Integer wareInfoId;
@ApiModelProperty(value = "图片类型:0:主图 1:副图")
private String imgUrl;
@ApiModelProperty(value = "图片类型:0:主图 1:副图")
private String imgUrl;
@ApiModelProperty(value = "图片ID")
private Integer imgType;
@ApiModelProperty(value = "图片ID")
private Integer imgType;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -19,61 +19,61 @@ import java.util.List;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.WareInfoDTO", description = "商品视频DTO")
public class WareInfoDTO implements Serializable {
private static final long serialVersionUID = -4916469576205012865L;
private static final long serialVersionUID = -4916469576205012865L;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "减库方式")
private Integer payStatus;
@ApiModelProperty(value = "减库方式")
private Integer payStatus;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最大押金")
private BigDecimal maxDeposit;
@ApiModelProperty(value = "最大押金")
private BigDecimal maxDeposit;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "最大租金")
private BigDecimal maxRent;
@ApiModelProperty(value = "最大租金")
private BigDecimal maxRent;
@ApiModelProperty(value = "总库存数量")
private Integer totalStock;
@ApiModelProperty(value = "总库存数量")
private Integer totalStock;
@ApiModelProperty(value = "总销量")
private Integer totalSale;
@ApiModelProperty(value = "总销量")
private Integer totalSale;
@ApiModelProperty(value = "sku数量")
private Integer skuNum;
@ApiModelProperty(value = "sku数量")
private Integer skuNum;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
@ApiModelProperty(value = "商品图片集合")
private List<WareImgDTO> wareImgs;
// @ApiModelProperty(value = "商品视频集合")
// private List<WareVideoDTO> wareVideos;
@ApiModelProperty(value = "商品活动对象")
private WarePropDTO warePropDTO;
@ApiModelProperty(value = "商品图片集合")
private List<WareImgDTO> wareImgs;
// @ApiModelProperty(value = "商品视频集合")
// private List<WareVideoDTO> wareVideos;
@ApiModelProperty(value = "商品活动对象")
private WarePropDTO warePropDTO;
@ApiModelProperty(value = "商品介绍详情")
private String wareDetailContent;
// @ApiModelProperty(value = "商品介绍详情")
// private WareDetailDTO wareDetailDTO;
// @ApiModelProperty(value = "商品sku信息")
// private List<SkuInfoDTO> skuInfoDTOList;
@ApiModelProperty(value = "商品介绍详情")
private String wareDetailContent;
// @ApiModelProperty(value = "商品介绍详情")
// private WareDetailDTO wareDetailDTO;
// @ApiModelProperty(value = "商品sku信息")
// private List<SkuInfoDTO> skuInfoDTOList;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -19,36 +19,36 @@ import java.util.List;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.WareInfoFirstPageDTO", description = "商品首页DTO")
public class WareInfoFirstPageDTO implements Serializable {
private static final long serialVersionUID = -220701135688609035L;
private static final long serialVersionUID = -220701135688609035L;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
@ApiModelProperty(value = "商品图片集合")
private List<WareImgDTO> wareImgs;
// @ApiModelProperty(value = "商品视频集合")
// private List<WareVideoDTO> wareVideos;
@ApiModelProperty(value = "商品活动对象")
private WarePropDTO warePropDTO;
@ApiModelProperty(value = "商品图片集合")
private List<WareImgDTO> wareImgs;
// @ApiModelProperty(value = "商品视频集合")
// private List<WareVideoDTO> wareVideos;
@ApiModelProperty(value = "商品活动对象")
private WarePropDTO warePropDTO;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......@@ -20,44 +20,44 @@ import java.util.List;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.dto.WareInfoItemDTO", description = "商品列表ItemDTO")
public class WareInfoItemDTO implements Serializable {
private static final long serialVersionUID = -4354269497656808831L;
private static final long serialVersionUID = -4354269497656808831L;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "ID")
private Integer id;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品类型ID")
private Integer wareTypeId;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "商品状态")
private Integer wareStatus;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最小押金")
private BigDecimal minDeposit;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "最小租金")
private BigDecimal minRent;
@ApiModelProperty(value = "总库存数量")
private Integer totalStock;
@ApiModelProperty(value = "总库存数量")
private Integer totalStock;
@ApiModelProperty(value = "总销量")
private Integer totalSale;
@ApiModelProperty(value = "总销量")
private Integer totalSale;
@ApiModelProperty(value = "商品活动属性Id")
private Integer propInfoId;
@ApiModelProperty(value = "商品活动属性Id")
private Integer propInfoId;
@ApiModelProperty(value = "生成时间")
private Date createTime;
@ApiModelProperty(value = "生成时间")
private Date createTime;
@ApiModelProperty(value = "商品图片")
private List<WareImgDTO> wareImgs;
@ApiModelProperty(value = "商品图片")
private List<WareImgDTO> wareImgs;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
@ApiModelProperty(value = "标签集合")
private List<String> tags;
}
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.dto;
package com.mmc.oms.model.dto.ware;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.qo;
import com.mmc.oms.common.Freeze;
import com.mmc.oms.common.Page;
import com.mmc.oms.common.publicinterface.Freeze;
import com.mmc.oms.common.publicinterface.Page;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -27,13 +27,13 @@ public class BaseInfoQO {
private String endTime;
@ApiModelProperty(value = "页码")
@NotNull(message = "页码不能为空", groups = { Page.class, Freeze.class })
@Min(value = 1, groups = Page.class,message = "pageNo不能少于1")
@NotNull(message = "页码不能为空", groups = {Page.class, Freeze.class})
@Min(value = 1, groups = Page.class, message = "pageNo不能少于1")
private Integer pageNo;
@ApiModelProperty(value = "每页显示数")
@NotNull(message = "每页显示数不能为空", groups = { Page.class, Freeze.class })
@Min(value = 1, groups = Page.class,message = "pageSize不能少于1")
@NotNull(message = "每页显示数不能为空", groups = {Page.class, Freeze.class})
@Min(value = 1, groups = Page.class, message = "pageSize不能少于1")
private Integer pageSize;
/**
......
package com.mmc.oms.model.qo;
import com.mmc.oms.common.Page;
import com.mmc.oms.common.publicinterface.Page;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -21,56 +21,56 @@ import java.util.List;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.qo.OrderInfoQO", description = "订单QO")
public class OrderInfoQO implements Serializable {
private static final long serialVersionUID = -3503119623575892302L;
private static final long serialVersionUID = -3503119623575892302L;
@ApiModelProperty(value = "用户ID", hidden = true)
private Integer repoAccountId;
@ApiModelProperty(value = "用户ID", hidden = true)
private Integer repoAccountId;
@ApiModelProperty(value = "关键字")
private String keyword;
@ApiModelProperty(value = "关键字")
private String keyword;
@ApiModelProperty(value = "买家名称")
private String buyerName;
@ApiModelProperty(value = "买家名称")
private String buyerName;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品名称")
private String wareTitle;
@ApiModelProperty(value = "商品名称")
private String wareTitle;
@ApiModelProperty(value = "订单状态:查字典")
private String tranStatus;
@ApiModelProperty(value = "订单状态:查字典")
private String tranStatus;
@ApiModelProperty(value = "开始时间")
private String startTime;
@ApiModelProperty(value = "开始时间")
private String startTime;
@ApiModelProperty(value = "结束时间")
private String endTime;
@ApiModelProperty(value = "结束时间")
private String endTime;
@ApiModelProperty(value = "用户ID", hidden = true)
private List<Integer> userIds;
@ApiModelProperty(value = "用户ID", hidden = true)
private List<Integer> userIds;
@ApiModelProperty(value = "单位ID", hidden = true)
private List<Integer> companys;
@ApiModelProperty(value = "单位ID", hidden = true)
private List<Integer> companys;
@ApiModelProperty(value = "页码", required = true)
@NotNull(
message = "页码不能为空",
groups = {Page.class})
@Min(value = 1, groups = Page.class)
private Integer pageNo;
@ApiModelProperty(value = "页码", required = true, example = "1")
@NotNull(
message = "页码不能为空",
groups = {Page.class})
@Min(value = 1, groups = Page.class)
private Integer pageNo;
@ApiModelProperty(value = "每页显示数", required = true)
@NotNull(
message = "每页显示数不能为空",
groups = {Page.class})
@Min(value = 1, groups = Page.class)
private Integer pageSize;
@ApiModelProperty(value = "每页显示数", required = true, example = "10")
@NotNull(
message = "每页显示数不能为空",
groups = {Page.class})
@Min(value = 1, groups = Page.class)
private Integer pageSize;
public void buildCurrentPage() {
this.pageNo = (pageNo - 1) * pageSize;
}
public void buildCurrentPage() {
this.pageNo = (pageNo - 1) * pageSize;
}
}
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.category;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.category;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.coupon;
import com.alibaba.fastjson.JSONObject;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
......@@ -26,24 +25,24 @@ import java.util.Date;
//@ApiModel(value="CouponInfoActivityVO对象", description="裂变优惠券表添加/修改VO")
public class CouponInfoActivityVO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "优惠券名称", required = true)
@NotBlank(message = "请填写优惠券名称")
@Length(max = 64, message = "优惠券名称长度不能超过64个字符")
private String couponName;
@ApiModelProperty(value = "分享者-优惠券使用类型 1vip,2品牌券",required = true)
@ApiModelProperty(value = "分享者-优惠券使用类型 1vip,2品牌券", required = true)
@Range(min = 1, max = 2, message = "请选择优惠券使用类型")
private Integer useType;
@ApiModelProperty(value = "分享者-所属 品牌范围id 例:5,9... ", required = true)
private String primaryKey;
@ApiModelProperty(value = "分享者-可使用时间范围 开始时间 yyyy-MM-dd HH:mm:ss",required = true)
@ApiModelProperty(value = "分享者-可使用时间范围 开始时间 yyyy-MM-dd HH:mm:ss", required = true)
private Date useStartTime;
@ApiModelProperty(value = "分享者-可使用时间范围 结束时间 yyyy-MM-dd HH:mm:ss",required = true)
@ApiModelProperty(value = "分享者-可使用时间范围 结束时间 yyyy-MM-dd HH:mm:ss", required = true)
private Date useEndTime;
@ApiModelProperty(value = "分享者-兑换的优惠券面值", required = true)
......@@ -51,36 +50,36 @@ public class CouponInfoActivityVO implements Serializable {
@DecimalMax(value = "99999.99", message = "优惠券面值不能大于99999.99")
private BigDecimal couponMoney;
@ApiModelProperty(value = "分享者-最低消费 0为无门槛",required = true)
@ApiModelProperty(value = "分享者-最低消费 0为无门槛", required = true)
private BigDecimal minPrice;
@ApiModelProperty(value = "分享者-优惠券类型 1打折卷, 2减免券 3无门槛",required = true)
@ApiModelProperty(value = "分享者-优惠券类型 1打折卷, 2减免券 3无门槛", required = true)
@Range(min = 1, max = 3, message = "请选择优惠券类型")
private Integer couponType;
@ApiModelProperty(value = "分享者-优惠券折扣")
private BigDecimal couponDiscount;
@ApiModelProperty(value = "分享者-是否多次核销 0单次核销 1多次核销",required = true)
@ApiModelProperty(value = "分享者-是否多次核销 0单次核销 1多次核销", required = true)
private Boolean verificationType;
@ApiModelProperty(value = "分享者-发放总数",required = true)
@ApiModelProperty(value = "分享者-发放总数", required = true)
private Integer couponTotal;
@ApiModelProperty(value = "分享者-每人限制领取张数",required = true)
@ApiModelProperty(value = "分享者-每人限制领取张数", required = true)
private Integer restrictedAccess;
@ApiModelProperty(value = "被分享用户标签")
private Integer userTag;
@ApiModelProperty(value = "分享者-分享人数")
private Integer peopleNumber ;
private Integer peopleNumber;
@ApiModelProperty(value = "分享者-最多优惠")
private BigDecimal preferentialLimit;
@ApiModelProperty(value = "被分享者-优惠券使用类型 1vip,2品牌券",required = true)
@ApiModelProperty(value = "被分享者-优惠券使用类型 1vip,2品牌券", required = true)
@Range(min = 1, max = 2, message = "请选择优惠券使用类型")
private Integer beSharedUseType;
......@@ -92,20 +91,20 @@ public class CouponInfoActivityVO implements Serializable {
@DecimalMax(value = "99999.99", message = "优惠券面值不能大于99999.99")
private BigDecimal beSharedCouponMoney;
@ApiModelProperty(value = "被分享者-最低消费 0为无门槛",required = true)
@ApiModelProperty(value = "被分享者-最低消费 0为无门槛", required = true)
private BigDecimal beSharedMinPrice;
@ApiModelProperty(value = "被分享者-优惠券类型 1打折卷, 2减免券 3无门槛",required = true)
@ApiModelProperty(value = "被分享者-优惠券类型 1打折卷, 2减免券 3无门槛", required = true)
@Range(min = 1, max = 3, message = "请选择优惠券类型")
private Integer beSharedCouponType;
@ApiModelProperty(value = "分享者-发放总数",required = true)
@ApiModelProperty(value = "分享者-发放总数", required = true)
private Integer beSharedCouponTotal;
@ApiModelProperty(value = "被分享者-优惠券折扣")
private BigDecimal beSharedCouponDiscount;
@ApiModelProperty(value = "被分享者-是否多次核销 0单次核销 1多次核销",required = true)
@ApiModelProperty(value = "被分享者-是否多次核销 0单次核销 1多次核销", required = true)
private Boolean beSharedVerificationType;
@ApiModelProperty(value = "被分享者-最多优惠")
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.Range;
......@@ -31,7 +28,7 @@ import java.util.Date;
//@ApiModel(value="CouponVO对象", description="优惠券表添加/修改VO")
public class CouponInfoVO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "优惠券名称", required = true)
@NotBlank(message = "请填写优惠券名称")
......@@ -53,18 +50,18 @@ public class CouponInfoVO implements Serializable {
@ApiModelProperty(value = "发放总数")
private Integer couponTotal;
@ApiModelProperty(value = "优惠券类型 1打折卷, 2减免券 3无门槛",required = true)
@ApiModelProperty(value = "优惠券类型 1打折卷, 2减免券 3无门槛", required = true)
@Range(min = 1, max = 3, message = "请选择优惠券类型")
private Integer couponType;
@ApiModelProperty(value = "优惠券使用类型 1vip,2品牌券",required = true)
@ApiModelProperty(value = "优惠券使用类型 1vip,2品牌券", required = true)
@Range(min = 1, max = 2, message = "请选择优惠券使用类型")
private Integer useType;
@ApiModelProperty(value = "所属 品牌范围id 例:5,9... ", required = true)
private String primaryKey;
@ApiModelProperty(value = "最低消费",required = true)
@ApiModelProperty(value = "最低消费", required = true)
private BigDecimal minPrice;
@ApiModelProperty(value = "有效期使用时间方式:0 固定使用时间, 1领取当日起 2领取次日起", required = true)
......@@ -81,7 +78,7 @@ public class CouponInfoVO implements Serializable {
@Max(value = 999, message = "天数不能超过999天")
private Integer couponDay;
@ApiModelProperty(value = "优惠券类型 1 手动领取 2 系统发放 3 批量导入用户",required = true)
@ApiModelProperty(value = "优惠券类型 1 手动领取 2 系统发放 3 批量导入用户", required = true)
@Range(min = 1, max = 3, message = "请选择优惠券领取方式")
private Integer getType;
......@@ -94,7 +91,7 @@ public class CouponInfoVO implements Serializable {
@ApiModelProperty(value = "最多优惠")
private BigDecimal preferentialLimit;
@ApiModelProperty(value = "是否单次核销 false单次核销 true多次核销",required = true)
@ApiModelProperty(value = "是否单次核销 false单次核销 true多次核销", required = true)
private Boolean verificationType;
@ApiModelProperty(value = "是否单次核销 0单次核销 1多次核销")
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.coupon;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
......@@ -22,18 +21,18 @@ import java.util.Date;
//@ApiModel(value="CouponUserVO对象", description="优惠券记录表修改VO")
public class CouponUserVO implements Serializable {
private static final long serialVersionUID=1L;
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "用户优惠券id",required = true)
@ApiModelProperty(value = "用户优惠券id", required = true)
private Integer id;
@ApiModelProperty(value = "订单id",required = true)
@ApiModelProperty(value = "订单id", required = true)
private Long cid;
@ApiModelProperty(value = "订单编码",required = true)
@ApiModelProperty(value = "订单编码", required = true)
private String orderNo;
@ApiModelProperty(value = "状态(0:未使用,1:已使用, 2:已失效,3:已转赠 4:使用中)",required = true)
@ApiModelProperty(value = "状态(0:未使用,1:已使用, 2:已失效,3:已转赠 4:使用中)", required = true)
@Range(min = 1, max = 4, message = "请选择优惠券类型")
private Integer status;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Update;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -48,7 +48,7 @@ public class GoodsAddVO implements Serializable {
@ApiModelProperty(value = "商品状态 0:下架 1:上架")
private Integer shelfStatus;
@ApiModelProperty(value = "规格信息")
private List<GoodsSpecVO> GoodsSpecVO;
private List<com.mmc.oms.model.vo.goods.GoodsSpecVO> GoodsSpecVO;
@ApiModelProperty(value = "其他服务: 1:免费配送,2:专业飞手培训2日, 3:半年保修, 4:一年保修 ")
private List<Integer> otherService;
@ApiModelProperty(value = "云享飞服务id")
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Update;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import com.mmc.oms.model.vo.category.CategoryParamValueVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import com.mmc.oms.model.vo.product.ProductSpecVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Update;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Update;
import com.mmc.oms.model.vo.product.PlanPackageVO;
import com.mmc.oms.model.vo.product.ProductSkuVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -46,7 +47,7 @@ public class MallGoodsAddVO implements Serializable {
private List<GoodsQaVO> question;
@ApiModelProperty(value = "清单及配置信息")
private GoodsConfigExportVO goodsConfigExport;
@ApiModelProperty(value ="规格组合集合")
@ApiModelProperty(value = "规格组合集合")
private List<SpuValuesVO> spu;
@ApiModelProperty(value = "加购商品")
private List<AddOnGoodsVO> addOnGoods;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.goods;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
......@@ -19,106 +19,106 @@ import java.util.Date;
@AllArgsConstructor
@NoArgsConstructor
public class LeaseOrderVO implements Serializable {
private static final long serialVersionUID = 3876353091071918771L;
private static final long serialVersionUID = 3876353091071918771L;
@ApiModelProperty(value = "订单编号", hidden = true)
private String orderNo;
@ApiModelProperty(value = "订单编号", hidden = true)
private String orderNo;
@ApiModelProperty(value = "商品id", example = "1")
private Integer wareInfoId;
@ApiModelProperty(value = "商品id", example = "1")
private Integer wareInfoId;
@ApiModelProperty(value = "商品编号", example = "mmcKu001")
private String wareNo;
@ApiModelProperty(value = "商品编号", example = "mmcKu001")
private String wareNo;
@ApiModelProperty(value = "商品标题", example = "入云龙")
private String wareTitle;
@ApiModelProperty(value = "商品标题", example = "入云龙")
private String wareTitle;
@ApiModelProperty(
value = "商品图片",
example =
"https://pad-video-x.oss-cn-shenzhen.aliyuncs.com/file/4edf7f84-1586-4f33-ad79-c37b9f31cbce.jpg")
private String wareImg;
@ApiModelProperty(
value = "商品图片",
example =
"https://pad-video-x.oss-cn-shenzhen.aliyuncs.com/file/4edf7f84-1586-4f33-ad79-c37b9f31cbce.jpg")
private String wareImg;
@ApiModelProperty(
value = "商品描述",
example ="新一代无人机")
private String wareDescription;
@ApiModelProperty(
value = "商品描述",
example = "新一代无人机")
private String wareDescription;
@ApiModelProperty(value = "套餐sku id", hidden = true)
private Integer skuInfoId;
@ApiModelProperty(value = "套餐sku id", hidden = true)
private Integer skuInfoId;
@ApiModelProperty(value = "套餐sku名称", hidden = true)
private String skuTitle;
@ApiModelProperty(value = "套餐sku名称", hidden = true)
private String skuTitle;
@ApiModelProperty(value = "租赁的用户id", example = "1" ,hidden = true)
private Integer repoAccountId;
@ApiModelProperty(value = "租赁的用户id", example = "1", hidden = true)
private Integer repoAccountId;
@ApiModelProperty(value = "租赁的用户uid", example = "UID008123",hidden = true)
private String uid;
@ApiModelProperty(value = "租赁的用户uid", example = "UID008123", hidden = true)
private String uid;
@ApiModelProperty(value = "租赁的用户名称", example = "xiaoXiao",hidden = true)
private String buyerName;
@ApiModelProperty(value = "租赁的用户名称", example = "xiaoXiao", hidden = true)
private String buyerName;
@ApiModelProperty(value = "租赁的用户手机", example = "18923131232",hidden = true)
private String buyerPhone;
@ApiModelProperty(value = "租赁的用户手机", example = "18923131232", hidden = true)
private String buyerPhone;
@ApiModelProperty(value = "单价 元/天", hidden = true)
private BigDecimal unitPrice;
@ApiModelProperty(value = "单价 元/天", hidden = true)
private BigDecimal unitPrice;
@ApiModelProperty(value = "租赁商品数量", example = "3")
private Integer wareNum;
@ApiModelProperty(value = "租赁商品数量", example = "3")
private Integer wareNum;
@ApiModelProperty(value = "应付款金额", example = "120")
private BigDecimal shouldPay;
@ApiModelProperty(value = "应付款金额", example = "120")
private BigDecimal shouldPay;
@ApiModelProperty(value = "实付款金额", example = "30")
private BigDecimal actualPay;
@ApiModelProperty(value = "实付款金额", example = "30")
private BigDecimal actualPay;
@ApiModelProperty(value = "订单类型 0租赁 100购买", hidden = true)
private Integer orderType;
@ApiModelProperty(value = "订单类型 0租赁 100购买", hidden = true)
private Integer orderType;
@ApiModelProperty(value = "押金 默认0", example = "0")
private BigDecimal deposit;
@ApiModelProperty(value = "押金 默认0", example = "0")
private BigDecimal deposit;
@ApiModelProperty(value = "租金总金额", example = "90")
private BigDecimal rentPrice;
@ApiModelProperty(value = "租金总金额", example = "90")
private BigDecimal rentPrice;
@ApiModelProperty(value = "租赁开始日期", example = "2023-05-20")
@JsonFormat(locale = "zh", timezone = "CMT+8", pattern = "yyyy-MM-dd")
private Date startDate;
@ApiModelProperty(value = "租赁开始日期", example = "2023-05-20")
@JsonFormat(locale = "zh", timezone = "CMT+8", pattern = "yyyy-MM-dd")
private Date startDate;
@JsonFormat(locale = "zh", timezone = "CMT+8", pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "租赁结束日期", example = "2023-05-27")
private Date endDate;
@JsonFormat(locale = "zh", timezone = "CMT+8", pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "租赁结束日期", example = "2023-05-27")
private Date endDate;
@JsonFormat(locale = "zh", timezone = "CMT+8", pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "租赁归还日期", example = "2023-05-28")
private Date returnDate;
@JsonFormat(locale = "zh", timezone = "CMT+8", pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "租赁归还日期", example = "2023-05-28")
private Date returnDate;
@ApiModelProperty(value = "付款天数", hidden = true)
private Integer payDay;
@ApiModelProperty(value = "付款天数", hidden = true)
private Integer payDay;
@ApiModelProperty(value = "减库方式---0:买家拍下减库存 1:卖家付款减库存", hidden = true)
private Integer exWare;
@ApiModelProperty(value = "减库方式---0:买家拍下减库存 1:卖家付款减库存", hidden = true)
private Integer exWare;
@ApiModelProperty(value = "交易状态: 查订单状态字典")
private String tranStatus;
@ApiModelProperty(value = "交易状态: 查订单状态字典")
private String tranStatus;
@ApiModelProperty(value = "用户备注", example = "包装需要完好")
private String remark;
@ApiModelProperty(value = "用户备注", example = "包装需要完好")
private String remark;
@ApiModelProperty(value = "")
private Integer rcdCompanyId;
@ApiModelProperty(value = "")
private Integer rcdCompanyId;
@ApiModelProperty(value = "添加时间", hidden = true)
private Date createTime;
@ApiModelProperty(value = "添加时间", hidden = true)
private Date createTime;
@ApiModelProperty(value = "收获地址")
private OrderReceiptVO orderReceipt;
@ApiModelProperty(value = "收获地址")
private OrderReceiptVO orderReceipt;
@ApiModelProperty(value = "优惠券id", example = "221")
private Integer couponId;
@ApiModelProperty(value = "优惠券id", example = "221")
private Integer couponId;
@ApiModelProperty(value = "规格id", example = "1")
private Integer specsId;
@ApiModelProperty(value = "规格id", example = "1")
private Integer specsId;
}
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.entity.OrderReceiptDO;
import com.mmc.oms.model.dto.RepoInfoDTO;
import com.mmc.oms.entity.order.OrderReceiptDO;
import com.mmc.oms.model.dto.repo.RepoInfoDTO;
import com.mmc.oms.model.vo.repo.RepoAddressDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -19,62 +20,62 @@ import java.io.Serializable;
@NoArgsConstructor
// @ApiModel(value = "com.mmc.csf.model.vo.OrderReceiptVO", description = "收货地址类")
public class OrderReceiptVO implements Serializable {
private static final long serialVersionUID = -3695743775258866831L;
private static final long serialVersionUID = -3695743775258866831L;
@ApiModelProperty(value = "", hidden = true)
private Integer id;
@ApiModelProperty(value = "", hidden = true)
private Integer id;
@ApiModelProperty(value = "订单id", example = "1")
private Integer orderInfoId;
@ApiModelProperty(value = "订单id", example = "1")
private Integer orderInfoId;
@ApiModelProperty(value = "收货方式:0邮寄 1门店地址", example = "0")
private Integer receiptMethod;
@ApiModelProperty(value = "收货方式:0邮寄 1门店地址", example = "0")
private Integer receiptMethod;
@ApiModelProperty(value = "收货人姓名", example = "xiao")
private String takeName;
@ApiModelProperty(value = "收货人姓名", example = "xiao")
private String takeName;
@ApiModelProperty(value = "收货人手机号", example = "18923323223")
private String takePhone;
@ApiModelProperty(value = "收货人手机号", example = "18923323223")
private String takePhone;
@ApiModelProperty(value = "收获区域", example = "广东省深圳市")
private String region;
@ApiModelProperty(value = "收获区域", example = "广东省深圳市")
private String region;
@ApiModelProperty(value = "收获详细地址", example = "南山区XXXX")
private String detailAddress;
@ApiModelProperty(value = "收获详细地址", example = "南山区XXXX")
private String detailAddress;
@ApiModelProperty(value = "门店名称", hidden = true)
private String repoName;
@ApiModelProperty(value = "门店名称", hidden = true)
private String repoName;
@ApiModelProperty(value = "门店地址", hidden = true)
private String repoAddress;
@ApiModelProperty(value = "门店地址", hidden = true)
private String repoAddress;
@ApiModelProperty(value = "预留手机号", hidden = true)
private String bookPhone;
@ApiModelProperty(value = "预留手机号", hidden = true)
private String bookPhone;
@ApiModelProperty(value = "物流公司编码")
private String sendExCode;
@ApiModelProperty(value = "物流公司编码")
private String sendExCode;
@ApiModelProperty(value = "物流单号")
private String sendExNo;
@ApiModelProperty(value = "物流单号")
private String sendExNo;
public void buildAddress(RepoAddressDTO d) {
this.takeName = d.getRealName();
this.takePhone = d.getPhoneNum();
this.region = d.getRegion();
this.detailAddress = d.getDetailAddress();
}
public void buildAddress(RepoAddressDTO d) {
this.takeName = d.getRealName();
this.takePhone = d.getPhoneNum();
this.region = d.getRegion();
this.detailAddress = d.getDetailAddress();
}
public void buildAddress(RepoInfoDTO d, String bookPhone) {
this.repoName = d.getRepoName();
this.repoAddress = d.getRepoAddress();
this.bookPhone = bookPhone;
}
public void buildAddress(RepoInfoDTO d, String bookPhone) {
this.repoName = d.getRepoName();
this.repoAddress = d.getRepoAddress();
this.bookPhone = bookPhone;
}
public OrderReceiptDO buildOrderReceiptDO() {
return OrderReceiptDO.builder()
.orderInfoId(this.orderInfoId)
.sendExCode(this.sendExCode)
.sendExNo(this.sendExNo)
.build();
}
public OrderReceiptDO buildOrderReceiptDO() {
return OrderReceiptDO.builder()
.orderInfoId(this.orderInfoId)
.sendExCode(this.sendExCode)
.sendExNo(this.sendExNo)
.build();
}
}
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.entity.OrderVcuDO;
import com.mmc.oms.entity.order.OrderVcuDO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.common.Freeze;
import com.mmc.oms.common.Page;
import com.mmc.oms.common.publicinterface.Freeze;
import com.mmc.oms.common.publicinterface.Page;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.common.Auto;
import com.mmc.oms.common.Send;
import com.mmc.oms.common.Take;
import com.mmc.oms.entity.OrderReceiptDO;
import com.mmc.oms.entity.OrderVcuDO;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.publicinterface.Auto;
import com.mmc.oms.common.publicinterface.Send;
import com.mmc.oms.common.publicinterface.Take;
import com.mmc.oms.entity.order.OrderReceiptDO;
import com.mmc.oms.entity.order.OrderVcuDO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -30,10 +29,10 @@ import java.util.List;
public class OrderVcuVO implements Serializable {
private static final long serialVersionUID = -4483344821357835193L;
@ApiModelProperty(value = "订单ID")
@NotNull(message = "订单id不能为空", groups = { Send.class, Auto.class })
@NotNull(message = "订单id不能为空", groups = {Send.class, Auto.class})
private Integer orderInfoId;
@ApiModelProperty(value = "退款单id(退款-发货必填,其他可不填)")
@NotNull(message = "退款单id不能为空", groups = { Auto.class })
@NotNull(message = "退款单id不能为空", groups = {Auto.class})
private Integer orderRefundId;
@ApiModelProperty(value = "物流公司编码")
@NotNull(message = "物流公司编码不能为空")
......@@ -44,16 +43,16 @@ public class OrderVcuVO implements Serializable {
@ApiModelProperty(value = "发货地址")
private String sendAddress;
@ApiModelProperty(value = "退换货-电话")
@NotNull(message = "退换货-电话不能为空", groups = { Send.class })
@NotNull(message = "退换货-电话不能为空", groups = {Send.class})
private String renPhone;
@ApiModelProperty(value = "退换货-姓名")
@NotNull(message = "退换货-姓名不能为空", groups = { Send.class })
@NotNull(message = "退换货-姓名不能为空", groups = {Send.class})
private String renName;
@ApiModelProperty(value = "退换货-地址")
@NotNull(message = "退换货-地址不能为空", groups = { Send.class })
@NotNull(message = "退换货-地址不能为空", groups = {Send.class})
private String renAddress;
@ApiModelProperty(value = "设备状况:0无问题 1有问题")
@NotNull(message = "设备状况", groups = { Take.class })
@NotNull(message = "设备状况", groups = {Take.class})
private Integer vcuSatus;
@ApiModelProperty(value = "补充描述")
private String remark;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.common.Confirm;
import com.mmc.oms.common.Query;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import javax.validation.constraints.NotNull;
/**
* @Author small
* @Date 2023/5/26 14:10
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.common.Confirm;
import com.mmc.oms.common.Query;
import com.mmc.oms.common.Update;
import com.mmc.oms.common.publicinterface.Confirm;
import com.mmc.oms.common.publicinterface.Query;
import com.mmc.oms.common.publicinterface.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -22,84 +22,84 @@ import java.util.Date;
// @ApiModel(value = "com.mmc.csf.model.vo.MathOrderVO", description = "计算租金VO")
public class RentalOrderVO implements Serializable {
private static final long serialVersionUID = -7517024869922103415L;
private static final long serialVersionUID = -7517024869922103415L;
@ApiModelProperty(value = "id")
@NotNull(
message = "订单id",
groups = {Update.class, Query.class})
private Integer id;
@ApiModelProperty(value = "id")
@NotNull(
message = "订单id",
groups = {Update.class, Query.class})
private Integer id;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "订单编号")
private String orderNo;
@ApiModelProperty(value = "商品id")
private Integer wareInfoId;
@ApiModelProperty(value = "商品id")
private Integer wareInfoId;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品编号")
private String wareNo;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品标题")
private String wareTitle;
@ApiModelProperty(value = "商品图片")
private String wareImg;
@ApiModelProperty(value = "商品图片")
private String wareImg;
@ApiModelProperty(value = "购买用户id")
private Integer repoAccountId;
@ApiModelProperty(value = "购买用户id")
private Integer repoAccountId;
@ApiModelProperty(value = "购买用户uid")
private String uid;
@ApiModelProperty(value = "购买用户uid")
private String uid;
@ApiModelProperty(value = "购买用户名称")
private String buyerName;
@ApiModelProperty(value = "购买用户名称")
private String buyerName;
@ApiModelProperty(value = "购买用户手机号")
private String buyerPhone;
@ApiModelProperty(value = "购买用户手机号")
private String buyerPhone;
@ApiModelProperty(value = "购买用户地址")
private String buyerAddress;
@ApiModelProperty(value = "购买用户地址")
private String buyerAddress;
@ApiModelProperty(value = "备注")
private String remark;
@ApiModelProperty(value = "备注")
private String remark;
private String shutReason;
private String payNo;
private Date payTime;
private Date sendWareTime;
private Integer rcdCompanyId;
private String shutReason;
private String payNo;
private Date payTime;
private Date sendWareTime;
private Integer rcdCompanyId;
@ApiModelProperty(value = "购买数量")
@Min(value = 1)
@NotNull(
message = "商品数量不能为空",
groups = {Confirm.class, Query.class})
private Integer wareNum;
@ApiModelProperty(value = "购买数量")
@Min(value = 1)
@NotNull(
message = "商品数量不能为空",
groups = {Confirm.class, Query.class})
private Integer wareNum;
@ApiModelProperty(value = "起租时间")
@NotNull(
message = "起租时间不能为空",
groups = {Confirm.class, Query.class})
private Date startDate;
@ApiModelProperty(value = "起租时间")
@NotNull(
message = "起租时间不能为空",
groups = {Confirm.class, Query.class})
private Date startDate;
@ApiModelProperty(value = "结束时间")
@NotNull(
message = "结束时间不能为空",
groups = {Confirm.class, Query.class})
private Date endDate;
@ApiModelProperty(value = "结束时间")
@NotNull(
message = "结束时间不能为空",
groups = {Confirm.class, Query.class})
private Date endDate;
@ApiModelProperty(value = "归还时间")
@NotNull(
message = "归还时间不能为空",
groups = {Confirm.class, Query.class})
private Date returnTime;
@ApiModelProperty(value = "归还时间")
@NotNull(
message = "归还时间不能为空",
groups = {Confirm.class, Query.class})
private Date returnTime;
@ApiModelProperty(value = "规格id")
@NotNull(
message = "规格id不能为null",
groups = {Confirm.class, Query.class})
private Integer specsId;
@ApiModelProperty(value = "规格id")
@NotNull(
message = "规格id不能为null",
groups = {Confirm.class, Query.class})
private Integer specsId;
@ApiModelProperty(value = "优惠券的id")
private Integer couponId;
@ApiModelProperty(value = "优惠券的id")
private Integer couponId;
}
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.entity.OrderVcuDO;
import com.mmc.oms.entity.order.OrderVcuDO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.order;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Insert;
import com.mmc.oms.common.Update;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Insert;
import com.mmc.oms.common.publicinterface.Update;
import com.mmc.oms.model.qo.BaseInfoQO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
......@@ -32,41 +32,41 @@ public class TagInfoAllotVO extends BaseInfoQO implements Serializable {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "id标识")
@NotNull(message = "id不能为空",groups = {Update.class})
@NotNull(message = "id不能为空", groups = {Update.class})
private Integer id;
@ApiModelProperty(value = "标签名称")
@NotBlank(message = "名称不能为空", groups = { Create.class, Update.class, Insert.class })
@Length(max = 70, message = "名称不能超过70个字符", groups = { Create.class, Update.class, })
@NotBlank(message = "名称不能为空", groups = {Create.class, Update.class, Insert.class})
@Length(max = 70, message = "名称不能超过70个字符", groups = {Create.class, Update.class,})
private String tagName;
@ApiModelProperty(value = "分成比例")
@Min(value = 0,message = "分成比例不能为负",groups = {Create.class,Update.class})
@Max(value = 100,message = "分成比例不能大于100",groups = {Create.class,Update.class})
@Min(value = 0, message = "分成比例不能为负", groups = {Create.class, Update.class})
@Max(value = 100, message = "分成比例不能大于100", groups = {Create.class, Update.class})
private BigDecimal proportion;
@ApiModelProperty(value = "上级分成比例")
@Min(value = 0,message = "分成比例不能为负",groups = {Create.class,Update.class})
@Max(value = 100,message = "分成比例不能大于100",groups = {Create.class,Update.class})
@Min(value = 0, message = "分成比例不能为负", groups = {Create.class, Update.class})
@Max(value = 100, message = "分成比例不能大于100", groups = {Create.class, Update.class})
private BigDecimal supProportion;
@ApiModelProperty(value = "结算时间")
@Min(value = 1,message = "结算时间不能少于1号",groups = {Create.class, Update.class})
@Max(value = 31,message = "结算时间不能大于31号",groups = {Create.class,Update.class})
@Min(value = 1, message = "结算时间不能少于1号", groups = {Create.class, Update.class})
@Max(value = 31, message = "结算时间不能大于31号", groups = {Create.class, Update.class})
private Integer balanceDate;
@ApiModelProperty(value = "提现费率")
@Min(value = 0,message = "分成比例不能为负",groups = {Create.class,Update.class})
@Max(value = 100,message = "分成比例不能大于100",groups = {Create.class, Update.class})
@Min(value = 0, message = "分成比例不能为负", groups = {Create.class, Update.class})
@Max(value = 100, message = "分成比例不能大于100", groups = {Create.class, Update.class})
private BigDecimal extractRatio;
/**
* 传入数据库为小数值
*/
public TagInfoAllotVO convertDecimals(){
this.proportion = this.proportion==null?null:this.proportion.divide(new BigDecimal("100"), 5, BigDecimal.ROUND_DOWN);
this.supProportion = this.supProportion==null?null:this.supProportion.divide(new BigDecimal("100"), 5, BigDecimal.ROUND_DOWN);
this.extractRatio = this.extractRatio==null?null:this.extractRatio.divide(new BigDecimal("100"), 5, BigDecimal.ROUND_DOWN);
public TagInfoAllotVO convertDecimals() {
this.proportion = this.proportion == null ? null : this.proportion.divide(new BigDecimal("100"), 5, BigDecimal.ROUND_DOWN);
this.supProportion = this.supProportion == null ? null : this.supProportion.divide(new BigDecimal("100"), 5, BigDecimal.ROUND_DOWN);
this.extractRatio = this.extractRatio == null ? null : this.extractRatio.divide(new BigDecimal("100"), 5, BigDecimal.ROUND_DOWN);
return this;
}
}
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.product;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.product;
import com.mmc.oms.model.vo.goods.GoodsSkuVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.product;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.product;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Update;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.product;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.product;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.repo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.repo;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Refund;
import com.mmc.oms.common.Share;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Refund;
import com.mmc.oms.common.publicinterface.Share;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
......@@ -27,23 +27,23 @@ import java.util.List;
public class RepoCashVO implements Serializable {
private static final long serialVersionUID = 1828354753495845609L;
@ApiModelProperty(value = "用户ID")
@NotNull(message = "用户ID不能为空", groups = { Create.class })
@NotNull(message = "用户ID不能为空", groups = {Create.class})
private Integer repoAccountId;
@ApiModelProperty(value = "订单ID")
@NotNull(message = "orderRefundId不能为空", groups = { Refund.class })
@NotNull(message = "orderRefundId不能为空", groups = {Refund.class})
private Integer orderRefundId;
@ApiModelProperty(value = "返租订单ID")
@NotNull(message = "shareOrderId不能为空", groups = { Share.class })
@NotNull(message = "shareOrderId不能为空", groups = {Share.class})
private Integer shareOrderId;
@ApiModelProperty(value = "变动金额")
@NotNull(message = "变动金额不能为空", groups = { Create.class, Refund.class })
@NotNull(message = "变动金额不能为空", groups = {Create.class, Refund.class})
private BigDecimal amtPaid;
@ApiModelProperty(value = "凭证图片集合")
private List<String> voucher;
@ApiModelProperty(value = "备注")
private String remark;
@ApiModelProperty(value = "操作人员密码")
@NotNull(message = "变动金额不能为空", groups = { Refund.class, Share.class })
@NotNull(message = "变动金额不能为空", groups = {Refund.class, Share.class})
private String authPwd;
}
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.repo;
import com.mmc.oms.model.dto.BaseAccountDTO;
import com.mmc.oms.model.dto.OrderInfoDTO;
import com.mmc.oms.model.dto.RepoAccountDTO;
import com.mmc.oms.model.dto.ShareOrderDTO;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.model.dto.order.OrderInfoDTO;
import com.mmc.oms.model.dto.order.ShareOrderDTO;
import com.mmc.oms.model.dto.repo.RepoAccountDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.ware;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.ware;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Update;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -28,11 +27,11 @@ import java.util.List;
public class WareInfoVO implements Serializable {
private static final long serialVersionUID = -4503117649945902464L;
@ApiModelProperty(value = "id")
@NotNull(message = "更新时ID不能为空", groups = { Update.class})
@NotNull(message = "更新时ID不能为空", groups = {Update.class})
private Integer id;
@ApiModelProperty(value = "商品名称")
@NotEmpty(message = "商品名称不能为空", groups = { Create.class})
@Size(max = 60, message = "商品名称不能超过60个字符", groups = { Create.class, Update.class })
@NotEmpty(message = "商品名称不能为空", groups = {Create.class})
@Size(max = 60, message = "商品名称不能超过60个字符", groups = {Create.class, Update.class})
private String wareTitle;
@ApiModelProperty(value = "商品类型id")
@NotNull(message = "商品类型ID不能为空", groups = {Create.class})
......@@ -49,11 +48,11 @@ public class WareInfoVO implements Serializable {
private Integer payStatus;
@ApiModelProperty(value = "一口押金-最小押金")
@NotNull(message = "最小押金不能为空", groups = {Create.class})
@Min(value = 0, groups = {Create.class, Update.class })
@Min(value = 0, groups = {Create.class, Update.class})
private BigDecimal minDeposit;
@ApiModelProperty(value = "一口价-最小日租金")
@NotNull(message = "最小租金不能为空", groups = {Create.class})
@Min(value = 0, groups = {Create.class, Update.class })
@Min(value = 0, groups = {Create.class, Update.class})
private BigDecimal minRent;
@ApiModelProperty(value = "商品标签")
private String tags;
......@@ -61,18 +60,18 @@ public class WareInfoVO implements Serializable {
@Min(value = 0, groups = {Create.class})
private Integer totalStock;
@ApiModelProperty(value = "商品详情")
@NotEmpty(message = "商品详情不能为空", groups = { Create.class })
@NotEmpty(message = "商品详情不能为空", groups = {Create.class})
private String wareDetailContent;
@ApiModelProperty(value = "sku总数量")
@Min(value = 0, groups = {Create.class, Update.class })
@Min(value = 0, groups = {Create.class, Update.class})
private Integer skuNum;
@ApiModelProperty(value = "商品图片")
@NotEmpty(message = "商品图片不能为空", groups = { Create.class })
@NotEmpty(message = "商品图片不能为空", groups = {Create.class})
private List<WareImgVO> imgList;
@ApiModelProperty(value = "新加的商品sku")
@NotEmpty(message = "商品sku不能为空", groups = {Create.class })
@NotEmpty(message = "商品sku不能为空", groups = {Create.class})
private List<WareSkuInfoVO> wareSkuInfoList;
@ApiModelProperty(value = "更新的商品sku")
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.ware;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Update;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -28,22 +27,22 @@ import java.util.List;
public class WareSkuInfoVO implements Serializable {
private static final long serialVersionUID = 7401232386069965527L;
@ApiModelProperty(value = "sku的id")
@NotNull(message = "sku的id不能为空", groups = {Update.class })
@NotNull(message = "sku的id不能为空", groups = {Update.class})
private Integer id;
@ApiModelProperty(value = "商品skuTitle名称")
@NotEmpty(message = "商品skuTitle名称不能为空", groups = { Create.class})
@NotEmpty(message = "商品skuTitle名称不能为空", groups = {Create.class})
private String skuTitle;
@ApiModelProperty(value = "出租押金")
@NotNull(message = "出租押金不能为空", groups = {Create.class})
@Min(value = 0, message = "出租押金不能小于0", groups = {Create.class, Update.class })
@Max(value = 100000000, message = "出租押金不能大于100000000", groups = {Create.class, Update.class })
@Min(value = 0, message = "出租押金不能小于0", groups = {Create.class, Update.class})
@Max(value = 100000000, message = "出租押金不能大于100000000", groups = {Create.class, Update.class})
private BigDecimal rentDeposit;
@ApiModelProperty(value = "sku库存数量")
@NotNull(message = "sku库存数量不能为空", groups = {Create.class})
@Min(value = 0, message = "sku库存数量不能小于0", groups = {Create.class, Update.class })
@Min(value = 0, message = "sku库存数量不能小于0", groups = {Create.class, Update.class})
private Integer stockNum;
@ApiModelProperty(value = "sku对应价格列表")
@NotEmpty(message = "sku对应价格列表不能为空", groups = { Create.class})
@NotEmpty(message = "sku对应价格列表不能为空", groups = {Create.class})
List<WareSkuPriceVO> wareSkuPriceVOList;
......
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.ware;
import com.mmc.oms.common.Create;
import com.mmc.oms.common.Update;
import io.swagger.annotations.ApiModel;
import com.mmc.oms.common.publicinterface.Create;
import com.mmc.oms.common.publicinterface.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
......@@ -26,20 +25,20 @@ import java.math.BigDecimal;
public class WareSkuPriceVO implements Serializable {
private static final long serialVersionUID = -3033801564005806565L;
@ApiModelProperty(value = "sku对应的id")
@NotNull(message = "sku对应的id不能为空", groups = {Update.class })
@NotNull(message = "sku对应的id不能为空", groups = {Update.class})
private Integer id;
@ApiModelProperty(value = "出租价格")
@NotNull(message = "出租价格不能为空", groups = {Create.class})
@Min(value = 0, message = "出租价格不能小于0", groups = {Create.class, Update.class })
@Max(value = 100000000, message = "出租价格不能大于100000000", groups = {Create.class, Update.class })
@Min(value = 0, message = "出租价格不能小于0", groups = {Create.class, Update.class})
@Max(value = 100000000, message = "出租价格不能大于100000000", groups = {Create.class, Update.class})
private BigDecimal rentPrice;
@ApiModelProperty(value = "起租天数")
@NotNull(message = "起租天数不能为空", groups = {Create.class })
@Min(value = 0, message = "起租天数不能小于0", groups = {Create.class, Update.class })
@NotNull(message = "起租天数不能为空", groups = {Create.class})
@Min(value = 0, message = "起租天数不能小于0", groups = {Create.class, Update.class})
private Integer minDay;
@ApiModelProperty(value = "最大天数")
@NotNull(message = "最大天数不能为空", groups = {Create.class })
@Min(value = 0, message = "最大天数不能小于0", groups = {Create.class, Update.class })
@NotNull(message = "最大天数不能为空", groups = {Create.class})
@Min(value = 0, message = "最大天数不能小于0", groups = {Create.class, Update.class})
private Integer maxDay;
}
package com.mmc.oms.model.vo;
package com.mmc.oms.model.vo.wx;
import com.alibaba.fastjson.JSONObject;
import com.mmc.oms.common.MsgData;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.util.CollectionUtils;
import org.apache.commons.lang.StringUtils;
import org.springframework.util.CollectionUtils;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.ArrayList;
......
package com.mmc.oms.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.entity.CouponDO;
import com.mmc.oms.model.dto.CouponActivityDTO;
import com.mmc.oms.model.dto.CouponDTO;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.entity.coupon.CouponDO;
import com.mmc.oms.model.dto.coupon.CouponActivityDTO;
import com.mmc.oms.model.dto.coupon.CouponDTO;
import com.mmc.oms.model.qo.CouponInfoQO;
import com.mmc.oms.model.qo.CouponUserInfoQO;
import com.mmc.oms.model.qo.ProductCouponQO;
import com.mmc.oms.model.vo.CouponInfoActivityVO;
import com.mmc.oms.model.vo.CouponInfoVO;
import com.mmc.oms.model.vo.coupon.CouponInfoActivityVO;
import com.mmc.oms.model.vo.coupon.CouponInfoVO;
import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletResponse;
......@@ -26,6 +26,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 创建-优惠券
*
* @param couponVO
* @return
*/
......@@ -33,6 +34,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 创建-裂变优惠券
*
* @param couponInfoActivityVO
* @return
*/
......@@ -41,6 +43,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 查询分页列表-优惠券
*
* @param couponInfoQO
* @return
*/
......@@ -48,6 +51,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 查询分页列表-裂变优惠券
*
* @param couponInfoQO
* @return
*/
......@@ -55,6 +59,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 裂变优惠券-下拉
*
* @return
*/
ResultBody getActivityCouponPullDown(Integer type);
......@@ -62,15 +67,17 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 根据id修改优惠券发放数量
*
* @param id
* @param count
* @return
*/
ResultBody increaseCouponCount(Integer id,Integer count);
ResultBody increaseCouponCount(Integer id, Integer count);
/**
* 根据id修改优惠卷状态
*
* @param id
* @return
*/
......@@ -79,6 +86,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 获取优惠券使用数据
*
* @param id 优惠券id
* @return
*/
......@@ -87,6 +95,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 获取优惠卷明细列表
*
* @param couponUserInfoQO
* @return
*/
......@@ -94,6 +103,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 优惠卷明细列表导出
*
* @param response
* @param couponUserInfoQO
* @throws IOException
......@@ -102,6 +112,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 获取优惠卷详情
*
* @param ids id
* @return
*/
......@@ -110,6 +121,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 根据id获取裂变优惠券详情
*
* @param id
* @return
*/
......@@ -117,6 +129,7 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 根据id获取裂变优惠券详情
*
* @param id
* @return
*/
......@@ -124,8 +137,9 @@ public interface CouponBackService extends IService<CouponDO> {
/**
* 扣减数量
* @param id 优惠券id
* @param num 数量
*
* @param id 优惠券id
* @param num 数量
* @param isLimited 是否限量
*/
Boolean deduction(Integer id, Integer num, Boolean isLimited);
......
package com.mmc.oms.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.entity.CouponUserDO;
import com.mmc.oms.model.dto.BaseAccountDTO;
import com.mmc.oms.model.dto.CouponUserDTO;
import com.mmc.oms.model.dto.CouponUserOrderDTO;
import com.mmc.oms.model.dto.OrderCouponDTO;
import com.mmc.oms.model.vo.CouponUserExchangeVO;
import com.mmc.oms.model.vo.CouponUserVO;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.entity.coupon.CouponUserDO;
import com.mmc.oms.model.dto.coupon.CouponUserDTO;
import com.mmc.oms.model.dto.coupon.CouponUserOrderDTO;
import com.mmc.oms.model.dto.order.OrderCouponDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.vo.coupon.CouponUserExchangeVO;
import com.mmc.oms.model.vo.coupon.CouponUserVO;
import java.util.List;
......@@ -21,17 +21,19 @@ public interface CouponUserService extends IService<CouponUserDO> {
/**
* 查询我的优惠券
* @param status 优惠券状态 1:已使用, 2:已失效,3:已转赠
* @param pageNo 页码
* @param pageSize 每页数
*
* @param status 优惠券状态 1:已使用, 2:已失效,3:已转赠
* @param pageNo 页码
* @param pageSize 每页数
* @param currentAccount 用户信息
* @return
*/
ResultBody getMyList(Integer status,Integer pageNo,Integer pageSize,BaseAccountDTO currentAccount);
ResultBody getMyList(Integer status, Integer pageNo, Integer pageSize, BaseAccountDTO currentAccount);
/**
* 领取优惠券
* @param id 优惠券id
*
* @param id 优惠券id
* @param currentAccount 用户信息
* @return
*/
......@@ -39,7 +41,8 @@ public interface CouponUserService extends IService<CouponUserDO> {
/**
* 批量领取优惠券
* @param id 优惠券id
*
* @param id 优惠券id
* @param currentAccount 用户信息
* @return
*/
......@@ -48,32 +51,36 @@ public interface CouponUserService extends IService<CouponUserDO> {
/**
* 转增优惠券
* @param id 优惠券
* @param uid 用户uid
*
* @param id 优惠券
* @param uid 用户uid
* @return
*/
ResultBody presentedCoupon(Integer id,String uid,BaseAccountDTO currentAccount);
ResultBody presentedCoupon(Integer id, String uid, BaseAccountDTO currentAccount);
/**
* 获取可领取优惠券列表
*
* @param priority 品牌id,搜索品牌指定优惠卷
* @param pageNo 页码
* @param pageNo 页码
* @param pageSize 每页数
* @return
*/
ResultBody getList(List<Integer> priority,Integer pageNo,Integer pageSize,BaseAccountDTO currentAccount);
ResultBody getList(List<Integer> priority, Integer pageNo, Integer pageSize, BaseAccountDTO currentAccount);
/**
* 根据品牌获取可用优惠券
*
* @param primaryKey 品牌id
* @param uid 用户信息
* @param uid 用户信息
* @return
*/
List<CouponUserOrderDTO> getUsableCoupon(List<Integer> primaryKey, Integer uid);
/**
* 根据id获取我的优惠券详情
*
* @param couponId id
* @return
*/
......@@ -82,6 +89,7 @@ public interface CouponUserService extends IService<CouponUserDO> {
/**
* 下单修改我的优惠券
*
* @param couponUserVO 优惠券记录表修改VO
* @return
*/
......@@ -100,12 +108,13 @@ public interface CouponUserService extends IService<CouponUserDO> {
/**
* 优惠券回退
*
* @param orderCouponDTOS
* @return
*/
Boolean feignRollbackCoupons(List<OrderCouponDTO> orderCouponDTOS);
ResultBody couponMerchandise(Integer couponId,String productName,Integer useType);
ResultBody couponMerchandise(Integer couponId, String productName, Integer useType);
ResultBody couponUsageDetails(Integer uid);
}
......@@ -14,19 +14,28 @@ import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.mmc.oms.common.*;
import com.mmc.oms.common.EasyExcelListener;
import com.mmc.oms.common.coupon.CouponConstants;
import com.mmc.oms.common.coupon.CouponUserExcel;
import com.mmc.oms.common.result.PageResult;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.common.util.TDateUtil;
import com.mmc.oms.dao.CouponBackDao;
import com.mmc.oms.dao.CouponUserDao;
import com.mmc.oms.entity.ChannelCouponDO;
import com.mmc.oms.entity.CouponDO;
import com.mmc.oms.entity.CouponUserDO;
import com.mmc.oms.entity.ProductInformationDo;
import com.mmc.oms.model.dto.*;
import com.mmc.oms.entity.coupon.ChannelCouponDO;
import com.mmc.oms.entity.coupon.CouponDO;
import com.mmc.oms.entity.coupon.CouponUserDO;
import com.mmc.oms.entity.order.ProductInformationDo;
import com.mmc.oms.model.dto.coupon.CouponActivityDTO;
import com.mmc.oms.model.dto.coupon.CouponDTO;
import com.mmc.oms.model.dto.coupon.CouponUserDTO;
import com.mmc.oms.model.dto.coupon.CouponViewDTO;
import com.mmc.oms.model.dto.user.MallUserDTO;
import com.mmc.oms.model.qo.CouponInfoQO;
import com.mmc.oms.model.qo.CouponUserInfoQO;
import com.mmc.oms.model.qo.ProductCouponQO;
import com.mmc.oms.model.vo.CouponInfoActivityVO;
import com.mmc.oms.model.vo.CouponInfoVO;
import com.mmc.oms.model.vo.coupon.CouponInfoActivityVO;
import com.mmc.oms.model.vo.coupon.CouponInfoVO;
import com.mmc.oms.service.CouponBackService;
import com.mmc.oms.service.CouponUserService;
import org.apache.commons.lang3.StringUtils;
......@@ -80,9 +89,9 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
if (count > 0) {
return ResultBody.error("优惠券名重复");
}
if (CouponConstants.COUPON_TYPE_REDUCED.equals(couponVO.getCouponType())){
if (CouponConstants.COUPON_TYPE_REDUCED.equals(couponVO.getCouponType())) {
int flag = couponVO.getMinPrice().compareTo(couponVO.getCouponMoney());
if (flag < 0){
if (flag < 0) {
return ResultBody.error("优惠券最低消费不能小于面值");
}
}
......@@ -95,24 +104,24 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
CouponDTO couponDTO = couponDO.bilIdCouponDTO();
//批量导入用户
if (file != null){
if (file != null) {
List<ChannelCouponDO> channelCouponDOS = redeExcel(file);
List<String> uid = new ArrayList<>();
List<String> phone = new ArrayList<>();
for (ChannelCouponDO channelCouponDO : channelCouponDOS) {
if (StringUtils.isNotBlank(channelCouponDO.getUid())){
if (StringUtils.isNotBlank(channelCouponDO.getUid())) {
uid.add(channelCouponDO.getUid());
}else {
} else {
phone.add(channelCouponDO.getUserPhone());
}
}
//远程调用 批量查询用户信息
List<MallUserDTO> mallUserDTOS =null;
//mallUserClient.feignGetListUserDTO(uid, phone);
if(mallUserDTOS!=null && mallUserDTOS.size() > 0){
List<MallUserDTO> mallUserDTOS = null;
//mallUserClient.feignGetListUserDTO(uid, phone);
if (mallUserDTOS != null && mallUserDTOS.size() > 0) {
//查看当前优惠券剩余量
if (couponDO.getIsLimited() && couponDO.getLastTotal() < mallUserDTOS.size()){
if (couponDO.getIsLimited() && couponDO.getLastTotal() < mallUserDTOS.size()) {
return ResultBody.error("当前剩余量不够领取");
}
List<CouponUserDO> couponUserList = extracted(couponDO, mallUserDTOS);
......@@ -143,15 +152,15 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
return ResultBody.error("优惠券名重复");
}
if (CouponConstants.COUPON_TYPE_REDUCED.equals(couponInfoActivityVO.getCouponType()) ||
CouponConstants.COUPON_TYPE_REDUCED.equals(couponInfoActivityVO.getBeSharedCouponType())){
CouponConstants.COUPON_TYPE_REDUCED.equals(couponInfoActivityVO.getBeSharedCouponType())) {
int flag = couponInfoActivityVO.getMinPrice().compareTo(couponInfoActivityVO.getCouponMoney());
int i = couponInfoActivityVO.getBeSharedMinPrice().compareTo(couponInfoActivityVO.getBeSharedCouponMoney());
if (flag < 0 || i < 0){
if (flag < 0 || i < 0) {
return ResultBody.error("优惠券最低消费不能小于面值");
}
}
if (couponInfoActivityVO.getBeSharedCouponTotal() < couponInfoActivityVO.getCouponTotal()){
if (couponInfoActivityVO.getBeSharedCouponTotal() < couponInfoActivityVO.getCouponTotal()) {
return ResultBody.error("被分享者券发行量应大于等于分享者券发行量*分享人数*1.5");
}
CouponDO couponDO = new CouponDO(couponInfoActivityVO);
......@@ -167,7 +176,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
this.save(couponActivity);
return Boolean.TRUE;
});
if (execute){
if (execute) {
return ResultBody.success();
} else {
return ResultBody.error("请稍后重试");
......@@ -181,16 +190,16 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
List<CouponUserDO> couponUserList = new ArrayList<>();
//优惠券有效期使用时间
if (CouponConstants.COUPON_USE_TIME_THE_DAY.equals(couponDO.getIsFixedTime())){
if (CouponConstants.COUPON_USE_TIME_THE_DAY.equals(couponDO.getIsFixedTime())) {
//领取当日起
couponDO.setUseStartTime(date);
couponDO.setUseEndTime(DateUtil.offsetDay(date, couponDay));
}else if (CouponConstants.COUPON_USE_TIME_NEXT_DAY.equals(couponDO.getIsFixedTime())){
} else if (CouponConstants.COUPON_USE_TIME_NEXT_DAY.equals(couponDO.getIsFixedTime())) {
//领取次日起
DateTime dateTime = DateUtil.offsetDay(date, 1);
couponDO.setUseStartTime(dateTime);
couponDO.setUseEndTime(DateUtil.offsetDay(dateTime, couponDay));
}else {
} else {
couponDO.setUseStartTime(couponDO.getUseStartTime());
couponDO.setUseEndTime(couponDO.getUseEndTime());
}
......@@ -221,13 +230,13 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
if (StringUtils.isNotBlank(couponInfoQO.getCouponId())) {
queryWrapper.like(CouponDO::getId, couponInfoQO.getCouponId());
}
if (couponInfoQO.getState() != null){
if (couponInfoQO.getState() != null) {
queryWrapper.eq(CouponDO::getCouponStatus, couponInfoQO.getState());
}
if (StringUtils.isNotBlank(couponInfoQO.getStartTime())){
if (StringUtils.isNotBlank(couponInfoQO.getStartTime())) {
queryWrapper.ge(CouponDO::getCreateTime, couponInfoQO.getStartTime());
}
if (StringUtils.isNotBlank(couponInfoQO.getEndTime())){
if (StringUtils.isNotBlank(couponInfoQO.getEndTime())) {
queryWrapper.le(CouponDO::getCreateTime, couponInfoQO.getEndTime());
}
......@@ -235,7 +244,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
queryWrapper.eq(CouponDO::getUseType, couponInfoQO.getUseType());
queryWrapper.orderByDesc(CouponDO::getCreateTime);
Page<CouponDO> pages = new Page<>(couponInfoQO.getPageNo(), couponInfoQO.getPageSize());
Page<CouponDO> pageInfo = this.page(pages, queryWrapper);
Page<CouponDO> pageInfo = this.page(pages, queryWrapper);
List<CouponDTO> collect = pageInfo.getRecords().stream().map(CouponDO::bilIdCouponDTO)
.collect(Collectors.toList());
......@@ -255,7 +264,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
if (StringUtils.isNotBlank(couponInfoQO.getCouponId())) {
queryWrapper.like(CouponDO::getId, couponInfoQO.getCouponId());
}
if (couponInfoQO.getState() != null){
if (couponInfoQO.getState() != null) {
queryWrapper.eq(CouponDO::getCouponStatus, couponInfoQO.getState());
}
queryWrapper.eq(CouponDO::getIsDel, false);
......@@ -264,13 +273,13 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
queryWrapper.isNull(CouponDO::getParentId);
queryWrapper.orderByDesc(CouponDO::getCreateTime);
Page<CouponDO> pages = new Page<>(couponInfoQO.getPageNo(), couponInfoQO.getPageSize());
Page<CouponDO> pageInfo = this.page(pages, queryWrapper);
Page<CouponDO> pageInfo = this.page(pages, queryWrapper);
List<CouponActivityDTO> collect = pageInfo.getRecords().stream().map(CouponDO::bilIdCouponActivityDTO)
.collect(Collectors.toList());
for (CouponActivityDTO couponActivityDTO : collect) {
LambdaQueryWrapper<CouponDO> activityWrapper = new LambdaQueryWrapper<>();
activityWrapper.eq(CouponDO::getParentId,couponActivityDTO.getId());
activityWrapper.eq(CouponDO::getParentId, couponActivityDTO.getId());
CouponActivityDTO activityDTO = this.getOne(activityWrapper).bilIdCouponActivityDTO();
activityDTO.setActivityRole("beShare");
couponActivityDTO.setBeSharedCoupon(activityDTO);
......@@ -284,9 +293,9 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
@Override
public ResultBody getActivityCouponPullDown(Integer type) {
LambdaQueryWrapper<CouponDO> queryWrapper = new LambdaQueryWrapper<>();
if (type == 2){
queryWrapper.eq(CouponDO::getGetType,CouponConstants.COUPON_ISSUE_TYPE_INITIATIVE);
}else {
if (type == 2) {
queryWrapper.eq(CouponDO::getGetType, CouponConstants.COUPON_ISSUE_TYPE_INITIATIVE);
} else {
queryWrapper.eq(CouponDO::getGetType, CouponConstants.COUPON_USR_TYPE_ACTIVITY);
queryWrapper.isNull(CouponDO::getParentId);
}
......@@ -297,13 +306,13 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
.collect(Collectors.toList());
for (CouponActivityDTO couponActivityDTO : collect) {
LambdaQueryWrapper<CouponDO> activityWrapper = new LambdaQueryWrapper<>();
activityWrapper.eq(CouponDO::getParentId,couponActivityDTO.getId());
activityWrapper.eq(CouponDO::getParentId, couponActivityDTO.getId());
CouponDO one = this.getOne(activityWrapper);
if (one != null){
if (one != null) {
CouponActivityDTO activityDTO = one.bilIdCouponActivityDTO();
activityDTO.setActivityRole("beShare");
couponActivityDTO.setBeSharedCoupon(activityDTO);
}else {
} else {
couponActivityDTO.setActivityRole(null);
}
}
......@@ -330,11 +339,11 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
LambdaUpdateWrapper<CouponDO> update = new LambdaUpdateWrapper();
update.eq(CouponDO::getId, id)
.set(CouponDO::getCouponTotal, newCouponTotal)
.set(CouponDO::getLastTotal,newLastTotal);
.set(CouponDO::getLastTotal, newLastTotal);
boolean updateStatus = update(update);
if (updateStatus){
if (updateStatus) {
return ResultBody.success();
}else {
} else {
return ResultBody.error("增发失败,请稍后再试");
}
}
......@@ -343,24 +352,24 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
@Override
public ResultBody shutDown(Integer id) {
CouponDO couponDO = getById(id);
if (couponDO == null){
if (couponDO == null) {
return ResultBody.error("该优惠券不存在");
}
LambdaQueryWrapper<CouponDO> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(CouponDO::getParentId,couponDO.getId());
queryWrapper.eq(CouponDO::getParentId, couponDO.getId());
List<CouponDO> list = list(queryWrapper);
if (list.size() > 0){
if (list.size() > 0) {
CouponDO coupon = list.get(0);
LambdaUpdateWrapper<CouponDO> updateWrapper = new LambdaUpdateWrapper<>();
updateWrapper.eq(CouponDO::getId,coupon.getId()).set(CouponDO::getCouponStatus,false);
updateWrapper.eq(CouponDO::getId, coupon.getId()).set(CouponDO::getCouponStatus, false);
update(updateWrapper);
}
LambdaUpdateWrapper<CouponDO> updateWrapper = new LambdaUpdateWrapper<>();
updateWrapper.eq(CouponDO::getId,id).set(CouponDO::getCouponStatus,false);
updateWrapper.eq(CouponDO::getId, id).set(CouponDO::getCouponStatus, false);
boolean update = update(updateWrapper);
if (update){
if (update) {
return ResultBody.success();
}else {
} else {
return ResultBody.error("关闭失败,请稍后再试");
}
}
......@@ -372,7 +381,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
//总发行量
CouponDO couponInfo = this.getById(id);
if (couponInfo == null){
if (couponInfo == null) {
return ResultBody.error("该优惠券不存在");
}
Integer couponTotal = couponInfo.getCouponTotal();
......@@ -380,20 +389,20 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
//领取量:用户成功领取的券数;
LambdaQueryWrapper<CouponUserDO> queryWrap = new LambdaQueryWrapper<>();
queryWrap.eq(CouponUserDO::getCouponId,id);
queryWrap.eq(CouponUserDO::getCouponId, id);
queryWrap.ne(CouponUserDO::getStatus, CouponConstants.STORE_COUPON_USER_STATUS_PRESENTED);
long receiveQuantity = couponUserService.count(queryWrap);
//领取率:(领取量 / 总发行量) * 100%;
String claimRate = df.format(((float)receiveQuantity / (float)couponTotal) * 100) + "%";
String claimRate = df.format(((float) receiveQuantity / (float) couponTotal) * 100) + "%";
//订单中心
List<Long> collect = couponUserDao.getOrderList(id);
ResultBody resultBody = null;
if (collect.size() > 0){
if (collect.size() > 0) {
resultBody = null;
//mallOrderClient.feignOrderUseCoupon(collect);
//mallOrderClient.feignOrderUseCoupon(collect);
}
//用户待付款订单使用的优惠券数量
......@@ -401,8 +410,8 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
//已付款订单使用的优惠券数量 = 有效使用量:用户结算的时候,成功使用优惠券进行抵扣金额的优惠券数量(已付款订单)
Integer accountPaid = 0;
if (resultBody != null){
Map<String,Integer> result = (Map<String, Integer>) resultBody.getResult();
if (resultBody != null) {
Map<String, Integer> result = (Map<String, Integer>) resultBody.getResult();
obligation = result.get("obligation");
accountPaid = result.get("accountPaid");
}
......@@ -412,10 +421,10 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
String availability;
//有效使用率:(有效使用量 / 使用量) * 100%;
if (usageAmount <= 0 ){
if (usageAmount <= 0) {
availability = 0 + "%";
}else {
availability = df.format(((float)accountPaid / (float)usageAmount) * 100) + "%";
} else {
availability = df.format(((float) accountPaid / (float) usageAmount) * 100) + "%";
}
......@@ -472,7 +481,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
public CouponActivityDTO getCouponActivityById(Integer id) {
CouponActivityDTO couponActivityDTO = this.getById(id).bilIdCouponActivityDTO();
LambdaQueryWrapper<CouponDO> activityWrapper = new LambdaQueryWrapper<>();
activityWrapper.eq(CouponDO::getParentId,couponActivityDTO.getId());
activityWrapper.eq(CouponDO::getParentId, couponActivityDTO.getId());
CouponActivityDTO activityDTO = this.getOne(activityWrapper).bilIdCouponActivityDTO();
activityDTO.setActivityRole("beShare");
couponActivityDTO.setBeSharedCoupon(activityDTO);
......@@ -484,9 +493,9 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
List<CouponActivityDTO> collect = this.listByIds(id).stream().map(CouponDO::bilIdCouponActivityDTO)
.collect(Collectors.toList());
for (CouponActivityDTO couponActivityDTO : collect) {
if (couponActivityDTO.getParentId() != null){
if (couponActivityDTO.getParentId() != null) {
LambdaQueryWrapper<CouponDO> activityWrapper = new LambdaQueryWrapper<>();
activityWrapper.eq(CouponDO::getParentId,couponActivityDTO.getId());
activityWrapper.eq(CouponDO::getParentId, couponActivityDTO.getId());
CouponActivityDTO activityDTO = this.getOne(activityWrapper).bilIdCouponActivityDTO();
activityDTO.setActivityRole("beShare");
couponActivityDTO.setBeSharedCoupon(activityDTO);
......@@ -509,7 +518,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
return update(updateWrapper);
}
public List<ChannelCouponDO> redeExcel(MultipartFile file){
public List<ChannelCouponDO> redeExcel(MultipartFile file) {
EasyExcelListener<ChannelCouponDO> listener = new EasyExcelListener<ChannelCouponDO>();
ExcelReader build = null;
try {
......@@ -533,11 +542,11 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
type = "后台发放";
} else if (CouponConstants.STORE_COUPON_USER_TYPE_PRESENTED.equals(m.getCouponType())) {
type = "赠送";
}else if (CouponConstants.STORE_COUPON_USER_TYPE_ACQUIRE.equals(m.getCouponType())) {
} else if (CouponConstants.STORE_COUPON_USER_TYPE_ACQUIRE.equals(m.getCouponType())) {
type = "获赠";
}else if (CouponConstants.STORE_COUPON_USER_TYPE_EXCHANGE.equals(m.getCouponType())) {
} else if (CouponConstants.STORE_COUPON_USER_TYPE_EXCHANGE.equals(m.getCouponType())) {
type = "兑换";
}else if (CouponConstants.STORE_COUPON_USER_TYPE_ACTIVITY.equals(m.getCouponType())) {
} else if (CouponConstants.STORE_COUPON_USER_TYPE_ACTIVITY.equals(m.getCouponType())) {
type = "活动领取";
}
String status = null;
......@@ -547,9 +556,9 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
status = "已使用";
} else if (CouponConstants.STORE_COUPON_USER_STATUS_LAPSED.equals(m.getStatus())) {
status = "已失效";
}else if (CouponConstants.STORE_COUPON_USER_STATUS_PRESENTED.equals(m.getStatus())) {
} else if (CouponConstants.STORE_COUPON_USER_STATUS_PRESENTED.equals(m.getStatus())) {
status = "已转赠";
}else if (CouponConstants.STORE_COUPON_USER_STATUS_IN_USE.equals(m.getStatus())) {
} else if (CouponConstants.STORE_COUPON_USER_STATUS_IN_USE.equals(m.getStatus())) {
status = "使用中";
}
String entAuthStatus = null;
......@@ -559,7 +568,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
entAuthStatus = "单次核销";
}
String transform = null;
if (m.getConversionRatio() != null){
if (m.getConversionRatio() != null) {
transform = "1:" + m.getConversionRatio();
}
return CouponUserExcel.builder()
......@@ -573,6 +582,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
.useTime(m.getUseTime())
.orderNo(m.getOrderNo()).build();
}
@Override
public void overdueCouponTask() {
// 查询所有状态——可用的优惠券
......@@ -581,7 +591,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
queryWrapper.eq(CouponDO::getIsDel, false);
queryWrapper.eq(CouponDO::getIsFixedTime, CouponConstants.COUPON_USE_TIME_FIXED);
List<CouponDO> list = this.list(queryWrapper);
if (CollUtil.isEmpty(list)){
if (CollUtil.isEmpty(list)) {
return;
}
List<CouponDO> updateList = CollUtil.newArrayList();
......@@ -594,11 +604,11 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
}
});
if (CollUtil.isEmpty(updateList)){
if (CollUtil.isEmpty(updateList)) {
return;
}
boolean update = this.updateBatchById(updateList);
if (!update){
if (!update) {
log.error("批量更新优惠券状态动作失败");
}
......@@ -619,7 +629,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
public ResultBody ordinaryActivities(ProductCouponQO productCouponQO) {
Integer goodsInfoId = productCouponQO.getGoodsInfoId();
ProductInformationDo product = couponBackDao.findProduct(goodsInfoId);
if (product==null){
if (product == null) {
return ResultBody.error("当前商品没有优惠券");
}
List<CouponDO> couponDOS = couponBackDao.ordinaryActivities(product.getBrandId());
......@@ -632,7 +642,7 @@ public class CouponBackServiceImpl extends ServiceImpl<CouponBackDao, CouponDO>
public ResultBody fissionActivity(ProductCouponQO productCouponQO) {
Integer goodsInfoId = productCouponQO.getGoodsInfoId();
ProductInformationDo product = couponBackDao.findProduct(goodsInfoId);
if (product==null){
if (product == null) {
return ResultBody.error("当前商品没有优惠券");
}
List<CouponDO> couponDOS = couponBackDao.fissionActivity(product.getBrandId());
......
......@@ -10,20 +10,33 @@ import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.mmc.oms.common.*;
import com.mmc.oms.common.MsgData;
import com.mmc.oms.common.WxMsgDataConfig;
import com.mmc.oms.common.coupon.CouponConstants;
import com.mmc.oms.common.coupon.CouponType;
import com.mmc.oms.common.result.PageResult;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.common.util.TDateUtil;
import com.mmc.oms.config.FlyerSystemConstant;
import com.mmc.oms.dao.CouponBackDao;
import com.mmc.oms.dao.CouponUserDao;
import com.mmc.oms.entity.CouponDO;
import com.mmc.oms.entity.CouponUsageDetailsDO;
import com.mmc.oms.entity.CouponUserDO;
import com.mmc.oms.entity.GoodsInfoDO;
import com.mmc.oms.model.dto.*;
import com.mmc.oms.entity.coupon.CouponDO;
import com.mmc.oms.entity.coupon.CouponUsageDetailsDO;
import com.mmc.oms.entity.coupon.CouponUserDO;
import com.mmc.oms.entity.goods.GoodsInfoDO;
import com.mmc.oms.model.dto.coupon.CouponListDTO;
import com.mmc.oms.model.dto.coupon.CouponUsageDetailsDTO;
import com.mmc.oms.model.dto.coupon.CouponUserDTO;
import com.mmc.oms.model.dto.coupon.CouponUserOrderDTO;
import com.mmc.oms.model.dto.goods.AppGoodsInfoDTO;
import com.mmc.oms.model.dto.order.OrderCouponDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.dto.user.MallUserDTO;
import com.mmc.oms.model.qo.CouponUserInfoQO;
import com.mmc.oms.model.vo.AppletMsgVO;
import com.mmc.oms.model.vo.CouponUserExchangeVO;
import com.mmc.oms.model.vo.CouponUserVO;
import com.mmc.oms.model.vo.WxSendMsgVO;
import com.mmc.oms.model.vo.coupon.AppletMsgVO;
import com.mmc.oms.model.vo.coupon.CouponUserExchangeVO;
import com.mmc.oms.model.vo.coupon.CouponUserVO;
import com.mmc.oms.model.vo.wx.WxSendMsgVO;
import com.mmc.oms.service.CouponBackService;
import com.mmc.oms.service.CouponUserService;
import com.mmc.oms.wx.WxMsgTemplete;
......@@ -53,7 +66,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
@Autowired
private TransactionTemplate transactionTemplate;
// @Autowired
// @Autowired
//private MallUserClient mallUserClient;
@Resource
......@@ -62,16 +75,16 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
@Resource
private CouponBackDao couponBackDao;
// @Autowired
// private UserServletClient userServletClient;
// @Autowired
// private UserServletClient userServletClient;
//VIP优惠券
private final Integer VIPCOUPON=1;
private final Integer BRAND_COUPONS=2;
private final Integer VIPCOUPON = 1;
private final Integer BRAND_COUPONS = 2;
@Override
public ResultBody getMyList(Integer status,Integer pageNo,Integer pageSize, BaseAccountDTO currentAccount) {
public ResultBody getMyList(Integer status, Integer pageNo, Integer pageSize, BaseAccountDTO currentAccount) {
Integer uid = currentAccount.getUserAccountId();
LambdaQueryWrapper<CouponUserDO> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(CouponUserDO::getUid, uid);
......@@ -83,13 +96,13 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
queryWrapper.and(wq -> wq.eq(CouponUserDO::getStatus, status));
}
queryWrapper.orderByDesc(CouponUserDO::getCreateTime);
Page<CouponUserDO> pages = new Page<>(pageNo,pageSize);
Page<CouponUserDO> pages = new Page<>(pageNo, pageSize);
Page<CouponUserDO> pageInfo = this.page(pages, queryWrapper);
List<CouponUserDTO> collect = pageInfo.getRecords().stream().map(CouponUserDO::bilIdCouponDTO)
.collect(Collectors.toList());
PageResult pageResult = PageResult.buildPage(pageNo,pageSize, (int) pageInfo.getTotal(), collect);
PageResult pageResult = PageResult.buildPage(pageNo, pageSize, (int) pageInfo.getTotal(), collect);
return ResultBody.success(pageResult);
}
......@@ -98,7 +111,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
public ResultBody receiveCoupon(Integer id, BaseAccountDTO currentAccount) {
//获取优惠券信息
CouponDO couponDO = couponBackService.getById(id);
if (couponDO == null){
if (couponDO == null) {
return ResultBody.error("暂无该优惠券");
}
......@@ -124,7 +137,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
// }
// }
if (!couponDO.getGetType().equals(CouponConstants.COUPON_USR_TYPE_ACTIVITY)){
if (!couponDO.getGetType().equals(CouponConstants.COUPON_USR_TYPE_ACTIVITY)) {
//查看当前优惠券是否限制每人领取
LambdaQueryWrapper<CouponUserDO> queryWrap = new LambdaQueryWrapper<>();
queryWrap.eq(CouponUserDO::getUid, currentAccount.getUserAccountId()).eq(CouponUserDO::getCouponId, id);
......@@ -153,10 +166,10 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
couponUser.setUuid(currentAccount.getUid());
couponUser.setUserPhone(currentAccount.getPhoneNum());
//如果优惠券是活动券 则为活动领取
if (CouponConstants.COUPON_USR_TYPE_ACTIVITY.equals(couponDO.getGetType())){
if (CouponConstants.COUPON_USR_TYPE_ACTIVITY.equals(couponDO.getGetType())) {
couponUser.setGainType(CouponConstants.STORE_COUPON_USER_TYPE_ACTIVITY);
//如果优惠券用户标签不为空 则为系统发放
}else if (couponDO.getUserTag() != null){
} else if (couponDO.getUserTag() != null) {
couponUser.setGainType(CouponConstants.STORE_COUPON_USER_TYPE_SEND);
} else {
couponUser.setGainType(CouponConstants.STORE_COUPON_USER_TYPE_GET);
......@@ -164,7 +177,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
couponUser.setCreateTime(date);
List<CouponUserDO> couponUserList = new ArrayList<>();
//系统发放的同一张优惠券如果每人限领数量在多次以上 一次性领取多张
if (CouponConstants.COUPON_ISSUE_TYPE_INITIATIVE.equals(couponDO.getGetType())){
if (CouponConstants.COUPON_ISSUE_TYPE_INITIATIVE.equals(couponDO.getGetType())) {
Integer restrictedAccess = couponDO.getRestrictedAccess();
// if (restrictedAccess > 1){
// for (Integer integer = 0; integer < restrictedAccess; integer++) {
......@@ -174,7 +187,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
for (Integer integer = 0; integer < restrictedAccess; integer++) {
couponUserList.add(couponUser);
}
}else {
} else {
couponUserList.add(couponUser);
}
Boolean execute = transactionTemplate.execute(e -> {
......@@ -185,18 +198,19 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
});
if (execute) {
asynSendUserAppletMsg(currentAccount.getUserAccountId(),couponDO) ;
asynSendUserAppletMsg(currentAccount.getUserAccountId(), couponDO);
return ResultBody.success();
} else {
return ResultBody.error("领取失败,请稍后再试");
}
}
public void asynSendUserAppletMsg(Integer userId, CouponDO couponDO){
public void asynSendUserAppletMsg(Integer userId, CouponDO couponDO) {
BigDecimal couponMoney = couponDO.getCouponMoney();
MallUserDTO mallUserDTO =null;
MallUserDTO mallUserDTO = null;
// mallUserClient.feignGetSimpleUserInfo(userId);
if(Objects.nonNull(mallUserDTO)){
if (Objects.nonNull(mallUserDTO)) {
AppletMsgVO aMsg = new AppletMsgVO();
aMsg.setTouser(mallUserDTO.getOpenId());
aMsg.setTemplate_id(WxMsgTemplete.BOUNTY_ACCOUNT_INFORM);
......@@ -211,30 +225,30 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
//备注
JSONObject thing4 = new JSONObject();
//打折券
if (CouponType.DISCOUNT_COUPONS.equals(couponDO.getCouponType())){
if (CouponType.DISCOUNT_COUPONS.equals(couponDO.getCouponType())) {
//无门槛
// 奖励类型
thing1.put("value", "折扣优惠券奖励");
// 奖励金额
amount2.put("value",null);
amount2.put("value", null);
// 备注
thing4.put("value",String.format("恭喜,%s折优惠券已到账",couponDO.getCouponDiscount()));
}else if(CouponType.REDUCTION_ROLLS.equals(couponDO.getCouponType())){
thing4.put("value", String.format("恭喜,%s折优惠券已到账", couponDO.getCouponDiscount()));
} else if (CouponType.REDUCTION_ROLLS.equals(couponDO.getCouponType())) {
//满减
// 奖励类型
thing1.put("value", "满减优惠券奖励");
// 奖励金额
amount2.put("value",null);
amount2.put("value", null);
// 备注
thing4.put("value",String.format("恭喜,满%s减%s优惠券已到账",couponDO.getMinPrice(),couponDO.getCouponMoney()));
}else if(CouponType.NO_THRESHOLD.equals(couponDO.getCouponType())){
thing4.put("value", String.format("恭喜,满%s减%s优惠券已到账", couponDO.getMinPrice(), couponDO.getCouponMoney()));
} else if (CouponType.NO_THRESHOLD.equals(couponDO.getCouponType())) {
//无门槛
// 奖励类型
thing1.put("value", "奖励到账通知");
amount2.put("value", couponMoney);
// 备注
String format = String.format("恭喜,%s元平台优惠券已到账",couponMoney);
thing4.put("value",format);
String format = String.format("恭喜,%s元平台优惠券已到账", couponMoney);
thing4.put("value", format);
}
JSONObject data = new JSONObject();
data.put("thing1", thing1);
......@@ -242,7 +256,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
data.put("time3", time3);
data.put("thing4", thing4);
aMsg.setData(data);
// mallUserClient.asynSendUserAppletMsg(aMsg);
// mallUserClient.asynSendUserAppletMsg(aMsg);
}
}
......@@ -253,7 +267,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
Boolean execute = true;
StringBuffer sb = new StringBuffer();
List<Integer> list = new ArrayList<>();
if (couponDOS.size() > 0){
if (couponDOS.size() > 0) {
for (CouponDO couponDO : couponDOS) {
//查看优惠券状态 开启并且未删除
if (!couponDO.getCouponStatus() || couponDO.getIsDel()) {
......@@ -268,7 +282,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
continue;
}
//查看当前优惠券是否限制每人领取
if (couponDO.getIsLimited()){
if (couponDO.getIsLimited()) {
LambdaQueryWrapper<CouponUserDO> queryWrap = new LambdaQueryWrapper<>();
queryWrap.eq(CouponUserDO::getUid, currentAccount.getUserAccountId()).eq(CouponUserDO::getCouponId, couponDO.getId());
long count = this.count(queryWrap);
......@@ -297,10 +311,10 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
couponUser.setUuid(currentAccount.getUid());
couponUser.setUserPhone(currentAccount.getPhoneNum());
//如果优惠券是活动券 则为活动领取
if (CouponConstants.COUPON_USR_TYPE_ACTIVITY.equals(couponDO.getGetType())){
if (CouponConstants.COUPON_USR_TYPE_ACTIVITY.equals(couponDO.getGetType())) {
couponUser.setGainType(CouponConstants.STORE_COUPON_USER_TYPE_ACTIVITY);
//如果优惠券用户标签不为空 则为系统发放
}else if (couponDO.getUserTag() != null){
} else if (couponDO.getUserTag() != null) {
couponUser.setGainType(CouponConstants.STORE_COUPON_USER_TYPE_SEND);
} else {
couponUser.setGainType(CouponConstants.STORE_COUPON_USER_TYPE_GET);
......@@ -308,12 +322,12 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
couponUser.setCreateTime(date);
List<CouponUserDO> couponUserList = new ArrayList<>();
//系统发放的同一张优惠券如果每人限领数量在多次以上 一次性领取多张
if (CouponConstants.COUPON_ISSUE_TYPE_INITIATIVE.equals(couponDO.getGetType())){
if (CouponConstants.COUPON_ISSUE_TYPE_INITIATIVE.equals(couponDO.getGetType())) {
Integer restrictedAccess = couponDO.getRestrictedAccess();
for (Integer integer = 0; integer < restrictedAccess; integer++) {
couponUserList.add(couponUser);
}
}else {
} else {
couponUserList.add(couponUser);
}
execute = transactionTemplate.execute(e -> {
......@@ -328,16 +342,16 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
if (execute) {
List<CouponDO> collect = couponDOS.stream().filter(e -> {
for (Integer integer : list) {
if (integer.equals(e.getId())){
if (integer.equals(e.getId())) {
return false;
}
}
return true;
}).collect(Collectors.toList());
System.out.println(collect);
log.info("消息发送成功"+collect);
collect.stream().forEach(t->{
asynSendUserAppletMsgList(currentAccount.getUserAccountId(),t);
log.info("消息发送成功" + collect);
collect.stream().forEach(t -> {
asynSendUserAppletMsgList(currentAccount.getUserAccountId(), t);
});
return ResultBody.success(sb);
} else {
......@@ -347,11 +361,11 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
}
public void asynSendUserAppletMsgList(Integer userId,CouponDO couponDO){
public void asynSendUserAppletMsgList(Integer userId, CouponDO couponDO) {
BigDecimal couponMoney = couponDO.getCouponMoney();
MallUserDTO mallUserDTO =null;
//mallUserClient.feignGetSimpleUserInfo(userId);
if(Objects.nonNull(mallUserDTO)){
MallUserDTO mallUserDTO = null;
//mallUserClient.feignGetSimpleUserInfo(userId);
if (Objects.nonNull(mallUserDTO)) {
AppletMsgVO aMsg = new AppletMsgVO();
aMsg.setTouser(mallUserDTO.getOpenId());
aMsg.setTemplate_id(WxMsgTemplete.BOUNTY_ACCOUNT_INFORM);
......@@ -366,30 +380,30 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
//备注
JSONObject thing4 = new JSONObject();
//打折券
if (CouponType.DISCOUNT_COUPONS.equals(couponDO.getCouponType())){
if (CouponType.DISCOUNT_COUPONS.equals(couponDO.getCouponType())) {
//打折券
// 奖励类型
thing1.put("value", "折扣优惠券奖励");
// 奖励金额
amount2.put("value",null);
amount2.put("value", null);
// 备注
thing4.put("value",String.format("恭喜,%s折优惠券已到账",couponDO.getCouponDiscount()));
}else if(CouponType.REDUCTION_ROLLS.equals(couponDO.getCouponType())){
thing4.put("value", String.format("恭喜,%s折优惠券已到账", couponDO.getCouponDiscount()));
} else if (CouponType.REDUCTION_ROLLS.equals(couponDO.getCouponType())) {
//满减
// 奖励类型
thing1.put("value", "满减优惠券奖励");
// 奖励金额
amount2.put("value",null);
amount2.put("value", null);
// 备注
thing4.put("value",String.format("恭喜,满%s减%s优惠券已到账",couponDO.getMinPrice(),couponDO.getCouponMoney()));
}else if(CouponType.NO_THRESHOLD.equals(couponDO.getCouponType())){
thing4.put("value", String.format("恭喜,满%s减%s优惠券已到账", couponDO.getMinPrice(), couponDO.getCouponMoney()));
} else if (CouponType.NO_THRESHOLD.equals(couponDO.getCouponType())) {
//无门槛
// 奖励类型
thing1.put("value", "奖励到账通知");
amount2.put("value", couponMoney);
// 备注
String format = String.format("恭喜,%s元平台优惠券已到账",couponMoney);
thing4.put("value",format);
String format = String.format("恭喜,%s元平台优惠券已到账", couponMoney);
thing4.put("value", format);
}
JSONObject data = new JSONObject();
data.put("thing1", thing1);
......@@ -397,25 +411,25 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
data.put("time3", time3);
data.put("thing4", thing4);
aMsg.setData(data);
// mallUserClient.asynSendUserAppletMsg(aMsg);
// mallUserClient.asynSendUserAppletMsg(aMsg);
}
}
@Override
public ResultBody presentedCoupon(Integer id, String uid,BaseAccountDTO currentAccount) {
public ResultBody presentedCoupon(Integer id, String uid, BaseAccountDTO currentAccount) {
CouponUserDO couponUser = getById(id);
if (couponUser == null) {
return ResultBody.error("该优惠券不存在");
}
if (CouponConstants.STORE_COUPON_USER_STATUS_USED.equals(couponUser.getStatus()) ||
CouponConstants.STORE_COUPON_USER_STATUS_IN_USE.equals(couponUser.getStatus())){
CouponConstants.STORE_COUPON_USER_STATUS_IN_USE.equals(couponUser.getStatus())) {
return ResultBody.error("该优惠券已使用不能转赠");
}
if (CouponConstants.STORE_COUPON_USER_TYPE_ACTIVITY.equals(couponUser.getGainType())){
if (CouponConstants.STORE_COUPON_USER_TYPE_ACTIVITY.equals(couponUser.getGainType())) {
return ResultBody.error("该优惠券不能转赠");
}
String uuid = "UID" + uid;
PageResult<List<MallUserDTO>> listPageResult =null;
PageResult<List<MallUserDTO>> listPageResult = null;
// mallUserClient.feignMallUserBySearchKey(uuid, 1, 10);
if (listPageResult != null && listPageResult.getList() != null) {
List<MallUserDTO> list = listPageResult.getList();
......@@ -446,8 +460,8 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
});
if (execute) {
Integer useType = couponUser.getUseType();
if (VIPCOUPON.equals(useType)){
asynSendMessage(couponUser.getUid(),couponUser.getCouponMoney());
if (VIPCOUPON.equals(useType)) {
asynSendMessage(couponUser.getUid(), couponUser.getCouponMoney());
}
return ResultBody.success();
} else {
......@@ -459,10 +473,10 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
}
public void asynSendMessage(Integer userId, BigDecimal couponMoney){
MallUserDTO mallUserDTO =null;
//mallUserClient.feignGetSimpleUserInfo(userId);
if(Objects.nonNull(mallUserDTO)){
public void asynSendMessage(Integer userId, BigDecimal couponMoney) {
MallUserDTO mallUserDTO = null;
//mallUserClient.feignGetSimpleUserInfo(userId);
if (Objects.nonNull(mallUserDTO)) {
WxSendMsgVO param = new WxSendMsgVO();
param.setWxAppltAppId(FlyerSystemConstant.AppletFlyerWxAppid);
// 对接
......@@ -478,26 +492,24 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
k1.setValue("VIP优惠券");
data.add(k1);
MsgData k2 = new MsgData();
k2.setValue(couponMoney+"");
k2.setValue(couponMoney + "");
data.add(k2);
MsgData k3 = new MsgData();
k3.setValue(TDateUtil.getCurrentDate());
data.add(k3);
MsgData k4 = new MsgData();
String format = String.format("恭喜,好友赠送%s元VIP优惠券已到账",couponMoney);
String format = String.format("恭喜,好友赠送%s元VIP优惠券已到账", couponMoney);
k4.setValue(format);
data.add(k4);
param.setData(data);
// param.setRemark(remark);
// userServletClient.asynSendMessage(param);
// userServletClient.asynSendMessage(param);
}
}
@Override
public ResultBody getList( List<Integer> priority,Integer pageNo,Integer pageSize, BaseAccountDTO currentAccount) {
public ResultBody getList(List<Integer> priority, Integer pageNo, Integer pageSize, BaseAccountDTO currentAccount) {
String date = DateUtil.now();
String categoryIdStr = priority.stream().map(Object::toString).collect(Collectors.joining("|"));
StringBuffer sb = new StringBuffer();
......@@ -529,7 +541,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
couponListDTO.setIsUse(true);
LambdaQueryWrapper<CouponUserDO> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(CouponUserDO::getUid, userId);
queryWrapper.eq(CouponUserDO::getCouponId,coupon.getId());
queryWrapper.eq(CouponUserDO::getCouponId, coupon.getId());
int count = Math.toIntExact(this.count(queryWrapper));
couponListDTO.setReceivedCount(count);
}
......@@ -542,14 +554,14 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
}
@Override
public List<CouponUserOrderDTO> getUsableCoupon(List<Integer> primaryKey,Integer uid) {
public List<CouponUserOrderDTO> getUsableCoupon(List<Integer> primaryKey, Integer uid) {
String categoryIdStr = primaryKey.stream().map(Object::toString).collect(Collectors.joining("|"));
String date = DateUtil.now();
StringBuffer sb = new StringBuffer();
sb.append(",(").append(categoryIdStr).append(")");
//可用优惠券
List<CouponUserDO> couponUserDOS = couponUserDao.selectCouponUserList(sb.toString(),uid, date);
List<CouponUserDO> couponUserDOS = couponUserDao.selectCouponUserList(sb.toString(), uid, date);
List<CouponUserOrderDTO> collect = couponUserDOS.stream().map(CouponUserDO::buildCouponUserOrderDTO)
.collect(Collectors.toList());
......@@ -558,7 +570,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
lambdaQueryWrapper.eq(CouponUserDO::getUid, uid);
lambdaQueryWrapper.ge(CouponUserDO::getEndTime, new Date());
lambdaQueryWrapper.and(i -> i.eq(CouponUserDO::getStatus, CouponConstants.STORE_COUPON_USER_STATUS_USABLE)
.or().eq(CouponUserDO::getStatus,CouponConstants.STORE_COUPON_USER_STATUS_IN_USE));
.or().eq(CouponUserDO::getStatus, CouponConstants.STORE_COUPON_USER_STATUS_IN_USE));
List<CouponUserDO> list = this.list(lambdaQueryWrapper);
List<CouponUserOrderDTO> disable = list.stream().map(CouponUserDO::buildCouponUserOrderDTO)
......@@ -566,7 +578,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
for (CouponUserOrderDTO couponUserOrderDTO : collect) {
for (CouponUserOrderDTO userOrderDTO : disable) {
if (couponUserOrderDTO.getId().equals(userOrderDTO.getId())){
if (couponUserOrderDTO.getId().equals(userOrderDTO.getId())) {
userOrderDTO.setValidStr("usable");
}
}
......@@ -593,7 +605,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
this.updateById(couponUserDO);
return Boolean.TRUE;
});
if (!execute){
if (!execute) {
updateById = false;
}
}
......@@ -610,7 +622,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
couponUserDO.setStatus(CouponConstants.STORE_COUPON_USER_STATUS_USABLE);
couponUserDO.setStartTime(date);
//兑换vip卷过期时间=+50年
DateTime dateTime = DateUtil.offset(date, DateField.YEAR,50);
DateTime dateTime = DateUtil.offset(date, DateField.YEAR, 50);
couponUserDO.setEndTime(dateTime);
couponUserDO.setCreateTime(date);
return this.save(couponUserDO);
......@@ -622,7 +634,7 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
LambdaQueryWrapper<CouponUserDO> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(CouponUserDO::getStatus, CouponConstants.STORE_COUPON_USER_STATUS_USABLE);
List<CouponUserDO> list = this.list(queryWrapper);
if (CollUtil.isEmpty(list)){
if (CollUtil.isEmpty(list)) {
return;
}
......@@ -636,11 +648,11 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
}
});
if (CollUtil.isEmpty(updateList)){
if (CollUtil.isEmpty(updateList)) {
return;
}
boolean update = this.updateBatchById(updateList);
if (!update){
if (!update) {
log.error("批量更新优惠券过期动作失败");
}
......@@ -667,29 +679,29 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
public Boolean feignRollbackCoupons(List<OrderCouponDTO> orderCouponDTOS) {
log.info("feignRollbackCoupons优惠券回滚:{}", JSONObject.toJSON(orderCouponDTOS));
Set<Long> orderIds = orderCouponDTOS.stream().map(d -> d.getOrderId()).collect(Collectors.toSet());
List<Integer> ids = orderCouponDTOS.stream().map(d->d.getCouponUserId()).collect(Collectors.toList());
List<Integer> ids = orderCouponDTOS.stream().map(d -> d.getCouponUserId()).collect(Collectors.toList());
List<CouponUserDO> couponUserDOS = couponUserDao.selectBatchIds(ids);
//批量删除该订单相关优惠券
couponUserDao.batchRemoveByOIds(orderIds);
couponUserDOS.forEach(d->{
if (d.getUseType().equals(1) || (d.getUseType().equals(2) && d.getCouponType().equals(3)) ){
couponUserDOS.forEach(d -> {
if (d.getUseType().equals(1) || (d.getUseType().equals(2) && d.getCouponType().equals(3))) {
//vip和无门槛券
if (d.getVerificationType() == null || d.getVerificationType().equals(true)){
if (d.getVerificationType() == null || d.getVerificationType().equals(true)) {
//多次核销
for (OrderCouponDTO couponDTO : orderCouponDTOS) {
if (d.getId().toString().equals(couponDTO.getCouponUserId().toString())){
if (d.getId().toString().equals(couponDTO.getCouponUserId().toString())) {
d.setStatus(4);
d.setRemainingBalance(d.getRemainingBalance() == null ? couponDTO.getUseAmount() : d.getRemainingBalance().add(couponDTO.getUseAmount()));
break;
}
}
}else {
} else {
//单次核销
d.setStatus(0);
d.setRemainingBalance(d.getCouponMoney());
d.setUseTime(null);
}
}else {
} else {
//满减和折扣
d.setStatus(0);
d.setUseTime(null);
......@@ -700,24 +712,24 @@ public class CouponUserServiceImpl extends ServiceImpl<CouponUserDao, CouponUser
}
@Override
public ResultBody couponMerchandise(Integer couponId,String productName,Integer useType) {
List<AppGoodsInfoDTO> collect =null;
List<GoodsInfoDO> goodsInfoDos=null;
if (VIPCOUPON.equals(useType)){
public ResultBody couponMerchandise(Integer couponId, String productName, Integer useType) {
List<AppGoodsInfoDTO> collect = null;
List<GoodsInfoDO> goodsInfoDos = null;
if (VIPCOUPON.equals(useType)) {
goodsInfoDos = couponUserDao.VipCouponMerchandise(productName);
}else if(BRAND_COUPONS.equals(useType)){
} else if (BRAND_COUPONS.equals(useType)) {
List<Integer> merchandise = couponUserDao.merchandise(couponId);
if (merchandise.size()==0){
if (merchandise.size() == 0) {
return ResultBody.error("当前优惠券没有关联的商品");
}
goodsInfoDos = couponUserDao.couponMerchandise(merchandise,productName);
goodsInfoDos = couponUserDao.couponMerchandise(merchandise, productName);
}
collect = goodsInfoDos.stream().map(GoodsInfoDO::buildAppGoodsInfoDTO).collect(Collectors.toList());
return ResultBody.success(collect);
}
@Override
public ResultBody couponUsageDetails(Integer uid){
public ResultBody couponUsageDetails(Integer uid) {
List<CouponUsageDetailsDO> couponUsageDetailsDOS = couponUserDao.couponUsageDetails(uid);
List<CouponUsageDetailsDTO> collect = couponUsageDetailsDOS.stream().map(CouponUsageDetailsDO::bilIdCouponUsageDetailsDTO).collect(Collectors.toList());
return ResultBody.success(collect);
......
......@@ -2,15 +2,33 @@ package com.mmc.oms.service.Impl;
import com.alibaba.fastjson.JSONObject;
import com.mmc.oms.common.*;
import com.mmc.oms.common.json.JsonUtil;
import com.mmc.oms.common.publicinterface.Publicsher;
import com.mmc.oms.common.result.PageResult;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.common.status.TranStatusDic;
import com.mmc.oms.common.status.WarePayStatus;
import com.mmc.oms.common.util.KdnExpressUtil;
import com.mmc.oms.common.util.TDateUtil;
import com.mmc.oms.dao.OrderLogisticsDao;
import com.mmc.oms.dao.OrderRefundDao;
import com.mmc.oms.entity.OrderInfoDO;
import com.mmc.oms.entity.OrderReceiptDO;
import com.mmc.oms.entity.OrderRefundDO;
import com.mmc.oms.entity.OrderVcuDO;
import com.mmc.oms.model.dto.*;
import com.mmc.oms.entity.order.OrderInfoDO;
import com.mmc.oms.entity.order.OrderReceiptDO;
import com.mmc.oms.entity.order.OrderRefundDO;
import com.mmc.oms.entity.order.OrderVcuDO;
import com.mmc.oms.model.dto.company.CompanyInfoDTO;
import com.mmc.oms.model.dto.kdn.KdnDicDTO;
import com.mmc.oms.model.dto.kdn.KdnExpDTO;
import com.mmc.oms.model.dto.order.*;
import com.mmc.oms.model.dto.repo.RepoAccountDTO;
import com.mmc.oms.model.dto.repo.RepoInfoDTO;
import com.mmc.oms.model.dto.transtatus.TranStatusDicDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.dto.user.UserAccountDTO;
import com.mmc.oms.model.qo.OrderInfoQO;
import com.mmc.oms.model.vo.*;
import com.mmc.oms.model.vo.coupon.AppletMsgVO;
import com.mmc.oms.model.vo.order.*;
import com.mmc.oms.model.vo.repo.RepoOrderPayVO;
import com.mmc.oms.service.OrderLogisticsService;
import com.mmc.oms.wx.WxMsgTemplete;
import lombok.extern.slf4j.Slf4j;
......@@ -22,7 +40,6 @@ import org.springframework.transaction.annotation.Transactional;
import org.springframework.transaction.interceptor.TransactionAspectSupport;
import org.springframework.util.CollectionUtils;
import javax.annotation.Resource;
import java.util.*;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ThreadPoolExecutor;
......@@ -64,8 +81,8 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
@Autowired
private StringRedisTemplate stringRedisTemplate;
@Autowired
private Publicsher publicsher;
@Autowired
private Publicsher publicsher;
@Autowired
private ThreadPoolExecutor executor;
......@@ -129,7 +146,7 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
data.put("amount6", amount6);
data.put("thing9", thing9);
aMsg.setData(data);
// repoServletClient.asynSendUserAppletMsg(aMsg);
// repoServletClient.asynSendUserAppletMsg(aMsg);
}
@Override
......@@ -175,7 +192,7 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
OrderInfoVO stock = OrderInfoVO.builder().wareInfoId(order.getWareInfoId()).skuInfoId(order.getSkuInfoId())
.addStock(order.getWareNum()).build();
ResultBody stockResult = null;
//wareServletClient.feignOrderNum(stock);
//wareServletClient.feignOrderNum(stock);
return stockResult;
}
return ResultBody.success();
......@@ -194,8 +211,8 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
if (WarePayStatus.BEFORE.getStatus().equals(order.getExWare().toString())) {
OrderInfoVO stock = OrderInfoVO.builder().wareInfoId(order.getWareInfoId()).skuInfoId(order.getSkuInfoId())
.addStock(order.getWareNum()).build();
ResultBody stockResult =null;
//wareServletClient.feignOrderNum(stock);
ResultBody stockResult = null;
//wareServletClient.feignOrderNum(stock);
return stockResult;
}
return ResultBody.success();
......@@ -277,8 +294,8 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
}
OrderInfoVO stock = OrderInfoVO.builder().exWare(orderInfo.getExWare()).wareInfoId(orderInfo.getWareInfoId())
.skuInfoId(orderInfo.getSkuInfoId()).addStock(addStock).addSale(addSale).build();
ResultBody stockResult =null;
//wareServletClient.feignOrderNum(stock);
ResultBody stockResult = null;
//wareServletClient.feignOrderNum(stock);
if (!ResultEnum.SUCCESS.getResultCode().equals(stockResult.getCode())) {
TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
return stockResult;
......@@ -287,7 +304,7 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
// 结账流水
RepoOrderPayVO orderPay = RepoOrderPayVO.builder().orderInfo(orderInfo).account(account).build();
PayCashResultDTO result = null;
//repoPayServletClient.feignPayCashOrder(orderPay);
//repoPayServletClient.feignPayCashOrder(orderPay);
if (!ResultEnum.SUCCESS.getResultCode().equals(result.getStatus())) {
TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
return ResultBody.error(result.getStatus(), result.getMessage());
......@@ -369,7 +386,7 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
public ResultBody sendOrderWare(BaseAccountDTO cuser, OrderVcuVO param) {
// 密码认证
ResultBody body = null;
//userServletClient.feignAuthUserPwd(cuser.getId(), param.getAuthPwd());
//userServletClient.feignAuthUserPwd(cuser.getId(), param.getAuthPwd());
if (!ResultEnum.SUCCESS.getResultCode().equals(body.getCode())) {
return body;
}
......@@ -402,8 +419,8 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
private void sendShipMsg(Integer orderInfoId) {
OrderInfoDO orderInfo = orderLogisticsDao.getOrderInfo(orderInfoId);
RepoAccountDTO wechat =null;
//repoServletClient.feignRepoLoginInfo(orderInfo.getRepoAccountId());
RepoAccountDTO wechat = null;
//repoServletClient.feignRepoLoginInfo(orderInfo.getRepoAccountId());
OrderReceiptDO receipt = orderLogisticsDao.getOrderReceiptByOrder(orderInfoId);
if (wechat == null || StringUtils.isBlank(wechat.getOpenId())) {
return;
......@@ -496,7 +513,7 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
return ResultBody.error(ResultEnum.SHOP_RETURN_ERROR);
}
RepoInfoDTO repoInfo = null;
//repoDeviceServletClient.feignGetRepoShop(param.getRepoInfoId());
//repoDeviceServletClient.feignGetRepoShop(param.getRepoInfoId());
if (repoInfo == null) {
return ResultBody.error(ResultEnum.FEIGN_DEVICE_SERVLET_ERROR);
}
......@@ -506,7 +523,7 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
receipt.setRenRepoName(repoInfo.getRepoName());
receipt.setRenRepoAddr(repoInfo.getRepoAddress());
UserAccountDTO repoUser = null;
//userServletClient.feignGetUserSimpleInfo(repoInfo.getUserAccountId());
//userServletClient.feignGetUserSimpleInfo(repoInfo.getUserAccountId());
if (repoUser == null) {
return ResultBody.error(ResultEnum.FEIGN_USER_SERVLET_ERROR);
}
......@@ -531,8 +548,8 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
@Override
public ResultBody pfConfirmOrderWare(BaseAccountDTO cuser, OrderVcuVO param) {
// 密码认证
ResultBody body =null;
//userServletClient.feignAuthUserPwd(cuser.getId(), param.getAuthPwd());
ResultBody body = null;
//userServletClient.feignAuthUserPwd(cuser.getId(), param.getAuthPwd());
if (!ResultEnum.SUCCESS.getResultCode().equals(body.getCode())) {
return body;
}
......@@ -557,43 +574,43 @@ public class OrderLogisticsServiceImpl implements OrderLogisticsService {
@Override
public void SynchronousDataToPushMoney(String OrderNo) {
CompletableFuture.runAsync(()->{
CompletableFuture.runAsync(() -> {
OrderInfoDO upOrder = orderLogisticsDao.getOrderDetail(OrderNo);
Integer rcdCompanyId = upOrder.getRcdCompanyId();
Integer repoAccountId = upOrder.getRepoAccountId();
Date createTime = upOrder.getCreateTime();
if(rcdCompanyId == null){
if (rcdCompanyId == null) {
log.info("推荐机构ID为空,不参与过分成管理");
}
// 通过用户ID查找对应分享码单位
ResultBody<CompanyInfoDTO> result = null;
//userServletClient.queryCompanyInfoById(rcdCompanyId);
if(Objects.isNull(result)){
//userServletClient.queryCompanyInfoById(rcdCompanyId);
if (Objects.isNull(result)) {
// 失败重试
result = null;
//userServletClient.queryCompanyInfoById(rcdCompanyId);
//userServletClient.queryCompanyInfoById(rcdCompanyId);
}
if(Objects.isNull(result)){
log.info("订单ID为[{}],推荐机构ID为[{}],没有参与过分享码活动",upOrder.getId(),rcdCompanyId);
if (Objects.isNull(result)) {
log.info("订单ID为[{}],推荐机构ID为[{}],没有参与过分享码活动", upOrder.getId(), rcdCompanyId);
return;
}
if(Objects.isNull(result.getResult().getId())){
log.info("订单ID为[{}],用户ID为[{}],没有参与过分享码活动,不记录到分成明细中",upOrder.getId(),repoAccountId);
if (Objects.isNull(result.getResult().getId())) {
log.info("订单ID为[{}],用户ID为[{}],没有参与过分享码活动,不记录到分成明细中", upOrder.getId(), repoAccountId);
}
CompanyInfoDTO companyInfoDTO = result.getResult();
// 记录到订单明细中
String s = stringRedisTemplate.opsForValue().get(RedisConstant.TAGINFOALLOT_QUESTALL);
if(s==null){
if (s == null) {
log.error("访问redis的key值失败,其key为[{}]", RedisConstant.TAGINFOALLOT_QUESTALL);
return;
}
List<TagInfoAllotVO> tagInfoAllotDOS = JSONObject.parseArray(s,TagInfoAllotVO.class);
List<TagInfoAllotVO> tagInfoAllotDOS = JSONObject.parseArray(s, TagInfoAllotVO.class);
Optional<TagInfoAllotVO> tagInfoAllot = tagInfoAllotDOS.stream().filter(item -> item.getTagName().equals(companyInfoDTO.getChannelLevel())).findFirst();
if(Objects.nonNull(tagInfoAllot)){
if (Objects.nonNull(tagInfoAllot)) {
TagInfoAllotVO tagInfoAllotVO = tagInfoAllot.get();
//orderServletClient.pushMoneyDetailInsert(new PushMoneyDetailVO(upOrder.getOrderNo(),repoAccountId,companyInfoDTO.getId(),tagInfoAllotVO.getProportion(),tagInfoAllotVO.getSupProportion(),PushMoneyEnum.STORE_CHANNEL.getCode(),createTime));
}
},executor);
}, executor);
}
@Override
......
package com.mmc.oms.service.Impl;
import com.mmc.oms.common.*;
import com.mmc.oms.common.ResultEnum;
import com.mmc.oms.common.VcuType;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.common.status.RefundStatus;
import com.mmc.oms.common.status.TranStatusDic;
import com.mmc.oms.common.util.CodeUtil;
import com.mmc.oms.dao.OrderRefundDao;
import com.mmc.oms.dao.RentalOrdersDao;
import com.mmc.oms.entity.OrderInfoDO;
import com.mmc.oms.entity.OrderRefundDO;
import com.mmc.oms.entity.OrderVcuDO;
import com.mmc.oms.model.dto.BaseAccountDTO;
import com.mmc.oms.model.vo.OrderRefundVO;
import com.mmc.oms.model.vo.RefundYesOrNoVO;
import com.mmc.oms.entity.order.OrderInfoDO;
import com.mmc.oms.entity.order.OrderRefundDO;
import com.mmc.oms.entity.order.OrderVcuDO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.vo.order.OrderRefundVO;
import com.mmc.oms.model.vo.order.RefundYesOrNoVO;
import com.mmc.oms.service.OrderRefundService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
......
......@@ -2,12 +2,26 @@ package com.mmc.oms.service.Impl;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.mmc.oms.common.*;
import com.mmc.oms.common.RenMethod;
import com.mmc.oms.common.ResultEnum;
import com.mmc.oms.common.VcuType;
import com.mmc.oms.common.WxMsgDataConfig;
import com.mmc.oms.common.json.JsonUtil;
import com.mmc.oms.common.result.PageResult;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.common.status.TranStatusDic;
import com.mmc.oms.common.util.CodeUtil;
import com.mmc.oms.dao.RentalOrdersDao;
import com.mmc.oms.entity.*;
import com.mmc.oms.model.dto.*;
import com.mmc.oms.entity.coupon.CouponDO;
import com.mmc.oms.entity.order.*;
import com.mmc.oms.entity.ware.WareInfoDO;
import com.mmc.oms.model.dto.order.*;
import com.mmc.oms.model.dto.repo.RepoAccountDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.dto.user.UserAccountSimpleDTO;
import com.mmc.oms.model.qo.OrderInfoQO;
import com.mmc.oms.model.vo.*;
import com.mmc.oms.model.vo.coupon.AppletMsgVO;
import com.mmc.oms.model.vo.order.*;
import com.mmc.oms.service.RentalOrdersService;
import com.mmc.oms.wx.WxMsgTemplete;
import org.apache.commons.lang.StringUtils;
......@@ -56,7 +70,10 @@ public class RentalOrdersServiceImpl implements RentalOrdersService {
@Override
public OrderInfoDTO feignAddLease(BaseAccountDTO user, LeaseOrderVO param) {
public ResultBody feignAddLease(BaseAccountDTO user, LeaseOrderVO param) {
if (0 == user.getPortType()) {
return ResultBody.error(ResultEnum.THE_CURRENT_ACCOUNT_CANNOT_PLACE_ORDERS);
}
//用户信息的远程调用
ResponseEntity<String> responseEntity = UserId(user.getUserAccountId());
UserAccountSimpleDTO account = JSON.parseObject(responseEntity.getBody(), UserAccountSimpleDTO.class);
......@@ -87,7 +104,7 @@ public class RentalOrdersServiceImpl implements RentalOrdersService {
// 将当前的用户id及订单编号存入redis
OrderInfoDTO dto = orderInfo.buildOrderInfoDTO();
stringRedisTemplate.opsForValue().set(orderInfo.getOrderNo(), JsonUtil.parseObjToJson(dto));
return dto;
return ResultBody.success(dto);
}
/**
......
package com.mmc.oms.service;
import com.mmc.oms.common.PageResult;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.model.dto.*;
import com.mmc.oms.common.result.PageResult;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.dto.kdn.KdnDicDTO;
import com.mmc.oms.model.dto.order.CountOrderDTO;
import com.mmc.oms.model.dto.order.ExpressInfoDTO;
import com.mmc.oms.model.dto.order.OrderInfoDTO;
import com.mmc.oms.model.dto.order.OrderReceiptDTO;
import com.mmc.oms.model.dto.transtatus.TranStatusDicDTO;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.qo.OrderInfoQO;
import com.mmc.oms.model.vo.LeaseOrderVO;
import com.mmc.oms.model.vo.OrderReceiptVO;
import com.mmc.oms.model.vo.OrderVcuVO;
import com.mmc.oms.model.vo.ReturnWareVO;
import com.mmc.oms.model.vo.order.LeaseOrderVO;
import com.mmc.oms.model.vo.order.OrderReceiptVO;
import com.mmc.oms.model.vo.order.OrderVcuVO;
import com.mmc.oms.model.vo.order.ReturnWareVO;
import java.util.List;
......@@ -41,7 +47,7 @@ public interface OrderLogisticsService {
List<ExpressInfoDTO> listExpressInfo();
PageResult listPcOrderInfo(OrderInfoQO param,BaseAccountDTO cuser);
PageResult listPcOrderInfo(OrderInfoQO param, BaseAccountDTO cuser);
CountOrderDTO countOrderInfo(BaseAccountDTO cuser);
......@@ -69,7 +75,7 @@ public interface OrderLogisticsService {
int listPcOrderInfoCount();
Integer getOrderInfoCount(Integer dayNum,Integer dateType);
Integer getOrderInfoCount(Integer dayNum, Integer dateType);
ResultBody testSendMsg(Integer id);
......
package com.mmc.oms.service;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.model.dto.BaseAccountDTO;
import com.mmc.oms.model.vo.OrderRefundVO;
import com.mmc.oms.model.vo.RefundYesOrNoVO;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.vo.order.OrderRefundVO;
import com.mmc.oms.model.vo.order.RefundYesOrNoVO;
/**
* @Author small
......
package com.mmc.oms.service;
import com.mmc.oms.common.PageResult;
import com.mmc.oms.common.ResultBody;
import com.mmc.oms.model.dto.BaseAccountDTO;
import com.mmc.oms.model.dto.OrderInfoDTO;
import com.mmc.oms.common.result.PageResult;
import com.mmc.oms.common.result.ResultBody;
import com.mmc.oms.model.dto.user.BaseAccountDTO;
import com.mmc.oms.model.qo.OrderInfoQO;
import com.mmc.oms.model.vo.LeaseOrderVO;
import com.mmc.oms.model.vo.OrderStatusVO;
import com.mmc.oms.model.vo.OrderVcuVO;
import com.mmc.oms.model.vo.ReturnWareVO;
import com.mmc.oms.model.vo.order.LeaseOrderVO;
import com.mmc.oms.model.vo.order.OrderStatusVO;
import com.mmc.oms.model.vo.order.OrderVcuVO;
import com.mmc.oms.model.vo.order.ReturnWareVO;
/**
* @Author small @Date 2023/5/26 10:52 @Version 1.0
......@@ -18,7 +17,7 @@ public interface RentalOrdersService {
ResultBody getOrderDetail(String orderNo);
OrderInfoDTO feignAddLease(BaseAccountDTO user, LeaseOrderVO param);
ResultBody feignAddLease(BaseAccountDTO user, LeaseOrderVO param);
PageResult listPcOrderInfo(OrderInfoQO param, BaseAccountDTO cuser);
......
......@@ -2,7 +2,7 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.mmc.oms.dao.CouponBackDao">
<select id="selectCouponList" resultType="com.mmc.oms.entity.CouponDO">
<select id="selectCouponList" resultType="com.mmc.oms.entity.coupon.CouponDO">
SELECT
id,
coupon_name,
......@@ -72,109 +72,105 @@
</select>
<select id="fissionActivity" resultType="com.mmc.oms.entity.CouponDO">
SELECT DISTINCT
substring_index( substring_index( a.primary_key, ',', b.help_topic_id + 1 ), ',',- 1 ) primaryKey,
a.id,
a.coupon_name AS couponName,
a.get_type,
a.coupon_money AS couponMoney,
a.coupon_discount AS couponDiscount,
a.is_limited AS isLimited,
a.restricted_access AS restrictedAccess,
a.coupon_total AS couponTotal,
a.last_total AS lastTotal,
a.coupon_type AS couponType,
a.use_type AS useType,
a.min_price AS minPrice,
a.is_fixed_time AS isFixedTime,
a.use_start_time AS useStartTime,
a.use_end_time AS useEndTime,
a.coupon_day AS couponDay,
a.get_type AS getType,
a.user_tag AS userTag,
a.coupon_status AS couponStatus,
a.is_del AS isDel,
a.preferential_limit AS preferentialLimit,
a.verification_type AS verificationType,
a.create_time AS createTime,
a.update_time AS updateTime,
a.parent_id AS parentId,
a.people_number AS peopleNumber,
a.file_url AS fileUrl,
CASE WHEN a.coupon_total - a.last_total IS NULL THEN
0 ELSE a.coupon_total - a.last_total
END quantityClaimed
FROM
coupon a
JOIN mysql.help_topic b ON b.help_topic_id &lt; ( length( a.primary_key ) - length( REPLACE ( a.primary_key, ',', '' ) ) + 1 )
WHERE
a.is_del = 0
<select id="fissionActivity" resultType="com.mmc.oms.entity.coupon.CouponDO">
SELECT DISTINCT substring_index(substring_index(a.primary_key, ',', b.help_topic_id + 1), ',', - 1) primaryKey,
a.id,
a.coupon_name AS couponName,
a.get_type,
a.coupon_money AS couponMoney,
a.coupon_discount AS couponDiscount,
a.is_limited AS isLimited,
a.restricted_access AS restrictedAccess,
a.coupon_total AS couponTotal,
a.last_total AS lastTotal,
a.coupon_type AS couponType,
a.use_type AS useType,
a.min_price AS minPrice,
a.is_fixed_time AS isFixedTime,
a.use_start_time AS useStartTime,
a.use_end_time AS useEndTime,
a.coupon_day AS couponDay,
a.get_type AS getType,
a.user_tag AS userTag,
a.coupon_status AS couponStatus,
a.is_del AS isDel,
a.preferential_limit AS preferentialLimit,
a.verification_type AS verificationType,
a.create_time AS createTime,
a.update_time AS updateTime,
a.parent_id AS parentId,
a.people_number AS peopleNumber,
a.file_url AS fileUrl,
CASE
WHEN a.coupon_total - a.last_total IS NULL THEN
0
ELSE a.coupon_total - a.last_total
END quantityClaimed
FROM coupon a
JOIN mysql.help_topic b
ON b.help_topic_id &lt; (length(a.primary_key) - length(REPLACE(a.primary_key, ',', '')) + 1)
WHERE a.is_del = 0
AND a.get_type = 4
AND a.primary_key = #{brandId}
</select>
<select id="ordinaryActivities" resultType="com.mmc.oms.entity.CouponDO">
SELECT DISTINCT
substring_index( substring_index( a.primary_key, ',', b.help_topic_id + 1 ), ',',- 1 ) primaryKey,
a.id,
a.coupon_name AS couponName,
a.get_type,
a.coupon_money AS couponMoney,
a.coupon_discount AS couponDiscount,
a.is_limited AS isLimited,
a.restricted_access AS restrictedAccess,
a.coupon_total AS couponTotal,
a.last_total AS lastTotal,
a.coupon_type AS couponType,
a.use_type AS useType,
a.min_price AS minPrice,
a.is_fixed_time AS isFixedTime,
a.use_start_time AS useStartTime,
a.use_end_time AS useEndTime,
a.coupon_day AS couponDay,
a.get_type AS getType,
a.user_tag AS userTag,
a.coupon_status AS couponStatus,
a.is_del AS isDel,
a.preferential_limit AS preferentialLimit,
a.verification_type AS verificationType,
a.create_time AS createTime,
a.update_time AS updateTime,
a.parent_id AS parentId,
a.people_number AS peopleNumber,
a.file_url AS fileUrl,
CASE WHEN a.coupon_total - a.last_total IS NULL THEN
0 ELSE a.coupon_total - a.last_total
END quantityClaimed
FROM
coupon a
JOIN mysql.help_topic b ON b.help_topic_id &lt; ( length( a.primary_key ) - length( REPLACE ( a.primary_key, ',', '' ) ) + 1 )
WHERE
a.is_del = 0
AND a.get_type IN ( 1, 2, 3 )
AND a.primary_key = #{brandId}
<select id="ordinaryActivities" resultType="com.mmc.oms.entity.coupon.CouponDO">
SELECT DISTINCT substring_index(substring_index(a.primary_key, ',', b.help_topic_id + 1), ',', - 1) primaryKey,
a.id,
a.coupon_name AS couponName,
a.get_type,
a.coupon_money AS couponMoney,
a.coupon_discount AS couponDiscount,
a.is_limited AS isLimited,
a.restricted_access AS restrictedAccess,
a.coupon_total AS couponTotal,
a.last_total AS lastTotal,
a.coupon_type AS couponType,
a.use_type AS useType,
a.min_price AS minPrice,
a.is_fixed_time AS isFixedTime,
a.use_start_time AS useStartTime,
a.use_end_time AS useEndTime,
a.coupon_day AS couponDay,
a.get_type AS getType,
a.user_tag AS userTag,
a.coupon_status AS couponStatus,
a.is_del AS isDel,
a.preferential_limit AS preferentialLimit,
a.verification_type AS verificationType,
a.create_time AS createTime,
a.update_time AS updateTime,
a.parent_id AS parentId,
a.people_number AS peopleNumber,
a.file_url AS fileUrl,
CASE
WHEN a.coupon_total - a.last_total IS NULL THEN
0
ELSE a.coupon_total - a.last_total
END quantityClaimed
FROM coupon a
JOIN mysql.help_topic b
ON b.help_topic_id &lt; (length(a.primary_key) - length(REPLACE(a.primary_key, ',', '')) + 1)
WHERE a.is_del = 0
AND a.get_type IN (1, 2, 3)
AND a.primary_key = #{brandId}
</select>
<select id="findProduct" resultType="com.mmc.oms.entity.ProductInformationDo">
SELECT
gi.id AS goodsInfoId,
gi.goods_name AS goodsName,
mpsi.prod_sku_spec_name AS prodSkuSpecName,
ps.id AS productSkuId,
ps.product_name AS productName,
bi.id AS brandId,
bi.brand_name AS brandName
FROM
uav_mall_goods.goods_info gi
INNER JOIN uav_mall_goods.mall_prod_sku_info mpsi ON mpsi.goods_info_id = gi.id
INNER JOIN uav_mall_goods.product_sku ps ON mpsi.prod_sku_id = ps.id and ps.is_deleted=0
INNER JOIN uav_mall_goods.brand_info bi ON ps.brand_info_id = bi.id and bi.is_delete=0
WHERE
gi.is_deleted=0
<select id="findProduct" resultType="com.mmc.oms.entity.order.ProductInformationDo">
SELECT gi.id AS goodsInfoId,
gi.goods_name AS goodsName,
mpsi.prod_sku_spec_name AS prodSkuSpecName,
ps.id AS productSkuId,
ps.product_name AS productName,
bi.id AS brandId,
bi.brand_name AS brandName
FROM uav_mall_goods.goods_info gi
INNER JOIN uav_mall_goods.mall_prod_sku_info mpsi ON mpsi.goods_info_id = gi.id
INNER JOIN uav_mall_goods.product_sku ps ON mpsi.prod_sku_id = ps.id and ps.is_deleted = 0
INNER JOIN uav_mall_goods.brand_info bi ON ps.brand_info_id = bi.id and bi.is_delete = 0
WHERE gi.is_deleted = 0
and gi.id = #{goodsInfoId}
</select>
</mapper>
......@@ -9,51 +9,45 @@
</foreach>
</update>
<select id="selectCouponUserList" resultType="com.mmc.oms.entity.CouponUserDO">
SELECT
id,
coupon_id,
uid,
user_phone,
coupon_name,
coupon_type,
use_type,
coupon_money,
min_price,
coupon_discount,
remaining_balance,
gain_type,
status,
create_time,
update_time,
start_time,
end_time,
use_time,
primary_key,
conversion_ratio,
transferor_uid,
receive_uid,
transferor_time,
preferential_limit,
verification_type
FROM
coupon_user
WHERE
(status = 0 or status = 4)
AND
start_time &lt; #{data}
AND
end_time &gt; #{data}
AND
uid = #{uid}
AND
(use_type = 1
OR
((use_type = 2) AND CONCAT(',',primary_key,',') REGEXP #{list} ))
<select id="selectCouponUserList" resultType="com.mmc.oms.entity.coupon.CouponUserDO">
SELECT id,
coupon_id,
uid,
user_phone,
coupon_name,
coupon_type,
use_type,
coupon_money,
min_price,
coupon_discount,
remaining_balance,
gain_type,
status,
create_time,
update_time,
start_time,
end_time,
use_time,
primary_key,
conversion_ratio,
transferor_uid,
receive_uid,
transferor_time,
preferential_limit,
verification_type
FROM coupon_user
WHERE (status = 0 or status = 4)
AND start_time &lt; #{data}
AND end_time &gt; #{data}
AND uid = #{uid}
AND (use_type = 1
OR
((use_type = 2) AND CONCAT(',', primary_key, ',') REGEXP #{list})
)
</select>
<select id="selectCouponUserInfoList" resultType="com.mmc.oms.model.dto.CouponUserDTO">
<select id="selectCouponUserInfoList" resultType="com.mmc.oms.model.dto.coupon.CouponUserDTO">
SELECT
cu.id,
cu.coupon_id,
......@@ -87,7 +81,7 @@
coupon_user cu
LEFT JOIN
coupon_user_order cuo on cu.id = cuo.coupon_user_id
AND cuo.is_del = false
AND cuo.is_del = false
WHERE
1=1
<if test="uid != null and uid !=''">
......@@ -126,7 +120,7 @@
coupon_user cu
LEFT JOIN
coupon_user_order cuo on cu.id = cuo.coupon_user_id
AND cuo.is_del = false
AND cuo.is_del = false
WHERE
1 = 1
<if test="uid != null and uid !=''">
......@@ -157,35 +151,30 @@
<insert id="insertCouponUserOrder" keyProperty="id" useGeneratedKeys="true">
insert into coupon_user_order(coupon_user_id, order_id, order_no,remaining_balance,use_amount,order_usage_time)
values (#{id}, #{cid}, #{orderNo},#{remainingBalance},#{useAmount},#{orderUsageTime})
insert into coupon_user_order(coupon_user_id, order_id, order_no, remaining_balance, use_amount,
order_usage_time)
values (#{id}, #{cid}, #{orderNo}, #{remainingBalance}, #{useAmount}, #{orderUsageTime})
</insert>
<select id="getOrderList" resultType="java.lang.Long">
SELECT
cuo.order_id
FROM
coupon_user_order cuo
LEFT JOIN
coupon_user cu on cuo.coupon_user_id = cu.id
WHERE
cuo.is_del = false
AND
cu.coupon_id = #{id}
SELECT cuo.order_id
FROM coupon_user_order cuo
LEFT JOIN
coupon_user cu on cuo.coupon_user_id = cu.id
WHERE cuo.is_del = false
AND cu.coupon_id = #{id}
</select>
<select id="merchandise" resultType="java.lang.Integer" parameterType="java.lang.Integer">
SELECT DISTINCT
substring_index( substring_index( a.primary_key, ',', b.help_topic_id + 1 ), ',',- 1 ) primaryKey
FROM
coupon a
JOIN mysql.help_topic b ON b.help_topic_id &lt; ( length( a.primary_key ) - length( REPLACE ( a.primary_key, ',', '' ) ) + 1 )
WHERE
a.is_del = 0
SELECT DISTINCT substring_index(substring_index(a.primary_key, ',', b.help_topic_id + 1), ',', - 1) primaryKey
FROM coupon a
JOIN mysql.help_topic b
ON b.help_topic_id &lt; (length(a.primary_key) - length(REPLACE(a.primary_key, ',', '')) + 1)
WHERE a.is_del = 0
AND a.id = #{couponId}
</select>
<select id="couponMerchandise" resultType="com.mmc.oms.entity.GoodsInfoDO">
<select id="couponMerchandise" resultType="com.mmc.oms.entity.goods.GoodsInfoDO">
SELECT
gi.id,
gi.is_deleted,
......@@ -224,7 +213,7 @@
</if>
</select>
<select id="VipCouponMerchandise" resultType="com.mmc.oms.entity.GoodsInfoDO">
<select id="VipCouponMerchandise" resultType="com.mmc.oms.entity.goods.GoodsInfoDO">
SELECT
gi.id,
gi.is_deleted,
......@@ -249,26 +238,23 @@
</if>
</select>
<select id="couponUsageDetails" resultType="com.mmc.oms.entity.CouponUsageDetailsDO">
SELECT DISTINCT
cuo.id,
cu.coupon_id AS couponId,
cu.uid,
cu.start_time AS startTime,
cu.coupon_name AS couponName,
cu.`status`,
cu.verification_type AS verificationType,
cuo.coupon_user_id AS couponUserId,
cuo.order_id AS orderId,
cuo.order_no AS orderNo,
cuo.remaining_balance AS remainingBalance,
cuo.use_amount AS useAmount,
cuo.order_usage_time AS orderUsageTime
FROM
coupon_user cu,
coupon_user_order cuo
WHERE
cuo.coupon_user_id = cu.id
<select id="couponUsageDetails" resultType="com.mmc.oms.entity.coupon.CouponUsageDetailsDO">
SELECT DISTINCT cuo.id,
cu.coupon_id AS couponId,
cu.uid,
cu.start_time AS startTime,
cu.coupon_name AS couponName,
cu.`status`,
cu.verification_type AS verificationType,
cuo.coupon_user_id AS couponUserId,
cuo.order_id AS orderId,
cuo.order_no AS orderNo,
cuo.remaining_balance AS remainingBalance,
cuo.use_amount AS useAmount,
cuo.order_usage_time AS orderUsageTime
FROM coupon_user cu,
coupon_user_order cuo
WHERE cuo.coupon_user_id = cu.id
AND cu.coupon_type = 3
AND cu.verification_type = 1
AND cu.`status` = 1
......
......@@ -4,7 +4,7 @@
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.mmc.oms.dao.OrderLogisticsDao">
<resultMap id="orderInfoResultMap"
type="com.mmc.oms.entity.OrderInfoDO">
type="com.mmc.oms.entity.order.OrderInfoDO">
<id property="id" column="id"/>
<result property="orderNo" column="order_no"/>
<result property="wareInfoId" column="ware_info_id"/>
......@@ -39,12 +39,12 @@
<result property="updateTime" column="update_time"/>
<result property="rcdCompanyId" column="rcd_company_id"/>
<association property="receipt"
javaType="com.mmc.oms.entity.OrderReceiptDO"
javaType="com.mmc.oms.entity.order.OrderReceiptDO"
resultMap="orderReceiptResultMap"></association>
</resultMap>
<resultMap id="tranStatusResultMap"
type="com.mmc.oms.entity.TranStatusDicDO">
type="com.mmc.oms.entity.transtatus.TranStatusDicDO">
<id property="id" column="id"/>
<result property="status" column="status"/>
<result property="doing" column="doing"/>
......@@ -53,14 +53,14 @@
</resultMap>
<resultMap id="kdnDicResultMap"
type="com.mmc.oms.entity.KdnDicDO">
type="com.mmc.oms.entity.order.KdnDicDO">
<id property="id" column="id"/>
<result property="code" column="code"/>
<result property="msg" column="msg"/>
</resultMap>
<resultMap id="orderReceiptResultMap"
type="com.mmc.oms.entity.OrderReceiptDO">
type="com.mmc.oms.entity.order.OrderReceiptDO">
<id property="id" column="id"/>
<result property="orderInfoId" column="order_info_id"/>
<result property="receiptMethod" column="receipt_method"/>
......@@ -88,14 +88,14 @@
</resultMap>
<resultMap id="expressInfoResultMap"
type="com.mmc.oms.entity.ExpressInfoDO">
type="com.mmc.oms.entity.order.ExpressInfoDO">
<id property="id" column="id"/>
<result property="exName" column="ex_name"/>
<result property="exCode" column="ex_code"/>
</resultMap>
<resultMap id="orderVcuResultMap"
type="com.mmc.oms.entity.OrderVcuDO">
type="com.mmc.oms.entity.order.OrderVcuDO">
<id property="id" column="id"/>
<result property="orderInfoId" column="order_info_id"/>
<result property="orderRefundId" column="order_refund_id"/>
......@@ -140,7 +140,7 @@
</select>
<insert id="insertOrderInfo" useGeneratedKeys="true"
keyProperty="id" parameterType="com.mmc.oms.entity.OrderInfoDO">
keyProperty="id" parameterType="com.mmc.oms.entity.order.OrderInfoDO">
insert into order_info
(order_no, ware_info_id, ware_no, ware_title, ware_img, sku_info_id, sku_title, repo_account_id,
uid, buyer_name, buyer_phone, unit_price, ware_num, should_pay, actual_pay, order_type,
......@@ -155,7 +155,7 @@
</insert>
<insert id="insertOrderReceipt" useGeneratedKeys="true"
keyProperty="id" parameterType="com.mmc.oms.entity.OrderReceiptDO">
keyProperty="id" parameterType="com.mmc.oms.entity.order.OrderReceiptDO">
insert into order_receipt
(order_info_id, receipt_method, take_name, take_phone, region, detail_address, repo_name,
repo_address, book_phone, create_time)
......@@ -241,7 +241,7 @@
and o.repo_account_id = #{repoAccountId}
</select>
<update id="updateOrderInfo" parameterType="com.mmc.oms.entity.OrderInfoDO">
<update id="updateOrderInfo" parameterType="com.mmc.oms.entity.order.OrderInfoDO">
update order_info
<set>
<if test="tranStatus != null and tranStatus != '' ">
......@@ -269,7 +269,7 @@
where id = #{id}
</update>
<update id="updateOrderReceipt" parameterType="com.mmc.oms.entity.OrderReceiptDO">
<update id="updateOrderReceipt" parameterType="com.mmc.oms.entity.order.OrderReceiptDO">
update order_receipt
<set>
<if test=" takeName != null and takeName != '' ">
......@@ -555,7 +555,7 @@
</select>
<insert id="insertOrderVcu" useGeneratedKeys="true"
keyProperty="id" parameterType="com.mmc.oms.entity.OrderVcuDO">
keyProperty="id" parameterType="com.mmc.oms.entity.order.OrderVcuDO">
insert into order_vcu
(order_info_id, order_refund_id, vcu_type, vcu_satus, imgs, video_url, remark, create_time)
values (#{orderInfoId}, #{orderRefundId}, #{vcuType}, #{vcuSatus}, #{imgs}, #{videoUrl}, #{remark},
......
......@@ -13,7 +13,7 @@
<insert id="insertOrderRefund" useGeneratedKeys="true"
keyProperty="id"
parameterType="com.mmc.oms.entity.OrderRefundDO">
parameterType="com.mmc.oms.entity.order.OrderRefundDO">
insert into order_refund
(order_info_id, refund_no, refund_status, should_refund, actual_refund, reason, create_time, user_account_id)
values (#{orderInfoId}, #{refundNo}, #{refundStatus}, #{shouldRefund}, #{actualRefund}, #{reason},
......@@ -21,7 +21,7 @@
</insert>
<insert id="insertOrderVcu" useGeneratedKeys="true"
keyProperty="id" parameterType="com.mmc.oms.entity.OrderVcuDO">
keyProperty="id" parameterType="com.mmc.oms.entity.order.OrderVcuDO">
insert into order_vcu
(order_info_id, order_refund_id, vcu_type, vcu_satus, imgs, video_url, remark, create_time)
values (#{orderInfoId}, #{orderRefundId}, #{vcuType}, #{vcuSatus}, #{imgs}, #{videoUrl}, #{remark},
......
......@@ -4,7 +4,7 @@
<resultMap id="orderInfoResultMap"
type="com.mmc.oms.entity.OrderInfoDO">
type="com.mmc.oms.entity.order.OrderInfoDO">
<id property="id" column="id"/>
<result property="orderNo" column="order_no"/>
<result property="wareInfoId" column="ware_info_id"/>
......@@ -39,13 +39,13 @@
<result property="updateTime" column="update_time"/>
<result property="rcdCompanyId" column="rcd_company_id"/>
<association property="receipt"
javaType="com.mmc.oms.entity.OrderReceiptDO"
javaType="com.mmc.oms.entity.order.OrderReceiptDO"
resultMap="orderReceiptResultMap"></association>
</resultMap>
<resultMap id="orderReceiptResultMap"
type="com.mmc.oms.entity.OrderReceiptDO">
type="com.mmc.oms.entity.order.OrderReceiptDO">
<id property="id" column="id"/>
<result property="orderInfoId" column="order_info_id"/>
<result property="receiptMethod" column="receipt_method"/>
......@@ -73,7 +73,7 @@
</resultMap>
<resultMap id="orderRefundResultMap"
type="com.mmc.oms.entity.OrderRefundDO">
type="com.mmc.oms.entity.order.OrderRefundDO">
<id property="id" column="id"/>
<result property="orderInfoId" column="order_info_id"/>
<result property="refundNo" column="refund_no"/>
......@@ -85,12 +85,12 @@
<result property="createTime" column="create_time"/>
<association property="orderInfo"
javaType="com.mmc.oms.entity.OrderInfoDO"
javaType="com.mmc.oms.entity.order.OrderInfoDO"
resultMap="refundOrderResultMap"></association>
</resultMap>
<resultMap id="refundOrderResultMap"
type="com.mmc.oms.entity.OrderInfoDO">
type="com.mmc.oms.entity.order.OrderInfoDO">
<id property="id" column="order_info_id"/>
<result property="orderNo" column="order_no"/>
<result property="wareInfoId" column="ware_info_id"/>
......@@ -124,7 +124,7 @@
<result property="updateTime" column="update_time"/>
</resultMap>
<select id="coupon" resultType="com.mmc.oms.entity.CouponUserDO">
<select id="coupon" resultType="com.mmc.oms.entity.coupon.CouponUserDO">
select coupon_money AS couponMoney, `status`, end_time AS endTime
from coupon_user
</select>
......@@ -177,7 +177,7 @@
</select>
<insert id="insertOrderInfo" useGeneratedKeys="true"
keyProperty="id" parameterType="com.mmc.oms.entity.OrderInfoDO">
keyProperty="id" parameterType="com.mmc.oms.entity.order.OrderInfoDO">
insert into order_info
(order_no, ware_info_id, ware_no, ware_title, ware_img, sku_info_id, sku_title, repo_account_id,
uid, buyer_name, buyer_phone, unit_price, ware_num, should_pay, actual_pay, order_type,
......@@ -191,7 +191,7 @@
#{sendWareTime}, now(), #{rcdCompanyId}, #{returnTime}, #{couponId}, #{specsId})
</insert>
<insert id="insertOrderReceipt" useGeneratedKeys="true"
keyProperty="id" parameterType="com.mmc.oms.entity.OrderReceiptDO">
keyProperty="id" parameterType="com.mmc.oms.entity.order.OrderReceiptDO">
insert into order_receipt
(order_info_id, receipt_method, take_name, take_phone, region, detail_address, repo_name,
repo_address, book_phone, create_time)
......@@ -391,7 +391,7 @@
where o.id = #{orderInfoId}
</select>
<update id="updateOrderReceipt" parameterType="com.mmc.oms.entity.OrderReceiptDO">
<update id="updateOrderReceipt" parameterType="com.mmc.oms.entity.order.OrderReceiptDO">
update order_receipt
<set>
<if test=" takeName != null and takeName != '' ">
......@@ -474,14 +474,14 @@
</update>
<insert id="insertOrderVcu" useGeneratedKeys="true"
keyProperty="id" parameterType="com.mmc.oms.entity.OrderVcuDO">
keyProperty="id" parameterType="com.mmc.oms.entity.order.OrderVcuDO">
insert into order_vcu
(order_info_id, order_refund_id, vcu_type, vcu_satus, imgs, video_url, remark, create_time)
values (#{orderInfoId}, #{orderRefundId}, #{vcuType}, #{vcuSatus}, #{imgs}, #{videoUrl}, #{remark},
#{createTime})
</insert>
<update id="updateOrderInfo" parameterType="com.mmc.oms.entity.OrderInfoDO">
<update id="updateOrderInfo" parameterType="com.mmc.oms.entity.order.OrderInfoDO">
update order_info
<set>
<if test="tranStatus != null and tranStatus != '' ">
......@@ -528,8 +528,8 @@
where r.order_info_id = #{orderInfoId}
</select>
<select id="listOfRentalOrders" resultType="com.mmc.oms.entity.OrderStatusDO"
parameterType="com.mmc.oms.model.vo.OrderStatusVO">
<select id="listOfRentalOrders" resultType="com.mmc.oms.entity.order.OrderStatusDO"
parameterType="com.mmc.oms.model.vo.order.OrderStatusVO">
SELECT
o.id,
o.order_no AS orderNo,
......@@ -555,7 +555,7 @@
limit #{pageNo},#{pageSize}
</select>
<select id="rentalOrdersCount" resultType="int" parameterType="com.mmc.oms.model.vo.OrderStatusVO">
<select id="rentalOrdersCount" resultType="int" parameterType="com.mmc.oms.model.vo.order.OrderStatusVO">
SELECT
count(1)
FROM
......@@ -575,7 +575,7 @@
where order_no = #{orderNo}
</update>
<select id="getApplicationInformation" resultType="com.mmc.oms.entity.OrderRefundDO">
<select id="getApplicationInformation" resultType="com.mmc.oms.entity.order.OrderRefundDO">
SELECT id,
order_info_id AS orderInfoId,
refund_no AS refundNo,
......@@ -584,7 +584,7 @@
where order_info_id = #{id}
</select>
<select id="couponMoney" resultType="com.mmc.oms.entity.CouponDO">
<select id="couponMoney" resultType="com.mmc.oms.entity.coupon.CouponDO">
select id,
coupon_name,
coupon_money AS couponMoney,
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论