Move fido configuation items into fido namespace. If keeping packets move them into a date aligned subdir
This commit is contained in:
@@ -19,6 +19,8 @@ class File extends Model
|
||||
|
||||
private const LOGKEY = 'MF-';
|
||||
private bool $no_export = FALSE;
|
||||
public string $prefix = '';
|
||||
public string $replaces = '';
|
||||
|
||||
protected $casts = [
|
||||
'kludges' => CollectionOrNull::class,
|
||||
@@ -162,11 +164,31 @@ class File extends Model
|
||||
|
||||
/* ATTRIBUTES */
|
||||
|
||||
/**
|
||||
* Return the relative path to Storage::disk() in the store
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getFullStoragePathAttribute(): string
|
||||
{
|
||||
return sprintf('%04X/%s',$this->filearea_id,$this->name);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the relative path to Storage::disk() in the inbound;
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getRelNameAttribute(): string
|
||||
{
|
||||
return sprintf('%s/%s',config('fido.dir'),$this->prefix_name);
|
||||
}
|
||||
|
||||
public function getPrefixNameAttribute(): string
|
||||
{
|
||||
return sprintf('%s%s',$this->prefix ? $this->prefix.'-' : '',$this->name);
|
||||
}
|
||||
|
||||
/* METHODS */
|
||||
|
||||
public function jsonSerialize(): array
|
||||
|
Reference in New Issue
Block a user