Skip to content

Commit 3262cad

Browse files
removed Acme namespace from examples
1 parent cee45af commit 3262cad

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

README.md

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ echo json_encode($dataTable->make());
2424

2525
### Basic example
2626
```php
27-
namespace Acme;
28-
2927
use LiveControl\EloquentDataTable\DataTable;
3028

3129
class UserController {
@@ -47,8 +45,6 @@ In this case we are making a datatable response with all users who live in Londo
4745
### Combining columns
4846
If you want to combine the firstname and lastname into one column, you can wrap them into an array.
4947
```php
50-
namespace Acme;
51-
5248
use LiveControl\EloquentDataTable\DataTable;
5349

5450
class UserController {
@@ -57,8 +53,8 @@ class UserController {
5753
{
5854
$users = new User();
5955
$dataTable = new DataTable(
60-
$users
61-
['email', ['firstname', 'lastname'], 'city'],
56+
$users,
57+
['email', ['firstname', 'lastname'], 'city']
6258
);
6359

6460
return response()->json($dataTable->make());
@@ -69,8 +65,6 @@ class UserController {
6965
Sometimes you want to use custom sql statements on a column to get specific results,
7066
this can be achieved using the `ExpressionWithName` class.
7167
```php
72-
namespace Acme;
73-
7468
use LiveControl\EloquentDataTable\DataTable;
7569
use LiveControl\EloquentDataTable\ExpressionWithName;
7670

@@ -96,8 +90,6 @@ class UserController {
9690
### Return custom row format
9791
If you would like to return a custom row format you can do this by adding an anonymous function as an extra argument to the make method.
9892
```php
99-
namespace Acme;
100-
10193
use LiveControl\EloquentDataTable\DataTable;
10294
use LiveControl\EloquentDataTable\ExpressionWithName;
10395

0 commit comments

Comments
 (0)