CoreCodeCamp icon indicating copy to clipboard operation
CoreCodeCamp copied to clipboard

Cannot Post: Module 4-3

Open JayOwl opened this issue 4 years ago • 1 comments

Unmapped members were found. Review the types and members below. Add a custom mapping expression, ignore, add a custom resolver, or modify the source/destination type For no matching constructor, add a no-arg ctor, add optional arguments, or map all of the constructor parameters

AutoMapper created this type map for you, but your types cannot be mapped using the current configuration. CampModel -> Camp (Destination member list) CoreCodeCamp.Models.CampModel -> CoreCodeCamp.Data.Camp (Destination member list)

Unmapped properties: CampId Location

JayOwl avatar Jul 07 '21 00:07 JayOwl

The solution was adding:

[DatabaseGenerated(DatabaseGeneratedOption.None)]to the CampModel.cs above public int CampId { get; set; }

This was my solution but I'm not sure if there is a fix present in the module.

JayOwl avatar Jul 07 '21 00:07 JayOwl