As the doc mentioned:
Parameters:
relation List of relationships keys to be fetched (eager fetch instead of default lazy fetch for a relation) : use "|" separator to put many relationships keys
I write code:
qx::dao::fetch_by_id_with_relation("type_id|admin_id", card);
But I find the implementation of the code above is:
static inline QSqlError fetchById(const QString & relation, T & t, QSqlDatabase * pDatabase)
{ return QxDao_FetchById_WithRelation<T>::fetchById((relation.isEmpty() ? QStringList() : (QStringList() << relation)), t, pDatabase); }
I think "type_id|admin_id" cann't be convert to QStringList via "QStringList() << relation". Maybe it's a bug.