Skip to content

Commit cd4a7ee

Browse files
committed
✨ Add data field to Product
1 parent 8d965d2 commit cd4a7ee

4 files changed

Lines changed: 68 additions & 75 deletions

File tree

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
package com.rubberduckcrew.ecoscan_backend.products.dto;
22

3-
public record ProductDTO(String id, String name, String description, String imageUrl) {
3+
public record ProductDTO(String id, String name, String description, String imageUrl, String data) {
44
}

ecoscan_backend/src/main/java/com/rubberduckcrew/ecoscan_backend/products/entity/Product.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,6 @@ public class Product implements Serializable {
2929

3030
@NotNull @Size(max = 2048) @Column(length = 2048, nullable = false)
3131
private String description;
32+
33+
@NotNull private String data;
3234
}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
ALTER TABLE product
2+
ADD COLUMN data VARCHAR(2048) NOT NULL;

0 commit comments

Comments
 (0)