diff --git a/app/Http/Transformers/ActionlogsTransformer.php b/app/Http/Transformers/ActionlogsTransformer.php index dcccc92e6c..9198f89d00 100644 --- a/app/Http/Transformers/ActionlogsTransformer.php +++ b/app/Http/Transformers/ActionlogsTransformer.php @@ -171,8 +171,10 @@ class ActionlogsTransformer unset($clean_meta['location_id']); } if(array_key_exists('model_id', $clean_meta)) { + $clean_meta['model_id']['old'] = "[id: ".$clean_meta['model_id']['old']."] ".$model->find($clean_meta['model_id']['old'])->name; $clean_meta['model_id']['new'] = "[id: ".$clean_meta['model_id']['new']."] ".$model->find($clean_meta['model_id']['new'])->name; /* model is required at asset creation */ + $clean_meta['Model'] = $clean_meta['model_id']; unset($clean_meta['model_id']); } @@ -199,4 +201,4 @@ class ActionlogsTransformer -} \ No newline at end of file +} diff --git a/database/migrations/2022_10_25_215520_add_label2_settings.php b/database/migrations/2022_10_25_215520_add_label2_settings.php index 692e8440db..2b07651e67 100644 --- a/database/migrations/2022_10_25_215520_add_label2_settings.php +++ b/database/migrations/2022_10_25_215520_add_label2_settings.php @@ -21,11 +21,7 @@ class AddLabel2Settings extends Migration $table->string('label2_1d_type')->default('default'); $table->string('label2_2d_type')->default('default'); $table->string('label2_2d_target')->default('hardware_id'); - $table->string('label2_fields')->default( - trans('admin/hardware/form.name').'=name;'. - trans('admin/hardware/form.serial').'=serial;'. - trans('admin/hardware/form.model').'=model.name;' - ); + $table->string('label2_fields')->default('name=name;serial=serial;model=model.name;'); }); }