You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
user: ActiveModel = Entity::find()
.filter(user_data.user_id)
.one(db)
.await?
.ok_or(DbErr::Custom("Cannot find user".to_owned()))
.map(Into::into)?;
```.
But I got error from rust-analyzer:
function or associated item `find_by_id` not found for this structrustc[E0599](https://doc.rust-lang.org/error-index.html#E0599)
mod.rs(23, 28): original diagnostic
function or associated item `find` not found for this structrustc[E0599](https://doc.rust-lang.org/error-index.html#E0599)
mod.rs(38, 41): original diagnostic
doesn't satisfy `db::entity::Entity: Iterator`rustc[E0599](https://doc.rust-lang.org/error-index.html#E0599)
mod.rs(38, 41): original diagnostic
I searched some, and I can not find the answer. Did I make some silly mistake here that I can not find it as new?
Please help.
BTW, it is the latest version I am using.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi, I am new to sea-ORM. And I try to write some toy code from my Mac m2.
Here is my entity definition:
Then I import this from another file:
Then I try use it as:
And
Beta Was this translation helpful? Give feedback.
All reactions