<?php

namespace App\Classes\Modules\Companies\Services;

use App\Classes\General\Eloquent\AbstractUpdateRecord;
use App\Classes\ValueObjects\Constants\ApprovalStatus;
use App\Models\CompanyConnection;
use App\Models\Document;
use Carbon\Carbon;

class ApprovesCompanyConnection extends AbstractUpdateRecord
{

    /**
     * @param CompanyConnection $model
     * @return \Illuminate\Database\Eloquent\Model
     * @throws \App\Classes\Exceptions\MalformedRequestException
     */
    public function execute(CompanyConnection $model)
    {
        $model->status = ApprovalStatus::APPROVED;

        return $this->handler($model);
    }
}