可正常启动
This commit is contained in:
parent
7e40c620e7
commit
130ff8b592
@ -6,6 +6,7 @@ import com.qqchen.deploy.backend.framework.query.BaseQuery;
|
|||||||
import com.qqchen.deploy.backend.framework.api.Response;
|
import com.qqchen.deploy.backend.framework.api.Response;
|
||||||
import com.qqchen.deploy.backend.framework.service.IBaseService;
|
import com.qqchen.deploy.backend.framework.service.IBaseService;
|
||||||
import jakarta.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import org.springframework.core.GenericTypeResolver;
|
||||||
import org.springframework.data.domain.Page;
|
import org.springframework.data.domain.Page;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
@ -81,4 +82,5 @@ public abstract class BaseController<T extends Entity<ID>, D extends BaseDTO, ID
|
|||||||
* @param data 要导出的数据
|
* @param data 要导出的数据
|
||||||
*/
|
*/
|
||||||
protected abstract void exportData(HttpServletResponse response, List<D> data);
|
protected abstract void exportData(HttpServletResponse response, List<D> data);
|
||||||
}
|
|
||||||
|
}
|
||||||
@ -116,6 +116,9 @@ public abstract class BaseServiceImpl<T extends Entity<ID>, D extends BaseDTO, I
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<D> findAll(BaseQuery query) {
|
public List<D> findAll(BaseQuery query) {
|
||||||
|
if (query == null) {
|
||||||
|
return findAll(); // 如果查询参数为空,返回所有数据
|
||||||
|
}
|
||||||
BooleanBuilder builder = createQueryPredicate(query);
|
BooleanBuilder builder = createQueryPredicate(query);
|
||||||
Sort sort = createSort(query);
|
Sort sort = createSort(query);
|
||||||
List<T> entities = repository.findAllByCondition(builder, sort);
|
List<T> entities = repository.findAllByCondition(builder, sort);
|
||||||
|
|||||||
@ -122,8 +122,8 @@ public class UserServiceImpl extends BaseServiceImpl<User, UserDTO, Long> implem
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
// @Override
|
||||||
public List<UserDTO> findAll(BaseQuery query) {
|
// public List<UserDTO> findAll(BaseQuery query) {
|
||||||
return null;
|
// return null;
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue
Block a user