Initial commit

This commit is contained in:
2026-09-03 12:21:17 +02:00
commit 6d40da0410
155 changed files with 21554 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
/**
* Załącznik wyposażenia (legacy seg_equipments_files) - plik trzymany jako BLOB
* w bazie (EQF_FILE mediumblob). Rola pliku wynika z prefiksu MIME:
* 'image/*' = zdjęcie, pozostałe (np. 'application/pdf') = dokumentacja.
*/
class EquipmentFile extends Model
{
protected $connection = 'softspm';
protected $table = 'seg_equipments_files';
protected $primaryKey = 'EQF_ID';
public $timestamps = false;
protected $guarded = [];
/** Czy to plik graficzny (zdjęcie). */
public function isImage(): bool
{
return str_starts_with(strtolower((string) $this->EQF_FILE_TYPE), 'image/');
}
}