Skip to content

Instantly share code, notes, and snippets.

@icebeam7
Created May 11, 2018 12:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save icebeam7/2cd72a67df1d27b1606d9b7bc8641a7e to your computer and use it in GitHub Desktop.
Save icebeam7/2cd72a67df1d27b1606d9b7bc8641a7e to your computer and use it in GitHub Desktop.
SistemaEscolar: Alumno.cs
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace SistemaEscolar.Modelos
{
public class Alumno
{
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
[Key]
public int Id { get; set; }
public string Nombre { get; set; }
public DateTime FechaNacimiento { get; set; }
public Escuela Escuela { get; set; }
[ForeignKey("EscuelaForeignKey")]
public int IdEscuela { get; set; }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment