findById method

Future<TDao?> findById(
  1. TPrimaryKey id
)

Returns the object with primary key id or null if id does not exist.

Implementation

Future<TDao?> findById(TPrimaryKey id) async {
  return await transaction((context) async {
    return await context.queryId(bean, id);
  });
}