use parent qw(SL::BackgroundJob::Base);
use YAML ();
+use SL::JSON;
use SL::DB::CsvImportProfile;
use SL::SessionFile::Random;
my $job = $self->{db_obj};
$c->profile($self->profile);
+ $c->mappings(SL::JSON::from_json($self->profile->get('json_mappings'))) if $self->profile->get('json_mappings');
$c->type($job->data_as_hash->{type});
$c->{employee_id} = $job->data_as_hash->{employee_id};
$result = $::locale->text('Import finished with errors.');
} else {
- my $report_id = $c->save_report(session_id => $session_id);
+ my $report_id = $c->save_report(session_id => $session_id, test => $test);
$job->set_data(report_id => $report_id)->save;
$c->track_progress(finished => 1);