Added the ability to automatically translate documentation content.

This commit is contained in:
2025-02-09 18:58:51 +05:00
parent 25faa3d62b
commit 58a256e1e4
24 changed files with 768 additions and 3 deletions
@@ -0,0 +1,51 @@
<?php declare(strict_types=1);
namespace App\Models;
use App\Enums\Morph;
use App\Enums\ProjectTranslationServiceHashes\Status;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
final class ProjectTranslationServiceHash extends Model
{
use HasFactory;
protected $table = 'project_translation_service_hashes';
/**
* The model's default values for attributes.
*
* @var array
*/
protected $attributes = [
'status' => Status::Waiting,
];
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'language_id',
'field',
'status',
'hash',
'morph_type',
'morph_id',
];
/**
* Get the attributes that should be cast.
*
* @return array<string, string>
*/
protected function casts(): array
{
return [
'status' => Status::class,
'morph_type' => Morph::class,
];
}
}