0

I want to declare my own datatype in order to use it in an other entity.

JDL doesn't seem to recognize the entities that I already declared. How can I declare my own datatypes?

entity Adress{
    street String,
    streetNumber Integer,
    postCode Integer,
    city String
}

entity Doctor {
    lanr Integer,
    telephone Integer,
    adress Adress
}

I expected to be able to use Adress as an Datatype because the JDL will create a Java Class.

Aref
  • 746
  • 10
  • 27

1 Answers1

2

Jhipster currently doesn't support embedded "entities".

Found this https://github.com/jhipster/generator-jhipster/issues/6306

What happens if you use a relationship to solve it?

relationship OneToMany {
        Doctor{address} to Address
    }

https://www.jhipster.tech/managing-relationships/

admlz635
  • 1,001
  • 1
  • 9
  • 18