| @@ -36,7 +36,7 @@ discard block | ||
| 36 | 36 |              $symbol = Currency::where('code', $currency)->pluck('symbol')->first(); | 
| 37 | 37 |              $orders = $order->where('client', $clientid)->get(); | 
| 38 | 38 | |
| 39 | -            return view('themes.default1.invoice.newpayment', compact('clientid', 'client', 'invoices',  'orders', | |
| 39 | +            return view('themes.default1.invoice.newpayment', compact('clientid', 'client', 'invoices', 'orders', | |
| 40 | 40 | 'invoiceSum', 'amountReceived', 'pendingAmount', 'currency', 'symbol')); | 
| 41 | 41 |          } catch (Exception $ex) { | 
| 42 | 42 |              return redirect()->back()->with('fails', $ex->getMessage()); | 
| @@ -112,7 +112,7 @@ discard block | ||
| 112 | 112 | $invoicAmount = $request->invoiceAmount; | 
| 113 | 113 | $amtToCredit = $request->amtToCredit; | 
| 114 | 114 | $payment_status = 'success'; | 
| 115 | - $payment = $this->multiplePayment($clientid,$invoiceChecked, $payment_method, | |
| 115 | + $payment = $this->multiplePayment($clientid, $invoiceChecked, $payment_method, | |
| 116 | 116 | $payment_date, $totalAmt, $invoicAmount, $amtToCredit, $payment_status); | 
| 117 | 117 | $response = ['type' => 'success', 'message' => 'Payment Updated Successfully']; | 
| 118 | 118 | |
| @@ -129,7 +129,7 @@ discard block | ||
| 129 | 129 | } | 
| 130 | 130 | } | 
| 131 | 131 | |
| 132 | - public function multiplePayment($clientid,$invoiceChecked, $payment_method, | |
| 132 | + public function multiplePayment($clientid, $invoiceChecked, $payment_method, | |
| 133 | 133 | $payment_date, $totalAmt, $invoicAmount, $amtToCredit, $payment_status) | 
| 134 | 134 |      { | 
| 135 | 135 |          try { | 
| @@ -204,7 +204,7 @@ discard block | ||
| 204 | 204 | $invoicAmount = $request->invoiceAmount; | 
| 205 | 205 | $amtToCredit = $request->amtToCredit; | 
| 206 | 206 | $payment_status = 'success'; | 
| 207 | - $payment = $this->updatePaymentByInvoice($clientid,$invoiceChecked, $payment_method, | |
| 207 | + $payment = $this->updatePaymentByInvoice($clientid, $invoiceChecked, $payment_method, | |
| 208 | 208 | $payment_date, $totalAmt, $invoicAmount, $amtToCredit, $payment_status); | 
| 209 | 209 | $response = ['type' => 'success', 'message' => 'Payment Updated Successfully']; | 
| 210 | 210 | |
| @@ -218,7 +218,7 @@ discard block | ||
| 218 | 218 | } | 
| 219 | 219 | } | 
| 220 | 220 | |
| 221 | - public function updatePaymentByInvoice($clientid,$invoiceChecked, $payment_method, | |
| 221 | + public function updatePaymentByInvoice($clientid, $invoiceChecked, $payment_method, | |
| 222 | 222 | $payment_date, $totalAmt, $invoicAmount, $amtToCredit, $payment_status) | 
| 223 | 223 |      { | 
| 224 | 224 |          try { | 
| @@ -10,7 +10,7 @@ discard block | ||
| 10 | 10 | use LogsActivity; | 
| 11 | 11 | protected $table = 'products'; | 
| 12 | 12 | protected $fillable = ['name', 'description', 'type', 'group', 'file', 'image', 'require_domain', 'category', | 
| 13 | - 'can_modify_agent', 'can_modify_quantity', 'show_agent', 'tax_apply', 'show_product_quantity', 'hidden', 'auto_terminate', | |
| 13 | + 'can_modify_agent', 'can_modify_quantity', 'show_agent', 'tax_apply', 'show_product_quantity', 'hidden', 'auto_terminate', | |
| 14 | 14 | 'setup_order_placed', 'setup_first_payment', 'setup_accept_manually', | 
| 15 | 15 | 'no_auto_setup', 'shoping_cart_link', 'process_url', 'github_owner', | 
| 16 | 16 | 'github_repository', | 
| @@ -19,7 +19,7 @@ discard block | ||
| 19 | 19 | protected static $logName = 'Product'; | 
| 20 | 20 | |
| 21 | 21 | protected static $logAttributes = ['name', 'description', 'type', 'file', 'category', | 
| 22 | - 'github_owner', 'github_repository', 'version', 'subscription', 'hidden', 'product_sku', ]; | |
| 22 | + 'github_owner', 'github_repository', 'version', 'subscription', 'hidden', 'product_sku', ]; | |
| 23 | 23 | |
| 24 | 24 | protected static $logOnlyDirty = true; | 
| 25 | 25 | |
| @@ -118,25 +118,25 @@ discard block | ||
| 118 | 118 | |
| 119 | 119 | return\ DataTables::of($new_product) | 
| 120 | 120 | |
| 121 | -                            ->addColumn('checkbox', function ($model) { | |
| 121 | +                            ->addColumn('checkbox', function($model) { | |
| 122 | 122 | return "<input type='checkbox' class='product_checkbox' | 
| 123 | 123 | value=".$model->id.' name=select[] id=check>'; | 
| 124 | 124 | }) | 
| 125 | -                            ->addColumn('name', function ($model) { | |
| 125 | +                            ->addColumn('name', function($model) { | |
| 126 | 126 | return ucfirst($model->name); | 
| 127 | 127 | }) | 
| 128 | -                              ->addColumn('image', function ($model) { | |
| 128 | +                              ->addColumn('image', function($model) { | |
| 129 | 129 | // return $model->image; | 
| 130 | 130 | return "<img src= '$model->image' + height=\"80\"/>"; | 
| 131 | 131 | }) | 
| 132 | -                            ->addColumn('type', function ($model) { | |
| 132 | +                            ->addColumn('type', function($model) { | |
| 133 | 133 |                                  if ($this->type->where('id', $model->type)->first()) { | 
| 134 | 134 |                                      return $this->type->where('id', $model->type)->first()->name; | 
| 135 | 135 |                                  } else { | 
| 136 | 136 | return 'Not available'; | 
| 137 | 137 | } | 
| 138 | 138 | }) | 
| 139 | -                            ->addColumn('group', function ($model) { | |
| 139 | +                            ->addColumn('group', function($model) { | |
| 140 | 140 |                                  if ($this->group->where('id', $model->group)->first()) { | 
| 141 | 141 |                                      return $this->group->where('id', $model->group)->first()->name; | 
| 142 | 142 |                                  } else { | 
| @@ -144,7 +144,7 @@ discard block | ||
| 144 | 144 | } | 
| 145 | 145 | }) | 
| 146 | 146 | |
| 147 | -                            ->addColumn('Action', function ($model) { | |
| 147 | +                            ->addColumn('Action', function($model) { | |
| 148 | 148 | $permissions = LicensePermissionsController::getPermissionsForProduct($model->id); | 
| 149 | 149 | $url = ''; | 
| 150 | 150 |                                  if ($permissions['downloadPermission'] == 1) { | 
| @@ -199,21 +199,21 @@ | ||
| 199 | 199 |              switch ($request->input('type')) { | 
| 200 | 200 | case 'text': | 
| 201 | 201 | $array = json_decode($result, true); | 
| 202 | - $response = ['type' => 'success', | |
| 203 | - 'message' => 'OTP has been resent to '.$number.'.Please Enter the OTP to login!!', ]; | |
| 202 | + $response = ['type' => 'success', | |
| 203 | + 'message' => 'OTP has been resent to '.$number.'.Please Enter the OTP to login!!', ]; | |
| 204 | 204 | |
| 205 | 205 | break; | 
| 206 | 206 | |
| 207 | 207 | case 'voice': | 
| 208 | 208 | $array = json_decode($result, true); | 
| 209 | 209 | $response = ['type' => 'success', | 
| 210 | - 'message' => 'Voice call has been sent to '.$number.'.Please Enter the OTP received on the call to login!!', ]; | |
| 210 | + 'message' => 'Voice call has been sent to '.$number.'.Please Enter the OTP received on the call to login!!', ]; | |
| 211 | 211 | break; | 
| 212 | 212 | |
| 213 | 213 | default: | 
| 214 | 214 | $array = json_decode($result, true); | 
| 215 | 215 | $response = ['type' => 'success', | 
| 216 | - 'message' => 'Voice call has been sent to '.$number.'.Please Enter the OTP received on the call to login!!', ]; | |
| 216 | + 'message' => 'Voice call has been sent to '.$number.'.Please Enter the OTP received on the call to login!!', ]; | |
| 217 | 217 | break; | 
| 218 | 218 | |
| 219 | 219 | } | 
| @@ -69,7 +69,7 @@ discard block | ||
| 69 | 69 |              $msg91Sender = $apikeys->pluck('msg91_sender')->first(); | 
| 70 | 70 |              $updateUrl = $apikeys->pluck('update_api_url')->first(); | 
| 71 | 71 |              $emailStatus = StatusSetting::pluck('emailverification_status')->first(); | 
| 72 | -            $twitterKeys = $apikeys->select('twitter_consumer_key','twitter_consumer_secret', | |
| 72 | +            $twitterKeys = $apikeys->select('twitter_consumer_key', 'twitter_consumer_secret', | |
| 73 | 73 | 'twitter_access_token', 'access_tooken_secret')->first(); | 
| 74 | 74 |              $twitterStatus = $this->statusSetting->pluck('twitter_status')->first(); | 
| 75 | 75 |              $zohoStatus = $this->statusSetting->pluck('zoho_status')->first(); | 
| @@ -306,16 +306,16 @@ discard block | ||
| 306 | 306 | |
| 307 | 307 | return \DataTables::of($query->take(50)) | 
| 308 | 308 | ->setTotalRecords($query->count()) | 
| 309 | -             ->addColumn('checkbox', function ($model) { | |
| 309 | +             ->addColumn('checkbox', function($model) { | |
| 310 | 310 | return "<input type='checkbox' class='activity' value=".$model->id.' name=select[] id=check>'; | 
| 311 | 311 | }) | 
| 312 | -                           ->addColumn('name', function ($model) { | |
| 312 | +                           ->addColumn('name', function($model) { | |
| 313 | 313 | return ucfirst($model->log_name); | 
| 314 | 314 | }) | 
| 315 | -                             ->addColumn('description', function ($model) { | |
| 315 | +                             ->addColumn('description', function($model) { | |
| 316 | 316 | return ucfirst($model->description); | 
| 317 | 317 | }) | 
| 318 | -                          ->addColumn('username', function ($model) { | |
| 318 | +                          ->addColumn('username', function($model) { | |
| 319 | 319 | $causer_id = $model->causer_id; | 
| 320 | 320 |                                $names = User::where('id', $causer_id)->pluck('last_name', 'first_name'); | 
| 321 | 321 |                                foreach ($names as $key => $value) { | 
| @@ -324,41 +324,41 @@ discard block | ||
| 324 | 324 | return $fullName; | 
| 325 | 325 | } | 
| 326 | 326 | }) | 
| 327 | -                              ->addColumn('role', function ($model) { | |
| 327 | +                              ->addColumn('role', function($model) { | |
| 328 | 328 | $causer_id = $model->causer_id; | 
| 329 | 329 |                                    $role = User::where('id', $causer_id)->pluck('role'); | 
| 330 | 330 | |
| 331 | 331 | return json_decode($role); | 
| 332 | 332 | }) | 
| 333 | -                               ->addColumn('new', function ($model) { | |
| 333 | +                               ->addColumn('new', function($model) { | |
| 334 | 334 | $properties = ($model->properties); | 
| 335 | 335 | $newEntry = $this->getNewEntry($properties, $model); | 
| 336 | 336 | |
| 337 | 337 | return $newEntry; | 
| 338 | 338 | }) | 
| 339 | -                                ->addColumn('old', function ($model) { | |
| 339 | +                                ->addColumn('old', function($model) { | |
| 340 | 340 | $data = ($model->properties); | 
| 341 | 341 | $oldEntry = $this->getOldEntry($data, $model); | 
| 342 | 342 | |
| 343 | 343 | return $oldEntry; | 
| 344 | 344 | }) | 
| 345 | -                                ->addColumn('created_at', function ($model) { | |
| 345 | +                                ->addColumn('created_at', function($model) { | |
| 346 | 346 | $newDate = $this->getDate($model->created_at); | 
| 347 | 347 | |
| 348 | 348 | return $newDate; | 
| 349 | 349 | }) | 
| 350 | 350 | |
| 351 | -                                    ->filterColumn('log_name', function ($query, $keyword) { | |
| 351 | +                                    ->filterColumn('log_name', function($query, $keyword) { | |
| 352 | 352 | $sql = 'log_name like ?'; | 
| 353 | 353 |                                          $query->whereRaw($sql, ["%{$keyword}%"]); | 
| 354 | 354 | }) | 
| 355 | 355 | |
| 356 | -                                ->filterColumn('description', function ($query, $keyword) { | |
| 356 | +                                ->filterColumn('description', function($query, $keyword) { | |
| 357 | 357 | $sql = 'description like ?'; | 
| 358 | 358 |                                      $query->whereRaw($sql, ["%{$keyword}%"]); | 
| 359 | 359 | }) | 
| 360 | 360 | |
| 361 | -                            ->filterColumn('causer_id', function ($query, $keyword) { | |
| 361 | +                            ->filterColumn('causer_id', function($query, $keyword) { | |
| 362 | 362 | $sql = 'first_name like ?'; | 
| 363 | 363 |                                  $query->whereRaw($sql, ["%{$keyword}%"]); | 
| 364 | 364 | }) | 
| @@ -379,10 +379,10 @@ discard block | ||
| 379 | 379 |              $email_log = \DB::table('email_log')->orderBy('date', 'desc')->get(); | 
| 380 | 380 | |
| 381 | 381 | return\ DataTables::of($email_log) | 
| 382 | -             ->addColumn('checkbox', function ($model) { | |
| 382 | +             ->addColumn('checkbox', function($model) { | |
| 383 | 383 | return "<input type='checkbox' class='email' value=".$model->id.' name=select[] id=check>'; | 
| 384 | 384 | }) | 
| 385 | -                           ->addColumn('date', function ($model) { | |
| 385 | +                           ->addColumn('date', function($model) { | |
| 386 | 386 | $date = $model->date; | 
| 387 | 387 |                                 if ($date) { | 
| 388 | 388 | $date1 = new \DateTime($date); | 
| @@ -393,18 +393,18 @@ discard block | ||
| 393 | 393 | |
| 394 | 394 | return $finalDate; | 
| 395 | 395 | }) | 
| 396 | -                             ->addColumn('from', function ($model) { | |
| 396 | +                             ->addColumn('from', function($model) { | |
| 397 | 397 | $from = Markdown::convertToHtml($model->from); | 
| 398 | 398 | |
| 399 | 399 | return $from; | 
| 400 | 400 | }) | 
| 401 | -                              ->addColumn('to', function ($model) { | |
| 401 | +                              ->addColumn('to', function($model) { | |
| 402 | 402 | $to = Markdown::convertToHtml($model->to); | 
| 403 | 403 | |
| 404 | 404 | return $to; | 
| 405 | 405 | }) | 
| 406 | 406 | |
| 407 | -                               ->addColumn('subject', function ($model) { | |
| 407 | +                               ->addColumn('subject', function($model) { | |
| 408 | 408 | return ucfirst($model->subject); | 
| 409 | 409 | }) | 
| 410 | 410 |                                  // ->addColumn('headers', function ($model) { | 
| @@ -412,12 +412,12 @@ discard block | ||
| 412 | 412 | |
| 413 | 413 | // return $headers; | 
| 414 | 414 | // }) | 
| 415 | -                              ->addColumn('status', function ($model) { | |
| 415 | +                              ->addColumn('status', function($model) { | |
| 416 | 416 | return ucfirst($model->status); | 
| 417 | 417 | }) | 
| 418 | 418 | |
| 419 | 419 | ->rawColumns(['checkbox', 'date', 'from', 'to', | 
| 420 | - 'bcc', 'subject', 'status', ]) | |
| 420 | + 'bcc', 'subject', 'status', ]) | |
| 421 | 421 | ->make(true); | 
| 422 | 422 |          } catch (\Exception $e) { | 
| 423 | 423 | Bugsnag::notifyException($e); |