| 12345678910111213141516171819202122232425262728293031323334353637 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel.DataAnnotations.Schema;
- using System.Data.Entity.ModelConfiguration;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace YZXYH.Repository.Models.Mapping
- {
- public class LotteryMap : EntityTypeConfiguration<Lottery>
- {
- public LotteryMap()
- {
- // Primary Key
- this.HasKey(t => t.Id);
- this.Property(t => t.LotteryName)
- .IsRequired()
- .HasMaxLength(50);
- this.Property(t => t.LotteryGroup)
- .IsRequired()
- .HasMaxLength(50);
- this.Property(t => t.Mobile)
- .HasMaxLength(50);
- this.Property(t => t.ExpLotteryType)
- .HasMaxLength(100);
- this.ToTable("CJ_Lottery");
- this.Property(t => t.Id).HasColumnName("Id").HasDatabaseGeneratedOption(DatabaseGeneratedOption.Identity);
- this.Property(t => t.LotteryName).HasColumnName("LotteryName");
- this.Property(t => t.LotteryGroup).HasColumnName("LotteryGroup");
- this.Property(t => t.Mobile).HasColumnName("Mobile");
- this.Property(t => t.ExpLotteryType).HasColumnName("ExpLotteryType");
- }
- }
- }
|