@@ -5,6 +5,6 @@ |
||
5 | 5 | class ProductVendorRelation extends Model |
6 | 6 | { |
7 | 7 | protected $table = 'sd_product_vendor_relation'; |
8 | - protected $fillable = ['product_id','vendor_id']; |
|
8 | + protected $fillable = ['product_id', 'vendor_id']; |
|
9 | 9 | |
10 | 10 | } |
11 | 11 | \ No newline at end of file |
@@ -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 |
@@ -5,5 +5,5 @@ |
||
5 | 5 | class Attachments extends Model |
6 | 6 | { |
7 | 7 | protected $table = 'sd_attachments'; |
8 | - protected $fillable = ['saved','owner','value','type','size']; |
|
8 | + protected $fillable = ['saved', 'owner', 'value', 'type', 'size']; |
|
9 | 9 | } |
10 | 10 | \ No newline at end of file |
@@ -5,11 +5,11 @@ |
||
5 | 5 | class AssetRelation extends Model |
6 | 6 | { |
7 | 7 | protected $table = 'sd_asset_relations'; |
8 | - protected $fillable = ['asset_ids','owner']; |
|
8 | + protected $fillable = ['asset_ids', 'owner']; |
|
9 | 9 | |
10 | - public function getAssetIdsAttribute($value){ |
|
11 | - if($value){ |
|
12 | - $value = explode(',', $value); |
|
10 | + public function getAssetIdsAttribute($value) { |
|
11 | + if ($value) { |
|
12 | + $value = explode(',', $value); |
|
13 | 13 | } |
14 | 14 | return $value; |
15 | 15 | } |
@@ -6,7 +6,7 @@ |
||
6 | 6 | class Department extends Model |
7 | 7 | { |
8 | 8 | protected $table = 'department'; |
9 | - protected $fillable = ['id','name','type','sla','manager','ticket_assignment','outgoing_email','template_set','auto_ticket_response', |
|
10 | - 'auto_message_response','auto_response_email','recipient','group_access','department_sign','created_at','updated_at']; |
|
9 | + protected $fillable = ['id', 'name', 'type', 'sla', 'manager', 'ticket_assignment', 'outgoing_email', 'template_set', 'auto_ticket_response', |
|
10 | + 'auto_message_response', 'auto_response_email', 'recipient', 'group_access', 'department_sign', 'created_at', 'updated_at']; |
|
11 | 11 | } |
12 | 12 |
@@ -6,5 +6,5 @@ |
||
6 | 6 | class SdImpactypes extends Model |
7 | 7 | { |
8 | 8 | protected $table = 'sd_impact_types'; |
9 | - protected $fillable = ['id','name','created_at','updated_at']; |
|
9 | + protected $fillable = ['id', 'name', 'created_at', 'updated_at']; |
|
10 | 10 | } |
@@ -7,7 +7,7 @@ discard block |
||
7 | 7 | class SdLocations extends Model |
8 | 8 | { |
9 | 9 | protected $table = 'sd_locations'; |
10 | - protected $fillable = ['id','location_category_id','title','email','phone','address','departments','status','organization']; |
|
10 | + protected $fillable = ['id', 'location_category_id', 'title', 'email', 'phone', 'address', 'departments', 'status', 'organization']; |
|
11 | 11 | |
12 | 12 | public function departmentRelation() { |
13 | 13 | return $this->belongsTo('App\Model\helpdesk\Agent\Department', 'departments'); |
@@ -29,11 +29,11 @@ discard block |
||
29 | 29 | return ucfirst($value); |
30 | 30 | } |
31 | 31 | |
32 | - public function category(){ |
|
33 | - return $this->belongsTo('App\Plugins\ServiceDesk\Model\Changes\SdLocationcategories',"location_category_id"); |
|
32 | + public function category() { |
|
33 | + return $this->belongsTo('App\Plugins\ServiceDesk\Model\Changes\SdLocationcategories', "location_category_id"); |
|
34 | 34 | } |
35 | 35 | |
36 | - public function locationCategory(){ |
|
36 | + public function locationCategory() { |
|
37 | 37 | $value = "--"; |
38 | 38 | $attr = $this->attributes['location_category_id']; |
39 | 39 | if ($attr) { |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | $orgs = $this->getOrganizationRelation()->first(); |
69 | 69 | if ($orgs) { |
70 | 70 | $id = $orgs->id; |
71 | - $name = "<a href=" . url('organizations/' . $id) . ">" . ucfirst($org) . "</a>"; |
|
71 | + $name = "<a href=".url('organizations/'.$id).">".ucfirst($org)."</a>"; |
|
72 | 72 | } |
73 | 73 | } |
74 | 74 | return $name; |
@@ -6,5 +6,5 @@ |
||
6 | 6 | class SdAssettypes extends Model |
7 | 7 | { |
8 | 8 | protected $table = 'sd_asset_types'; |
9 | - protected $fillable = ['id','name','parent_id','created_at','updated_at']; |
|
9 | + protected $fillable = ['id', 'name', 'parent_id', 'created_at', 'updated_at']; |
|
10 | 10 | } |
@@ -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 | } |