Ignore:
Timestamp:
02/05/23 19:55:10 (21 months ago)
Author:
Gjoko Kostadinov <gjoko.kostadinov@…>
Branches:
master
Children:
2b0a4db
Parents:
cc52b09
Message:

Adding customer registration

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/main/java/edu/gjoko/schedlr/entity/Business.java

    rcc52b09 ra436340  
    11package edu.gjoko.schedlr.entity;
    22
     3import com.fasterxml.jackson.annotation.JsonManagedReference;
    34import lombok.AllArgsConstructor;
    45import lombok.Getter;
     
    2526    private String name;
    2627
    27     @Column(name = "business_type")
    28     @Enumerated(EnumType.STRING)
     28    @OneToOne
     29    @JoinColumn(name = "business_type_id", referencedColumnName = "id")
    2930    private BusinessType businessType;
    3031
     
    3940    private Stakeholder owner;
    4041
     42    @OneToMany(mappedBy = "business")
     43    @JsonManagedReference
     44    private List<Service> services;
     45
    4146    @Column(name = "created")
    4247    private LocalDateTime created;
     
    4550    private LocalDateTime modified;
    4651
    47     @OneToMany(mappedBy = "business")
    48     private List<Service> services;
     52
    4953}
Note: See TracChangeset for help on using the changeset viewer.