public CoursesController(DMVDataContext context) { _context = context; if (_context.Courses.Count() == 0) { _context.Courses.Add(new Course { NombreCourse = "Course1" }); _context.Courses.Add(new Course { NombreCourse = "Course2" }); _context.Courses.Add(new Course { NombreCourse = "Course3" }); _context.Courses.Add(new Course { NombreCourse = "Course4" }); _context.Courses.Add(new Course { NombreCourse = "Course5" }); _context.Courses.Add(new Course { NombreCourse = "Course6" }); _context.Courses.Add(new Course { NombreCourse = "Course7" }); _context.Courses.Add(new Course { NombreCourse = "Course8" }); _context.Courses.Add(new Course { NombreCourse = "Course9" }); _context.SaveChanges(); } }
public EmpresasController(DMVDataContext context) { _context = context; if (_context.Empresas.Count() == 0) { _context.Empresas.Add(new Empresa { NombreEmpresa = "Empresa1", MaxEmpleadosEmpresa = 1 }); _context.Empresas.Add(new Empresa { NombreEmpresa = "Empresa2", MaxEmpleadosEmpresa = 2 }); _context.Empresas.Add(new Empresa { NombreEmpresa = "Empresa3", MaxEmpleadosEmpresa = 3 }); _context.SaveChanges(); } }
public CancionesController(DMVDataContext context) { _context = context; if (_context.Canciones.Count() == 0) { _context.Canciones.Add(new Cancion { NombreCancion = "Residencial1", IdGenero = 1 }); _context.Canciones.Add(new Cancion { NombreCancion = "Residencial2", IdGenero = 2 }); _context.Canciones.Add(new Cancion { NombreCancion = "Residencial3", IdGenero = 3 }); _context.SaveChanges(); } }
public GradosController(DMVDataContext context) { _context = context; if (_context.Grados.Count() == 0) { _context.Grados.Add(new Grado { NombreGrado = "Grado1" }); _context.Grados.Add(new Grado { NombreGrado = "Grado2" }); _context.Grados.Add(new Grado { NombreGrado = "Grado3" }); _context.SaveChanges(); } }
public ResidencialesController(DMVDataContext context) { _context = context; if (_context.Residenciales.Count() == 0) { _context.Residenciales.Add(new Residencial { NombreResidencial = "Residencial1", IdCiudad = 1 }); _context.Residenciales.Add(new Residencial { NombreResidencial = "Residencial2", IdCiudad = 2 }); _context.Residenciales.Add(new Residencial { NombreResidencial = "Residencial3", IdCiudad = 3 }); _context.SaveChanges(); } }
public GenerosController(DMVDataContext context) { _context = context; if (_context.Generos.Count() == 0) { _context.Generos.Add(new Genero { NombreGenero = "Genero1" }); _context.Generos.Add(new Genero { NombreGenero = "Genero2" }); _context.Generos.Add(new Genero { NombreGenero = "Genero3" }); _context.SaveChanges(); } }
public VehiculosController(DMVDataContext context) { _context = context; if (_context.Vehiculos.Count() == 0) { _context.Vehiculos.Add(new Vehiculo { NombreVehiculo = "Vehiculo1", MarcaVehiculo = "Marca1", AñoVehiculo = 2000, ColorVehiculo = "Color1", IdCategoria = 1 }); _context.Vehiculos.Add(new Vehiculo { NombreVehiculo = "Vehiculo2", MarcaVehiculo = "Marca2", AñoVehiculo = 2001, ColorVehiculo = "Color2", IdCategoria = 2 }); _context.Vehiculos.Add(new Vehiculo { NombreVehiculo = "Vehiculo3", MarcaVehiculo = "Marca3", AñoVehiculo = 2002, ColorVehiculo = "Color3", IdCategoria = 3 }); _context.SaveChanges(); } }
public AlumnosController(DMVDataContext context) { _context = context; if (_context.Alumnos.Count() == 0) { _context.Alumnos.Add(new Alumno { NombreAlumno = "Alumno1", IdGrado = 1 }); _context.Alumnos.Add(new Alumno { NombreAlumno = "Alumno2", IdGrado = 2 }); _context.Alumnos.Add(new Alumno { NombreAlumno = "Alumno3", IdGrado = 3 }); _context.SaveChanges(); } }
public StudentsController(DMVDataContext context) { _context = context; if (_context.Students.Count() == 0) { _context.Students.Add(new Student { NombreStudent = "Student1", EdadStudent = 20, EstadoStudent = "activo" }); _context.Students.Add(new Student { NombreStudent = "Student2", EdadStudent = 21, EstadoStudent = "activo" }); _context.Students.Add(new Student { NombreStudent = "Student3", EdadStudent = 22, EstadoStudent = "activo" }); _context.SaveChanges(); } }
public ProfesionalesController(DMVDataContext context) { _context = context; if (_context.Profesionales.Count() == 0) { _context.Profesionales.Add(new Profesional { NombreProfesional = "Profesional1", EdadProfesional = 1, EstadoProfesional = true }); _context.Profesionales.Add(new Profesional { NombreProfesional = "Profesional2", EdadProfesional = 1, EstadoProfesional = true }); _context.Profesionales.Add(new Profesional { NombreProfesional = "Profesional3", EdadProfesional = 1, EstadoProfesional = true }); _context.SaveChanges(); } }
public CiudadesController(DMVDataContext context) { _context = context; if (_context.Ciudades.Count() == 0) { _context.Ciudades.Add(new Ciudad { NombreCiudad = "Ciudad1" }); _context.Ciudades.Add(new Ciudad { NombreCiudad = "Ciudad2" }); _context.Ciudades.Add(new Ciudad { NombreCiudad = "Ciudad3" }); _context.SaveChanges(); } }
public CategoriasController(DMVDataContext context) { _context = context; if (_context.Categorias.Count() == 0) { _context.Categorias.Add(new Categoria { NombreCategoria = "Categoria1", DescripcionCategoria = "Descripcion1" }); _context.Categorias.Add(new Categoria { NombreCategoria = "Categoria2", DescripcionCategoria = "Descripcion2" }); _context.Categorias.Add(new Categoria { NombreCategoria = "Categoria3", DescripcionCategoria = "Descripcion3" }); _context.SaveChanges(); } }
public StudentCoursesController(DMVDataContext context) { _context = context; }