/home/mip/mip/app/Modules/Client/Models/Participants/Participant.php
<?php

namespace QxCMS\Modules\Client\Models\Participants;

use Illuminate\Database\Eloquent\Model;
use Collective\Html\Eloquent\FormAccessible;
use \Carbon\Carbon;
class Participant extends Model
{
    use FormAccessible;

    protected $connection = 'client';

    protected $table = 'survey_participants';
    
    //public $module_id = 6;

    /*
    * The attributes that are mass assignable.
    *
    * @var array
    */
    protected $guarded = [];

    protected $appends = ['hashid'];
   

    public function getHashidAttribute()
    {
        return hashid($this->id);
    }


    /*
    * Model Custom Functions
    */
    public function answers()
    {
        return $this->hasMany('QxCMS\Modules\Client\Models\Participants\Answer', 'participant_id');
    }
/*

    public function template()
    {
        return $this->belongsTo('QxCMS\Modules\Client\Models\Questionnaire\Template', 'template_id');
    }

    public function fieldOfficer()
    {
        return $this->belongsTo('QxCMS\Modules\Likod\Models\Clients\User', 'field_officer_assigned');
    }

    public function editor()
    {
        return $this->belongsTo('QxCMS\Modules\Likod\Models\Clients\User', 'editor_assigned');
    }*/
}