Итератор спринг не видит список

 @GetMapping("/apt1-list")
    public String ListOfDrug(Model model) {
        model.addAttribute("pharmacy1", pharmacy1Repository.findAll());
        return "apt1-list";
    }



public interface Pharmacy1Repository extends JpaRepository<Pharmacy1, Integer> {
    
    List<Pharmacy1> findAll();
}


@Entity
@Table(name = "pharmacy1")
public class Pharmacy1 {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "id", nullable = false)
    private Integer id;

    @Column(name = "name", nullable = false, length = 100)
    private String name;

    @Column(name = "date", nullable = false)
    private LocalDate date;

    @Column(name = "count", nullable = false)
    private Integer count;

    @Column(name = "price", nullable = false)
    private Double price;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public LocalDate getDate() {
        return date;
    }

    public void setDate(LocalDate date) {
        this.date = date;
    }

    public Integer getCount() {
        return count;
    }

    public void setCount(Integer count) {
        this.count = count;
    }

    public Double getPrice() {
        return price;
    }

    public void setPrice(Double price) {
        this.price = price;
    }

}


  в контрлере вроде все правильно прописано,репозиторий тоже по всем правилам,и подключение через JPA Entities
             

введите сюда описание изображения


Ответы (0 шт):