Completed
Push — master ( bcb82e...80085e )
by vijay
07:39
created
app/Plugins/ServiceDesk/Requests/CreateLocationRequest.php 1 patch
Indentation   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -5,25 +5,25 @@  discard block
 block discarded – undo
5 5
 
6 6
 class CreateLocationRequest extends Request {
7 7
 
8
-	/**
9
-	 * Determine if the user is authorized to make this request.
10
-	 *
11
-	 * @return bool
12
-	 */
13
-	public function authorize()
14
-	{
15
-		return true;
16
-	}
8
+    /**
9
+     * Determine if the user is authorized to make this request.
10
+     *
11
+     * @return bool
12
+     */
13
+    public function authorize()
14
+    {
15
+        return true;
16
+    }
17 17
 
18
-	/**
19
-	 * Get the validation rules that apply to the request.
20
-	 *
21
-	 * @return array
22
-	 */
23
-	public function rules()
24
-	{
25
-		return [
26
-			//
18
+    /**
19
+     * Get the validation rules that apply to the request.
20
+     *
21
+     * @return array
22
+     */
23
+    public function rules()
24
+    {
25
+        return [
26
+            //
27 27
             'title' =>'required',
28 28
             'email' =>'required',
29 29
             'phone' =>'required',
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
             'department' =>'required',
33 33
            
34 34
           
35
-		];
36
-	}
35
+        ];
36
+    }
37 37
 
38 38
 }
39 39
\ No newline at end of file
Please login to merge, or discard this patch.
app/Plugins/ServiceDesk/Requests/CreateProductsRequest.php 1 patch
Indentation   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -5,36 +5,36 @@
 block discarded – undo
5 5
 
6 6
 class CreateProductsRequest extends Request {
7 7
 
8
-	/**
9
-	 * Determine if the user is authorized to make this request.
10
-	 *
11
-	 * @return bool
12
-	 */
13
-	public function authorize()
14
-	{
15
-		return true;
16
-	}
8
+    /**
9
+     * Determine if the user is authorized to make this request.
10
+     *
11
+     * @return bool
12
+     */
13
+    public function authorize()
14
+    {
15
+        return true;
16
+    }
17 17
 
18
-	/**
19
-	 * Get the validation rules that apply to the request.
20
-	 *
21
-	 * @return array
22
-	 */
23
-	public function rules()
24
-	{
25
-		return [
26
-			//
18
+    /**
19
+     * Get the validation rules that apply to the request.
20
+     *
21
+     * @return array
22
+     */
23
+    public function rules()
24
+    {
25
+        return [
26
+            //
27 27
             'name' => 'required',
28 28
             //'asset_type' => 'required',
29 29
             'manufacturer'=>'required',
30 30
             'Product_status'=>'required',
31 31
             'mode_procurement'=>'required',
32
-           	'department_access'=>'required',
33
-           'description'=>'required',
34
-           	'status'=>'required',
32
+                'department_access'=>'required',
33
+            'description'=>'required',
34
+                'status'=>'required',
35 35
            
36 36
 
37
-		];
38
-	}
37
+        ];
38
+    }
39 39
 
40 40
 }
41 41
\ No newline at end of file
Please login to merge, or discard this patch.
app/Plugins/ServiceDesk/Requests/CreateContractRequest.php 1 patch
Indentation   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -23,10 +23,10 @@  discard block
 block discarded – undo
23 23
     public function rules() {
24 24
         return [
25 25
 
26
-             'name' => 'required',
27
-             'description' => 'required',
28
-             'contract_type_id' => 'required',
29
-             'product_id' => 'required',
26
+                'name' => 'required',
27
+                'description' => 'required',
28
+                'contract_type_id' => 'required',
29
+                'product_id' => 'required',
30 30
              
31 31
         ];
32 32
     }
@@ -34,18 +34,18 @@  discard block
 block discarded – undo
34 34
     public function messages() {
35 35
         return [
36 36
 
37
-             "name.required" => "Name Required",
38
-             "description.required" => "Description Required",
39
-             "cost.required" => "Cost Required",
40
-             "contract_type_id.required" => "Contract Type Required",
41
-             "approver_id.required" => "Approver Required",
42
-             "vendor_id.required" => "Vendor Required",
43
-             "license_type_id.required" => "License Type Required",
44
-             "licensce_count.required" => "licensce Count Required",
45
-             "notify_expiry.required" => "Notify Expiry Required",
46
-             "product_id.required" => "Product Required",
47
-             "contract_start_date.required" => "Contract Start Date Required",
48
-             "contract_end_date.required" => "Contract End Date Required",
37
+                "name.required" => "Name Required",
38
+                "description.required" => "Description Required",
39
+                "cost.required" => "Cost Required",
40
+                "contract_type_id.required" => "Contract Type Required",
41
+                "approver_id.required" => "Approver Required",
42
+                "vendor_id.required" => "Vendor Required",
43
+                "license_type_id.required" => "License Type Required",
44
+                "licensce_count.required" => "licensce Count Required",
45
+                "notify_expiry.required" => "Notify Expiry Required",
46
+                "product_id.required" => "Product Required",
47
+                "contract_start_date.required" => "Contract Start Date Required",
48
+                "contract_end_date.required" => "Contract End Date Required",
49 49
         ];
50 50
     }
51 51
 
Please login to merge, or discard this patch.
app/Plugins/ServiceDesk/Requests/CreateLicensetypesRequest.php 1 patch
Indentation   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -5,27 +5,27 @@
 block discarded – undo
5 5
 
6 6
 class CreateLicensetypesRequest extends Request {
7 7
 
8
-	/**
9
-	 * Determine if the user is authorized to make this request.
10
-	 *
11
-	 * @return bool
12
-	 */
13
-	public function authorize()
14
-	{
15
-		return true;
16
-	}
8
+    /**
9
+     * Determine if the user is authorized to make this request.
10
+     *
11
+     * @return bool
12
+     */
13
+    public function authorize()
14
+    {
15
+        return true;
16
+    }
17 17
 
18
-	/**
19
-	 * Get the validation rules that apply to the request.
20
-	 *
21
-	 * @return array
22
-	 */
23
-	public function rules()
24
-	{
18
+    /**
19
+     * Get the validation rules that apply to the request.
20
+     *
21
+     * @return array
22
+     */
23
+    public function rules()
24
+    {
25 25
             $id = $this->segment(3);
26
-		return [
26
+        return [
27 27
                     'name' =>'required|unique:sd_license_types,name,'.$id
28
-		];
29
-	}
28
+        ];
29
+    }
30 30
 
31 31
 }
32 32
\ No newline at end of file
Please login to merge, or discard this patch.
app/Plugins/ServiceDesk/Requests/CreateLocationcatagoryRequest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
     public function rules() {
24 24
         $id = $this->segment(3);
25 25
         return [
26
-            'name' => 'required|unique:sd_location_categories,name,' . $id
26
+            'name' => 'required|unique:sd_location_categories,name,'.$id
27 27
         ];
28 28
     }
29 29
 
Please login to merge, or discard this patch.
app/Plugins/ServiceDesk/Requests/CreateVendorRequest.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
     public function rules() {
24 24
         return [
25 25
 
26
-             'name' => 'required',
26
+                'name' => 'required',
27 27
             'primary_contact' => 'required',
28 28
             'email' => 'required',
29 29
 //            'description' => 'required',
Please login to merge, or discard this patch.
app/Plugins/ServiceDesk/Controllers/Contract/ContractController.php 2 patches
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -27,12 +27,12 @@  discard block
 block discarded – undo
27 27
             return \Datatable::Collection($contracts)
28 28
                             ->showColumns('name', 'cost')
29 29
                             ->addColumn('action', function($model) {
30
-                                $url = url('service-desk/contracts/' . $model->id . '/delete');
30
+                                $url = url('service-desk/contracts/'.$model->id.'/delete');
31 31
                                 $delete = \App\Plugins\ServiceDesk\Controllers\Library\UtilityController::deletePopUp($model->id, $url, "Delete $model->subject");
32 32
                                 
33
-                                return "<a href=" . url('service-desk/contracts/' . $model->id . '/edit') . " class='btn btn-info btn-sm'>Edit</a> "
33
+                                return "<a href=".url('service-desk/contracts/'.$model->id.'/edit')." class='btn btn-info btn-sm'>Edit</a> "
34 34
                                         . $delete
35
-                                        . " <a href=" . url('service-desk/contracts/' . $model->id . '/show') . " class='btn btn-primary btn-sm'>View</a>";
35
+                                        . " <a href=".url('service-desk/contracts/'.$model->id.'/show')." class='btn btn-primary btn-sm'>View</a>";
36 36
                             })
37 37
                             ->searchColumns('name')
38 38
                             ->orderColumns('name', 'description', 'cost', 'contract_type_id', 'vendor_id', 'license_type_id', 'licensce_count', 'product_id', 'notify_expiry', 'contract_start_date')
@@ -87,10 +87,10 @@  discard block
 block discarded – undo
87 87
         $license_type_ids = License::lists('name', 'id')->toArray();
88 88
         $approvers = Cab::lists('name', 'id')->toArray();
89 89
         $vendor_ids = Vendors::lists('name', 'id')->toArray();
90
-        return view('service::contract.edit', compact('contract','contract_type_ids', 'approvers', 'product_ids', 'license_type_ids', 'vendor_ids'));
90
+        return view('service::contract.edit', compact('contract', 'contract_type_ids', 'approvers', 'product_ids', 'license_type_ids', 'vendor_ids'));
91 91
     }
92 92
 
93
-    public function handleEdit($id,CreateContractRequest $request) {
93
+    public function handleEdit($id, CreateContractRequest $request) {
94 94
        
95 95
         $sd_contracts = SdContract::findOrFail($id);
96 96
         $sd_contracts->name = $request->name;
@@ -110,21 +110,21 @@  discard block
 block discarded – undo
110 110
         \App\Plugins\ServiceDesk\Controllers\Library\UtilityController::attachment($sd_contracts->id, 'sd_contracts', $request->file('attachments'));
111 111
         return \Redirect::route('service-desk.contract.index')->with('message', 'Contract successfully edit !!!');
112 112
     }
113
-    public function sendCab($id,$cabid){
114
-        $activity='sd_contracts';
113
+    public function sendCab($id, $cabid) {
114
+        $activity = 'sd_contracts';
115 115
         $owner = "$activity:$id";
116 116
         $url = url("service-desk/cabs/vote/$cabid/$owner");
117 117
         //dd($url);
118 118
         \App\Plugins\ServiceDesk\Controllers\Library\UtilityController::cabMessage($cabid, $activity, $url);
119 119
         
120 120
     }
121
-    public function show($id){
122
-        try{
121
+    public function show($id) {
122
+        try {
123 123
             $contracts = new SdContract();
124 124
             $contract = $contracts->find($id);
125
-            if($contract){
126
-                return view('service::contract.show',  compact('contract'));
127
-            }else{
125
+            if ($contract) {
126
+                return view('service::contract.show', compact('contract'));
127
+            } else {
128 128
                 throw new \Exception('Sorry we can not find your request');
129 129
             }
130 130
         } catch (Exception $ex) {
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -124,7 +124,7 @@
 block discarded – undo
124 124
             $contract = $contracts->find($id);
125 125
             if($contract){
126 126
                 return view('service::contract.show',  compact('contract'));
127
-            }else{
127
+            } else{
128 128
                 throw new \Exception('Sorry we can not find your request');
129 129
             }
130 130
         } catch (Exception $ex) {
Please login to merge, or discard this patch.
Plugins/ServiceDesk/Controllers/Contracttypes/ContracttypeController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
             return \Datatable::Collection($contract_type)
25 25
                             ->showColumns('name', 'created_at', 'updated_at')
26 26
                             ->addColumn('action', function($model) {
27
-                                return "<a href=" . url('service-desk/contract-types/' . $model->id . '/edit') . " class='btn btn-info btn-xs'>Edit</a>";
27
+                                return "<a href=".url('service-desk/contract-types/'.$model->id.'/edit')." class='btn btn-info btn-xs'>Edit</a>";
28 28
                             })
29 29
                             ->searchColumns('name', 'created_at', 'updated_at')
30 30
                             ->orderColumns('name', 'created_at', 'updated_at')
Please login to merge, or discard this patch.
app/Plugins/ServiceDesk/Controllers/Procurment/ProcurmentController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
             return \Datatable::Collection($procurments)
29 29
                             ->showColumns('name')
30 30
                             ->addColumn('Action', function($model) {
31
-                                return "<a href=" . url('service-desk/procurement/' . $model->id . '/edit') . " class='btn btn-info btn-xs'>Edit</a> ";
31
+                                return "<a href=".url('service-desk/procurement/'.$model->id.'/edit')." class='btn btn-info btn-xs'>Edit</a> ";
32 32
                                 //. "<a href=" . url('service-desk/procurement/' . $model->id . '/delete') . " class='btn btn-warning btn-xs btn-flat'>Delete</a>";
33 33
                             })
34 34
                             ->searchColumns('name')
Please login to merge, or discard this patch.