StepAction.cs
2.29 KB
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Rcs.Domain.Enums;
namespace Rcs.Domain.Entities;
/// <summary>
/// 步骤动作实体类
/// </summary>
[Table("step_actions")]
public partial class StepAction : Entity
{
/// <summary>
/// 系统ID
/// </summary>
[Key]
[DatabaseGenerated(DatabaseGeneratedOption.None)]
[Column("action_id")]
public Guid ActionId { get; set; }
/// <summary>
/// 步骤属性ID(外键)
/// </summary>
[Required]
[Column("property_id")]
public Guid PropertyId { get; set; }
/// <summary>
/// 动作配置ID(外键)- 一对一关系
/// </summary>
[Column("action_config_id")]
public Guid? ActionConfigId { get; set; }
/// <summary>
/// 动作类型(如:Pick、Drop、Lift、DetectObject等)
/// </summary>
[Required]
[Column("type")]
[MaxLength(50)]
public ActionCategory Type { get; set; }
/// <summary>
/// 动作名称
/// </summary>
[Column("action_name")]
[MaxLength(100)]
public string? ActionName { get; set; }
/// <summary>
/// 动作描述
/// </summary>
[Column("description")]
[MaxLength(500)]
public string? Description { get; set; }
/// <summary>
/// 执行顺序(从1开始)
/// </summary>
[Required]
[Column("order")]
public int Order { get; set; }
/// <summary>
/// 阻塞类型(NONE、SOFT、HARD)
/// </summary>
[Column("blocking_type")]
public ActionBlockType BlockingType { get; set; }
/// <summary>
/// 创建时间
/// </summary>
[Column("created_at", TypeName = "timestamp")]
public DateTime? CreatedAt { get; set; }
/// <summary>
/// 更新时间
/// </summary>
[Column("updated_at", TypeName = "timestamp")]
public DateTime? UpdatedAt { get; set; }
#region 导航属性
/// <summary>
/// 步骤属性导航属性
/// </summary>
[ForeignKey(nameof(PropertyId))]
public virtual StepProperty? Property { get; set; }
/// <summary>
/// 动作配置导航属性 - 一对一关系
/// </summary>
[ForeignKey(nameof(ActionConfigId))]
public virtual ActionConfiguration? ActionConfiguration { get; set; }
#endregion
}