@@ -6,5 +6,5 @@ |
||
6 | 6 | class SdLocations extends Model |
7 | 7 | { |
8 | 8 | protected $table = 'sd_locations'; |
9 | - protected $fillable = ['id','location_category_id','title','email','phone','address','all_department_access','departments','status','created_at','updated_at']; |
|
9 | + protected $fillable = ['id', 'location_category_id', 'title', 'email', 'phone', 'address', 'all_department_access', 'departments', 'status', 'created_at', 'updated_at']; |
|
10 | 10 | } |
11 | 11 | \ No newline at end of file |
@@ -7,5 +7,5 @@ |
||
7 | 7 | { |
8 | 8 | protected $table = 'sd_release_priorities'; |
9 | 9 | |
10 | - protected $fillable = ['id','name','created_at','updated_at']; |
|
10 | + protected $fillable = ['id','name','created_at','updated_at']; |
|
11 | 11 | } |
12 | 12 | \ No newline at end of file |
@@ -7,5 +7,5 @@ |
||
7 | 7 | { |
8 | 8 | protected $table = 'sd_release_priorities'; |
9 | 9 | |
10 | - protected $fillable = ['id','name','created_at','updated_at']; |
|
10 | + protected $fillable = ['id', 'name', 'created_at', 'updated_at']; |
|
11 | 11 | } |
12 | 12 | \ No newline at end of file |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | $attrs = $this->locationRelation()->first(); |
51 | 51 | |
52 | 52 | if ($attrs) { |
53 | - $value = "<a href=" . url('service-desk/location-types/' . $attr . '/show') . ">$attrs->title</a>"; |
|
53 | + $value = "<a href=".url('service-desk/location-types/'.$attr.'/show').">$attrs->title</a>"; |
|
54 | 54 | } |
55 | 55 | } |
56 | 56 | return ucfirst($value); |
@@ -123,7 +123,7 @@ discard block |
||
123 | 123 | $value = str_limit($attr, 10); |
124 | 124 | } |
125 | 125 | if (strlen($value) > 10) { |
126 | - $value .=" <a href=# id='show-description'>Show</a>"; |
|
126 | + $value .= " <a href=# id='show-description'>Show</a>"; |
|
127 | 127 | } |
128 | 128 | return ucfirst($value); |
129 | 129 | } |
@@ -161,8 +161,8 @@ discard block |
||
161 | 161 | foreach ($ids as $id) { |
162 | 162 | $ass = $asset->find($id); |
163 | 163 | if ($ass) { |
164 | - $value = "<a href=" . url('service-desk/assets/' . $id . '/show') . ">" . ucfirst($ass->name) . "</a>"; |
|
165 | - $assets .=$value . "</br>"; |
|
164 | + $value = "<a href=".url('service-desk/assets/'.$id.'/show').">".ucfirst($ass->name)."</a>"; |
|
165 | + $assets .= $value."</br>"; |
|
166 | 166 | } |
167 | 167 | } |
168 | 168 | } |
@@ -218,7 +218,7 @@ discard block |
||
218 | 218 | public function subject() { |
219 | 219 | $id = $this->attributes['id']; |
220 | 220 | $title = $this->attributes['subject']; |
221 | - $subject = "<a href=" . url('service-desk/releases/' . $id . '/show') . ">" . $title . "</a>"; |
|
221 | + $subject = "<a href=".url('service-desk/releases/'.$id.'/show').">".$title."</a>"; |
|
222 | 222 | return $subject; |
223 | 223 | } |
224 | 224 |
@@ -7,5 +7,5 @@ |
||
7 | 7 | { |
8 | 8 | protected $table = 'sd_release_types'; |
9 | 9 | |
10 | - protected $fillable = ['id','name','created_at','updated_at']; |
|
10 | + protected $fillable = ['id','name','created_at','updated_at']; |
|
11 | 11 | } |
12 | 12 | \ No newline at end of file |
@@ -7,5 +7,5 @@ |
||
7 | 7 | { |
8 | 8 | protected $table = 'sd_release_types'; |
9 | 9 | |
10 | - protected $fillable = ['id','name','created_at','updated_at']; |
|
10 | + protected $fillable = ['id', 'name', 'created_at', 'updated_at']; |
|
11 | 11 | } |
12 | 12 | \ No newline at end of file |
@@ -5,7 +5,7 @@ |
||
5 | 5 | class GeneralInfo extends Model |
6 | 6 | { |
7 | 7 | protected $table = 'sd_gerneral'; |
8 | - protected $fillable = ['owner','key','value']; |
|
8 | + protected $fillable = ['owner', 'key', 'value']; |
|
9 | 9 | |
10 | 10 | |
11 | 11 | } |
12 | 12 | \ No newline at end of file |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | |
13 | 13 | public function getTicketRelation($table) { |
14 | 14 | //dd($table); |
15 | - $relation = $this->ticketRelation()->where('owner', 'LIKE', $table . "%")->first(); |
|
15 | + $relation = $this->ticketRelation()->where('owner', 'LIKE', $table."%")->first(); |
|
16 | 16 | if ($relation) { |
17 | 17 | |
18 | 18 | $owner = $relation->owner; |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | $id = $this->attributes['id']; |
67 | 67 | if ($thread) { |
68 | 68 | $title = $thread->title; |
69 | - $subject = "<a href=" . url('thread/' . $id) . ">" . $title . "</a>"; |
|
69 | + $subject = "<a href=".url('thread/'.$id).">".$title."</a>"; |
|
70 | 70 | } |
71 | 71 | return $subject; |
72 | 72 | } |
@@ -5,6 +5,6 @@ |
||
5 | 5 | class TicketRelation extends Model |
6 | 6 | { |
7 | 7 | protected $table = 'sd_ticket_relation'; |
8 | - protected $fillable = ['ticket_id','owner']; |
|
8 | + protected $fillable = ['ticket_id', 'owner']; |
|
9 | 9 | |
10 | 10 | } |
11 | 11 | \ No newline at end of file |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | class Location extends Model |
10 | 10 | { |
11 | 11 | protected $table = 'sd_locations'; |
12 | - protected $fillable = ['id','name','created_at','updated_at', |
|
12 | + protected $fillable = ['id', 'name', 'created_at', 'updated_at', |
|
13 | 13 | |
14 | 14 | ]; |
15 | 15 | |
@@ -32,11 +32,11 @@ discard block |
||
32 | 32 | return ucfirst($value); |
33 | 33 | } |
34 | 34 | |
35 | - public function category(){ |
|
36 | - return $this->belongsTo('App\Itil\Models\Changes\SdLocationcategories',"location_category_id"); |
|
35 | + public function category() { |
|
36 | + return $this->belongsTo('App\Itil\Models\Changes\SdLocationcategories', "location_category_id"); |
|
37 | 37 | } |
38 | 38 | |
39 | - public function locationCategory(){ |
|
39 | + public function locationCategory() { |
|
40 | 40 | $value = "--"; |
41 | 41 | $attr = $this->attributes['location_category_id']; |
42 | 42 | if ($attr) { |
@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | $orgs = $this->getOrganizationRelation()->first(); |
70 | 70 | if ($orgs) { |
71 | 71 | $id = $orgs->id; |
72 | - $name = "<a href=" . url('organizations/' . $id) . ">" . ucfirst($org) . "</a>"; |
|
72 | + $name = "<a href=".url('organizations/'.$id).">".ucfirst($org)."</a>"; |
|
73 | 73 | } |
74 | 74 | } |
75 | 75 | return $name; |
@@ -13,22 +13,22 @@ |
||
13 | 13 | 'aproval_mandatory', |
14 | 14 | ]; |
15 | 15 | |
16 | - public function setApproversAttribute($value){ |
|
17 | - if($value){ |
|
16 | + public function setApproversAttribute($value) { |
|
17 | + if ($value) { |
|
18 | 18 | $this->attributes['approvers'] = implode(',', $value); |
19 | 19 | } |
20 | 20 | } |
21 | 21 | |
22 | - public function getApproversAttribute($value){ |
|
23 | - if($value){ |
|
22 | + public function getApproversAttribute($value) { |
|
23 | + if ($value) { |
|
24 | 24 | return explode(',', $value); |
25 | 25 | } |
26 | 26 | } |
27 | 27 | |
28 | - public function setHeadAttribute($value){ |
|
29 | - if($value==""){ |
|
28 | + public function setHeadAttribute($value) { |
|
29 | + if ($value == "") { |
|
30 | 30 | $this->attributes['head'] = NULL; |
31 | - }else{ |
|
31 | + } else { |
|
32 | 32 | $this->attributes['head'] = $value; |
33 | 33 | } |
34 | 34 | } |
@@ -28,7 +28,7 @@ |
||
28 | 28 | public function setHeadAttribute($value){ |
29 | 29 | if($value==""){ |
30 | 30 | $this->attributes['head'] = NULL; |
31 | - }else{ |
|
31 | + } else{ |
|
32 | 32 | $this->attributes['head'] = $value; |
33 | 33 | } |
34 | 34 | } |