Sindbad~EG File Manager

Current Path : /home/copmadinaarea/creditunion.copeastlegondistrict.org/app/Models/
Upload File :
Current File : /home/copmadinaarea/creditunion.copeastlegondistrict.org/app/Models/Guarantor.php

<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class Guarantor extends Model {
    /**
     * The table associated with the model.
     *
     * @var string
     */
    protected $table = 'guarantors';

    public function member() {
        return $this->belongsTo('App\Models\Member', 'member_id')->withDefault();
    }

    public function loan() {
        return $this->belongsTo('App\Models\Loan', 'loan_id')->withDefault();
    }

    public function getCreatedAtAttribute($value) {
        $date_format = get_date_format();
        $time_format = get_time_format();
        return \Carbon\Carbon::parse($value)->format("$date_format $time_format");
    }

    public function getUpdatedAtAttribute($value) {
        $date_format = get_date_format();
        $time_format = get_time_format();
        return \Carbon\Carbon::parse($value)->format("$date_format $time_format");
    }
}

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists