mirror of
https://github.com/markjprice/cs11dotnet7.git
synced 2026-04-04 13:57:37 +00:00
Initial commit
This commit is contained in:
parent
1d9d051759
commit
9656378279
557 changed files with 182300 additions and 0 deletions
|
|
@ -0,0 +1,29 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace Packt.Shared
|
||||
{
|
||||
[Index("CategoryName", Name = "CategoryName")]
|
||||
public partial class Category
|
||||
{
|
||||
public Category()
|
||||
{
|
||||
Products = new HashSet<Product>();
|
||||
}
|
||||
|
||||
[Key]
|
||||
public int CategoryId { get; set; }
|
||||
[StringLength(15)]
|
||||
public string CategoryName { get; set; } = null!;
|
||||
[Column(TypeName = "ntext")]
|
||||
public string? Description { get; set; }
|
||||
[Column(TypeName = "image")]
|
||||
public byte[]? Picture { get; set; }
|
||||
|
||||
[InverseProperty("Category")]
|
||||
public virtual ICollection<Product> Products { get; set; }
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue