package com.example.demo.model; import lombok.Data; import org.springframework.beans.factory.annotation.Autowired; import javax.persistence.*; @Entity @Data @Table(name="payment_type") public class PaymentType { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) public Integer payment_type_id; public String payment_type; public PaymentType(Integer payment_type_id, String payment_type) { this.payment_type_id = payment_type_id; this.payment_type = payment_type; } public PaymentType() { } public Integer getPayment_type_id() { return payment_type_id; } public void setPayment_type_id(Integer payment_type_id) { this.payment_type_id = payment_type_id; } public String getPayment_type() { return payment_type; } public void setPayment_type(String payment_type) { this.payment_type = payment_type; } }