package com.izouma.zhirongip.domain;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.annotations.Where;

import javax.persistence.*;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@Entity
@ApiModel(value = "融合服务多图文页面")
@Where(clause = "del = 0")
public class ServiceDetail extends BaseEntity {

    private String icon;

    private String title;

    private String content;

    @ApiModelProperty("位置")
    private Long navigationId;

    @ManyToOne(fetch = FetchType.LAZY)
    @JoinColumn(name = "navigationId", insertable = false, updatable = false, foreignKey = @ForeignKey(ConstraintMode.NO_CONSTRAINT))
    private Navigation navigation;

}
