<?php

namespace App\Classes\Modules\Companies\Services;

use App\Classes\General\Eloquent\AbstractUpdateRecord;
use App\Models\Company;

class UpdatesCompanyEInvoiceInfo extends AbstractUpdateRecord
{

    /**
     * @param Company $model
     * @param string $tin
     * @param string $msicCode
     * @return \Illuminate\Database\Eloquent\Model
     * @throws \App\Classes\Exceptions\MalformedRequestException
     */
    public function execute(Company $model, string $tin, string $msicCode)
    {
        $model->tin = $tin;
        $model->msic_code = $msicCode;

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