Logging changes when processing TIC files

This commit is contained in:
2023-09-08 21:11:53 +10:00
parent 6d199345ac
commit 67c1be209d
4 changed files with 10 additions and 10 deletions

View File

@@ -56,7 +56,7 @@ class File extends Model
parent::boot();
static::creating(function($model) {
Log::debug(sprintf('%s:- Storing file [%s] in [%s]',self::LOGKEY,$model->fullname,$model->full_storage_path));
Log::info(sprintf('%s:- Storing file [%s] in [%s]',self::LOGKEY,$model->fullname,$model->full_storage_path));
// Store file
if (Storage::put($model->full_storage_path,Storage::disk('local')->get($model->fullname),'public')) {
@@ -122,11 +122,11 @@ class File extends Model
if ($exportto->count()) {
if ($model->no_export) {
Log::debug(sprintf('%s:- NOT processing exporting of message by configuration [%s] to [%s]',self::LOGKEY,$model->id,$exportto->join(',')));
Log::alert(sprintf('%s:- NOT processing exporting of message by configuration [%s] to [%s]',self::LOGKEY,$model->id,$exportto->join(',')));
return;
}
Log::debug(sprintf('%s:- Exporting file [%s] to [%s]',self::LOGKEY,$model->id,$exportto->join(',')));
Log::info(sprintf('%s:- Exporting file [%s] to [%s]',self::LOGKEY,$model->id,$exportto->join(',')));
// Save the seenby for the exported systems
$model->seenby()->syncWithPivotValues($exportto,['export_at'=>Carbon::now()],FALSE);