Changeset 1bd8d1e for src/main/java/com/example/autopartz/model
- Timestamp:
- 01/05/23 12:40:07 (23 months ago)
- Branches:
- main
- Children:
- f484b14
- Parents:
- 676144b
- Location:
- src/main/java/com/example/autopartz/model
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/main/java/com/example/autopartz/model/Delivery.java
r676144b r1bd8d1e 18 18 @Id 19 19 Integer ID_delivery; 20 String delivery_status; 21 String delivery_address; 20 @Column(name = "delivery_status") 21 String status; 22 @Column(name = "delivery_address") 23 String address; 22 24 @ManyToOne 23 25 @JoinColumn(name = "id_user") -
src/main/java/com/example/autopartz/model/Order.java
r676144b r1bd8d1e 21 21 @Id 22 22 @GeneratedValue(strategy = GenerationType.IDENTITY) 23 Integer ID_order; 23 @Column(name = "ID_order") 24 Integer orderid; 24 25 String order_status; 25 LocalDateTime order_date; 26 @Column(name = "order_date") 27 LocalDateTime date; 26 28 @JoinColumn(name = "id_user") 27 29 @ManyToOne … … 37 39 this.order_status = "created"; 38 40 this.user = user; 39 this. order_date = LocalDateTime.now();41 this.date = LocalDateTime.now(); 40 42 } 41 43 … … 45 47 if (o == null || Hibernate.getClass(this) != Hibernate.getClass(o)) return false; 46 48 Order order = (Order) o; 47 return ID_order != null && Objects.equals(ID_order, order.ID_order);49 return orderid != null && Objects.equals(orderid, order.orderid); 48 50 } 49 51
Note:
See TracChangeset
for help on using the changeset viewer.