From 2741fc4ef5c50b289bcdae413c9c119c5d4d17be Mon Sep 17 00:00:00 2001 From: flackjap Date: Mon, 23 Dec 2019 12:37:44 +0100 Subject: [PATCH] Improve README.md Add missing info about conversion from snakeCase to camel_case in search query params. Also some minor (grammar / eloquence) changes to other parts of documentation. --- README.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 48df1c2e..28532ce0 100644 --- a/README.md +++ b/README.md @@ -644,7 +644,7 @@ Request all data without filter by request ] ``` -Conducting research in the repository +Examples of using search queries: `http://prettus.local/users?search=John%20Doe` @@ -689,6 +689,7 @@ In order for it to query using the **AND**, pass the *searchJoin* parameter as s `http://prettus.local/users?search=age:17;email:john@gmail.com&searchJoin=and` +**Notice**: "Laravel 5 Repositories" automatically converts snakeCase to camel_case in search params. For example, if you would have a field in database named "phone_number", it can be searched like this: ?search=phoneNumber:38169000000 @@ -738,7 +739,7 @@ Sorting through related tables `http://prettus.local/users?orderBy=posts|title&sortedBy=desc` -Query will have something like this +Database query will look something like this ```sql ... @@ -750,7 +751,7 @@ ORDER BY title `http://prettus.local/users?orderBy=posts:custom_id|posts.title&sortedBy=desc` -Query will have something like this +Database query will look something like this ```sql ...