Stella981 Stella981
2年前
EntityFrameworkCore 中实体的几种配置方法
EntityFramework有几种方式可实现数据库表与实体的关系配置(relationship)1.convention2.annotation3.fluentapi使用数据注解实体类通常是在Models目录下,直接在实体类上添加属性注解,比如Required/Key等.