Passed
Push — master ( aeed11...c6540d )
by William
03:07
created
dashboard/application/controllers/computing-support/Room_move.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
                 $this->load->view('computing-support/room-move/complete');
53 53
                 $this->load->view('templates/footer');
54 54
                 
55
-                if ($furniture == "No Furniture"){
55
+                if ($furniture == "No Furniture") {
56 56
 
57 57
                     $to_add = array('[email protected]', '[email protected]', '[email protected]');
58 58
                     
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
                 $staff_involved_un6 = $user_un6;
166 166
                 $staff_involved_email6 = $this->room_move_model->get_email_username($staff_involved_un6);
167 167
                 
168
-                $staff_involved_un7= $user_un7;
168
+                $staff_involved_un7 = $user_un7;
169 169
                 $staff_involved_email7 = $this->room_move_model->get_email_username($staff_involved_un7);
170 170
                 
171 171
                 $staff_involved_un8 = $user_un8;
@@ -256,7 +256,7 @@  discard block
 block discarded – undo
256 256
                 $id = $_GET['id'];
257 257
                 $this->room_move_model->cancel($id);
258 258
 
259
-                $function = 'room_move_CANCEL_' . $id;
259
+                $function = 'room_move_CANCEL_'.$id;
260 260
                 $this->user_model->function_log($function);
261 261
                 
262 262
                 $get_request = $this->room_move_model->get_request($id);
@@ -282,7 +282,7 @@  discard block
 block discarded – undo
282 282
                 $staff_involved_un6 = $get_request[0]['staff_involved_un6'];
283 283
                 $staff_involved_email6 = $this->room_move_model->get_email_username($staff_involved_un6);
284 284
                 
285
-                $staff_involved_un7= $get_request[0]['staff_involved_un7'];
285
+                $staff_involved_un7 = $get_request[0]['staff_involved_un7'];
286 286
                 $staff_involved_email7 = $this->room_move_model->get_email_username($staff_involved_un7);
287 287
                 
288 288
                 $staff_involved_un8 = $get_request[0]['staff_involved_un8'];
@@ -328,7 +328,7 @@  discard block
 block discarded – undo
328 328
                 $id = $_GET['id'];
329 329
                 $this->room_move_model->eh_reject($id);
330 330
 
331
-                $function = 'room_move_EH_REJECT_' . $id;
331
+                $function = 'room_move_EH_REJECT_'.$id;
332 332
                 $this->user_model->function_log($function);
333 333
                 
334 334
                 $get_request = $this->room_move_model->get_request($id);
@@ -354,7 +354,7 @@  discard block
 block discarded – undo
354 354
                 $staff_involved_un6 = $get_request[0]['staff_involved_un6'];
355 355
                 $staff_involved_email6 = $this->room_move_model->get_email_username($staff_involved_un6);
356 356
                 
357
-                $staff_involved_un7= $get_request[0]['staff_involved_un7'];
357
+                $staff_involved_un7 = $get_request[0]['staff_involved_un7'];
358 358
                 $staff_involved_email7 = $this->room_move_model->get_email_username($staff_involved_un7);
359 359
                 
360 360
                 $staff_involved_un8 = $get_request[0]['staff_involved_un8'];
@@ -402,7 +402,7 @@  discard block
 block discarded – undo
402 402
                 $id = $_GET['id'];
403 403
                 $this->room_move_model->eh_approve($id);
404 404
 
405
-                $function = 'room_move_EH_APPROVED_' . $id;
405
+                $function = 'room_move_EH_APPROVED_'.$id;
406 406
                 $this->user_model->function_log($function);
407 407
                 
408 408
                 $get_request = $this->room_move_model->get_request($id);
@@ -444,7 +444,7 @@  discard block
 block discarded – undo
444 444
                 $reason = $_GET['reason'];
445 445
                 $this->room_move_model->cs_reject($id);
446 446
 
447
-                $function = 'room_move_CS_REJECT_' . $id;
447
+                $function = 'room_move_CS_REJECT_'.$id;
448 448
                 $this->user_model->function_log($function);
449 449
                 
450 450
                 $get_request = $this->room_move_model->get_request($id);
@@ -470,7 +470,7 @@  discard block
 block discarded – undo
470 470
                 $staff_involved_un6 = $get_request[0]['staff_involved_un6'];
471 471
                 $staff_involved_email6 = $this->room_move_model->get_email_username($staff_involved_un6);
472 472
                 
473
-                $staff_involved_un7= $get_request[0]['staff_involved_un7'];
473
+                $staff_involved_un7 = $get_request[0]['staff_involved_un7'];
474 474
                 $staff_involved_email7 = $this->room_move_model->get_email_username($staff_involved_un7);
475 475
                 
476 476
                 $staff_involved_un8 = $get_request[0]['staff_involved_un8'];
@@ -518,7 +518,7 @@  discard block
 block discarded – undo
518 518
                 $id = $_GET['id'];
519 519
                 $this->room_move_model->cs_approve($id);
520 520
 
521
-                $function = 'room_move_CS_APPROVED_' . $id;
521
+                $function = 'room_move_CS_APPROVED_'.$id;
522 522
                 $this->user_model->function_log($function);
523 523
                 
524 524
                 $get_request = $this->room_move_model->get_request($id);
@@ -544,7 +544,7 @@  discard block
 block discarded – undo
544 544
                 $staff_involved_un6 = $get_request[0]['staff_involved_un6'];
545 545
                 $staff_involved_email6 = $this->room_move_model->get_email_username($staff_involved_un6);
546 546
                 
547
-                $staff_involved_un7= $get_request[0]['staff_involved_un7'];
547
+                $staff_involved_un7 = $get_request[0]['staff_involved_un7'];
548 548
                 $staff_involved_email7 = $this->room_move_model->get_email_username($staff_involved_un7);
549 549
                 
550 550
                 $staff_involved_un8 = $get_request[0]['staff_involved_un8'];
@@ -591,7 +591,7 @@  discard block
 block discarded – undo
591 591
                 $id = $_GET['id'];
592 592
                 $this->room_move_model->cs_complete($id);
593 593
 
594
-                $function = 'room_move_CS_COMPLETE_' . $id;
594
+                $function = 'room_move_CS_COMPLETE_'.$id;
595 595
                 $this->user_model->function_log($function);
596 596
                 
597 597
                 $get_request = $this->room_move_model->get_request($id);
@@ -617,7 +617,7 @@  discard block
 block discarded – undo
617 617
                 $staff_involved_un6 = $get_request[0]['staff_involved_un6'];
618 618
                 $staff_involved_email6 = $this->room_move_model->get_email_username($staff_involved_un6);
619 619
                 
620
-                $staff_involved_un7= $get_request[0]['staff_involved_un7'];
620
+                $staff_involved_un7 = $get_request[0]['staff_involved_un7'];
621 621
                 $staff_involved_email7 = $this->room_move_model->get_email_username($staff_involved_un7);
622 622
                 
623 623
                 $staff_involved_un8 = $get_request[0]['staff_involved_un8'];
Please login to merge, or discard this patch.
dashboard/application/controllers/computing-support/Disposals.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
             $crud = new grocery_CRUD();
73 73
             $crud->set_table('disposals');
74 74
             $crud->set_subject('disposals', 'Disposals');
75
-            $crud->display_as('sn','Serial Number');
75
+            $crud->display_as('sn', 'Serial Number');
76 76
             $crud->unset_columns('id'); 
77 77
             $crud->unset_add();
78 78
             $crud->unset_read();
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
             $crud->set_table('disposals_current');
99 99
             $crud->set_subject('disposals', 'Disposals');
100 100
             $crud->set_primary_key('id');
101
-            $crud->display_as('sn','Serial Number');
101
+            $crud->display_as('sn', 'Serial Number');
102 102
             $crud->unset_columns('id'); 
103 103
             $crud->unset_add();
104 104
             $crud->unset_read();
Please login to merge, or discard this patch.
dashboard/application/controllers/computing-support/Mobile_policy.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
                 $this->email->to($_SESSION['ldap']['email']);
34 34
                 $this->email->subject('Mobile Phone Policy');
35 35
                 $this->email->message(
36
-                       'Name: ' . $_SESSION['ldap']['fll_name']. '
36
+                       'Name: '.$_SESSION['ldap']['fll_name'].'
37 37
                            
38 38
                        Has accepted the Canterbury College mobile phone policy.
39 39
 
@@ -66,11 +66,11 @@  discard block
 block discarded – undo
66 66
                 $this->email->to('[email protected]');
67 67
                 $this->email->subject('Mobile Phone Policy Accepted');
68 68
                 $this->email->message(
69
-                       'Name: ' . $_SESSION['ldap']['full_name'] . '
69
+                       'Name: '.$_SESSION['ldap']['full_name'].'
70 70
                            
71 71
                        Has accepted the Canterbury College mobile phone policy.
72 72
                        
73
-                       ' . date("d/m/Y") . ' ' . date("h:i"));
73
+                       ' . date("d/m/Y").' '.date("h:i"));
74 74
                 $this->email->send();
75 75
                 
76 76
                 $function = 'mobile_policy_accepted';
Please login to merge, or discard this patch.
dashboard/application/controllers/computing-support/Address_book.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -44,11 +44,11 @@
 block discarded – undo
44 44
                 $this->email->from('[email protected]', 'Address Book Update');
45 45
                 $this->email->to('[email protected]');
46 46
                 $this->email->subject('Address Book Update');
47
-                $this->email->message('A global address book update request been made by ' . $_SESSION['ldap']['full_name'] . '
48
-                       Change name to: ' . $name . '
49
-                       Change Faculty to: ' . $faculty[0]['faculty'] . '  
50
-                       Change Department to: ' . $department[0]['subfaculty'] . '  
51
-                       Change Room to : ' . $room . '
47
+                $this->email->message('A global address book update request been made by '.$_SESSION['ldap']['full_name'].'
48
+                       Change name to: ' . $name.'
49
+                       Change Faculty to: ' . $faculty[0]['faculty'].'  
50
+                       Change Department to: ' . $department[0]['subfaculty'].'  
51
+                       Change Room to : ' . $room.'
52 52
                        Change Telephone to : ' . $phone.'
53 53
                        Change Position to : ' . $position);
54 54
 
Please login to merge, or discard this patch.
dashboard/application/models/core/Jobs_model.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
                             !empty($entries[$x]['samaccountname'][0]) &&
38 38
                             !empty($entries[$x]['sn'][0]) &&
39 39
                             !empty($entries[$x]['mail'][0])) {  
40
-                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '. trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
40
+                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '.trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
41 41
                     }
42 42
                 }
43 43
             }
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
                             !empty($entries[$x]['samaccountname'][0]) &&
50 50
                             !empty($entries[$x]['sn'][0]) &&
51 51
                             !empty($entries[$x]['mail'][0])) {
52
-                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '. trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
52
+                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '.trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
53 53
                     }
54 54
                 }
55 55
             }
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
                             !empty($entries[$x]['samaccountname'][0]) &&
62 62
                             !empty($entries[$x]['sn'][0]) &&
63 63
                             !empty($entries[$x]['mail'][0])) {
64
-                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '. trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
64
+                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '.trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
65 65
                     }
66 66
                 }
67 67
             }
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
                             !empty($entries[$x]['samaccountname'][0]) &&
74 74
                             !empty($entries[$x]['sn'][0]) &&
75 75
                             !empty($entries[$x]['mail'][0])) {
76
-                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '. trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
76
+                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '.trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
77 77
                     }
78 78
                 }
79 79
             }
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
                             !empty($entries[$x]['samaccountname'][0]) &&
86 86
                             !empty($entries[$x]['sn'][0]) &&
87 87
                             !empty($entries[$x]['mail'][0])) {
88
-                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '. trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
88
+                        $ad_users[] = array('first_name' => trim($entries[$x]['givenname'][0]), 'last_name' => trim($entries[$x]['sn'][0]), 'full_name' => trim($entries[$x]['givenname'][0]).' '.trim($entries[$x]['sn'][0]), 'username' => trim($entries[$x]['samaccountname'][0]), 'email' => trim($entries[$x]['mail'][0]));
89 89
                     }
90 90
                 }
91 91
             }
Please login to merge, or discard this patch.
dashboard/application/models/User_model.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
 
14 14
         $ldap = ldap_connect($this->config->item('ldapserver'));
15 15
 
16
-        $ldaprdn = $this->config->item('ldapshortdomain') . $username;
16
+        $ldaprdn = $this->config->item('ldapshortdomain').$username;
17 17
 
18 18
         ldap_set_option($ldap, LDAP_OPT_PROTOCOL_VERSION, 3);
19 19
         ldap_set_option($ldap, LDAP_OPT_REFERRALS, 0);
@@ -135,7 +135,7 @@  discard block
 block discarded – undo
135 135
         $two_hour_login = strtotime("-2 hours");
136 136
         $current_timestamp = date("Y-m-d H:i:s", time());
137 137
         $login_count = 1;
138
-        $browser = $this->agent->browser() . ' ' . $this->agent->version();
138
+        $browser = $this->agent->browser().' '.$this->agent->version();
139 139
 
140 140
         if ($query->num_rows() > 0) {
141 141
 
@@ -235,8 +235,8 @@  discard block
 block discarded – undo
235 235
 
236 236
         $iv = mcrypt_create_iv(IV_SIZE, MCRYPT_DEV_URANDOM);
237 237
         $crypt = mcrypt_encrypt(MCRYPT_RIJNDAEL_128, $key, $encrypt_item, MCRYPT_MODE_CBC, $iv);
238
-        $combo = $iv . $crypt;
239
-        $output = base64_encode($iv . $crypt);
238
+        $combo = $iv.$crypt;
239
+        $output = base64_encode($iv.$crypt);
240 240
 
241 241
         return $output;
242 242
     }
Please login to merge, or discard this patch.
dashboard/application/models/marketing/Visitor_model.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
             'last_name' => $this->input->post('last_name'),
13 13
             'email' => $this->input->post('email'),
14 14
             'postcode' => $this->input->post('postcode'),
15
-            'date_birth' => $this->input->post('dob_d') .'/'. $this->input->post('dob_m') .'/'. $this->input->post('dob_y'),
15
+            'date_birth' => $this->input->post('dob_d').'/'.$this->input->post('dob_m').'/'.$this->input->post('dob_y'),
16 16
             'current_school' => $this->input->post('current'),
17 17
             'current_other' => $this->input->post('current_other'),
18 18
             'subject_interest' => implode(', ', $this->input->post('subject')),
Please login to merge, or discard this patch.
dashboard/application/models/computing-support/Room_move_model.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
                     $user_un10 = $user_un10[1];
40 40
                 } else { $user_un10 = NULL; }
41 41
                 
42
-        if ($furniture == "No Furniture"){
42
+        if ($furniture == "No Furniture") {
43 43
             $status = "1";
44 44
         } else {
45 45
             $status = "0";
Please login to merge, or discard this patch.
dashboard/application/models/computing-support/New_account_model.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -9,14 +9,14 @@  discard block
 block discarded – undo
9 9
     public function create($first_name, $last_name, $ern, $position, $faculty, $department, $room, $ext, $con_start, $con_end, $password, $site) {
10 10
 
11 11
         $firstchar = substr($this->input->post('first_name'), 0, 1);
12
-        $builtUsername = strtolower($firstchar) . strtolower($this->input->post('last_name'));
12
+        $builtUsername = strtolower($firstchar).strtolower($this->input->post('last_name'));
13 13
         //check user name is new
14 14
 
15
-        $username = $this->config->item('ldapshortdomain') . $builtUsername;
15
+        $username = $this->config->item('ldapshortdomain').$builtUsername;
16 16
         // specify the LDAP server to connect to
17 17
         $conn = ldap_connect($this->config->item('ldapserver')) or die("Oh no can't create LDAP connection");
18 18
         // bind to the LDAP server specified above
19
-        if (!ldap_bind($conn, $this->config->item('ldapbindun'),"@".$this->config->item('ldapdomain'), $this->config->item('ldapbindpass')))
19
+        if (!ldap_bind($conn, $this->config->item('ldapbindun'), "@".$this->config->item('ldapdomain'), $this->config->item('ldapbindpass')))
20 20
             echo "Invalid credentials.";
21 21
         // Search for user in directory
22 22
         $cred = explode('\\', $username);
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
         $info = ldap_count_entries($conn, $result);
28 28
 
29 29
         if ($info != 0) {
30
-            $builtUsername = $builtUsername . "2";
30
+            $builtUsername = $builtUsername."2";
31 31
         }
32 32
 
33 33
 
@@ -38,17 +38,17 @@  discard block
 block discarded – undo
38 38
         $this->email->message('A new staff account has been requested by yourself
39 39
                       
40 40
         Account Details:
41
-        Name: ' . $this->input->post('first_name') . ' ' . $this->input->post('last_name') . '
42
-        Position: ' . $this->input->post('position') . '
43
-        ERN: ' . $this->input->post('ern') . '
44
-        Faculty: ' . $this->input->post('faculty') . '
45
-        Department: ' . $this->input->post('department') . '
46
-        Room: ' . $this->input->post('room') . '
47
-        Phone: ' . $this->input->post('ext') . '
48
-        Site: ' . $this->input->post('site') . '
41
+        Name: ' . $this->input->post('first_name').' '.$this->input->post('last_name').'
42
+        Position: ' . $this->input->post('position').'
43
+        ERN: ' . $this->input->post('ern').'
44
+        Faculty: ' . $this->input->post('faculty').'
45
+        Department: ' . $this->input->post('department').'
46
+        Room: ' . $this->input->post('room').'
47
+        Phone: ' . $this->input->post('ext').'
48
+        Site: ' . $this->input->post('site').'
49 49
                            
50
-        Username: ' . $builtUsername . '
51
-        Password: ' . $this->input->post('password') . '
50
+        Username: ' . $builtUsername.'
51
+        Password: ' . $this->input->post('password').'
52 52
 
53 53
 
54 54
         If this account was made by mistake please contact Computing Support.
Please login to merge, or discard this patch.