package com.publiccms.entities.trade;
// Generated 2023-8-7 21:42:23 by Hibernate Tools 5.6.15.Final

import java.math.BigDecimal;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.publiccms.common.generator.annotation.GeneratorColumn;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.Table;

/**
 * TradeFreight generated by hbm2java
 */
@Entity
@Table(name = "trade_freight")
public class TradeFreight implements java.io.Serializable {

    private static final long serialVersionUID = 1L;
    /**
     * id
     */
    @GeneratorColumn(title = "ID")
    private Integer id;
    @GeneratorColumn(title = "站点", condition = true)
    @JsonIgnore
    private short siteId;
    @GeneratorColumn(title = "国家", condition = true)
    private String country;
    @GeneratorColumn(title = "省份", condition = true)
    private String province;
    @GeneratorColumn(title = "城市", condition = true)
    private String city;
    @GeneratorColumn(title = "地区", condition = true)
    private String district;
    @GeneratorColumn(title = "价格")
    private BigDecimal price;
    @GeneratorColumn(title = "免费价格")
    private BigDecimal freePrice;

    public TradeFreight() {
    }

    public TradeFreight(short siteId) {
        this.siteId = siteId;
    }

    public TradeFreight(short siteId, String country, String province, String city, String district, BigDecimal price,
            BigDecimal freePrice) {
        this.siteId = siteId;
        this.country = country;
        this.province = province;
        this.city = city;
        this.district = district;
        this.price = price;
        this.freePrice = freePrice;
    }

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "id", unique = true, nullable = false)
    public Integer getId() {
        return this.id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    @Column(name = "site_id", nullable = false)
    public short getSiteId() {
        return this.siteId;
    }

    public void setSiteId(short siteId) {
        this.siteId = siteId;
    }

    @Column(name = "country", length = 100)
    public String getCountry() {
        return this.country;
    }

    public void setCountry(String country) {
        this.country = country;
    }

    @Column(name = "province", length = 100)
    public String getProvince() {
        return this.province;
    }

    public void setProvince(String province) {
        this.province = province;
    }

    @Column(name = "city", length = 100)
    public String getCity() {
        return this.city;
    }

    public void setCity(String city) {
        this.city = city;
    }

    @Column(name = "district", length = 100)
    public String getDistrict() {
        return this.district;
    }

    public void setDistrict(String district) {
        this.district = district;
    }

    @Column(name = "price", precision = 10)
    public BigDecimal getPrice() {
        return this.price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    @Column(name = "free_price", precision = 10)
    public BigDecimal getFreePrice() {
        return this.freePrice;
    }

    public void setFreePrice(BigDecimal freePrice) {
        this.freePrice = freePrice;
    }

}
