Hi guys, I want to set value for a field in Form by this code:
$city = new Text('city');
$city->addValidators([ new PresenceOf() ]);
but I got this error:
Catchable fatal error: Object of class app\common\models\City could not be converted to string in E:\xampp\htdocs\phalcon\app\modules\frontend\views\user\profile.phtml on line 107
How can I set data from relationship ?