Browse Source

feat(system): 添加 AppIsin 实体及其相关功能

- 新增 AppIsin 实体类,用于表示 nm_isin 表的数据结构
- 添加 AppIsinMapper接口和对应的 XML 文件,实现对 AppIsin 数据的 CRUD操作
- 实现 AppIsinServiceImpl 类,提供 AppIsin相关的业务逻辑服务
-
SheepHy 1 week ago
parent
commit
3a2ce6c752

+ 1 - 1
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/app/service/IOrderService.java

@@ -14,7 +14,7 @@ public interface IOrderService {
      * @Param rulesId 时间段ID
      * @return OrderVO.createOrderPlaceSchool
      **/
-    OrderVO.createOrderPlaceSchool createOrderPlaceSchool(String rulesId);
+    OrderVO.createOrderPlaceSchool createOrderPlaceSchool(String rulesId, String userIds);
 
     /**
      * @Author SheepHy

+ 2 - 2
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/app/vo/OrderVO.java

@@ -116,8 +116,8 @@ public class OrderVO {
         @Schema(description = "订单ID")
         private String id;
         /** 预订信息**/
-        @Schema(description = "订单状态")
-        private String orderStatus;
+        @Schema(description = "订单状态0初始 1、支付中 2、待使用 3、已使用 4、待评价 5、退款中 6、已退款")
+        private int orderStatus;
         @Schema(description = "场地名称")
         private String placeName;
         @Schema(description = "时间段")

+ 84 - 0
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/entity/AppIsin.java

@@ -0,0 +1,84 @@
+package org.jeecg.modules.system.app.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import lombok.experimental.Accessors;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * @Description: nm_isin
+ * @Author: jeecg-boot
+ * @Date:   2025-07-16
+ * @Version: V1.0
+ */
+@Data
+@TableName("nm_isin")
+@Accessors(chain = true)
+@EqualsAndHashCode(callSuper = false)
+@Schema(description="nm_isin")
+public class AppIsin implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键ID*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @Schema(description = "主键ID")
+    private String id;
+	/**订单ID*/
+	@Excel(name = "订单ID", width = 15)
+    @Schema(description = "订单ID")
+    private String orderId;
+	/**用户ID*/
+	@Excel(name = "用户ID(关联家庭用户表)", width = 15)
+    @Schema(description = "用户ID(关联家庭用户表)")
+    private String familyId;
+	/**券码号*/
+	@Excel(name = "券码号", width = 15)
+    @Schema(description = "券码号")
+    private String isinCode;
+	/**券状态 1、待使用 2、已使用 3、已失效*/
+	@Excel(name = "券状态 1、待使用 2、已使用 3、已失效", width = 15)
+    @Schema(description = "券状态 1、待使用 2、已使用 3、已失效")
+    private Integer isinStatus;
+    /**核验人*/
+    @Excel(name = "核验人", width = 15)
+    @Schema(description = "核验人")
+    private String verifyBy;
+	/**使用时间*/
+	@Excel(name = "使用时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @Schema(description = "使用时间")
+    private Date useTime;
+	/**创建人;创建人*/
+    @Schema(description = "创建人;创建人")
+    private String createBy;
+	/**创建时间;创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @Schema(description = "创建时间;创建时间")
+    private Date createTime;
+	/**更新时间;更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @Schema(description = "更新时间;更新时间")
+    private Date updateTime;
+	/**系统状态;状态(0-正常,1-冻结)*/
+	@Excel(name = "系统状态;状态(0-正常,1-冻结)", width = 15)
+    @Schema(description = "系统状态;状态(0-正常,1-冻结)")
+    private Integer status;
+	/**删除标志;删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除标志;删除状态(0-正常,1-已删除)", width = 15)
+    @Schema(description = "删除标志;删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+}

+ 0 - 8
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/entity/AppOrder.java

@@ -46,10 +46,6 @@ public class AppOrder implements Serializable {
 	@Excel(name = "部门id", width = 15)
     @Schema(description = "部门id")
     private String orgCode;
-	/**租户id*/
-	@Excel(name = "租户id", width = 15)
-    @Schema(description = "租户id")
-    private String tenantId;
 	/**产品id列表;场地/赛事/课程*/
 	@Excel(name = "产品id列表;场地/赛事/课程", width = 15)
     @Schema(description = "产品id列表;场地/赛事/课程")
@@ -82,10 +78,6 @@ public class AppOrder implements Serializable {
 	@Excel(name = "订单状态", width = 15)
     @Schema(description = "订单状态0初始 1、支付中 2、待使用 3、已使用 4、待评价 5、退款中 6、已退款")
     private int orderStatus;
-	/**二维码券号*/
-	@Excel(name = "二维码券号", width = 15)
-    @Schema(description = "二维码券号")
-    private String isin;
 	/**保单id;保单列表*/
 	@Excel(name = "保单id;保单列表", width = 15)
     @Schema(description = "保单id;保单列表")

+ 7 - 31
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/entity/AppOrderProduct.java

@@ -1,23 +1,19 @@
 package org.jeecg.modules.system.app.entity;
 
-import java.io.Serializable;
-import java.io.UnsupportedEncodingException;
-import java.util.Date;
-import java.math.BigDecimal;
 import com.baomidou.mybatisplus.annotation.IdType;
 import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
 import com.baomidou.mybatisplus.annotation.TableLogic;
-import org.jeecg.common.constant.ProvinceCityArea;
-import org.jeecg.common.util.SpringContextUtils;
-import lombok.Data;
+import com.baomidou.mybatisplus.annotation.TableName;
 import com.fasterxml.jackson.annotation.JsonFormat;
-import org.springframework.format.annotation.DateTimeFormat;
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecg.common.aspect.annotation.Dict;
 import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
 import lombok.EqualsAndHashCode;
 import lombok.experimental.Accessors;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.io.Serializable;
+import java.util.Date;
 
 /**
  * @Description: 订单产品明细
@@ -41,10 +37,6 @@ public class AppOrderProduct implements Serializable {
 	@Excel(name = "部门id", width = 15)
     @Schema(description = "部门id")
     private String orgCode;
-	/**商户id/场地id;校验信息查看*/
-	@Excel(name = "商户id/场地id;校验信息查看", width = 15)
-    @Schema(description = "商户id/场地id;校验信息查看")
-    private String tenantId;
 	/**订单id*/
 	@Excel(name = "订单id", width = 15)
     @Schema(description = "订单id")
@@ -57,22 +49,6 @@ public class AppOrderProduct implements Serializable {
 	@Excel(name = "价格规则id;真正的产品id", width = 15)
     @Schema(description = "价格规则id;真正的产品id")
     private String ruleId;
-	/**产品订单状态;0初始 1已使用 2退款中 3已退款*/
-	@Excel(name = "产品订单状态;0初始 1已使用 2退款中 3已退款", width = 15)
-    @Schema(description = "产品订单状态;0初始 1已使用 2退款中 3已退款")
-    private String productOrderStatus;
-	/**核验人*/
-	@Excel(name = "核验人", width = 15)
-    @Schema(description = "核验人")
-    private String verifyBy;
-	/**使用人*/
-	@Excel(name = "使用人", width = 15)
-    @Schema(description = "使用人")
-    private String userId;
-	/**乐观锁*/
-	@Excel(name = "乐观锁", width = 15)
-    @Schema(description = "乐观锁")
-    private Integer revision;
 	/**创建人;创建人*/
     @Schema(description = "创建人;创建人")
     private String createBy;

+ 14 - 0
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/mapper/AppIsinMapper.java

@@ -0,0 +1,14 @@
+package org.jeecg.modules.system.app.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.jeecg.modules.system.app.entity.AppIsin;
+
+/**
+ * @Description: nm_isin
+ * @Author: jeecg-boot
+ * @Date:   2025-07-16
+ * @Version: V1.0
+ */
+public interface AppIsinMapper extends BaseMapper<AppIsin> {
+
+}

+ 5 - 0
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/mapper/xml/AppIsinMapper.xml

@@ -0,0 +1,5 @@
+<?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="org.jeecg.modules.system.app.mapper.AppIsinMapper">
+
+</mapper>

+ 1 - 1
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/mapper/xml/AppSitePriceRulesMapper.xml

@@ -24,7 +24,7 @@
         r.end_time,
         r.selling_price,
         r.day_of_week,
-        ROW_NUMBER() OVER ( PARTITION BY r.day_of_week ORDER BY r.start_time ) AS rn
+        ROW_NUMBER() OVER (PARTITION BY r.day_of_week ORDER BY r.selling_price ASC, r.start_time ASC) AS rn
         FROM
         nm_site_price_rules r
         LEFT JOIN nm_site_place sp ON r.site_place_id = sp.id

+ 14 - 0
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/service/IAppIsinService.java

@@ -0,0 +1,14 @@
+package org.jeecg.modules.system.app.service;
+
+import com.baomidou.mybatisplus.extension.service.IService;
+import org.jeecg.modules.system.app.entity.AppIsin;
+
+/**
+ * @Description: nm_isin
+ * @Author: jeecg-boot
+ * @Date:   2025-07-16
+ * @Version: V1.0
+ */
+public interface IAppIsinService extends IService<AppIsin> {
+
+}

+ 18 - 0
national-motion-module-system/national-motion-system-biz/src/main/java/org/jeecg/modules/system/app/service/impl/AppIsinServiceImpl.java

@@ -0,0 +1,18 @@
+package org.jeecg.modules.system.app.service.impl;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.jeecg.modules.system.app.entity.AppIsin;
+import org.jeecg.modules.system.app.mapper.AppIsinMapper;
+import org.jeecg.modules.system.app.service.IAppIsinService;
+import org.springframework.stereotype.Service;
+
+/**
+ * @Description: nm_isin
+ * @Author: jeecg-boot
+ * @Date:   2025-07-16
+ * @Version: V1.0
+ */
+@Service
+public class AppIsinServiceImpl extends ServiceImpl<AppIsinMapper, AppIsin> implements IAppIsinService {
+
+}