zoukankan      html  css  js  c++  java
  • JPA 及 Hibernate 相关注解

    一、Date
    @ApiModelProperty(name = "accountDate", value = "结算日")
    @Column(name="account_date", nullable=true, length = 10)
    @Temporal(TemporalType.DATE)
    @JsonFormat(pattern="yyyy-MM-dd",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date accountDate;


    二、columnDefinition
    @Column(name = "is_deleted", columnDefinition = "bit default 0")
    protected boolean deleted;
    
    
    @Column(name = "CREATED_DATE", nullable = true, updatable = false, columnDefinition = "datetime(3) default now(3)")
    protected Date createdDate;
    
    
    @Column(name="before_discount_price", nullable=false, columnDefinition = "decimal(17,2) default '0.00'")
    private BigDecimal beforeDiscountPrice = BigDecimal.ZERO;

    @Column(name="weight", nullable=false, columnDefinition = "float(10,2) default '0.00'")
    private Float weight = 0.00F;


    @Column(name="attach_base64",  columnDefinition = "text")
    private String attachBase64;
    @Column(name = "comment_count", columnDefinition = "long default '0'")
    private Long commentCount;
    @Column(name = "company_introduce", nullable = true, columnDefinition = "MEDIUMTEXT")
    private String companyIntroduce;
    @Column(name = "actual_weight", columnDefinition="double(10,3) default '0.000'")
    private Float actualWeight;
     
     
  • 相关阅读:
    401. Binary Watch
    46. Permutations
    61. Rotate List
    142. Linked List Cycle II
    86. Partition List
    234. Palindrome Linked List
    19. Remove Nth Node From End of List
    141. Linked List Cycle
    524. Longest Word in Dictionary through Deleting
    android ListView详解
  • 原文地址:https://www.cnblogs.com/yifanSJ/p/10148170.html
Copyright © 2011-2022 走看看