change 4 жил өмнө
parent
commit
3b71ad62ca

+ 11 - 0
zhongzheng-admin/src/main/java/com/zhongzheng/controller/schedule/ScheduleController.java

@@ -118,4 +118,15 @@ public class ScheduleController extends BaseController {
         iScheduleService.UpGoods(bo);
         return AjaxResult.success();
     }
+
+    /**
+     * 商品下架状态更新
+     * @return
+     */
+    @ApiOperation("更新考次次数")
+    @GetMapping("/UpExamNum")
+    public AjaxResult UpExamNum(UserQueryBo bo){
+        iScheduleService.UpExamNum(bo);
+        return AjaxResult.success();
+    }
 }

+ 3 - 1
zhongzheng-system/src/main/java/com/zhongzheng/modules/inform/bo/InformCourseAddBo.java

@@ -5,6 +5,8 @@ import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import com.fasterxml.jackson.annotation.JsonFormat;
 import lombok.Data;
+
+import java.math.BigDecimal;
 import java.util.Date;
 
 
@@ -42,7 +44,7 @@ public class InformCourseAddBo {
     private Long chapterId;
     /** 题目位置 */
     @ApiModelProperty("题目位置")
-    private Long topicNum;
+    private BigDecimal topicNum;
 
     @Excel(name = "商品ID")
     @ApiModelProperty("商品ID")

+ 5 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/inform/bo/InformCourseEditBo.java

@@ -5,6 +5,8 @@ import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import com.fasterxml.jackson.annotation.JsonFormat;
 import lombok.Data;
+
+import java.math.BigDecimal;
 import java.util.Date;
 
 
@@ -50,6 +52,9 @@ public class InformCourseEditBo {
     @Excel(name = "商品ID")
     @ApiModelProperty("商品ID")
     private Long goodsId;
+    /** 题目位置 */
+    @ApiModelProperty("题目位置")
+    private BigDecimal topicNum;
 
     /** $column.columnComment */
     @Excel(name = "商品id")

+ 5 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/inform/bo/InformCourseQueryBo.java

@@ -6,6 +6,7 @@ import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 import lombok.EqualsAndHashCode;
 
+import java.math.BigDecimal;
 import java.util.Date;
 import java.util.Map;
 import java.util.HashMap;
@@ -36,6 +37,10 @@ public class InformCourseQueryBo extends BaseEntity {
 	@ApiModelProperty(value = "排序的方向", example = "asc,desc")
 	private String isAsc;
 
+	/** 题目位置 */
+	@ApiModelProperty("题目位置")
+	private BigDecimal topicNum;
+
 
 	/** $column.columnComment */
 	@ApiModelProperty("$column.columnComment")

+ 2 - 1
zhongzheng-system/src/main/java/com/zhongzheng/modules/inform/domain/InformCourse.java

@@ -1,6 +1,7 @@
 package com.zhongzheng.modules.inform.domain;
 
 import com.baomidou.mybatisplus.annotation.*;
+import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 import lombok.NoArgsConstructor;
 import lombok.experimental.Accessors;
@@ -46,7 +47,7 @@ private static final long serialVersionUID=1L;
     /** 章ID */
     private Long goodsId;
     /** 题目位置 */
-    private Long topicNum;
+    private BigDecimal topicNum;
     /** $column.columnComment */
     private String sectionName;
     /** $column.columnComment */

+ 3 - 2
zhongzheng-system/src/main/java/com/zhongzheng/modules/inform/vo/InformCourseVo.java

@@ -5,6 +5,8 @@ import com.fasterxml.jackson.annotation.JsonFormat;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
+
+import java.math.BigDecimal;
 import java.util.Date;
 
 
@@ -46,9 +48,8 @@ public class InformCourseVo {
 	private Long chapterId;
 
 	/** 题目位置 */
-	@Excel(name = "题目位置")
 	@ApiModelProperty("题目位置")
-	private Long topicNum;
+	private BigDecimal topicNum;
 
 	@Excel(name = "商品名")
 	@ApiModelProperty("商品名")

+ 2 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/schedule/service/IScheduleService.java

@@ -38,4 +38,6 @@ public interface IScheduleService extends IService<PolyvVideo> {
     void UpExam(UserQueryBo bo);
 
     void UpGoods(UserQueryBo bo);
+
+    void UpExamNum(UserQueryBo bo);
 }

+ 9 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/schedule/service/impl/ScheduleServiceImpl.java

@@ -26,6 +26,7 @@ import com.zhongzheng.modules.exam.domain.ExamBefore;
 import com.zhongzheng.modules.exam.domain.ExamNumber;
 import com.zhongzheng.modules.exam.mapper.ExamApplyMapper;
 import com.zhongzheng.modules.exam.mapper.ExamBeforeMapper;
+import com.zhongzheng.modules.exam.mapper.ExamNumberMapper;
 import com.zhongzheng.modules.exam.vo.ExamApplyVo;
 import com.zhongzheng.modules.exam.vo.ExamBeforeVo;
 import com.zhongzheng.modules.exam.vo.ExamUserApplyVo;
@@ -164,6 +165,9 @@ public class ScheduleServiceImpl extends ServiceImpl<PolyvVideoMapper, PolyvVide
     @Autowired
     private ExamBeforeMapper examBeforeMapper;
 
+    @Autowired
+    private ExamNumberMapper examNumberMapper;
+
     @Value("${aliyun.sms.OpenTheGoodsCode}")
     private String OpenTheGoodsCode;
 
@@ -734,6 +738,11 @@ public class ScheduleServiceImpl extends ServiceImpl<PolyvVideoMapper, PolyvVide
         int goodsVos = iGoodsService.queryUpGoods();
     }
 
+    @Override
+    public void UpExamNum(UserQueryBo bo) {
+        List<ExamNumber> examNumbers = examNumberMapper.selectUpExamNum();
+    }
+
     //获得可用学习天数
     private static int getDutyDays(Date  startDateStr, Date endDateStr,Long[] longs,Long studyDay)  {
         int result = 0;