0

I'm trying to create job table have multi-image in JDL

I used to one-to-many relationship but jhipster warnning:

WARNING! otherEntityRelationshipName is missing in .jhipster/Attachment.json for relationship {
    "relationshipName": "job",
    "otherEntityName": "job",
    "relationshipType": "many-to-one",
    "otherEntityField": "id",
    "otherEntityRelationshipName": "attachment"
}, using attachment as fallback

My job JDL like that:

microservice * with job

entity Job{
    name String required
    description String
}

entity Attachment{
    name String
    image ImageBlob
}

relationship OneToMany{
     Job{image} to Attachment
}
service * with serviceClass
paginate * with pagination


How can I fix it. please help!

Tài Bùi
  • 3
  • 6

1 Answers1

0

Unidirectional one-to-many relationship is not provided by default in JHipster at the moment.
It should be like this:

relationship OneToMany{
    Job{image} to Attachment{job}
}
סטנלי גרונן
  • 2,917
  • 23
  • 46
  • 68
Busyluo
  • 21
  • 2