-
Notifications
You must be signed in to change notification settings - Fork 0
/
Model1.Context.cs
44 lines (38 loc) · 1.67 KB
/
Model1.Context.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
//------------------------------------------------------------------------------
// <auto-generated>
// Este código se generó a partir de una plantilla.
//
// Los cambios manuales en este archivo pueden causar un comportamiento inesperado de la aplicación.
// Los cambios manuales en este archivo se sobrescribirán si se regenera el código.
// </auto-generated>
//------------------------------------------------------------------------------
namespace ProyectoStarTech
{
using System;
using System.Data.Entity;
using System.Data.Entity.Infrastructure;
using System.Data.Entity.Core.Objects;
using System.Linq;
public partial class StarTechEntities : DbContext
{
public StarTechEntities()
: base("name=StarTechEntities")
{
}
protected override void OnModelCreating(DbModelBuilder modelBuilder)
{
throw new UnintentionalCodeFirstException();
}
public virtual DbSet<carrito> carrito { get; set; }
public virtual DbSet<Compra> Compra { get; set; }
public virtual DbSet<productos> productos { get; set; }
public virtual DbSet<usuario> usuario { get; set; }
public virtual int ComprasProc(Nullable<int> identificacionUsuario)
{
var identificacionUsuarioParameter = identificacionUsuario.HasValue ?
new ObjectParameter("identificacionUsuario", identificacionUsuario) :
new ObjectParameter("identificacionUsuario", typeof(int));
return ((IObjectContextAdapter)this).ObjectContext.ExecuteFunction("ComprasProc", identificacionUsuarioParameter);
}
}
}