feat: 还原
This commit is contained in:
+38
@@ -0,0 +1,38 @@
|
||||
package com.yida.data.school.fallback.transaction;
|
||||
|
||||
import com.yida.data.common.core.annotation.Fallback;
|
||||
import com.yida.data.common.core.common.ResultBean;
|
||||
import com.yida.data.school.feign.transaction.RemoteStudentApplyService;
|
||||
import feign.hystrix.FallbackFactory;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* RemoteStudentApplyService fallback处理类
|
||||
*
|
||||
* @author ZYJ
|
||||
* @date 2022/8/26
|
||||
*/
|
||||
@Slf4j
|
||||
@Fallback
|
||||
public class RemoteStudentApplyServiceFallback implements FallbackFactory<RemoteStudentApplyService> {
|
||||
|
||||
@Override
|
||||
public RemoteStudentApplyService create(Throwable throwable) {
|
||||
log.error("RemoteStudentApplyService fallback reason:{}", throwable.getMessage());
|
||||
|
||||
return new RemoteStudentApplyService() {
|
||||
@Override
|
||||
public ResultBean<Map<Long, List<String>>> listApplyCode(Long[] studentIds) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResultBean<Boolean> hasApply(Long studentId, String applyCode) {
|
||||
return null;
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
package com.yida.data.school.feign.transaction;
|
||||
|
||||
import com.yida.data.common.core.common.ResultBean;
|
||||
import com.yida.data.common.core.entity.constant.FebsServerConstant;
|
||||
|
||||
import com.yida.data.school.fallback.transaction.RemoteStudentApplyServiceFallback;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@FeignClient(value = FebsServerConstant.EDU_SCHOOL, contextId = "studentApplyServiceClient",
|
||||
fallbackFactory = RemoteStudentApplyServiceFallback.class)
|
||||
public interface RemoteStudentApplyService {
|
||||
|
||||
@GetMapping("/in/transaction/studentApply/listApply")
|
||||
ResultBean<Map<Long, List<String>>> listApplyCode(@RequestParam("studentIds") Long[] studentIds);
|
||||
|
||||
@GetMapping("/transaction/studentApply/hasApply")
|
||||
ResultBean<Boolean> hasApply(@RequestParam("studentId") Long studentId,
|
||||
@RequestParam("applyCode") String applyCode);
|
||||
}
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package com.yida.data.school.vo.news;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* 发布稿件进度 - 实体
|
||||
*/
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Data
|
||||
public class ManuscriptPublishPathVO {
|
||||
|
||||
@ApiModelProperty("名称")
|
||||
private String label;
|
||||
|
||||
@ApiModelProperty("")
|
||||
private Integer value;
|
||||
|
||||
private static Integer wxPath = 0;
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
package com.yida.data.school.vo.transcation;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class StudentApplyImportErrorVO {
|
||||
|
||||
@ExcelProperty(index = 1, value = "有效结束时间")
|
||||
@ApiModelProperty("错误信息")
|
||||
private String errorMsg;
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
package com.yida.data.school.vo.transcation;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class StudentApplyImportProgressVO {
|
||||
|
||||
private Integer totalNum;
|
||||
private Integer currentNum;
|
||||
private String errorPageUrl;
|
||||
private Integer finish;
|
||||
private String redisKey;
|
||||
}
|
||||
+57
@@ -0,0 +1,57 @@
|
||||
package com.yida.data.school.vo.transcation;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.yida.data.common.core.converter.LocalDateTimeConverter;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class StudentApplyImportVO {
|
||||
|
||||
@ExcelProperty(index = 0, value = "序号")
|
||||
@ApiModelProperty(value = "序号")
|
||||
private Long indexNo;
|
||||
|
||||
@ExcelProperty(index = 1, value = "学校名称")
|
||||
@ApiModelProperty("学校名称")
|
||||
private String schoolName;
|
||||
|
||||
@ExcelProperty(index = 2, value = "校区名称")
|
||||
@ApiModelProperty("校区名称")
|
||||
private String campusName;
|
||||
|
||||
@ExcelProperty(index = 3, value = "学段名称")
|
||||
@ApiModelProperty("学段名称")
|
||||
private String sectionName;
|
||||
|
||||
@ExcelProperty(index = 4, value = "年级名称")
|
||||
@ApiModelProperty("年级名称")
|
||||
private String gradeName;
|
||||
|
||||
@ExcelProperty(index = 5, value = "班级名称")
|
||||
@ApiModelProperty("班级名称")
|
||||
private String className;
|
||||
|
||||
@ExcelProperty(index = 6, value = "学生姓名")
|
||||
@ApiModelProperty("学生姓名")
|
||||
private String studentName;
|
||||
|
||||
@ExcelProperty(index = 7, value = "学生学号")
|
||||
@ApiModelProperty("学生学号")
|
||||
private String studentNumber;
|
||||
|
||||
@ExcelProperty(index = 8, value = "开通应用")
|
||||
@ApiModelProperty("开通应用")
|
||||
private String applyCode;
|
||||
|
||||
@ExcelProperty(index = 9, value = "有效开始时间")
|
||||
@ApiModelProperty("有效开始时间")
|
||||
private String startTime;
|
||||
|
||||
@ExcelProperty(index = 10, value = "有效结束时间")
|
||||
@ApiModelProperty("有效结束时间")
|
||||
private String endTime;
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.yida.data.school.vo.transcation;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDate;
|
||||
|
||||
@Data
|
||||
public class StudentApplyStatusVO {
|
||||
|
||||
@ApiModelProperty("应用状态,0-未开通,1-使用中,2-已过期")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("过期时间")
|
||||
private LocalDate deadLine;
|
||||
}
|
||||
Reference in New Issue
Block a user