Skip to content

Commit 07bacc7

Browse files
committed
update readme
1 parent 196b042 commit 07bacc7

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
![Social Image](social.jpeg)
22

33
[![GitHub Workflow Status](https://github.com/laratoolbox/query-viewer/workflows/Run%20tests/badge.svg)](https://github.com/laratoolbox/query-viewer/actions)
4-
54
[![Packagist](https://img.shields.io/packagist/v/laratoolbox/query-viewer.svg)](https://packagist.org/packages/laratoolbox/query-viewer)
6-
[![Packagist](https://poser.pugx.org/laratoolbox/query-viewer/d/total.svg)](https://packagist.org/packages/laratoolbox/query-viewer)
75
[![Packagist](https://img.shields.io/packagist/l/laratoolbox/query-viewer.svg)](https://packagist.org/packages/laratoolbox/query-viewer)
6+
[![GitHub issues](https://img.shields.io/github/issues/laratoolbox/query-viewer.svg)](https://github.com/laratoolbox/query-viewer/issues)
87

98
This package adds methods for getting sql query to eloquent and database query builder.
109

@@ -57,10 +56,10 @@ User::select('name')->where('id', 5)->getSql();
5756
User::select('name')
5857
->where('id', 5)
5958
->dumpSql()
59+
->logSql('LOG_PREFIX_HERE') // logs sql to log file. (LOG_PREFIX_HERE : select `name` from `users` where `id` = 5)
6060
->where('name', '!=', 'john')
6161
->dumpSql()
6262
->where('surname', '!=', 'doe')
63-
->logSql('SURNAME_QUERY') // logs sql to log file.
6463
->where('email', 'LIKE', '%example%')
6564
->getSqlFunc(function(string $sql) {
6665
echo $sql;
@@ -81,10 +80,10 @@ User::select('name')
8180
\DB::table('users')
8281
->where('id', 5)
8382
->dumpSql()
83+
->logSql('LOG_PREFIX_HERE') // logs sql to log file. (LOG_PREFIX_HERE : select `name` from `users` where `id` = 5)
8484
->where('name', '!=', 'john')
8585
->dumpSql()
8686
->where('surname', '!=', 'doe')
87-
->logSql('SURNAME_QUERY') // logs sql to log file.
8887
->where('email', 'LIKE', '%example%')
8988
->getSqlFunc(function(string $sql) {
9089
echo $sql;

0 commit comments

Comments
 (0)