Преглед на файлове

预约优化,和订单进行绑定

liude преди 1 година
родител
ревизия
5c467553f0

+ 5 - 0
vehicle-client/src/main/java/com/chelvc/cloud/vehicle/client/dto/ReservationDTO.java

@@ -67,4 +67,9 @@ public class ReservationDTO implements Serializable {
      * 商家信息
      */
     private MerchantDTO merchant;
+
+    /**
+     * 订单ID
+     */
+    private Long orderId;
 }

+ 0 - 1
vehicle-client/src/main/java/com/chelvc/cloud/vehicle/client/param/FeedBackModifyParam.java

@@ -22,7 +22,6 @@ public class FeedBackModifyParam implements Serializable {
     /**
      * 标题
      */
-    @NotEmpty(message = "标题不能为空")
     @Size(max = 255, message = "标题长度不能大于255")
     private String title;
 

+ 5 - 0
vehicle-client/src/main/java/com/chelvc/cloud/vehicle/client/param/ReservationModifyParam.java

@@ -45,4 +45,9 @@ public class ReservationModifyParam implements Serializable {
      */
     @Size(max = 255, message = "商品名称长度不能大于255")
     private String goodsName;
+
+    /**
+     * 订单ID
+     */
+    private Long orderId;
 }

+ 4 - 0
vehicle-server/src/main/java/com/chelvc/cloud/vehicle/server/entity/Reservation.java

@@ -75,4 +75,8 @@ public class Reservation extends ModifyEntity<Long> {
      * 商品名称
      */
     private String goodsName;
+    /**
+     * 订单ID
+     */
+    private Long orderId;
 }

+ 2 - 1
vehicle-server/src/main/resources/mapper/ReservationMapper.xml

@@ -13,6 +13,7 @@
         <result column="create_time" property="createTime" jdbcType="TIMESTAMP"/>
         <result column="updater" property="updater" jdbcType="BIGINT"/>
         <result column="goods_id" property="goodsId" jdbcType="BIGINT"/>
+        <result column="order_id" property="orderId" jdbcType="BIGINT"/>
         <result column="goods_name" property="goodsName" jdbcType="VARCHAR"/>
         <result column="update_time" property="updateTime" jdbcType="TIMESTAMP"/>
         <association property="merchant" javaType="com.chelvc.cloud.vehicle.client.dto.MerchantDTO">
@@ -28,7 +29,7 @@
 
     <select id="listUserReservations" resultMap="RESERVATION_RESULT_MAP">
         select rn.id,rn.user_id,rn.merchant_id,rn.mobile,rn.appoint_time,rn.status, mt.name, mt.logo, mt.score,
-        mt.sale, mt.address,rn.goods_id,rn.goods_name
+        mt.sale, mt.address,rn.goods_id,rn.goods_name,rn.order_id
         from reservation rn
         inner join merchant mt on merchant_id = mt.id and mt.status = 'ONLINE'
         where rn.user_id = #{userId}