李天标 пре 3 година
родитељ
комит
f7ca33cce1

+ 10 - 10
pom.xml

@@ -229,16 +229,16 @@
 		</plugins>
 	</build>
 	<repositories>
-		<repository>
-			<id>nexus</id>
-			<url>http://www.redouble.store:1888/repository/maven-public/</url>
-			<releases>
-				<enabled>true</enabled>
-			</releases>
-			<snapshots>
-				<enabled>false</enabled>
-			</snapshots>
-		</repository>
+		<!--<repository>-->
+			<!--<id>nexus</id>-->
+			<!--<url>http://www.redouble.store:1888/repository/maven-public/</url>-->
+			<!--<releases>-->
+				<!--<enabled>true</enabled>-->
+			<!--</releases>-->
+			<!--<snapshots>-->
+				<!--<enabled>false</enabled>-->
+			<!--</snapshots>-->
+		<!--</repository>-->
 		<!-- 个推 -->
 		<repository>
 			<id>getui-nexus</id>

+ 21 - 0
src/main/java/com/szwl/controller/TAreaController.java

@@ -0,0 +1,21 @@
+package com.szwl.controller;
+
+
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ * <p>
+ *  前端控制器
+ * </p>
+ *
+ * @author wuhs
+ * @since 2022-07-12
+ */
+@RestController
+@RequestMapping("/tArea")
+public class TAreaController {
+
+}
+

+ 306 - 0
src/main/java/com/szwl/controller/TOrderController.java

@@ -2097,6 +2097,145 @@ public class TOrderController {
 
         return "SUCCESS";
     }
+    /**
+     * MG280支付成功回调
+     *
+     * @return
+     */
+    @RequestMapping(value = "/mg280Notify", method = RequestMethod.GET)
+    @ResponseBody
+    public Object mg280Notify(HttpServletRequest request) {
+
+        String r6_Status = request.getParameter("r6_Status");
+
+        // 订单号
+        String sn = request.getParameter("r2_OrderNo");
+        LambdaQueryWrapper<TOrder> query = Wrappers.lambdaQuery();
+        query.eq(TOrder::getSn,sn);
+        List<TOrder> list = orderService.list();
+        TOrder order = new TOrder();
+
+
+        if (JoinpayConstant.r6_Status_100.equals(r6_Status)) {
+
+            // 已支付
+            order.setStatus(1);
+
+            // 支付平台产生的流水号
+            String r7_TrxNo = request.getParameter("r7_TrxNo");
+            order.setTrxNo(r7_TrxNo);
+
+            // 格式:YYYY-MM-DD HH:mm:ss
+            String ra_PayTime = request.getParameter("ra_PayTime");
+
+            try {
+                SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
+                Date payDate = sdf.parse(URLDecoder.decode(ra_PayTime, "UTF-8"));
+                order.setPayDate(payDate);
+            } catch (ParseException e) {
+                e.printStackTrace();
+            } catch (UnsupportedEncodingException e) {
+
+                e.printStackTrace();
+            }
+
+            orderService.updateById(order);
+
+            JSONObject kindData = new JSONObject();
+            kindData.put("sn", order.getSn());
+            kindData.put("productName", order.getProductName());
+
+            TEquipment byClientId = R.getDataIfSuccess(szwlFeign.findEquipmentByClientId(order.getClientId()));
+            String gtClientId = byClientId.getGtClientId();
+            Date endDate = byClientId.getEndDate();
+            Date date = new Date();
+            Date time = null;
+            double price1Price = 0;
+            BigDecimal price = order.getPrice();
+//            List<Price> priceList = priceService.findAll();
+//            for (Price price1 : priceList) {
+//                if (price1.getName().equals("MG280")) {
+//                    price1Price = price1.getPrice();
+//                }
+//            }
+            TPrice price1 = R.getDataIfSuccess(szwlFeign.getPrice("MG280"));
+            price1Price = price1.getPrice();
+            BigDecimal city = price.divide(BigDecimal.valueOf(price1Price));
+            int ci = city.intValue();
+            if (endDate.getTime() < date.getTime()) {
+                Calendar c = Calendar.getInstance();
+                c.setTime(date);
+                int i = c.get(Calendar.MONTH);
+                c.set(Calendar.MONTH, i - 1);
+                //上个月有多少天
+                int actualMaximum = c.getActualMaximum(Calendar.DAY_OF_MONTH);
+                long t = date.getTime() - endDate.getTime();
+                long m = actualMaximum * 1000 * 60 * 60 * 24l;
+                if (t <= m) {
+                    Calendar calendar = Calendar.getInstance();
+                    calendar.setTime(endDate);
+                    calendar.set(Calendar.DAY_OF_MONTH, 10);
+                    //将小时至0
+                    calendar.set(Calendar.HOUR_OF_DAY, 0);
+                    //将分钟至0
+                    calendar.set(Calendar.MINUTE, 0);
+                    //将秒至0
+                    calendar.set(Calendar.SECOND, 0);
+                    //将毫秒至0
+                    calendar.set(Calendar.MILLISECOND, 0);
+                    calendar.add(Calendar.MONTH, ci);
+                    time = calendar.getTime();
+                }
+                if (t > m) {
+                    Calendar calendar = Calendar.getInstance();
+                    calendar.setTime(date);
+                    calendar.set(Calendar.DAY_OF_MONTH, 10);
+                    //将小时至0
+                    calendar.set(Calendar.HOUR_OF_DAY, 0);
+                    //将分钟至0
+                    calendar.set(Calendar.MINUTE, 0);
+                    //将秒至0
+                    calendar.set(Calendar.SECOND, 0);
+                    //将毫秒至0
+                    calendar.set(Calendar.MILLISECOND, 0);
+                    calendar.add(Calendar.MONTH, ci);
+                    time = calendar.getTime();
+                }
+            } else {
+                Calendar calendar = Calendar.getInstance();
+                calendar.setTime(endDate);
+                calendar.set(Calendar.DAY_OF_MONTH, 10);
+                //将小时至0
+                calendar.set(Calendar.HOUR_OF_DAY, 0);
+                //将分钟至0
+                calendar.set(Calendar.MINUTE, 0);
+                //将秒至0
+                calendar.set(Calendar.SECOND, 0);
+                //将毫秒至0
+                calendar.set(Calendar.MILLISECOND, 0);
+                calendar.add(Calendar.MONTH, ci);
+                time = calendar.getTime();
+            }
+
+            byClientId.setEndDate(time);
+            //修改机器
+            szwlFeign.updateByEquipment(byClientId);
+            order.setNote(gtClientId + "已推送");
+            orderService.updateById(order);
+            equipmentService.sentMessage(byClientId.getClientId(),PushUtils.buildJson("endDate", String.valueOf(byClientId.getEndDate().getTime())).toString());
+//            PushUtils.push(byClientId.getGtClientId(), "", "", PushUtils.buildJson("endDate", String.valueOf(byClientId.getEndDate().getTime())).toString());
+            return "success";
+        } else {
+            TEquipment byClientId = R.getDataIfSuccess(szwlFeign.findEquipmentByClientId(order.getClientId()));
+            String gtClientId = byClientId.getGtClientId();
+            JSONObject kindData = new JSONObject();
+            kindData.put("sn", order.getSn());
+            order.setNote(gtClientId + "支付失败");
+            orderService.updateById(order);
+        }
+
+        return "success";
+    }
     //生成二维码,并返回base64格式
     private String toQrcode(String code) {
         String imgtext = null;
@@ -2117,6 +2256,53 @@ public class TOrderController {
         return imgtext;
     }
 
+    /**
+     * 退款成功回调
+     *
+     * @param request
+     * @return
+     */
+    @RequestMapping(value = "/notifyRefund", method = RequestMethod.GET)
+    @ResponseBody
+    public Object notifyRefund(HttpServletRequest request) {
+
+        String r6_Status = request.getParameter("ra_Status");
+
+        // 订单号
+        String sn = request.getParameter("r2_OrderNo");
+        LambdaQueryWrapper<TOrder> query = Wrappers.lambdaQuery();
+        query.eq(TOrder::getSn,sn);
+        List<TOrder> list = orderService.list();
+        TOrder order = new TOrder();
+        if (order == null) {
+            return "success";
+        }
+        if (order.getStatus() != 3) {
+            return "success";
+        }
+
+        if (JoinpayConstant.r6_Status_100.equals(r6_Status)) {
+
+            // 已退款
+            order.setStatus(3);
+            // 退款金额
+            order.setRefundAmount(new BigDecimal(request.getParameter("r4_RefundAmount_str")));
+            // 支付平台产生的退款流水号
+            String r5_RefundTrxNo = request.getParameter("r5_RefundTrxNo");
+            order.setRefundTrxNo(r5_RefundTrxNo);
+            order.setRefundDate(new Date());
+            order.setModifyDate(new Date());
+            orderService.updateById(order);
+            try {
+                esTOrderService.updateDataById(order);
+            }catch (Exception e) {
+                e.printStackTrace();
+            }
+            return "success";
+        }
+
+        return "success";
+    }
     @ApiOperation(value = "添加订单")
     @PostMapping("/addOrder")
     public ResponseModel<?> addOrder(@RequestBody TOrder order) {
@@ -2232,5 +2418,125 @@ public class TOrderController {
         return "success";
     }
 
+    /**
+     * 查询订单是否付款
+     *
+     * @param
+     * @param
+     * @return
+     */
+    @RequestMapping(value = "/getOrderStatus", method = RequestMethod.GET)
+    @ResponseBody
+    public JsonMessage getOrderStatus(String sn) {
+        LambdaQueryWrapper<TOrder> query = Wrappers.lambdaQuery();
+        query.eq(TOrder::getSn,sn);
+        List<TOrder> list = orderService.list(query);
+        TOrder order = list.get(0);
+        Integer status = order.getStatus();
+        String sta = status.toString();
+        if(status==1){
+            sta="pay";
+        }
+        return JsonMessage.success(sta);
+    }
+
+    /**
+     * 删除订单
+     *
+     * @param
+     * @param
+     * @return
+     */
+    @RequestMapping(value = "/deleteOrder", method = RequestMethod.GET)
+    @ResponseBody
+    public JsonMessage deleteOrder(String sn) {
+        LambdaQueryWrapper<TOrder> query = Wrappers.lambdaQuery();
+        query.eq(TOrder::getSn,sn);
+        List<TOrder> list = orderService.list(query);
+        TOrder order = list.get(0);
+        Integer status = order.getStatus();
+        String ss = status.toString();
+        if (status==0) {
+            orderService.removeById(order.getId());
+            return JsonMessage.success(sn + "删除成功");
+        }
+//        return JsonMessage.success(sn + "删除失败");
+
+        return JsonMessage.success(sn + "删除成功");
+    }
+
+    /**
+     * 添加订单
+     *
+     * @param clientId    设备client id
+     * @param productName 商品名称
+     * @param
+     * @return
+     */
+    @RequestMapping(value = "/addOrder", method = RequestMethod.GET)
+    @ResponseBody
+    public Object addOrder(String clientId, String productName, String pri,String sn) {
+
+        TEquipment equipment = R.getDataIfSuccess(szwlFeign.findEquipmentByClientId(clientId));
+        if (equipment == null) {
+            return JsonMessage.error("找不到设备");
+        }
+        Long equipmentId = equipment.getId();
+        BigDecimal price = new BigDecimal(pri);
+//        TAdmin admin = adminService.find(equipment.getAdminId());
+        TAdmin admin = R.getDataIfSuccess(szwlFeign.getAdmin(String.valueOf(equipment.getAdminId())));
+        if (admin == null) {
+            return JsonMessage.error("找不到设备商家");
+        }
+        JSONArray altInfo = new JSONArray();
+
+
+//        Long agencyId = admin.getAgencyId();
+//        Long merchantId = admin.getMerchantId();
+//        Long personageId = admin.getPersonageId();
+//        Admin.Type type = admin.getType();
+//        Order.Type orderType = null;
+        String orderType = null;
+        TProportion proportion = R.getDataIfSuccess(szwlFeign.getProportion(String.valueOf(equipment.getId())));
+        Integer type = proportion.getType();
+        switch (type) {
+
+            case 2:
+                orderType = "1";
+                break;
+            case 3:
+                orderType = "2";
+                break;
+            case 4:
+                orderType = "3";
+                break;
+        }
+//        TOrder order = new TOrder(sn, null, productName, price, equipment.getClientId(), equipmentId,
+//                orderType, admin.getId(), agencyId, merchantId, personageId,
+//                null, altInfo.toString(), null, null, null, null, Order.Status.pay);
+
+        TProduct product =  R.getDataIfSuccess(szwlFeign.getProduct(String.valueOf(equipmentId), productName));
+        TOrder order = new TOrder();
+        order.setCreateDate(new Date());
+        order.setModifyDate(new Date());
+        order.setAdminId(admin.getId());
+        order.setSn(sn);
+        order.setProductId(product.getId());
+        order.setProductNo(product.getNo());
+        order.setProductName(productName);
+        order.setPrice(price);
+        order.setClientId(equipment.getClientId());
+        order.setEquipmentId(equipmentId);
+        order.setAltInfo(altInfo.toString());
+        order.setStatus(1);
+        order.setType(type);
+        orderService.save(order);
+        try {
+            esTOrderService.insertData(order);
+        }catch (Exception e) {
+            e.printStackTrace();
+        }
+        return JsonMessage.success("success");
+    }
 }
 

+ 2 - 0
src/main/java/com/szwl/feign/bean/SzwlFeign.java

@@ -20,6 +20,8 @@ public interface SzwlFeign {
 
     @GetMapping("/tEquipment/findEquipmentByClientId")
     ResponseModel<TEquipment> findEquipmentByClientId(String clientId);
+    @GetMapping("/tEquipment/updateByEquipment")
+    ResponseModel<TEquipment> updateByEquipment(@RequestBody TEquipment equipment);
     @GetMapping("/tPromoCode/getTPromoCode")
     ResponseModel<IPage<TPromoCode>> getTPromoCode(String code);
     @GetMapping("/tPromoCode/updatePromoCode")

+ 16 - 0
src/main/java/com/szwl/mapper/TAreaMapper.java

@@ -0,0 +1,16 @@
+package com.szwl.mapper;
+
+import com.szwl.model.entity.TArea;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * <p>
+ *  Mapper 接口
+ * </p>
+ *
+ * @author wuhs
+ * @since 2022-07-12
+ */
+public interface TAreaMapper extends BaseMapper<TArea> {
+
+}

+ 23 - 0
src/main/java/com/szwl/mapper/xml/TAreaMapper.xml

@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.szwl.mapper.TAreaMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="BaseResultMap" type="com.szwl.model.entity.TArea">
+        <id column="id" property="id" />
+        <result column="create_date" property="createDate" />
+        <result column="modify_date" property="modifyDate" />
+        <result column="orders" property="orders" />
+        <result column="full_name" property="fullName" />
+        <result column="name" property="name" />
+        <result column="tree_path" property="treePath" />
+        <result column="parent" property="parent" />
+        <result column="code" property="code" />
+    </resultMap>
+
+    <!-- 通用查询结果列 -->
+    <sql id="Base_Column_List">
+        id, create_date, modify_date, orders, full_name, name, tree_path, parent, code
+    </sql>
+
+</mapper>

+ 47 - 0
src/main/java/com/szwl/model/entity/TArea.java

@@ -0,0 +1,47 @@
+package com.szwl.model.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import java.util.Date;
+import com.baomidou.mybatisplus.annotation.TableId;
+import java.io.Serializable;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * <p>
+ * 
+ * </p>
+ *
+ * @author wuhs
+ * @since 2022-07-12
+ */
+@Data
+@EqualsAndHashCode(callSuper = false)
+@ApiModel(value="TArea对象", description="")
+public class TArea implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    @TableId(value = "id", type = IdType.AUTO)
+    private Long id;
+
+    private Date createDate;
+
+    private Date modifyDate;
+
+    private Integer orders;
+
+    private String fullName;
+
+    private String name;
+
+    private String treePath;
+
+    private Long parent;
+
+    private String code;
+
+
+}

+ 152 - 0
src/main/java/com/szwl/model/query/Order.java

@@ -0,0 +1,152 @@
+/*
+ * 
+ * 
+ * 
+ */
+package com.szwl.model.query;
+
+import org.apache.commons.lang.builder.EqualsBuilder;
+import org.apache.commons.lang.builder.HashCodeBuilder;
+
+import java.io.Serializable;
+
+/**
+ * 排序
+ */
+public class Order implements Serializable {
+
+    private static final long serialVersionUID = -3078342809727773232L;
+
+    /**
+     * 方向
+     */
+    public enum Direction {
+
+        /**
+         * 递增
+         */
+        asc,
+
+        /**
+         * 递减
+         */
+        desc;
+
+        /**
+         * 从String中获取Direction
+         *
+         * @param value 值
+         * @return String对应的Direction
+         */
+        public static Direction fromString(String value) {
+            return Direction.valueOf(value.toLowerCase());
+        }
+    }
+
+    /**
+     * 默认方向
+     */
+    private static final Direction DEFAULT_DIRECTION = Direction.desc;
+
+    /**
+     * 属性
+     */
+    private String property;
+
+    /**
+     * 方向
+     */
+    private Direction direction = DEFAULT_DIRECTION;
+
+    /**
+     * 初始化一个新创建的Order对象
+     */
+    public Order() {
+    }
+
+    /**
+     * @param property  属性
+     * @param direction 方向
+     */
+    public Order(String property, Direction direction) {
+        this.property = property;
+        this.direction = direction;
+    }
+
+    /**
+     * 返回递增排序
+     *
+     * @param property 属性
+     * @return 递增排序
+     */
+    public static Order asc(String property) {
+        return new Order(property, Direction.asc);
+    }
+
+    /**
+     * 返回递减排序
+     *
+     * @param property 属性
+     * @return 递减排序
+     */
+    public static Order desc(String property) {
+        return new Order(property, Direction.desc);
+    }
+
+    /**
+     * 获取属性
+     *
+     * @return 属性
+     */
+    public String getProperty() {
+        return property;
+    }
+
+    /**
+     * 设置属性
+     *
+     * @param property 属性
+     */
+    public void setProperty(String property) {
+        this.property = property;
+    }
+
+    /**
+     * 获取方向
+     *
+     * @return 方向
+     */
+    public Direction getDirection() {
+        return direction;
+    }
+
+    /**
+     * 设置方向
+     *
+     * @param direction 方向
+     */
+    public void setDirection(Direction direction) {
+        this.direction = direction;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (obj == null) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        if (this == obj) {
+            return true;
+        }
+        Order other = (Order) obj;
+        return new EqualsBuilder().append(getProperty(), other.getProperty()).append(getDirection(), other.getDirection()).isEquals();
+    }
+
+    @Override
+    public int hashCode() {
+        return new HashCodeBuilder(17, 37).append(getProperty()).append(getDirection()).toHashCode();
+    }
+
+}

+ 4 - 4
src/main/java/com/szwl/model/query/Pageable.java

@@ -5,7 +5,7 @@
  */
 package com.szwl.model.query;
 
-import com.hboxs.common.Order.Direction;
+import com.szwl.model.utils.Filter;
 import org.apache.commons.lang.builder.EqualsBuilder;
 import org.apache.commons.lang.builder.HashCodeBuilder;
 
@@ -63,7 +63,7 @@ public class Pageable implements Serializable {
     /**
      * 排序方向
      */
-    private Direction orderDirection;
+    private Order.Direction orderDirection;
 
     /**
      * 筛选
@@ -197,7 +197,7 @@ public class Pageable implements Serializable {
      *
      * @return 排序方向
      */
-    public Direction getOrderDirection() {
+    public Order.Direction getOrderDirection() {
         return orderDirection;
     }
 
@@ -206,7 +206,7 @@ public class Pageable implements Serializable {
      *
      * @param orderDirection 排序方向
      */
-    public void setOrderDirection(Direction orderDirection) {
+    public void setOrderDirection(Order.Direction orderDirection) {
         this.orderDirection = orderDirection;
     }
 

+ 396 - 0
src/main/java/com/szwl/model/utils/Filter.java

@@ -0,0 +1,396 @@
+/*
+ * 
+ * 
+ * 
+ */
+package com.szwl.model.utils;
+
+import org.apache.commons.lang.builder.EqualsBuilder;
+import org.apache.commons.lang.builder.HashCodeBuilder;
+
+import java.io.Serializable;
+
+/**
+ * 筛选
+ *
+ *
+ *
+ */
+public class Filter implements Serializable {
+
+    private static final long serialVersionUID = -8712382358441065075L;
+
+
+
+    /**
+     * 运算符
+     */
+    public enum Operator {
+
+        /** 等于 */
+        eq,
+
+        /** 不等于 */
+        ne,
+
+        /** 大于 */
+        gt,
+
+        /** 小于 */
+        lt,
+
+        /** 大于等于 */
+        ge,
+        geDate,
+        /** 小于等于 */
+        le,
+        leDate,
+        /** 相似 */
+        like,
+
+        /** 包含 */
+        in,
+
+        /** 为Null */
+        isNull,
+
+        /** 不为Null */
+        isNotNull;
+
+        /**
+         * 从String中获取Operator
+         *
+         * @param value
+         *            值
+         * @return String对应的operator
+         */
+        public static Operator fromString(String value) {
+            return Operator.valueOf(value.toLowerCase());
+        }
+    }
+
+    /** 默认是否忽略大小写 */
+    private static final boolean DEFAULT_IGNORE_CASE = false;
+
+    /** 属性 */
+    private String property;
+
+    /** 运算符 */
+    private Operator operator;
+
+    /** 值 */
+    private Object value;
+
+    /** 是否忽略大小写 */
+    private Boolean ignoreCase = DEFAULT_IGNORE_CASE;
+
+    /**
+     * 初始化一个新创建的Filter对象
+     */
+    public Filter() {
+    }
+
+    /**
+     * 初始化一个新创建的Filter对象
+     *
+     * @param property
+     *            属性
+     * @param operator
+     *            运算符
+     * @param value
+     *            值
+     */
+    public Filter(String property, Operator operator, Object value) {
+        this.property = property;
+        this.operator = operator;
+        this.value = value;
+    }
+
+    /**
+     * 初始化一个新创建的Filter对象
+     *
+     * @param property
+     *            属性
+     * @param operator
+     *            运算符
+     * @param value
+     *            值
+     * @param ignoreCase
+     *            忽略大小写
+     */
+    public Filter(String property, Operator operator, Object value, boolean ignoreCase) {
+        this.property = property;
+        this.operator = operator;
+        this.value = value;
+        this.ignoreCase = ignoreCase;
+    }
+
+    /**
+     * 返回等于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 等于筛选
+     */
+    public static Filter eq(String property, Object value) {
+        return new Filter(property, Operator.eq, value);
+    }
+
+    /**
+     * 返回等于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @param ignoreCase
+     *            忽略大小写
+     * @return 等于筛选
+     */
+    public static Filter eq(String property, Object value, boolean ignoreCase) {
+        return new Filter(property, Operator.eq, value, ignoreCase);
+    }
+
+    /**
+     * 返回不等于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 不等于筛选
+     */
+    public static Filter ne(String property, Object value) {
+        return new Filter(property, Operator.ne, value);
+    }
+
+    /**
+     * 返回不等于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @param ignoreCase
+     *            忽略大小写
+     * @return 不等于筛选
+     */
+    public static Filter ne(String property, Object value, boolean ignoreCase) {
+        return new Filter(property, Operator.ne, value, ignoreCase);
+    }
+
+    /**
+     * 返回大于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 大于筛选
+     */
+    public static Filter gt(String property, Object value) {
+        return new Filter(property, Operator.gt, value);
+    }
+
+    /**
+     * 返回小于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 小于筛选
+     */
+    public static Filter lt(String property, Object value) {
+        return new Filter(property, Operator.lt, value);
+    }
+
+    /**
+     * 返回大于等于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 大于等于筛选
+     */
+    public static Filter ge(String property, Object value) {
+        return new Filter(property, Operator.ge, value);
+    }
+
+    public static Filter geDate(String property, Object value) {
+        return new Filter(property, Operator.geDate, value);
+    }
+    /**
+     * 返回小于等于筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 小于等于筛选
+     */
+    public static Filter le(String property, Object value) {
+        return new Filter(property, Operator.le, value);
+    }
+    public static Filter leDate(String property, Object value) {
+        return new Filter(property, Operator.leDate, value);
+    }
+
+    /**
+     * 返回相似筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 相似筛选
+     */
+    public static Filter like(String property, Object value) {
+        return new Filter(property, Operator.like, value);
+    }
+
+    /**
+     * 返回包含筛选
+     *
+     * @param property
+     *            属性
+     * @param value
+     *            值
+     * @return 包含筛选
+     */
+    public static Filter in(String property, Object value) {
+        return new Filter(property, Operator.in, value);
+    }
+
+    /**
+     * 返回为Null筛选
+     *
+     * @param property
+     *            属性
+     * @return 为Null筛选
+     */
+    public static Filter isNull(String property) {
+        return new Filter(property, Operator.isNull, null);
+    }
+
+    /**
+     * 返回不为Null筛选
+     *
+     * @param property
+     *            属性
+     * @return 不为Null筛选
+     */
+    public static Filter isNotNull(String property) {
+        return new Filter(property, Operator.isNotNull, null);
+    }
+
+    /**
+     * 返回忽略大小写筛选
+     *
+     * @return 忽略大小写筛选
+     */
+    public Filter ignoreCase() {
+        this.ignoreCase = true;
+        return this;
+    }
+
+    /**
+     * 获取属性
+     *
+     * @return 属性
+     */
+    public String getProperty() {
+        return property;
+    }
+
+    /**
+     * 设置属性
+     *
+     * @param property
+     *            属性
+     */
+    public void setProperty(String property) {
+        this.property = property;
+    }
+
+    /**
+     * 获取运算符
+     *
+     * @return 运算符
+     */
+    public Operator getOperator() {
+        return operator;
+    }
+
+    /**
+     * 设置运算符
+     *
+     * @param operator
+     *            运算符
+     */
+    public void setOperator(Operator operator) {
+        this.operator = operator;
+    }
+
+    /**
+     * 获取值
+     *
+     * @return 值
+     */
+    public Object getValue() {
+        return value;
+    }
+
+    /**
+     * 设置值
+     *
+     * @param value
+     *            值
+     */
+    public void setValue(Object value) {
+        this.value = value;
+    }
+
+    /**
+     * 获取是否忽略大小写
+     *
+     * @return 是否忽略大小写
+     */
+    public Boolean getIgnoreCase() {
+        return ignoreCase;
+    }
+
+    /**
+     * 设置是否忽略大小写
+     *
+     * @param ignoreCase
+     *            是否忽略大小写
+     */
+    public void setIgnoreCase(Boolean ignoreCase) {
+        this.ignoreCase = ignoreCase;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (obj == null) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        if (this == obj) {
+            return true;
+        }
+        Filter other = (Filter) obj;
+        return new EqualsBuilder().append(getProperty(), other.getProperty()).append(getOperator(), other.getOperator()).append(getValue(), other.getValue()).isEquals();
+    }
+
+    @Override
+    public int hashCode() {
+        return new HashCodeBuilder(17, 37).append(getProperty()).append(getOperator()).append(getValue()).toHashCode();
+    }
+
+}

+ 3 - 3
src/main/java/com/szwl/model/utils/JoinpayConstant.java

@@ -39,13 +39,13 @@ public class JoinpayConstant {
     /**
      *  支付成功回调
      */
-    public final static String Notify_Url = "http://app.sunzee.com.cn/api/order/notify.htm";
+    public final static String Notify_Url = "http://pay.sunzee.com.cn:49013/tOrder/notify.htm";
 //    public final static String Notify_Url = "http://slb.sunzee.com.cn/api/order/notify.htm";
 
-    public final static String mg280Notify_Url = "http://app.sunzee.com.cn/api/order/mg280Notify.htm";
+    public final static String mg280Notify_Url = "http://pay.sunzee.com.cn:49013/tOrder/mg280Notify.htm";
 //    public final static String mg280Notify_Url = "http://slb.sunzee.com.cn/api/order/mg280Notify.htm";
 
-    public final static String Notify_Url_PromoCode = "http://app.sunzee.com.cn/api/order/promoCodeNotify.htm";
+    public final static String Notify_Url_PromoCode = "http://pay.sunzee.com.cn:49013/tOrder/promoCodeNotify.htm";
 //    public final static String Notify_Url_PromoCode = "http://slb.sunzee.com.cn/api/order/promoCodeNotify.htm";
 
     public final static String Jiesuan_Url = "http://app.sunzee.com.cn/api/order/jiesuan.htm";

+ 10 - 10
src/main/java/com/szwl/model/utils/JsonUtils.java

@@ -85,16 +85,16 @@ public final class JsonUtils {
      * @param typeReference 对象类型
      * @return 对象
      */
-    public static <T> T toObject(String json, TypeReference<?> typeReference) {
-        Assert.hasText(json);
-        Assert.notNull(typeReference);
-        try {
-            return mapper.readValue(json, typeReference);
-        } catch (Exception e) {
-            e.printStackTrace();
-        }
-        return null;
-    }
+//    public static <T> T toObject(String json, TypeReference<?> typeReference) {
+//        Assert.hasText(json);
+//        Assert.notNull(typeReference);
+//        try {
+//            return mapper.readValue(json, typeReference);
+//        } catch (Exception e) {
+//            e.printStackTrace();
+//        }
+//        return null;
+//    }
 
     /**
      * 将JSON字符串转换为对象

+ 16 - 0
src/main/java/com/szwl/service/TAreaService.java

@@ -0,0 +1,16 @@
+package com.szwl.service;
+
+import com.szwl.model.entity.TArea;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+/**
+ * <p>
+ *  服务类
+ * </p>
+ *
+ * @author wuhs
+ * @since 2022-07-12
+ */
+public interface TAreaService extends IService<TArea> {
+
+}

+ 20 - 0
src/main/java/com/szwl/service/impl/TAreaServiceImpl.java

@@ -0,0 +1,20 @@
+package com.szwl.service.impl;
+
+import com.szwl.model.entity.TArea;
+import com.szwl.mapper.TAreaMapper;
+import com.szwl.service.TAreaService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+
+/**
+ * <p>
+ *  服务实现类
+ * </p>
+ *
+ * @author wuhs
+ * @since 2022-07-12
+ */
+@Service
+public class TAreaServiceImpl extends ServiceImpl<TAreaMapper, TArea> implements TAreaService {
+
+}

+ 1 - 1
src/main/java/com/szwl/service/impl/TShandeMchServiceImpl.java

@@ -83,7 +83,7 @@ public class TShandeMchServiceImpl extends ServiceImpl<TShandeMchMapper, TShande
     @Override
     public String uniPay(String orderNo, BigDecimal amount, String productName, String productDesc, String commonParameter, String returnUrl, String notifyUrl, String frpCode, String isShowPic, String openId, String authCode, String appid, String transactionModel, String tradeMerchantNo, String buyerId, String isAlt, String altType, JSONArray altInfo, String altUrl, BigDecimal marketingAmount) {
 //        long startTime = System.currentTimeMillis();
-        notifyUrl= "http://app.sunzee.com.cn/api/order/shandeRefund.htm";
+        notifyUrl= "http://pay.sunzee.com.cn:49013/tOrder/shandeRefund.htm";
 //        notifyUrl= "http://sunzee.free.idcfengye.com/api/order/shandeRefund.htm";
 //        String payWay = null;
 //        if(frpCode.equals("ALIPAY_NATIVE")){

+ 1 - 1
src/main/resources/bootstrap.yml

@@ -37,7 +37,7 @@ elasticSearch:
   client.esUserName: elastic
   client.esPassword: sunzee@020
 server:
-  port: 49011
+  port: 49013
 
 management:
   endpoints:

+ 1 - 1
src/test/java/com/szwl/AutoGeneratorTests.java

@@ -47,7 +47,7 @@ class AutoGeneratorTests {
 		strategyConfig
 //				.setCapitalMode(true)//设置全局大写命名
 				.setInclude(new String[]{
-						"t_time_rule"
+						""
 				})//只会生成该表
 				.setEntityLombokModel(true)//实体类生成之后自动添加lombok注解
 				.setNaming(NamingStrategy.underline_to_camel)//数据库表映射到实体的命名策略