 9a6f1788a4
			
		
	
	9a6f1788a4
	
	
	
		
			
			PHP 5.5.9 adds the new static `class` property which provides the fully qualified class name. This is preferred over using strings for class names since the `class` property references are checked by PHP.
		
			
				
	
	
		
			25 lines
		
	
	
		
			608 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			25 lines
		
	
	
		
			608 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
| <?php
 | |
| 
 | |
| namespace App\Model\helpdesk\Manage;
 | |
| 
 | |
| use App\BaseModel;
 | |
| 
 | |
| class Help_topic extends BaseModel
 | |
| {
 | |
|     protected $table = 'help_topic';
 | |
| 
 | |
|     protected $fillable = [
 | |
|         'id', 'topic', 'parent_topic', 'custom_form', 'department', 'ticket_status', 'priority',
 | |
|         'sla_plan', 'thank_page', 'ticket_num_format', 'internal_notes', 'status', 'type', 'auto_assign',
 | |
|         'auto_response',
 | |
|     ];
 | |
| 
 | |
|     public function department()
 | |
|     {
 | |
|         $related = \App\Model\helpdesk\Agent\Department::class;
 | |
|         $foreignKey = 'department';
 | |
| 
 | |
|         return $this->belongsTo($related, $foreignKey);
 | |
|     }
 | |
| }
 |