@@ -189,7 +189,7 @@ discard block |
||
| 189 | 189 | |
| 190 | 190 | return response()->json($result); |
| 191 | 191 | } catch (\Exception $ex) { |
| 192 | - app('log')->error($ex->getMessage()); |
|
| 192 | + app('log')->error($ex->getMessage()); |
|
| 193 | 193 | Bugsnag::notifyException($ex); |
| 194 | 194 | |
| 195 | 195 | return $ex->getMessage(); |
@@ -237,7 +237,7 @@ discard block |
||
| 237 | 237 | return redirect('auth/login')->with('fails', \Lang::get('please-purcahse-a-product')); |
| 238 | 238 | } |
| 239 | 239 | } catch (\Exception $ex) { |
| 240 | - app('log')->error($ex->getMessage()); |
|
| 240 | + app('log')->error($ex->getMessage()); |
|
| 241 | 241 | Bugsnag::notifyException($ex); |
| 242 | 242 | |
| 243 | 243 | return redirect('auth/login')->with('fails', $ex->getMessage()); |
@@ -59,7 +59,7 @@ discard block |
||
| 59 | 59 | { |
| 60 | 60 | $end = '--'; |
| 61 | 61 | if ($orders->subscription()->first()) { |
| 62 | - if (strtotime($orders->subscription()->first()->update_ends_at) >1) { |
|
| 62 | + if (strtotime($orders->subscription()->first()->update_ends_at) > 1) { |
|
| 63 | 63 | $ends = new DateTime($orders->subscription()->first()->update_ends_at); |
| 64 | 64 | $tz = \Auth::user()->timezone()->first()->name; |
| 65 | 65 | $ends->setTimezone(new DateTimeZone($tz)); |
@@ -201,27 +201,27 @@ discard block |
||
| 201 | 201 | } |
| 202 | 202 | |
| 203 | 203 | return \DataTables::of($invoices->get()) |
| 204 | - ->addColumn('number', function ($model) { |
|
| 204 | + ->addColumn('number', function($model) { |
|
| 205 | 205 | return $model->number; |
| 206 | 206 | }) |
| 207 | - ->addColumn('products', function ($model) { |
|
| 207 | + ->addColumn('products', function($model) { |
|
| 208 | 208 | $invoice = $this->invoice->find($model->id); |
| 209 | 209 | $products = $invoice->invoiceItem()->pluck('product_name')->toArray(); |
| 210 | 210 | |
| 211 | 211 | return ucfirst(implode(',', $products)); |
| 212 | 212 | }) |
| 213 | - ->addColumn('date', function ($model) { |
|
| 213 | + ->addColumn('date', function($model) { |
|
| 214 | 214 | $date = date_create($model->created_at); |
| 215 | 215 | |
| 216 | 216 | return date_format($date, 'M j, Y, g:i a'); |
| 217 | 217 | }) |
| 218 | - ->addColumn('total', function ($model) { |
|
| 218 | + ->addColumn('total', function($model) { |
|
| 219 | 219 | return $model->grand_total; |
| 220 | 220 | }) |
| 221 | - ->addColumn('status', function ($model) { |
|
| 221 | + ->addColumn('status', function($model) { |
|
| 222 | 222 | return ucfirst($model->status); |
| 223 | 223 | }) |
| 224 | - ->addColumn('action', function ($model) { |
|
| 224 | + ->addColumn('action', function($model) { |
|
| 225 | 225 | if (\Auth::user()->role == 'admin') { |
| 226 | 226 | $url = '/invoices/show?invoiceid='.$model->id; |
| 227 | 227 | } else { |
@@ -252,7 +252,7 @@ discard block |
||
| 252 | 252 | $symbol = $currency['symbol']; |
| 253 | 253 | |
| 254 | 254 | |
| 255 | - return view('themes.default1.front.clients.show-invoice', compact('invoice', 'items', 'user','currency','symbol')); |
|
| 255 | + return view('themes.default1.front.clients.show-invoice', compact('invoice', 'items', 'user', 'currency', 'symbol')); |
|
| 256 | 256 | } catch (Exception $ex) { |
| 257 | 257 | Bugsnag::notifyException($ex); |
| 258 | 258 | |
@@ -158,7 +158,7 @@ discard block |
||
| 158 | 158 | $paymentRenewal = $this->updateInvoicePayment( |
| 159 | 159 | $invoiceid, |
| 160 | 160 | $payment_method, |
| 161 | - $payment_status, |
|
| 161 | + $payment_status, |
|
| 162 | 162 | $payment_date, |
| 163 | 163 | $amount |
| 164 | 164 | ); |
@@ -216,15 +216,15 @@ discard block |
||
| 216 | 216 | |
| 217 | 217 | return view( |
| 218 | 218 | 'themes.default1.invoice.payment', |
| 219 | - compact( |
|
| 220 | - 'invoice_status', |
|
| 221 | - 'payment_status', |
|
| 222 | - 'payment_method', |
|
| 223 | - 'invoice_id', |
|
| 224 | - 'domain', |
|
| 225 | - 'invoice', |
|
| 226 | - 'userid' |
|
| 227 | - ) |
|
| 219 | + compact( |
|
| 220 | + 'invoice_status', |
|
| 221 | + 'payment_status', |
|
| 222 | + 'payment_method', |
|
| 223 | + 'invoice_id', |
|
| 224 | + 'domain', |
|
| 225 | + 'invoice', |
|
| 226 | + 'userid' |
|
| 227 | + ) |
|
| 228 | 228 | ); |
| 229 | 229 | } |
| 230 | 230 | |
@@ -364,7 +364,7 @@ discard block |
||
| 364 | 364 | foreach ($amounts as $amount) { |
| 365 | 365 | if ($amount) { |
| 366 | 366 | $paidSum = $paidSum + $amount->amount; |
| 367 | - // $credit = $paidSum + $amount->amt_to_credit; |
|
| 367 | + // $credit = $paidSum + $amount->amt_to_credit; |
|
| 368 | 368 | } |
| 369 | 369 | } |
| 370 | 370 | return $paidSum; |
@@ -374,5 +374,5 @@ discard block |
||
| 374 | 374 | |
| 375 | 375 | return redirect()->back()->with('fails', $ex->getMessage()); |
| 376 | 376 | } |
| 377 | - } |
|
| 377 | + } |
|
| 378 | 378 | } |