Answer the question
In order to leave comments, you need to log in
How to make one link to two Yii2 models?
Hello.
There is a model, it has a field, but it is not known which model will be used by the user.
Those. there are two tables with identical data, but they cannot be merged. The codes are the same in both.
The user creates a model and selects certain data to fill in from different models. How to make the most optimal way so that one field can refer to different tables.
Answer the question
In order to leave comments, you need to log in
There is a model, she has a field,
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question