Completed
Push — development ( 059e30...d1b094 )
by Ashutosh
09:16
created
app/Http/Requests/User/ProfileRequest.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
                     'zip'                    => 'required|numeric',
38 38
                     'user_name'              => 'required|unique:users,user_name,'.$userid,
39 39
                     'bussiness'              => 'required',
40
-                     'profile_pic'           => 'sometimes|mimes:jpeg,jpg,png,gif|max:100000',
40
+                        'profile_pic'           => 'sometimes|mimes:jpeg,jpg,png,gif|max:100000',
41 41
 
42 42
         ];
43 43
         }
@@ -46,10 +46,10 @@  discard block
 block discarded – undo
46 46
             $userid = \Auth::user()->id;
47 47
 
48 48
             return [
49
-                     'first_name'            => 'required|min:3|max:30',
49
+                        'first_name'            => 'required|min:3|max:30',
50 50
                     'last_name'              => 'required|max:30',
51
-                     'mobile'                => 'required|regex:/[0-9]/|min:5|max:20',
52
-                     'email'                 => 'required',
51
+                        'mobile'                => 'required|regex:/[0-9]/|min:5|max:20',
52
+                        'email'                 => 'required',
53 53
                     'mobile_code'            => 'required|numeric',
54 54
                     'mobile'                 => 'required|numeric',
55 55
                     'zip'                    => 'required|numeric',
Please login to merge, or discard this patch.
app/Model/Product/Product.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
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
 
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
     use LogsActivity;
11 11
     protected $table = 'products';
12 12
     protected $fillable = ['name', 'description', 'type', 'group', 'file', 'image', 'require_domain', 'category',
13
-        'stock_control',  'stock_qty', 'sort_order', 'tax_apply', 'retired', 'hidden',  'auto_terminate',
13
+        'stock_control', 'stock_qty', 'sort_order', 'tax_apply', 'retired', '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
 block discarded – undo
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
 
Please login to merge, or discard this patch.
app/Console/Kernel.php 2 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -16,8 +16,8 @@  discard block
 block discarded – undo
16 16
      */
17 17
     protected $commands = [
18 18
         //
19
-         'App\Console\Commands\Inspire',
20
-         \App\Console\Commands\Install::class,
19
+            'App\Console\Commands\Inspire',
20
+            \App\Console\Commands\Install::class,
21 21
         'App\Console\Commands\ExpiryCron',
22 22
     ];
23 23
 
@@ -50,13 +50,13 @@  discard block
 block discarded – undo
50 50
             switch ($task) {
51 51
             case 'expiryMail':
52 52
                if ($expiryMailStatus == 1) {
53
-                   return $this->getCondition($schedule->command('expiry:notification'), $command);
54
-               }
53
+                    return $this->getCondition($schedule->command('expiry:notification'), $command);
54
+                }
55 55
 
56 56
             case 'deleteLogs':
57 57
              if ($logDeleteStatus == 1) {
58
-                 return $this->getCondition($schedule->command('activitylog:clean'), $command);
59
-             }
58
+                    return $this->getCondition($schedule->command('activitylog:clean'), $command);
59
+                }
60 60
             }
61 61
         }
62 62
     }
Please login to merge, or discard this patch.
Switch Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -48,15 +48,15 @@
 block discarded – undo
48 48
             $condition = new \App\Model\Mailjob\Condition();
49 49
             $command = $condition->getConditionValue($task);
50 50
             switch ($task) {
51
-            case 'expiryMail':
52
-               if ($expiryMailStatus == 1) {
53
-                   return $this->getCondition($schedule->command('expiry:notification'), $command);
54
-               }
51
+                case 'expiryMail':
52
+                   if ($expiryMailStatus == 1) {
53
+                       return $this->getCondition($schedule->command('expiry:notification'), $command);
54
+                   }
55 55
 
56
-            case 'deleteLogs':
57
-             if ($logDeleteStatus == 1) {
58
-                 return $this->getCondition($schedule->command('activitylog:clean'), $command);
59
-             }
56
+                case 'deleteLogs':
57
+                 if ($logDeleteStatus == 1) {
58
+                     return $this->getCondition($schedule->command('activitylog:clean'), $command);
59
+                 }
60 60
             }
61 61
         }
62 62
     }
Please login to merge, or discard this patch.
app/Http/Controllers/Order/BaseOrderController.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
                 $user_id = $this->order->find($orderid)->client;
163 163
                 $this->subscription->create(['user_id' => $user_id,
164 164
                     'plan_id'                          => $planid, 'order_id' => $orderid, 'ends_at' => $ends_at,
165
-                     'version'                         => $version, 'product_id' =>$product, ]);
165
+                        'version'                         => $version, 'product_id' =>$product, ]);
166 166
             }
167 167
             $licenseStatus = StatusSetting::pluck('license_status')->first();
168 168
             if ($licenseStatus == 1) {
@@ -270,7 +270,7 @@  discard block
 block discarded – undo
270 270
         $data = $template->data;
271 271
         $replace = [
272 272
             'name'         => $user->first_name.' '.$user->last_name,
273
-             'serialkeyurl'=> $myaccounturl,
273
+                'serialkeyurl'=> $myaccounturl,
274 274
             'downloadurl'  => $downloadurl,
275 275
             'invoiceurl'   => $invoiceurl,
276 276
             'product'      => $product,
Please login to merge, or discard this patch.
app/Http/Controllers/License/LicenseController.php 3 patches
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -85,7 +85,8 @@  discard block
 block discarded – undo
85 85
       &search_type=product&search_keyword=$product_sku");
86 86
 
87 87
             $details = json_decode($getProductId);
88
-            if ($details->api_error_detected == 0 && is_array($details->page_message)) {//This is not true if Product_sku is updated
88
+            if ($details->api_error_detected == 0 && is_array($details->page_message)) {
89
+//This is not true if Product_sku is updated
89 90
                 $productId = $details->page_message[0]->product_id;
90 91
             }
91 92
 
@@ -121,7 +122,8 @@  discard block
 block discarded – undo
121 122
       &search_type=client&search_keyword=$email");
122 123
 
123 124
         $details = json_decode($getUserId);
124
-        if ($details->api_error_detected == 0 && is_array($details->page_message)) {//This is not true if email is updated
125
+        if ($details->api_error_detected == 0 && is_array($details->page_message)) {
126
+//This is not true if email is updated
125 127
             $userId = $details->page_message[0]->client_id;
126 128
         }
127 129
 
Please login to merge, or discard this patch.
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -154,14 +154,14 @@
 block discarded – undo
154 154
     public function updateLicensedDomain($clientEmail, $domain)
155 155
     {
156 156
         $url = $this->url;
157
-          $isIP = (bool)ip2long($domain);
158
-         if($isIP == true) {
159
-           $ip = $domain;
160
-           $domain = '';
161
-         } else {
162
-          $domain = $domain ;
163
-          $ip= '';
164
-      }
157
+            $isIP = (bool)ip2long($domain);
158
+            if($isIP == true) {
159
+            $ip = $domain;
160
+            $domain = '';
161
+            } else {
162
+            $domain = $domain ;
163
+            $ip= '';
164
+        }
165 165
         $api_key_secret = $this->api_key_secret;
166 166
         $searchLicense = $this->searchLicenseId($clientEmail);
167 167
         $licenseId = $searchLicense['licenseId'];
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -154,13 +154,13 @@
 block discarded – undo
154 154
     public function updateLicensedDomain($clientEmail, $domain)
155 155
     {
156 156
         $url = $this->url;
157
-          $isIP = (bool)ip2long($domain);
158
-         if($isIP == true) {
157
+          $isIP = (bool) ip2long($domain);
158
+         if ($isIP == true) {
159 159
            $ip = $domain;
160 160
            $domain = '';
161 161
          } else {
162
-          $domain = $domain ;
163
-          $ip= '';
162
+          $domain = $domain;
163
+          $ip = '';
164 164
       }
165 165
         $api_key_secret = $this->api_key_secret;
166 166
         $searchLicense = $this->searchLicenseId($clientEmail);
Please login to merge, or discard this patch.
app/Http/Controllers/Common/MailChimpController.php 1 patch
Indentation   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
         try {
83 83
             $merge_fields = $this->field($email);
84 84
             $interestGroupIdForNo = $this->relation->is_paid_no; //Interest GroupId for IsPaid Is No
85
-              $interestGroupIdForYes = $this->relation->is_paid_yes; //Interest GroupId for IsPaid Is Yes
85
+                $interestGroupIdForYes = $this->relation->is_paid_yes; //Interest GroupId for IsPaid Is Yes
86 86
             $result = $this->mailchimp->post("lists/$this->list_id/members", [
87 87
                 'status'        => $this->mailchimp_set->subscribe_status,
88 88
                 'email_address' => $email,
@@ -107,14 +107,14 @@  discard block
 block discarded – undo
107 107
         try {
108 108
             $merge_fields = $this->field($email);
109 109
             $interestGroupIdForNo = $this->relation->is_paid_no; //Interest GroupId for IsPaid Is No
110
-              $interestGroupIdForYes = $this->relation->is_paid_yes; //Interest GroupId for IsPaid Is Yes
111
-              $productGroupId = $this->groupRelation->where('agora_product_id', $productid)
112
-              ->pluck('mailchimp_group_cat_id')->first();
110
+                $interestGroupIdForYes = $this->relation->is_paid_yes; //Interest GroupId for IsPaid Is Yes
111
+                $productGroupId = $this->groupRelation->where('agora_product_id', $productid)
112
+                ->pluck('mailchimp_group_cat_id')->first();
113 113
             $hash = md5($email);
114 114
             $result = $this->mailchimp->patch("lists/$this->list_id/members/$hash", [
115
-                 'interests'         => [$interestGroupIdForNo => true, $interestGroupIdForYes=>false, $productGroupId =>true],
116
-                 //refer to https://us7.api.mailchimp.com/playground
117
-              ]);
115
+                    'interests'         => [$interestGroupIdForNo => true, $interestGroupIdForYes=>false, $productGroupId =>true],
116
+                    //refer to https://us7.api.mailchimp.com/playground
117
+                ]);
118 118
         } catch (Exception $ex) {
119 119
             $exe = json_decode($ex->getMessage(), true);
120 120
         }
@@ -126,16 +126,16 @@  discard block
 block discarded – undo
126 126
         try {
127 127
             $merge_fields = $this->field($email);
128 128
             $interestGroupIdForNo = $this->relation->is_paid_no; //Interest GroupId for IsPaid Is No
129
-              $interestGroupIdForYes = $this->relation->is_paid_yes; //Interest GroupId for IsPaid Is Yes
130
-               $productGroupId = $this->groupRelation->where('agora_product_id', $productid)
131
-              ->pluck('mailchimp_group_cat_id')->first();
129
+                $interestGroupIdForYes = $this->relation->is_paid_yes; //Interest GroupId for IsPaid Is Yes
130
+                $productGroupId = $this->groupRelation->where('agora_product_id', $productid)
131
+                ->pluck('mailchimp_group_cat_id')->first();
132 132
 
133 133
             $hash = md5($email);
134 134
             $result = $this->mailchimp->patch("lists/$this->list_id/members/$hash", [
135
-                 'interests' => [$interestGroupIdForNo => false, $interestGroupIdForYes=>true, $productGroupId =>true],
135
+                    'interests' => [$interestGroupIdForNo => false, $interestGroupIdForYes=>true, $productGroupId =>true],
136 136
 
137
-                 //refer to https://us7.api.mailchimp.com/playground
138
-              ]);
137
+                    //refer to https://us7.api.mailchimp.com/playground
138
+                ]);
139 139
         } catch (Exception $ex) {
140 140
             dd($ex);
141 141
             $exe = json_decode($ex->getMessage(), true);
@@ -178,7 +178,7 @@  discard block
 block discarded – undo
178 178
             $country = Country::where('country_code_char2', $user->country)->pluck('nicename')->first();
179 179
             if ($user) {
180 180
                 $fields = ['first_name', 'last_name', 'company', 'mobile',
181
-                 'address', 'town', 'country', 'state', 'zip', 'active', 'role', 'source', ];
181
+                    'address', 'town', 'country', 'state', 'zip', 'active', 'role', 'source', ];
182 182
                 $relation = $this->relation;
183 183
                 $merge_fields = [];
184 184
                 foreach ($fields as $field) {
@@ -329,11 +329,11 @@  discard block
 block discarded – undo
329 329
             // this->addIsPaidInterestFieldsToAgora();
330 330
 
331 331
             $group_fields = $this->groups->where('list_id', $this->list_id)
332
-          ->select('category_name', 'category_option_id', 'category_id')->get()->toArray();
332
+            ->select('category_name', 'category_option_id', 'category_id')->get()->toArray();
333 333
             // dd($group_fields[0]);
334 334
             $relations = MailchimpGroupAgoraRelation::where('id', '!=', 0)
335
-          ->select('agora_product_id', 'mailchimp_group_cat_id')
336
-          ->orderBy('id', 'asc')->get()->toArray();
335
+            ->select('agora_product_id', 'mailchimp_group_cat_id')
336
+            ->orderBy('id', 'asc')->get()->toArray();
337 337
             $productList = [];
338 338
             $categoryList = [];
339 339
             if (count($relations) != 0) {
@@ -343,7 +343,7 @@  discard block
 block discarded – undo
343 343
                     // code...
344 344
                 }
345 345
                 // dd(count($categoryList));
346
-         // dd($productList);
346
+            // dd($productList);
347 347
             }
348 348
 
349 349
             // $relations = MailchimpGroupAgoraRelation::where('id', '!=', 0)->orderBy('id', 'asc')->get()->toArray();
@@ -377,7 +377,7 @@  discard block
 block discarded – undo
377 377
                 echo '<option value='.$field['category_option_id'].'>'.$field['category_option_name'].'</option>';
378 378
 
379 379
                 // array_push($responseData, (['selectedCat'=>$selectedCategory, 'catId'=>$field['category_option_id'],'catName'=>$field['category_option_name']]
380
-                  //  ));
380
+                    //  ));
381 381
             }
382 382
             // return $responseData;
383 383
         }
@@ -427,7 +427,7 @@  discard block
 block discarded – undo
427 427
             MailchimpGroupAgoraRelation::where('id', '!=', 0)->delete();
428 428
             foreach ($request->row as $key => $value) {
429 429
                 MailchimpGroupAgoraRelation::create(['agora_product_id'=> $value[0],
430
-             'mailchimp_group_cat_id'                                  => $value[1], ]);
430
+                'mailchimp_group_cat_id'                                  => $value[1], ]);
431 431
             }
432 432
 
433 433
             return redirect()->back()->with('success', \Lang::get('message.updated-successfully'));
Please login to merge, or discard this patch.
app/Http/Controllers/Common/BaseSettingsController.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -215,11 +215,11 @@  discard block
 block discarded – undo
215 215
             }
216 216
         }
217 217
         $delLogDays = ['720'=> '720 Days', '365'=>'365 days', '180'=>'180 Days',
218
-       '150'                => '150 Days', '60'=>'60 Days', '30'=>'30 Days', '15'=>'15 Days', '5'=>'5 Days', '2'=>'2 Days', '0'=>'Delete All Logs', ];
218
+        '150'                => '150 Days', '60'=>'60 Days', '30'=>'30 Days', '15'=>'15 Days', '5'=>'5 Days', '2'=>'2 Days', '0'=>'Delete All Logs', ];
219 219
         $beforeLogDay[] = ActivityLogDay::first()->days;
220 220
 
221 221
         return view('themes.default1.common.cron.cron', compact('cronPath','warn', 'commands', 'condition',
222
-             'status', 'expiryDays', 'selectedDays', 'delLogDays', 'beforeLogDay', 'execEnabled', 'paths'));
222
+                'status', 'expiryDays', 'selectedDays', 'delLogDays', 'beforeLogDay', 'execEnabled', 'paths'));
223 223
     }
224 224
 
225 225
     public function postSchedular(StatusSetting $status, Request $request)
@@ -359,8 +359,8 @@  discard block
 block discarded – undo
359 359
         if ($request['expiryday'] != null) {
360 360
             foreach ($request['expiryday'] as $key => $value) {
361 361
                 $daysList->create([
362
-          'days'=> $value,
363
-           ]);
362
+            'days'=> $value,
363
+            ]);
364 364
             }
365 365
         }
366 366
         ActivityLogDay::findorFail(1)->update(['days'=>$request->logdelday]);
@@ -406,7 +406,7 @@  discard block
 block discarded – undo
406 406
 
407 407
         StatusSetting::where('id', 1)->update(['recaptcha_status'=>$status]);
408 408
         ApiKey::where('id', 1)->update(['nocaptcha_sitekey'=> $nocaptcha_sitekey,
409
-         'captcha_secretCheck'                             => $captcha_secretCheck, ]);
409
+            'captcha_secretCheck'                             => $captcha_secretCheck, ]);
410 410
 
411 411
         return ['message' => 'success', 'update'=>'Recaptcha Settings Updated'];
412 412
     }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -218,7 +218,7 @@  discard block
 block discarded – undo
218 218
        '150'                => '150 Days', '60'=>'60 Days', '30'=>'30 Days', '15'=>'15 Days', '5'=>'5 Days', '2'=>'2 Days', '0'=>'Delete All Logs', ];
219 219
         $beforeLogDay[] = ActivityLogDay::first()->days;
220 220
 
221
-        return view('themes.default1.common.cron.cron', compact('cronPath','warn', 'commands', 'condition',
221
+        return view('themes.default1.common.cron.cron', compact('cronPath', 'warn', 'commands', 'condition',
222 222
              'status', 'expiryDays', 'selectedDays', 'delLogDays', 'beforeLogDay', 'execEnabled', 'paths'));
223 223
     }
224 224
 
@@ -279,7 +279,7 @@  discard block
 block discarded – undo
279 279
 
280 280
         // validate detected / default PHP CLI
281 281
         // Because array_filter() preserves keys, you should consider the resulting array to be an associative array even if the original array had integer keys for there may be holes in your sequence of keys. This means that, for example, json_encode() will convert your result array into an object instead of an array. Call array_values() on the result array to guarantee json_encode() gives you an array.
282
-        $paths = array_values(array_filter($paths, function ($path) {
282
+        $paths = array_values(array_filter($paths, function($path) {
283 283
             return is_executable($path) && preg_match("/php[0-9\.a-z]{0,3}$/i", $path);
284 284
         }));
285 285
 
Please login to merge, or discard this patch.
app/Http/Controllers/Common/SettingsController.php 2 patches
Indentation   +59 added lines, -59 removed lines patch added patch discarded remove patch
@@ -254,37 +254,37 @@  discard block
 block discarded – undo
254 254
             //     'subject_id', 'subject_type', 'causer_id', 'properties', 'created_at')->orderBy('id', 'desc');
255 255
 
256 256
             return \DataTables::of($query->take(50))
257
-             ->setTotalRecords($query->count())
258
-             ->addColumn('checkbox', function ($model) {
259
-                 return "<input type='checkbox' class='activity' value=".$model->id.' name=select[] id=check>';
260
-             })
261
-                           ->addColumn('name', function ($model) {
262
-                               return ucfirst($model->log_name);
263
-                           })
264
-                             ->addColumn('description', function ($model) {
265
-                                 return ucfirst($model->description);
266
-                             })
267
-                          ->addColumn('username', function ($model) {
268
-                              $causer_id = $model->causer_id;
269
-                              $names = User::where('id', $causer_id)->pluck('last_name', 'first_name');
270
-                              foreach ($names as $key => $value) {
271
-                                  $fullName = $key.' '.$value;
272
-
273
-                                  return $fullName;
274
-                              }
275
-                          })
276
-                              ->addColumn('role', function ($model) {
277
-                                  $causer_id = $model->causer_id;
278
-                                  $role = User::where('id', $causer_id)->pluck('role');
279
-
280
-                                  return json_decode($role);
281
-                              })
282
-                               ->addColumn('new', function ($model) {
283
-                                   $properties = ($model->properties);
284
-                                   $newEntry = $this->getNewEntry($properties, $model);
285
-
286
-                                   return $newEntry;
287
-                               })
257
+                ->setTotalRecords($query->count())
258
+                ->addColumn('checkbox', function ($model) {
259
+                    return "<input type='checkbox' class='activity' value=".$model->id.' name=select[] id=check>';
260
+                })
261
+                            ->addColumn('name', function ($model) {
262
+                                return ucfirst($model->log_name);
263
+                            })
264
+                                ->addColumn('description', function ($model) {
265
+                                    return ucfirst($model->description);
266
+                                })
267
+                            ->addColumn('username', function ($model) {
268
+                                $causer_id = $model->causer_id;
269
+                                $names = User::where('id', $causer_id)->pluck('last_name', 'first_name');
270
+                                foreach ($names as $key => $value) {
271
+                                    $fullName = $key.' '.$value;
272
+
273
+                                    return $fullName;
274
+                                }
275
+                            })
276
+                                ->addColumn('role', function ($model) {
277
+                                    $causer_id = $model->causer_id;
278
+                                    $role = User::where('id', $causer_id)->pluck('role');
279
+
280
+                                    return json_decode($role);
281
+                                })
282
+                                ->addColumn('new', function ($model) {
283
+                                    $properties = ($model->properties);
284
+                                    $newEntry = $this->getNewEntry($properties, $model);
285
+
286
+                                    return $newEntry;
287
+                                })
288 288
                                 ->addColumn('old', function ($model) {
289 289
                                     $data = ($model->properties);
290 290
                                     $oldEntry = $this->getOldEntry($data, $model);
@@ -329,39 +329,39 @@  discard block
 block discarded – undo
329 329
             $email_log = \DB::table('email_log')->get();
330 330
 
331 331
             return\ DataTables::of($email_log)
332
-             ->addColumn('checkbox', function ($model) {
333
-                 return "<input type='checkbox' class='email' value=".$model->id.' name=select[] id=check>';
334
-             })
335
-                           ->addColumn('date', function ($model) {
336
-                               return ucfirst($model->date);
337
-                           })
338
-                             ->addColumn('from', function ($model) {
339
-                                 $from = Markdown::convertToHtml(ucfirst($model->from));
340
-
341
-                                 return $from;
342
-                             })
343
-                              ->addColumn('to', function ($model) {
344
-                                  $to = Markdown::convertToHtml(ucfirst($model->to));
345
-
346
-                                  return $to;
347
-                              })
348
-                             ->addColumn('cc', function ($model) {
349
-                                 $cc = '--';
350
-
351
-                                 return $cc;
352
-                             })
353
-
354
-                               ->addColumn('subject', function ($model) {
355
-                                   return ucfirst($model->subject);
356
-                               })
332
+                ->addColumn('checkbox', function ($model) {
333
+                    return "<input type='checkbox' class='email' value=".$model->id.' name=select[] id=check>';
334
+                })
335
+                            ->addColumn('date', function ($model) {
336
+                                return ucfirst($model->date);
337
+                            })
338
+                                ->addColumn('from', function ($model) {
339
+                                    $from = Markdown::convertToHtml(ucfirst($model->from));
340
+
341
+                                    return $from;
342
+                                })
343
+                                ->addColumn('to', function ($model) {
344
+                                    $to = Markdown::convertToHtml(ucfirst($model->to));
345
+
346
+                                    return $to;
347
+                                })
348
+                                ->addColumn('cc', function ($model) {
349
+                                    $cc = '--';
350
+
351
+                                    return $cc;
352
+                                })
353
+
354
+                                ->addColumn('subject', function ($model) {
355
+                                    return ucfirst($model->subject);
356
+                                })
357 357
                                 ->addColumn('headers', function ($model) {
358 358
                                     $headers = Markdown::convertToHtml(ucfirst($model->headers));
359 359
 
360 360
                                     return $headers;
361 361
                                 })
362
-                              ->addColumn('status', function ($model) {
363
-                                  return ucfirst($model->status);
364
-                              })
362
+                                ->addColumn('status', function ($model) {
363
+                                    return ucfirst($model->status);
364
+                                })
365 365
 
366 366
                             ->rawColumns(['checkbox', 'date', 'from', 'to', 'cc',
367 367
                                 'bcc', 'subject', 'headers', 'status', ])
Please login to merge, or discard this patch.
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -255,16 +255,16 @@  discard block
 block discarded – undo
255 255
 
256 256
             return \DataTables::of($query->take(50))
257 257
              ->setTotalRecords($query->count())
258
-             ->addColumn('checkbox', function ($model) {
258
+             ->addColumn('checkbox', function($model) {
259 259
                  return "<input type='checkbox' class='activity' value=".$model->id.' name=select[] id=check>';
260 260
              })
261
-                           ->addColumn('name', function ($model) {
261
+                           ->addColumn('name', function($model) {
262 262
                                return ucfirst($model->log_name);
263 263
                            })
264
-                             ->addColumn('description', function ($model) {
264
+                             ->addColumn('description', function($model) {
265 265
                                  return ucfirst($model->description);
266 266
                              })
267
-                          ->addColumn('username', function ($model) {
267
+                          ->addColumn('username', function($model) {
268 268
                               $causer_id = $model->causer_id;
269 269
                               $names = User::where('id', $causer_id)->pluck('last_name', 'first_name');
270 270
                               foreach ($names as $key => $value) {
@@ -273,41 +273,41 @@  discard block
 block discarded – undo
273 273
                                   return $fullName;
274 274
                               }
275 275
                           })
276
-                              ->addColumn('role', function ($model) {
276
+                              ->addColumn('role', function($model) {
277 277
                                   $causer_id = $model->causer_id;
278 278
                                   $role = User::where('id', $causer_id)->pluck('role');
279 279
 
280 280
                                   return json_decode($role);
281 281
                               })
282
-                               ->addColumn('new', function ($model) {
282
+                               ->addColumn('new', function($model) {
283 283
                                    $properties = ($model->properties);
284 284
                                    $newEntry = $this->getNewEntry($properties, $model);
285 285
 
286 286
                                    return $newEntry;
287 287
                                })
288
-                                ->addColumn('old', function ($model) {
288
+                                ->addColumn('old', function($model) {
289 289
                                     $data = ($model->properties);
290 290
                                     $oldEntry = $this->getOldEntry($data, $model);
291 291
 
292 292
                                     return $oldEntry;
293 293
                                 })
294
-                                ->addColumn('created_at', function ($model) {
294
+                                ->addColumn('created_at', function($model) {
295 295
                                     $newDate = $this->getDate($model->created_at);
296 296
 
297 297
                                     return $newDate;
298 298
                                 })
299 299
 
300
-                                    ->filterColumn('log_name', function ($query, $keyword) {
300
+                                    ->filterColumn('log_name', function($query, $keyword) {
301 301
                                         $sql = 'log_name like ?';
302 302
                                         $query->whereRaw($sql, ["%{$keyword}%"]);
303 303
                                     })
304 304
 
305
-                                ->filterColumn('description', function ($query, $keyword) {
305
+                                ->filterColumn('description', function($query, $keyword) {
306 306
                                     $sql = 'description like ?';
307 307
                                     $query->whereRaw($sql, ["%{$keyword}%"]);
308 308
                                 })
309 309
 
310
-                            ->filterColumn('causer_id', function ($query, $keyword) {
310
+                            ->filterColumn('causer_id', function($query, $keyword) {
311 311
                                 $sql = 'first_name like ?';
312 312
                                 $query->whereRaw($sql, ["%{$keyword}%"]);
313 313
                             })
@@ -329,37 +329,37 @@  discard block
 block discarded – undo
329 329
             $email_log = \DB::table('email_log')->get();
330 330
 
331 331
             return\ DataTables::of($email_log)
332
-             ->addColumn('checkbox', function ($model) {
332
+             ->addColumn('checkbox', function($model) {
333 333
                  return "<input type='checkbox' class='email' value=".$model->id.' name=select[] id=check>';
334 334
              })
335
-                           ->addColumn('date', function ($model) {
335
+                           ->addColumn('date', function($model) {
336 336
                                return ucfirst($model->date);
337 337
                            })
338
-                             ->addColumn('from', function ($model) {
338
+                             ->addColumn('from', function($model) {
339 339
                                  $from = Markdown::convertToHtml(ucfirst($model->from));
340 340
 
341 341
                                  return $from;
342 342
                              })
343
-                              ->addColumn('to', function ($model) {
343
+                              ->addColumn('to', function($model) {
344 344
                                   $to = Markdown::convertToHtml(ucfirst($model->to));
345 345
 
346 346
                                   return $to;
347 347
                               })
348
-                             ->addColumn('cc', function ($model) {
348
+                             ->addColumn('cc', function($model) {
349 349
                                  $cc = '--';
350 350
 
351 351
                                  return $cc;
352 352
                              })
353 353
 
354
-                               ->addColumn('subject', function ($model) {
354
+                               ->addColumn('subject', function($model) {
355 355
                                    return ucfirst($model->subject);
356 356
                                })
357
-                                ->addColumn('headers', function ($model) {
357
+                                ->addColumn('headers', function($model) {
358 358
                                     $headers = Markdown::convertToHtml(ucfirst($model->headers));
359 359
 
360 360
                                     return $headers;
361 361
                                 })
362
-                              ->addColumn('status', function ($model) {
362
+                              ->addColumn('status', function($model) {
363 363
                                   return ucfirst($model->status);
364 364
                               })
365 365
 
Please login to merge, or discard this patch.
app/Http/Controllers/Order/ExtendedOrderController.php 2 patches
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -175,15 +175,15 @@
 block discarded – undo
175 175
     {
176 176
         $needle = 'www';
177 177
         foreach ($seperateDomains as $domain) {
178
-         $isIP = (bool)ip2long($domain);
179
-         if($isIP == true) {
180
-           $allowedDomains[] = $domain;
181
-         } else {
182
-          $customDomain = (strpos($domain, $needle) !== false) ? str_replace('www.', '', $domain) : 'www.'.$domain;
183
-          $allowedDomains[] = ($domain.','.$customDomain);
178
+            $isIP = (bool)ip2long($domain);
179
+            if($isIP == true) {
180
+            $allowedDomains[] = $domain;
181
+            } else {
182
+            $customDomain = (strpos($domain, $needle) !== false) ? str_replace('www.', '', $domain) : 'www.'.$domain;
183
+            $allowedDomains[] = ($domain.','.$customDomain);
184 184
          
185
-         }
186
-       }
185
+            }
186
+        }
187 187
         return  $allowedDomains;
188 188
     }
189 189
 }
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -154,16 +154,16 @@  discard block
 block discarded – undo
154 154
         $domain = '';
155 155
         $arrayOfDomains = array();
156 156
         $allDomains = $request->input('domain');
157
-        $seperateDomains = explode(',', $allDomains);//Bifurcate the domains here
157
+        $seperateDomains = explode(',', $allDomains); //Bifurcate the domains here
158 158
           
159
-        $allowedDomains =$this->getAllowedDomains( $seperateDomains);
159
+        $allowedDomains = $this->getAllowedDomains($seperateDomains);
160 160
         $id = $request->input('id');
161 161
         $order = Order::findorFail($id);
162 162
         $clientEmail = $order->user->email;
163 163
         $order->domain = implode(",", $allowedDomains);
164 164
         $order->save();
165 165
         $cont = new \App\Http\Controllers\License\LicenseController();
166
-        $updateLicensedDomain = $cont->updateLicensedDomain($clientEmail,$order->domain);
166
+        $updateLicensedDomain = $cont->updateLicensedDomain($clientEmail, $order->domain);
167 167
         //Now make Installation status as inactive
168 168
         $updateInstallStatus = $cont->updateInstalledDomain($clientEmail);
169 169
 
@@ -175,8 +175,8 @@  discard block
 block discarded – undo
175 175
     {
176 176
         $needle = 'www';
177 177
         foreach ($seperateDomains as $domain) {
178
-         $isIP = (bool)ip2long($domain);
179
-         if($isIP == true) {
178
+         $isIP = (bool) ip2long($domain);
179
+         if ($isIP == true) {
180 180
            $allowedDomains[] = $domain;
181 181
          } else {
182 182
           $customDomain = (strpos($domain, $needle) !== false) ? str_replace('www.', '', $domain) : 'www.'.$domain;
Please login to merge, or discard this patch.