45 lines
1.2 KiB
C#
45 lines
1.2 KiB
C#
|
|
using APT.Infrastructure.EF.Map;
|
|||
|
|
using APT.BaseData.Domain.Entities.FM;
|
|||
|
|
using Microsoft.EntityFrameworkCore.Metadata.Builders;
|
|||
|
|
using System;
|
|||
|
|
using System.Collections.Generic;
|
|||
|
|
using System.Linq;
|
|||
|
|
using System.Text;
|
|||
|
|
using System.Threading.Tasks;
|
|||
|
|
using Microsoft.EntityFrameworkCore;
|
|||
|
|
|
|||
|
|
namespace APT.BaseData.Data.Mapping.FM
|
|||
|
|
{
|
|||
|
|
public class FMUserCCQueryFieldMap : APTEntityBaseMap<T_FM_USER_C_C_QUERY_FIELD>
|
|||
|
|
{
|
|||
|
|
public override void Configure(EntityTypeBuilder<T_FM_USER_C_C_QUERY_FIELD> builder)
|
|||
|
|
{
|
|||
|
|
base.Configure(builder);
|
|||
|
|
builder.Property(t => t.QUERY_NAME)
|
|||
|
|
.HasMaxLength(100);
|
|||
|
|
|
|||
|
|
builder.Property(t => t.LABEL)
|
|||
|
|
.HasMaxLength(64);
|
|||
|
|
|
|||
|
|
builder.Property(t => t.OP_DEFAULT)
|
|||
|
|
.HasMaxLength(64);
|
|||
|
|
|
|||
|
|
builder.Property(t => t.DATA_VALUE)
|
|||
|
|
.HasMaxLength(100);
|
|||
|
|
|
|||
|
|
builder.Property(t => t.ENUM_NAME).HasMaxLength(100);
|
|||
|
|
builder.Property(t => t.CODE).HasMaxLength(100);
|
|||
|
|
builder.HasOne(t => t.Nav_UserCCQuery).WithMany(t => t.Nav_Fields).HasForeignKey(t => t.USER_C_C_QUERY_ID).OnDelete(DeleteBehavior.Restrict);
|
|||
|
|
builder.HasOne(t => t.Nav_UserCCQueryGroup).WithMany().HasForeignKey(t => t.USER_C_C_QUERY_GROUP_ID).OnDelete(DeleteBehavior.Restrict);
|
|||
|
|
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
public FMUserCCQueryFieldMap()
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
}
|