banboshi_V1/halftoneproject-master/Models/Step.cs
2023-10-31 13:19:29 +08:00

42 lines
1.2 KiB
C#
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Models
{
[SugarIndex("index_{table}_code", nameof(Step.Code), OrderByType.Asc, isUnique: true)]
public class Step:BaseTable
{
/// <summary>
/// 0-主控台 1-修复台
/// </summary>
public int Tag { get; set; }
public string Code { get; set; }
public string Name { get; set; }
/// <summary>
/// 开始计时工序索引1-n0则不计时
/// </summary>
public int StartTimeIndex { get; set; }
[Navigate(NavigateType.OneToMany, nameof(StepProcess.Pid))]
public List<StepProcess> ProcessList { get; set; }//注意禁止给books手动赋值,也不能new初始化否则导航查询不到
}
public class StepProcess : BaseTable
{
public int Pid { get; set; }
public int Order { get; set; } = 1;
public string ProcessCode { get; set; }
public string ProcessName { get; set; }
/// <summary>
/// json
/// </summary>
[SugarColumn(IsNullable = true, Length =2048)]
public string ProcessParams { get; set; }
}
}