Spring 无法使用多通发送邮递员数据

Spring 无法使用多通发送邮递员数据,spring,spring-boot,hibernate,postman,spring-rest,Spring,Spring Boot,Hibernate,Postman,Spring Rest,嗨,我在我的项目中与spring boot and rest合作,我建立了两个enteties之间的关系,但我无法发送邮递员请求添加任务及其类别,我甚至不确定这两个enteties是否正确相关 他是两个实体和控制者 使命 @实体 @表(name=“任务”) 公课使命{ 公共使命(){ } 公共任务(整数id、字符串状态、字符串地址、整数任务、字符串图像、列表类别、, 字符串ville,int duree,字符串描述,字符串域){ this.id=id; this.state=状态; this.a

嗨,我在我的项目中与spring boot and rest合作,我建立了两个enteties之间的关系,但我无法发送邮递员请求添加任务及其类别,我甚至不确定这两个enteties是否正确相关 他是两个实体和控制者

使命
@实体
@表(name=“任务”)
公课使命{
公共使命(){
}
公共任务(整数id、字符串状态、字符串地址、整数任务、字符串图像、列表类别、,
字符串ville,int duree,字符串描述,字符串域){
this.id=id;
this.state=状态;
this.adrese=adrese;
this.etatMission=etatMission;
这个图像=图像;
这个。类别=类别;
this.ville=ville;
this.duree=duree;
this.description=描述;
这个。多迈内=多迈内;
}
公共列表getCategories(){
退货类别;
}
公共类别(列出类别){
这个。类别=类别;
}
公共字符串getVille(){
返回维尔;
}
公共空间塞特维尔(字符串维尔){
this.ville=ville;
}
公共使命(地图用户地图){
if(userMap.get(“id”)!=null)
this.id=(int)userMap.get(“id”);
this.state=(String)userMap.get(“state”);
this.duree=(int)userMap.get(“duree”);
this.domaine=(字符串)userMap.get(“domaine”);
this.description=(String)userMap.get(“description”);
this.ville=(字符串)userMap.get(“ville”);
this.adresse=(字符串)userMap.get(“adrese”);
this.etatMission=(int)userMap.get(“etatMission”);
this.image=(字符串)userMap.get(“image”);
this.categories=(List)userMap.get(“categories”);
}
@身份证
@GeneratedValue(策略=GenerationType.AUTO)
私有int-id;
私有字符串状态;
私人字符串地址;
私人情报任务;
私有字符串图像;
@OneToMany(mappedBy=“mission”,cascade=CascadeType.ALL)
私人名单类别;
公共字符串getImage(){
返回图像;
}
公共void setImage(字符串图像){
这个图像=图像;
}
私家侦探;
public int getEtatMission(){
返回任务;
}
公共无效设置etatMission(int etatMission){
this.etatMission=etatMission;
}
私人住宅;
私有字符串描述;
私有字符串域;
公共字符串getDomaine(){
返回域;
}
公共无效设置域(字符串域){
这个。多迈内=多迈内;
}
公共字符串getDescription(){
返回说明;
}
公共void集合描述(字符串描述){
this.description=描述;
}
公共字符串getAddresse(){
返回地址;
}
公共无效设置地址(字符串地址){
this.adrese=adrese;
}
@凌驾
公共字符串toString(){
返回“任务[id=“+id+”,状态=“+state+”,duree=“+duree+”””;
}
公共int getId(){
返回id;
}
公共无效集合id(内部id){
this.id=id;
}
公共字符串getState(){
返回状态;
} 
公共无效设置状态(字符串状态){
this.state=状态;
}
public int getDuree(){
返还被胁迫人;
}
公共无效设置(内部设置){
this.duree=duree;
}
公共无效添加(分类类别){
如果(类别==null){
categories=newarraylist();
}
类别。添加(cat);
cat.setMission(本);
}   
}
尝试添加@ManyToOne(cascade=CascadeType.ALL)