嵌套的异常是org.springframework.data.mapping.propertyreferenceExce



我收到以下错误:

org.springframework.data.mapping.propertyReferenceException:未找到针对InwardRegister的属性

这是我的代码:

@Repository
public interface InwardRegisterRepository extends ReactiveSortingRepository<InwardRegister,Long> {
    @AllowFiltering
    Flux<InwardRegister> findByDateTime(Date dateTime);
    @AllowFiltering
    Flux<InwardRegister> findBySenderOrderById(String sender);
}
@Service
public class InwardRegisterService {
    @Autowired
    InwardRegisterRepository inwardRegisterRepository;
    public Mono<InwardRegister> create(InwardRegister inwardRegisterRecord) {
        return inwardRegisterRepository.save(inwardRegisterRecord);
    }
    public Mono<InwardRegister> read(Long id){
        return inwardRegisterRepository.findById(id);
    }
    public Flux<InwardRegister> readAll(){
        return inwardRegisterRepository.findAll(Sort.by("ASI","id"));
    }
}

错误看起来您的bean inwardregister.class不包含@id javax.persistence注释,请提供实体类详细信息以进一步检查..

相关内容

  • 没有找到相关文章

最新更新