@@ -43,12 +43,12 @@ |
||
43 | 43 | public function registerMediaConversions() |
44 | 44 | { |
45 | 45 | $this->addMediaConversion('thumb') |
46 | - ->setManipulations(['w' => 50, 'h' => 50, 'q' => 100, 'fit' => 'crop']) |
|
47 | - ->performOnCollections('staff'); |
|
46 | + ->setManipulations(['w' => 50, 'h' => 50, 'q' => 100, 'fit' => 'crop']) |
|
47 | + ->performOnCollections('staff'); |
|
48 | 48 | |
49 | 49 | $this->addMediaConversion('form') |
50 | - ->setManipulations(['w' => 70, 'h' => 70, 'q' => 100, 'fit' => 'crop']) |
|
51 | - ->performOnCollections('staff'); |
|
50 | + ->setManipulations(['w' => 70, 'h' => 70, 'q' => 100, 'fit' => 'crop']) |
|
51 | + ->performOnCollections('staff'); |
|
52 | 52 | } |
53 | 53 | |
54 | 54 | public function scopeExcludeArchive($query) |
@@ -23,7 +23,7 @@ |
||
23 | 23 | 'discount_note', |
24 | 24 | 'created_by', |
25 | 25 | 'updated_by', |
26 | - ]; |
|
26 | + ]; |
|
27 | 27 | |
28 | 28 | protected $dates = ['created_at', 'updated_at']; |
29 | 29 |
@@ -36,39 +36,39 @@ |
||
36 | 36 | protected function schedule(Schedule $schedule) |
37 | 37 | { |
38 | 38 | $schedule->command('reshoot:offlineSms') |
39 | - ->hourly(); |
|
39 | + ->hourly(); |
|
40 | 40 | |
41 | 41 | $schedule->command('birthday:sms') |
42 | - ->dailyAt('00:01'); |
|
42 | + ->dailyAt('00:01'); |
|
43 | 43 | |
44 | 44 | $schedule->command('set:expired') |
45 | - ->dailyAt('00:05'); |
|
45 | + ->dailyAt('00:05'); |
|
46 | 46 | |
47 | 47 | $schedule->command('sms:event') |
48 | - ->dailyAt('09:00'); |
|
48 | + ->dailyAt('09:00'); |
|
49 | 49 | |
50 | 50 | $schedule->command('sms:expiring') |
51 | - ->dailyAt('10:00'); |
|
51 | + ->dailyAt('10:00'); |
|
52 | 52 | |
53 | 53 | $schedule->command('expense:alert') |
54 | - ->dailyAt('10:30') |
|
55 | - ->when(function () { |
|
56 | - return \Utilities::getSetting('primary_contact') != null; |
|
57 | - }); |
|
54 | + ->dailyAt('10:30') |
|
55 | + ->when(function () { |
|
56 | + return \Utilities::getSetting('primary_contact') != null; |
|
57 | + }); |
|
58 | 58 | |
59 | 59 | $schedule->command('pending:invoice') |
60 | - ->dailyAt('11:00'); |
|
60 | + ->dailyAt('11:00'); |
|
61 | 61 | |
62 | 62 | $schedule->command('followup:sms') |
63 | - ->dailyAt('11:30'); |
|
63 | + ->dailyAt('11:30'); |
|
64 | 64 | |
65 | 65 | $schedule->command('sms:expired') |
66 | - ->dailyAt('11:45'); |
|
66 | + ->dailyAt('11:45'); |
|
67 | 67 | |
68 | 68 | $schedule->command('repeat:expense') |
69 | - ->dailyAt('23:00'); |
|
69 | + ->dailyAt('23:00'); |
|
70 | 70 | |
71 | 71 | $schedule->command('sms:status') |
72 | - ->dailyAt('23:45'); |
|
72 | + ->dailyAt('23:45'); |
|
73 | 73 | } |
74 | 74 | } |
@@ -44,53 +44,53 @@ |
||
44 | 44 | foreach ($expenses as $expense) { |
45 | 45 | if ($expense->repeat == 1) { |
46 | 46 | $expenseData = ['name' => $expense->name, |
47 | - 'category_id' => $expense->category_id, |
|
48 | - 'due_date' => $expense->due_date->addDays(1), |
|
49 | - 'repeat' => $expense->repeat, |
|
50 | - 'note' => $expense->note, |
|
51 | - 'amount' => $expense->amount, |
|
52 | - 'paid' => 0, |
|
53 | - 'created_by' => 1, |
|
54 | - 'updated_by' => 1, ]; |
|
47 | + 'category_id' => $expense->category_id, |
|
48 | + 'due_date' => $expense->due_date->addDays(1), |
|
49 | + 'repeat' => $expense->repeat, |
|
50 | + 'note' => $expense->note, |
|
51 | + 'amount' => $expense->amount, |
|
52 | + 'paid' => 0, |
|
53 | + 'created_by' => 1, |
|
54 | + 'updated_by' => 1, ]; |
|
55 | 55 | |
56 | 56 | $newExpense = new Expense($expenseData); |
57 | 57 | $newExpense->save(); |
58 | 58 | } elseif ($expense->repeat == 2) { |
59 | 59 | $expenseData = ['name' => $expense->name, |
60 | - 'category_id' => $expense->category_id, |
|
61 | - 'due_date' => $expense->due_date->addWeek(), |
|
62 | - 'repeat' => $expense->repeat, |
|
63 | - 'note' => $expense->note, |
|
64 | - 'amount' => $expense->amount, |
|
65 | - 'paid' => 0, |
|
66 | - 'created_by' => 1, |
|
67 | - 'updated_by' => 1, ]; |
|
60 | + 'category_id' => $expense->category_id, |
|
61 | + 'due_date' => $expense->due_date->addWeek(), |
|
62 | + 'repeat' => $expense->repeat, |
|
63 | + 'note' => $expense->note, |
|
64 | + 'amount' => $expense->amount, |
|
65 | + 'paid' => 0, |
|
66 | + 'created_by' => 1, |
|
67 | + 'updated_by' => 1, ]; |
|
68 | 68 | |
69 | 69 | $newExpense = new Expense($expenseData); |
70 | 70 | $newExpense->save(); |
71 | 71 | } elseif ($expense->repeat == 3) { |
72 | 72 | $expenseData = ['name' => $expense->name, |
73 | - 'category_id' => $expense->category_id, |
|
74 | - 'due_date' => $expense->due_date->addMonth(), |
|
75 | - 'repeat' => $expense->repeat, |
|
76 | - 'note' => $expense->note, |
|
77 | - 'amount' => $expense->amount, |
|
78 | - 'paid' => 0, |
|
79 | - 'created_by' => 1, |
|
80 | - 'updated_by' => 1, ]; |
|
73 | + 'category_id' => $expense->category_id, |
|
74 | + 'due_date' => $expense->due_date->addMonth(), |
|
75 | + 'repeat' => $expense->repeat, |
|
76 | + 'note' => $expense->note, |
|
77 | + 'amount' => $expense->amount, |
|
78 | + 'paid' => 0, |
|
79 | + 'created_by' => 1, |
|
80 | + 'updated_by' => 1, ]; |
|
81 | 81 | |
82 | 82 | $newExpense = new Expense($expenseData); |
83 | 83 | $newExpense->save(); |
84 | 84 | } elseif ($expense->repeat == 4) { |
85 | 85 | $expenseData = ['name' => $expense->name, |
86 | - 'category_id' => $expense->category_id, |
|
87 | - 'due_date' => $expense->due_date->addYear(), |
|
88 | - 'repeat' => $expense->repeat, |
|
89 | - 'note' => $expense->note, |
|
90 | - 'amount' => $expense->amount, |
|
91 | - 'paid' => 0, |
|
92 | - 'created_by' => 1, |
|
93 | - 'updated_by' => 1, ]; |
|
86 | + 'category_id' => $expense->category_id, |
|
87 | + 'due_date' => $expense->due_date->addYear(), |
|
88 | + 'repeat' => $expense->repeat, |
|
89 | + 'note' => $expense->note, |
|
90 | + 'amount' => $expense->amount, |
|
91 | + 'paid' => 0, |
|
92 | + 'created_by' => 1, |
|
93 | + 'updated_by' => 1, ]; |
|
94 | 94 | |
95 | 95 | $newExpense = new Expense($expenseData); |
96 | 96 | $newExpense->save(); |
@@ -80,10 +80,10 @@ |
||
80 | 80 | |
81 | 81 | //Store the followup details |
82 | 82 | $followupData = ['enquiry_id'=>$enquiry->id, |
83 | - 'followup_by'=>$request->followup_by, |
|
84 | - 'due_date'=>$request->due_date, |
|
85 | - 'status'=> \constFollowUpStatus::Pending, |
|
86 | - 'outcome'=>'', ]; |
|
83 | + 'followup_by'=>$request->followup_by, |
|
84 | + 'due_date'=>$request->due_date, |
|
85 | + 'status'=> \constFollowUpStatus::Pending, |
|
86 | + 'outcome'=>'', ]; |
|
87 | 87 | |
88 | 88 | $followup = new Followup($followupData); |
89 | 89 | $followup->createdBy()->associate(Auth::user()); |
@@ -59,7 +59,7 @@ |
||
59 | 59 | { |
60 | 60 | //Model Validation |
61 | 61 | $this->validate($request, ['plan_code' => 'unique:mst_plans,plan_code', |
62 | - 'plan_name' => 'unique:mst_plans,plan_name', ]); |
|
62 | + 'plan_name' => 'unique:mst_plans,plan_name', ]); |
|
63 | 63 | |
64 | 64 | $plan = new Plan($request->all()); |
65 | 65 |
@@ -66,11 +66,11 @@ |
||
66 | 66 | public function store(Request $request) |
67 | 67 | { |
68 | 68 | $expenseData = ['name' => $request->name, |
69 | - 'category_id' => $request->category_id, |
|
70 | - 'due_date' => $request->due_date, |
|
71 | - 'repeat' => $request->repeat, |
|
72 | - 'note' => $request->note, |
|
73 | - 'amount' => $request->amount, ]; |
|
69 | + 'category_id' => $request->category_id, |
|
70 | + 'due_date' => $request->due_date, |
|
71 | + 'repeat' => $request->repeat, |
|
72 | + 'note' => $request->note, |
|
73 | + 'amount' => $request->amount, ]; |
|
74 | 74 | |
75 | 75 | $expense = new Expense($expenseData); |
76 | 76 | $expense->createdBy()->associate(Auth::user()); |
@@ -11,7 +11,7 @@ |
||
11 | 11 | protected $fillable = [ |
12 | 12 | 'key', |
13 | 13 | 'value', |
14 | - ]; |
|
14 | + ]; |
|
15 | 15 | |
16 | 16 | const CREATED_AT = null; |
17 | 17 |
@@ -650,11 +650,11 @@ |
||
650 | 650 | if (str_contains($response, 'SMS-SHOOT-ID')) { |
651 | 651 | //Log entry for SMS_log table |
652 | 652 | $log->update(['shoot_id' => substr($response, strpos($response, 'SMS-SHOOT-ID/') + 13), |
653 | - 'number' => $member_contact, |
|
654 | - 'message' => $sms_text, |
|
655 | - 'sender_id' => $sender_id, |
|
656 | - 'send_time' => Carbon::now(), |
|
657 | - 'status' => 'NA', ]); |
|
653 | + 'number' => $member_contact, |
|
654 | + 'message' => $sms_text, |
|
655 | + 'sender_id' => $sender_id, |
|
656 | + 'send_time' => Carbon::now(), |
|
657 | + 'status' => 'NA', ]); |
|
658 | 658 | $log->save(); |
659 | 659 | } |
660 | 660 | //Update SMS balance |