mirror of
https://github.com/getnamingo/registry.git
synced 2025-08-12 04:19:25 +02:00
Small fixes
This commit is contained in:
parent
001b348087
commit
f5dfe87ed5
1 changed files with 4 additions and 9 deletions
|
@ -418,6 +418,7 @@ class RegistrarsController extends Controller
|
||||||
$db = $this->container->get('db');
|
$db = $this->container->get('db');
|
||||||
$registrar = $data['reg_clid'] ?? null;
|
$registrar = $data['reg_clid'] ?? null;
|
||||||
|
|
||||||
|
$data['ipAddress'] = array_filter($data['ipAddress']);
|
||||||
$iso3166 = new ISO3166();
|
$iso3166 = new ISO3166();
|
||||||
$countries = $iso3166->all();
|
$countries = $iso3166->all();
|
||||||
|
|
||||||
|
@ -460,15 +461,9 @@ class RegistrarsController extends Controller
|
||||||
'url' => v::url(),
|
'url' => v::url(),
|
||||||
'abuseEmail' => v::email(),
|
'abuseEmail' => v::email(),
|
||||||
'abusePhone' => v::optional($phoneValidator),
|
'abusePhone' => v::optional($phoneValidator),
|
||||||
'accountBalance' => v::numericVal(),
|
|
||||||
'creditLimit' => v::numericVal(),
|
'creditLimit' => v::numericVal(),
|
||||||
'creditThreshold' => v::numericVal(),
|
'creditThreshold' => v::numericVal(),
|
||||||
'thresholdType' => v::in(['fixed', 'percent']),
|
'ipAddress' => v::optional($ipAddressValidator)
|
||||||
'ipAddress' => v::optional($ipAddressValidator),
|
|
||||||
'user_name' => v::stringType()->notEmpty()->length(1, 255),
|
|
||||||
'user_email' => v::email(),
|
|
||||||
'eppPassword' => v::stringType()->notEmpty(),
|
|
||||||
'panelPassword' => v::stringType()->notEmpty(),
|
|
||||||
];
|
];
|
||||||
|
|
||||||
$errors = [];
|
$errors = [];
|
||||||
|
@ -640,11 +635,11 @@ class RegistrarsController extends Controller
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
$db->rollBack();
|
$db->rollBack();
|
||||||
$this->container->get('flash')->addMessage('error', 'Database failure during update: ' . $e->getMessage());
|
$this->container->get('flash')->addMessage('error', 'Database failure during update: ' . $e->getMessage());
|
||||||
return $response->withHeader('Location', '/registrar/update/'.$data['clid'])->withStatus(302);
|
return $response->withHeader('Location', '/registrar/update/'.$registrar)->withStatus(302);
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->container->get('flash')->addMessage('success', 'Registrar ' . $data['name'] . ' has been updated successfully on ' . $update);
|
$this->container->get('flash')->addMessage('success', 'Registrar ' . $data['name'] . ' has been updated successfully on ' . $update);
|
||||||
return $response->withHeader('Location', '/registrar/update/'.$data['clid'])->withStatus(302);
|
return $response->withHeader('Location', '/registrar/update/'.$registrar)->withStatus(302);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue