@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | public function setup() |
31 | 31 | { |
32 | 32 | CRUD::setModel(\App\Models\ScheduledPayment::class); |
33 | - CRUD::setRoute(config('backpack.base.route_prefix') . '/scheduled-payment'); |
|
33 | + CRUD::setRoute(config('backpack.base.route_prefix').'/scheduled-payment'); |
|
34 | 34 | CRUD::setEntityNameStrings(__('scheduled payment'), __('scheduled payments')); |
35 | 35 | CRUD::enableExportButtons(); |
36 | 36 | } |
@@ -49,9 +49,9 @@ discard block |
||
49 | 49 | 'attribute' => 'lastname', |
50 | 50 | 'label' => __('Last Name'), |
51 | 51 | 'type' => 'relationship', |
52 | - 'searchLogic' => function ($query, $column, $searchTerm) { |
|
53 | - $query->orWhereHas('enrollment', function ($q) use ($searchTerm) { |
|
54 | - $q->whereHas('user', function ($q) use ($searchTerm) { |
|
52 | + 'searchLogic' => function($query, $column, $searchTerm) { |
|
53 | + $query->orWhereHas('enrollment', function($q) use ($searchTerm) { |
|
54 | + $q->whereHas('user', function($q) use ($searchTerm) { |
|
55 | 55 | $q->where('lastname', 'like', '%'.$searchTerm.'%'); |
56 | 56 | }); |
57 | 57 | }); |
@@ -64,9 +64,9 @@ discard block |
||
64 | 64 | 'attribute' => 'firstname', |
65 | 65 | 'label' => __('First Name'), |
66 | 66 | 'type' => 'relationship', |
67 | - 'searchLogic' => function ($query, $column, $searchTerm) { |
|
68 | - $query->orWhereHas('enrollment', function ($q) use ($searchTerm) { |
|
69 | - $q->whereHas('user', function ($q) use ($searchTerm) { |
|
67 | + 'searchLogic' => function($query, $column, $searchTerm) { |
|
68 | + $query->orWhereHas('enrollment', function($q) use ($searchTerm) { |
|
69 | + $q->whereHas('user', function($q) use ($searchTerm) { |
|
70 | 70 | $q->where('firstname', 'like', '%'.$searchTerm.'%'); |
71 | 71 | }); |
72 | 72 | }); |
@@ -80,9 +80,9 @@ discard block |
||
80 | 80 | 'attribute' => 'email', |
81 | 81 | 'label' => __('Email'), |
82 | 82 | 'type' => 'relationship', |
83 | - 'searchLogic' => function ($query, $column, $searchTerm) { |
|
84 | - $query->orWhereHas('enrollment', function ($q) use ($searchTerm) { |
|
85 | - $q->whereHas('user', function ($q) use ($searchTerm) { |
|
83 | + 'searchLogic' => function($query, $column, $searchTerm) { |
|
84 | + $query->orWhereHas('enrollment', function($q) use ($searchTerm) { |
|
85 | + $q->whereHas('user', function($q) use ($searchTerm) { |
|
86 | 86 | $q->where('email', 'like', '%'.$searchTerm.'%'); |
87 | 87 | }); |
88 | 88 | }); |
@@ -112,10 +112,10 @@ discard block |
||
112 | 112 | 'name' => 'status_id', |
113 | 113 | 'type' => 'select2', |
114 | 114 | 'label'=> __('Status'), |
115 | - ], function () { |
|
115 | + ], function() { |
|
116 | 116 | return EnrollmentStatusType::all()->pluck('name', 'id')->toArray(); |
117 | 117 | }, |
118 | - function ($value) { // if the filter is active |
|
118 | + function($value) { // if the filter is active |
|
119 | 119 | CRUD::addClause('where', 'status', $value); |
120 | 120 | }); |
121 | 121 | } |
@@ -101,10 +101,10 @@ discard block |
||
101 | 101 | { |
102 | 102 | if (config('app.currency_position') === 'before') |
103 | 103 | { |
104 | - return config('app.currency_symbol') . " ". $this->value; |
|
104 | + return config('app.currency_symbol')." ".$this->value; |
|
105 | 105 | } |
106 | 106 | |
107 | - return $this->value . " " . config('app.currency_symbol'); |
|
107 | + return $this->value." ".config('app.currency_symbol'); |
|
108 | 108 | } |
109 | 109 | |
110 | 110 | function getDateForHumansAttribute() |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | |
131 | 131 | public function identifiableAttribute() |
132 | 132 | { |
133 | - return $this->date . " (" . $this->value_with_currency . ")"; |
|
133 | + return $this->date." (".$this->value_with_currency.")"; |
|
134 | 134 | } |
135 | 135 | |
136 | 136 | public function getStatusTypeNameAttribute() |