Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Sairahcaz authored Oct 12, 2023
1 parent 4229cae commit 03b13a3
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,15 @@ class Transaction extends Model
use DateScopes;
}

Transaction::ofToday(); // query transactions created today
Transaction::ofLastWeek(); // query transactions created during the last week
Transaction::monthToDate(); // query transactions created during the start of the current month till now
Transaction::ofLastYear(startFrom: '2020-01-01') // query transactions created during the last year, starting from 2020
// query transactions created today
Transaction::ofToday();
// query transactions created during the last week
Transaction::ofLastWeek();
// query transactions created during the start of the current month till now
Transaction::monthToDate();
// query transactions created during the last year, starting from 2020
Transaction::ofLastYear(startFrom: '2020-01-01');

// ... and much more scopes are available (see below)

// For sure, you can chain any Builder function you want here.
Expand Down

0 comments on commit 03b13a3

Please sign in to comment.