Retrieving Entities
var users = getInstance( "User" ).all();
// users is a QuickCollection. To get an array,
// first call `get` or `toArray`
for ( var user in users.get() ) {
writeOutput( user.getUsername() );
}var users = getInstance( "User" ).all();
prc.users.each( function( user ) {
writeOutput( user.getUsername() );
} );var users = getInstance( "User" )
.where( "active", 1 )
.orderBy( "username", "desc" )
.limit( 10 )
.get();Collections
Aggregates
Custom Quick Retrieval Methods
all
findOrFail & firstOrFail
Last updated
Was this helpful?