namespace Admin.NET.Plugin.AiDOP;
///
/// S0 示范组织节点种子(灌入 SysOrg,公司 Type=201 / 工厂 Type=501)
///
[IncreSeed]
public class S0OrgSeedData : ISqlSugarEntitySeedData
{
private const long S0CompanyId = 1329900200001L;
private const long S0Factory1Id = 1329900200002L;
private const long S0Factory2Id = 1329900200003L;
public IEnumerable HasData()
{
var ct = DateTime.Parse("2022-02-10 00:00:00");
var tenantId = SqlSugarConst.DefaultTenantId;
return new[]
{
new SysOrg
{
Id = S0CompanyId,
Pid = tenantId,
Name = "S0示范公司",
Code = "S0-C001",
Type = "201",
Level = 2,
OrderNo = 200,
Status = StatusEnum.Enable,
Remark = "S0 运营建模示范公司",
TenantId = tenantId,
CreateTime = ct,
},
new SysOrg
{
Id = S0Factory1Id,
Pid = S0CompanyId,
Name = "一工厂",
Code = "S0-F001",
Type = "501",
Level = 3,
OrderNo = 201,
Status = StatusEnum.Enable,
Remark = "S0 示范工厂 1",
TenantId = tenantId,
CreateTime = ct,
},
new SysOrg
{
Id = S0Factory2Id,
Pid = S0CompanyId,
Name = "二工厂",
Code = "S0-F002",
Type = "501",
Level = 3,
OrderNo = 202,
Status = StatusEnum.Enable,
Remark = "S0 示范工厂 2",
TenantId = tenantId,
CreateTime = ct,
},
};
}
}