Form HasOne relationship

I would like to use one form to create a model and a related model (hasOne).

But not all models will have the related model. Is there a way to instruct the form to create the related model only when the relevant fields are filled?
Was this page helpful?