Introduce VwmyCatalog as a keyless entity mapped to the VWMY_CATALOG database view. Update ApplicationDbContext to include the new DbSet and configure its mapping. Modify CatalogRepository to query the view instead of the table for GetAllAsync and GetByIdAsync. Add AutoMapper configuration for VwmyCatalog to Catalog. Add the VwmyCatalog entity class.
19 lines
415 B
C#
19 lines
415 B
C#
namespace DbFirst.Infrastructure.ScaffoldEntities;
|
|
|
|
public partial class VwmyCatalog
|
|
{
|
|
public int Guid { get; set; }
|
|
|
|
public string CatTitle { get; set; } = null!;
|
|
|
|
public string CatString { get; set; } = null!;
|
|
|
|
public string AddedWho { get; set; } = null!;
|
|
|
|
public DateTime AddedWhen { get; set; }
|
|
|
|
public string? ChangedWho { get; set; }
|
|
|
|
public DateTime? ChangedWhen { get; set; }
|
|
}
|