Add COnstructor

This commit is contained in:
tl 2022-06-07 14:59:13 +02:00
parent 261a47068a
commit c811615d6f
5 changed files with 9 additions and 6 deletions

Binary file not shown.

View File

@ -7,7 +7,6 @@ import lombok.Setter;
import lombok.ToString;
import javax.persistence.*;
import java.util.List;
@Getter
@Setter
@ -20,6 +19,9 @@ import java.util.List;
//@ToString(callSuper = true, onlyExplicitlyIncluded = true)
public class PropulsionTypeEntity extends AbstractEntity {
@Column(name = "type_id", unique = true, nullable = false)
private String typeId;
@Column(nullable = false, unique = true)
private String name;

View File

@ -7,8 +7,7 @@ import lombok.Setter;
@Getter
@Setter
@NoArgsConstructor
public class VehicleModelDto extends AbstractBaseDto{
public class VehicleModelDto extends AbstractBaseDto {
private Long id;
@ -17,7 +16,9 @@ public class VehicleModelDto extends AbstractBaseDto{
private String modelId;
private String name;
private String propulsionType;
public VehicleModelDto(String modelId, String name) {
this.modelId = modelId;
this.name = name;
}
}

View File

@ -13,7 +13,7 @@ public class PropulsionTypeDto extends AbstractServerDto {
private String propulsionId;
private String name;
public PropulsionTypeDto(Long id, String propulsionId, String name){
public PropulsionTypeDto(Long id, String propulsionId, String name) {
super(id);
this.propulsionId = propulsionId;
this.name = name;