是否可以与用户建立多对多关系?我试图建立一个简单的实体
{
"relationships": [
{
"relationshipName": "leader",
"otherEntityName": "user",
"relationshipType": "many-to-many",
"otherEntityField": "login",
"ownerSide": true
},
{
"relationshipName": "member",
"otherEntityName": "user",
"relationshipType": "many-to-many",
"otherEntityField": "login",
"ownerSide": true
}
],
"fields": [
{
"fieldName": "name",
"fieldType": "String"
}
],
"changelogDate": "20160712043251",
"dto": "mapstruct",
"service": "no",
"entityTableName": "team",
"pagination": "no"
}
但是当我从列表中选择用户并选择保存时会出现错误
org.springframework.dao.InvalidDataAccessApiUsageException:org.hibernate.TransientObjectException: object引用未保存的瞬态实例 - 在刷新之前保存瞬态实例: com.mycompany.myapp.domain.User;嵌套异常是java.lang.IllegalStateException: org.hibernate.TransientObjectException:object引用未保存的瞬态实例 - 在刷新之前保存瞬态实例:com.mycompany.myapp.domain.User
是否可以在jhipster中与用户建立这种关系?