Track IP for scheduled report

This commit is contained in:
Hillel Coren 2018-04-12 20:22:42 +03:00
parent 0c95b13693
commit 464e0b95e0
3 changed files with 11 additions and 5 deletions

View File

@ -162,6 +162,7 @@ class ReportController extends BaseController
$schedule->config = json_encode($options);
$schedule->frequency = request('frequency');
$schedule->send_date = Utils::toSqlDate(request('send_date'));
$schedule->ip = request()->getClientIp();
$schedule->save();
session()->flash('message', trans('texts.created_scheduled_report'));

View File

@ -132,6 +132,10 @@ class AddMoreCustomFields extends Migration
$table->text('custom_value2')->nullable()->change();
});
Schema::table('scheduled_reports', function ($table) {
$table->string('ip')->nullable();
});
}
/**

File diff suppressed because one or more lines are too long