mirror of
https://gitee.com/orangeform/orange-admin.git
synced 2026-01-18 02:56:30 +08:00
commit:权限模块新增分配详情功能
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
package com.orange.demo.courseclassinterface.client;
|
||||
|
||||
import com.orange.demo.common.core.base.client.BaseFallbackFactory;
|
||||
import com.orange.demo.common.core.base.client.BaseClient;
|
||||
import com.orange.demo.common.core.constant.ErrorCodeEnum;
|
||||
import com.orange.demo.common.core.object.MyQueryParam;
|
||||
import com.orange.demo.common.core.object.ResponseResult;
|
||||
import com.orange.demo.courseclassinterface.dto.AreaCodeDto;
|
||||
import feign.hystrix.FallbackFactory;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.stereotype.Component;
|
||||
@@ -93,8 +93,8 @@ public interface AreaCodeClient extends BaseClient<AreaCodeDto, Long> {
|
||||
*
|
||||
* @return 字典数据列表,返回形式为 List<Map<String, Object>>,map中包含两条记录,分别是id和name。
|
||||
*/
|
||||
@PostMapping("/areaCode/listDictAreaCode")
|
||||
ResponseResult<List<Map<String, Object>>> listDictAreaCode();
|
||||
@PostMapping("/areaCode/listDict")
|
||||
ResponseResult<List<Map<String, Object>>> listDict();
|
||||
|
||||
/**
|
||||
* 以id、name的形式返回所有字典数据的列表。
|
||||
@@ -102,50 +102,21 @@ public interface AreaCodeClient extends BaseClient<AreaCodeDto, Long> {
|
||||
* @param parentId 主键的ParentId,用于对主键数据进行过滤。
|
||||
* @return 字典数据列表,返回形式为 List<Map<String, Object>>,map中包含两条记录,分别是id和name。
|
||||
*/
|
||||
@PostMapping("/areaCode/listDictAreaCodeByParentId")
|
||||
ResponseResult<List<Map<String, Object>>> listDictAreaCodeByParentId(@RequestParam("parentId") Long parentId);
|
||||
@GetMapping("/areaCode/listDictByParentId")
|
||||
ResponseResult<List<Map<String, Object>>> listDictByParentId(@RequestParam("parentId") Long parentId);
|
||||
|
||||
@Component
|
||||
@Slf4j
|
||||
class AreaCodeClientFallbackFactory implements FallbackFactory<AreaCodeClient>, AreaCodeClient {
|
||||
class AreaCodeClientFallbackFactory
|
||||
extends BaseFallbackFactory<AreaCodeDto, Long, AreaCodeClient> implements AreaCodeClient {
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<AreaCodeDto>> listByIds(Set<Long> areaCodeIds, Boolean withDict) {
|
||||
public ResponseResult<List<Map<String, Object>>> listDict() {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<AreaCodeDto> getById(Long areaId, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existIds(Set<Long> areaIds) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existId(Long areaId) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<AreaCodeDto>> listBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<AreaCodeDto> getBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> listDictAreaCode() {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> listDictAreaCodeByParentId(Long parentId) {
|
||||
public ResponseResult<List<Map<String, Object>>> listDictByParentId(Long parentId) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
package com.orange.demo.courseclassinterface.client;
|
||||
|
||||
import com.orange.demo.common.core.base.client.BaseFallbackFactory;
|
||||
import com.orange.demo.common.core.config.FeignConfig;
|
||||
import com.orange.demo.common.core.base.client.BaseClient;
|
||||
import com.orange.demo.common.core.constant.ErrorCodeEnum;
|
||||
import com.orange.demo.common.core.object.*;
|
||||
import com.orange.demo.courseclassinterface.dto.CourseDto;
|
||||
import feign.hystrix.FallbackFactory;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.stereotype.Component;
|
||||
@@ -71,6 +70,26 @@ public interface CourseClient extends BaseClient<CourseDto, Long> {
|
||||
@PostMapping("/course/existId")
|
||||
ResponseResult<Boolean> existId(@RequestParam("courseId") Long courseId);
|
||||
|
||||
/**
|
||||
* 删除主键Id关联的对象。
|
||||
*
|
||||
* @param courseId 主键Id。
|
||||
* @return 应答结果对象。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/course/delete")
|
||||
ResponseResult<Void> delete(@RequestParam("courseId") Long courseId);
|
||||
|
||||
/**
|
||||
* 删除符合过滤条件的数据。
|
||||
*
|
||||
* @param filter 过滤对象。
|
||||
* @return 应答结果对象,包含删除数量。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/course/deleteBy")
|
||||
ResponseResult<Integer> deleteBy(@RequestBody CourseDto filter);
|
||||
|
||||
/**
|
||||
* 获取远程主对象中符合查询条件的数据列表。
|
||||
*
|
||||
@@ -124,54 +143,8 @@ public interface CourseClient extends BaseClient<CourseDto, Long> {
|
||||
|
||||
@Component("CourseClassCourseClientFallbackFactory")
|
||||
@Slf4j
|
||||
class CourseClientFallbackFactory implements FallbackFactory<CourseClient>, CourseClient {
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<CourseDto>> listByIds(
|
||||
Set<Long> courseIds, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<CourseDto> getById(
|
||||
Long courseId, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existIds(Set<Long> courseIds) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existId(Long courseId) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<CourseDto>> listBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<CourseDto> getBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> listMapBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Integer> countBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> aggregateBy(MyAggregationParam aggregationParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
class CourseClientFallbackFactory
|
||||
extends BaseFallbackFactory<CourseDto, Long, CourseClient> implements CourseClient {
|
||||
|
||||
@Override
|
||||
public CourseClient create(Throwable throwable) {
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
package com.orange.demo.courseclassinterface.client;
|
||||
|
||||
import com.orange.demo.common.core.base.client.BaseFallbackFactory;
|
||||
import com.orange.demo.common.core.config.FeignConfig;
|
||||
import com.orange.demo.common.core.base.client.BaseClient;
|
||||
import com.orange.demo.common.core.constant.ErrorCodeEnum;
|
||||
import com.orange.demo.common.core.object.*;
|
||||
import com.orange.demo.courseclassinterface.dto.GradeDto;
|
||||
import feign.hystrix.FallbackFactory;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.stereotype.Component;
|
||||
@@ -71,6 +70,26 @@ public interface GradeClient extends BaseClient<GradeDto, Integer> {
|
||||
@PostMapping("/grade/existId")
|
||||
ResponseResult<Boolean> existId(@RequestParam("gradeId") Integer gradeId);
|
||||
|
||||
/**
|
||||
* 删除主键Id关联的对象。
|
||||
*
|
||||
* @param gradeId 主键Id。
|
||||
* @return 应答结果对象。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/grade/delete")
|
||||
ResponseResult<Void> delete(@RequestParam("gradeId") Integer gradeId);
|
||||
|
||||
/**
|
||||
* 删除符合过滤条件的数据。
|
||||
*
|
||||
* @param filter 过滤对象。
|
||||
* @return 应答结果对象,包含删除数量。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/grade/deleteBy")
|
||||
ResponseResult<Integer> deleteBy(@RequestBody GradeDto filter);
|
||||
|
||||
/**
|
||||
* 获取远程主对象中符合查询条件的数据列表。
|
||||
*
|
||||
@@ -93,39 +112,8 @@ public interface GradeClient extends BaseClient<GradeDto, Integer> {
|
||||
|
||||
@Component("CourseClassGradeClientFallbackFactory")
|
||||
@Slf4j
|
||||
class GradeClientFallbackFactory implements FallbackFactory<GradeClient>, GradeClient {
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<GradeDto>> listByIds(
|
||||
Set<Integer> gradeIds, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<GradeDto> getById(
|
||||
Integer gradeId, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existIds(Set<Integer> gradeIds) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existId(Integer gradeId) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<GradeDto>> listBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<GradeDto> getBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
class GradeClientFallbackFactory
|
||||
extends BaseFallbackFactory<GradeDto, Integer, GradeClient> implements GradeClient {
|
||||
|
||||
@Override
|
||||
public GradeClient create(Throwable throwable) {
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
package com.orange.demo.courseclassinterface.client;
|
||||
|
||||
import com.orange.demo.common.core.base.client.BaseFallbackFactory;
|
||||
import com.orange.demo.common.core.config.FeignConfig;
|
||||
import com.orange.demo.common.core.base.client.BaseClient;
|
||||
import com.orange.demo.common.core.constant.ErrorCodeEnum;
|
||||
import com.orange.demo.common.core.object.*;
|
||||
import com.orange.demo.courseclassinterface.dto.SchoolInfoDto;
|
||||
import feign.hystrix.FallbackFactory;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.stereotype.Component;
|
||||
@@ -71,6 +70,26 @@ public interface SchoolInfoClient extends BaseClient<SchoolInfoDto, Long> {
|
||||
@PostMapping("/schoolInfo/existId")
|
||||
ResponseResult<Boolean> existId(@RequestParam("schoolId") Long schoolId);
|
||||
|
||||
/**
|
||||
* 删除主键Id关联的对象。
|
||||
*
|
||||
* @param schoolId 主键Id。
|
||||
* @return 应答结果对象。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/schoolInfo/delete")
|
||||
ResponseResult<Void> delete(@RequestParam("schoolId") Long schoolId);
|
||||
|
||||
/**
|
||||
* 删除符合过滤条件的数据。
|
||||
*
|
||||
* @param filter 过滤对象。
|
||||
* @return 应答结果对象,包含删除数量。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/schoolInfo/deleteBy")
|
||||
ResponseResult<Integer> deleteBy(@RequestBody SchoolInfoDto filter);
|
||||
|
||||
/**
|
||||
* 获取远程主对象中符合查询条件的数据列表。
|
||||
*
|
||||
@@ -124,54 +143,8 @@ public interface SchoolInfoClient extends BaseClient<SchoolInfoDto, Long> {
|
||||
|
||||
@Component("CourseClassSchoolInfoClientFallbackFactory")
|
||||
@Slf4j
|
||||
class SchoolInfoClientFallbackFactory implements FallbackFactory<SchoolInfoClient>, SchoolInfoClient {
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<SchoolInfoDto>> listByIds(
|
||||
Set<Long> schoolIds, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<SchoolInfoDto> getById(
|
||||
Long schoolId, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existIds(Set<Long> schoolIds) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existId(Long schoolId) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<SchoolInfoDto>> listBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<SchoolInfoDto> getBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> listMapBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Integer> countBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> aggregateBy(MyAggregationParam aggregationParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
class SchoolInfoClientFallbackFactory
|
||||
extends BaseFallbackFactory<SchoolInfoDto, Long, SchoolInfoClient> implements SchoolInfoClient {
|
||||
|
||||
@Override
|
||||
public SchoolInfoClient create(Throwable throwable) {
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
package com.orange.demo.courseclassinterface.client;
|
||||
|
||||
import com.orange.demo.common.core.base.client.BaseFallbackFactory;
|
||||
import com.orange.demo.common.core.config.FeignConfig;
|
||||
import com.orange.demo.common.core.base.client.BaseClient;
|
||||
import com.orange.demo.common.core.constant.ErrorCodeEnum;
|
||||
import com.orange.demo.common.core.object.*;
|
||||
import com.orange.demo.courseclassinterface.dto.StudentClassDto;
|
||||
import feign.hystrix.FallbackFactory;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.stereotype.Component;
|
||||
@@ -71,6 +70,26 @@ public interface StudentClassClient extends BaseClient<StudentClassDto, Long> {
|
||||
@PostMapping("/studentClass/existId")
|
||||
ResponseResult<Boolean> existId(@RequestParam("classId") Long classId);
|
||||
|
||||
/**
|
||||
* 删除主键Id关联的对象。
|
||||
*
|
||||
* @param classId 主键Id。
|
||||
* @return 应答结果对象。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/studentClass/delete")
|
||||
ResponseResult<Void> delete(@RequestParam("classId") Long classId);
|
||||
|
||||
/**
|
||||
* 删除符合过滤条件的数据。
|
||||
*
|
||||
* @param filter 过滤对象。
|
||||
* @return 应答结果对象,包含删除数量。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/studentClass/deleteBy")
|
||||
ResponseResult<Integer> deleteBy(@RequestBody StudentClassDto filter);
|
||||
|
||||
/**
|
||||
* 获取远程主对象中符合查询条件的数据列表。
|
||||
*
|
||||
@@ -124,54 +143,8 @@ public interface StudentClassClient extends BaseClient<StudentClassDto, Long> {
|
||||
|
||||
@Component("CourseClassStudentClassClientFallbackFactory")
|
||||
@Slf4j
|
||||
class StudentClassClientFallbackFactory implements FallbackFactory<StudentClassClient>, StudentClassClient {
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<StudentClassDto>> listByIds(
|
||||
Set<Long> classIds, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<StudentClassDto> getById(
|
||||
Long classId, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existIds(Set<Long> classIds) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existId(Long classId) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<StudentClassDto>> listBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<StudentClassDto> getBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> listMapBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Integer> countBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> aggregateBy(MyAggregationParam aggregationParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
class StudentClassClientFallbackFactory
|
||||
extends BaseFallbackFactory<StudentClassDto, Long, StudentClassClient> implements StudentClassClient {
|
||||
|
||||
@Override
|
||||
public StudentClassClient create(Throwable throwable) {
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
package com.orange.demo.courseclassinterface.client;
|
||||
|
||||
import com.orange.demo.common.core.base.client.BaseFallbackFactory;
|
||||
import com.orange.demo.common.core.config.FeignConfig;
|
||||
import com.orange.demo.common.core.base.client.BaseClient;
|
||||
import com.orange.demo.common.core.constant.ErrorCodeEnum;
|
||||
import com.orange.demo.common.core.object.*;
|
||||
import com.orange.demo.courseclassinterface.dto.StudentDto;
|
||||
import feign.hystrix.FallbackFactory;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.stereotype.Component;
|
||||
@@ -71,6 +70,26 @@ public interface StudentClient extends BaseClient<StudentDto, Long> {
|
||||
@PostMapping("/student/existId")
|
||||
ResponseResult<Boolean> existId(@RequestParam("studentId") Long studentId);
|
||||
|
||||
/**
|
||||
* 删除主键Id关联的对象。
|
||||
*
|
||||
* @param studentId 主键Id。
|
||||
* @return 应答结果对象。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/student/delete")
|
||||
ResponseResult<Void> delete(@RequestParam("studentId") Long studentId);
|
||||
|
||||
/**
|
||||
* 删除符合过滤条件的数据。
|
||||
*
|
||||
* @param filter 过滤对象。
|
||||
* @return 应答结果对象,包含删除数量。
|
||||
*/
|
||||
@Override
|
||||
@PostMapping("/student/deleteBy")
|
||||
ResponseResult<Integer> deleteBy(@RequestBody StudentDto filter);
|
||||
|
||||
/**
|
||||
* 获取远程主对象中符合查询条件的数据列表。
|
||||
*
|
||||
@@ -124,54 +143,8 @@ public interface StudentClient extends BaseClient<StudentDto, Long> {
|
||||
|
||||
@Component("CourseClassStudentClientFallbackFactory")
|
||||
@Slf4j
|
||||
class StudentClientFallbackFactory implements FallbackFactory<StudentClient>, StudentClient {
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<StudentDto>> listByIds(
|
||||
Set<Long> studentIds, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<StudentDto> getById(
|
||||
Long studentId, Boolean withDict) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existIds(Set<Long> studentIds) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Boolean> existId(Long studentId) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<StudentDto>> listBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<StudentDto> getBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> listMapBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<Integer> countBy(MyQueryParam queryParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResponseResult<List<Map<String, Object>>> aggregateBy(MyAggregationParam aggregationParam) {
|
||||
return ResponseResult.error(ErrorCodeEnum.RPC_DATA_ACCESS_FAILED);
|
||||
}
|
||||
class StudentClientFallbackFactory
|
||||
extends BaseFallbackFactory<StudentDto, Long, StudentClient> implements StudentClient {
|
||||
|
||||
@Override
|
||||
public StudentClient create(Throwable throwable) {
|
||||
|
||||
Reference in New Issue
Block a user