Code: Select all
namespace EconomyEnergy.Data.Entities
{
public class AccountEmailMapping
{
[Key, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public int Id { get; set; }
public string AccountNumber { get; set; }
public int AccountId { get; set; }
[ForeignKey("AccountId")]
public Account AccountObj { get; set; }
public string Email { get; set; }
}
}
namespace EconomyEnergy.Data
{
using System;
using System.Data.Entity.Migrations;
public partial class AddingAccountEmailMapping : DbMigration
{
public override void Up()
{
}
public override void Down()
{
}
}
}
< /code>
Ich bin zuerst neu im Code, kann jemand bitte erklären, wo ich den Fehler mache.
Ich habe versucht, vor ein paar Tagen eine Tabelle hinzuzufügen, und ich war in der Lage, es erfolgreich zu tun.>