baoshiwei
2025-04-23 c2375c2bcc0bf9e6a3af7f9776d5a0eb14370b40
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
package com.zhitan.engine.entity;
 
import lombok.Data;
import org.hibernate.annotations.GenericGenerator;
 
import javax.persistence.*;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.time.LocalTime;
 
/**
 * 尖峰平谷电价设置实体类
 * 对应数据库中的electricity_price表
 */
@Data
@Entity
@Table(name = "electricity_price")
public class ElectricityPrice {
    private static final long serialVersionUID = 1L;
 
    @Id
    @GenericGenerator(name = "uuid", strategy = "uuid2")
    @GeneratedValue(generator = "uuid")
    @Column(name = "id", length = 36)
    private String id;
 
    /**
     * 父级id,关联electricity_price_date表的id
     */
    @Column(name = "parent_id", length = 36, nullable = false)
    private String parentId;
 
    /**
     * 用电类型(尖、峰、平、谷、深谷)
     * SHARP: 尖
     * PEAK: 峰
     * FLAT: 平
     * VALLEY: 谷
     * DEEP: 深谷
     */
    @Column(name = "type", length = 36)
    private String type;
 
    /**
     * 时段开始时间
     */
    @Column(name = "start_time")
    private LocalTime startTime;
 
    /**
     * 时段结束时间
     */
    @Column(name = "stop_time")
    private LocalTime stopTime;
 
    /**
     * 电价
     */
    @Column(name = "effecticity_price", precision = 12, scale = 2)
    private BigDecimal effecticityPrice;
 
    @Column(name = "create_by", length = 64)
    private String createBy;
 
    @Column(name = "create_time")
    private LocalDateTime createTime;
 
    @Column(name = "update_by", length = 64)
    private String updateBy;
 
    @Column(name = "update_time")
    private LocalDateTime updateTime;
 
    @Column(name = "remark", length = 255)
    private String remark;
}