First set of code for #461

This commit is contained in:
James Cole
2016-12-13 17:21:28 +01:00
parent 8a8279f97a
commit a9e57e1c34
14 changed files with 331 additions and 46 deletions

View File

@@ -36,9 +36,14 @@ class ConfigurationRequest extends Request
public function getConfigurationData(): array
{
return [
'single_user_mode' => intval($this->get('single_user_mode')) === 1,
'must_confirm_account' => intval($this->get('must_confirm_account')) === 1,
'is_demo_site' => intval($this->get('is_demo_site')) === 1,
'single_user_mode' => intval($this->get('single_user_mode')) === 1,
'must_confirm_account' => intval($this->get('must_confirm_account')) === 1,
'is_demo_site' => intval($this->get('is_demo_site')) === 1,
'mail_for_lockout' => intval($this->get('mail_for_lockout')) === 1,
'mail_for_blocked_domain' => intval($this->get('mail_for_blocked_domain')) === 1,
'mail_for_blocked_email' => intval($this->get('mail_for_blocked_email')) === 1,
'mail_for_bad_login' => intval($this->get('mail_for_bad_login')) === 1,
'mail_for_blocked_login' => intval($this->get('mail_for_blocked_login')) === 1,
];
}
@@ -48,9 +53,14 @@ class ConfigurationRequest extends Request
public function rules()
{
$rules = [
'single_user_mode' => 'between:0,1|numeric',
'must_confirm_account' => 'between:0,1|numeric',
'is_demo_site' => 'between:0,1|numeric',
'single_user_mode' => 'between:0,1|numeric',
'must_confirm_account' => 'between:0,1|numeric',
'is_demo_site' => 'between:0,1|numeric',
'mail_for_lockout' => 'between:0,1|numeric',
'mail_for_blocked_domain' => 'between:0,1|numeric',
'mail_for_blocked_email' => 'between:0,1|numeric',
'mail_for_bad_login' => 'between:0,1|numeric',
'mail_for_blocked_login' => 'between:0,1|numeric',
];
return $rules;