mirror of
https://github.com/getnamingo/registry.git
synced 2025-07-25 20:08:23 +02:00
Last required TMCH updates in panel
This commit is contained in:
parent
e56fa9d034
commit
de119b013f
3 changed files with 78 additions and 1 deletions
|
@ -100,6 +100,29 @@ class ApplicationsController extends Controller
|
|||
]);
|
||||
}
|
||||
|
||||
$currentDateTime = new \DateTime();
|
||||
$currentDate = $currentDateTime->format('Y-m-d H:i:s.v'); // Current timestamp
|
||||
|
||||
$phase_details = $db->selectValue(
|
||||
"SELECT phase_category
|
||||
FROM launch_phases
|
||||
WHERE tld_id = ?
|
||||
AND phase_type = ?
|
||||
AND start_date <= ?
|
||||
AND (end_date >= ? OR end_date IS NULL OR end_date = '')
|
||||
",
|
||||
[$tld_id, $phaseType, $currentDate, $currentDate]
|
||||
);
|
||||
|
||||
if ($phase_details !== 'Application') {
|
||||
return view($response, 'admin/domains/createApplication.twig', [
|
||||
'domainName' => $domainName,
|
||||
'error' => 'The launch phase ' . $phaseType . ' is improperly configured. Please check the settings or contact support.',
|
||||
'registrars' => $registrars,
|
||||
'registrar' => $registrar,
|
||||
]);
|
||||
}
|
||||
|
||||
$domain_already_reserved = $db->selectValue(
|
||||
'SELECT id FROM reserved_domain_names WHERE name = ? LIMIT 1',
|
||||
[$label]
|
||||
|
|
|
@ -105,6 +105,9 @@ class DomainsController extends Controller
|
|||
$contactTech = $data['contactTech'] ?? null;
|
||||
$contactBilling = $data['contactBilling'] ?? null;
|
||||
|
||||
$phaseType = $data['phaseType'] ?? null;
|
||||
$smd = $data['smd'] ?? null;
|
||||
|
||||
$nameservers = !empty($data['nameserver']) ? $data['nameserver'] : null;
|
||||
$nameserver_ipv4 = !empty($data['nameserver_ipv4']) ? $data['nameserver_ipv4'] : null;
|
||||
$nameserver_ipv6 = !empty($data['nameserver_ipv6']) ? $data['nameserver_ipv6'] : null;
|
||||
|
@ -169,6 +172,38 @@ class DomainsController extends Controller
|
|||
]);
|
||||
}
|
||||
|
||||
$currentDateTime = new \DateTime();
|
||||
$currentDate = $currentDateTime->format('Y-m-d H:i:s.v'); // Current timestamp
|
||||
|
||||
$phase_details = $db->selectValue(
|
||||
"SELECT phase_category
|
||||
FROM launch_phases
|
||||
WHERE tld_id = ?
|
||||
AND phase_type = ?
|
||||
AND start_date <= ?
|
||||
AND (end_date >= ? OR end_date IS NULL OR end_date = '')
|
||||
",
|
||||
[$tld_id, $phaseType, $currentDate, $currentDate]
|
||||
);
|
||||
|
||||
if ($phase_details !== 'First-Come-First-Serve') {
|
||||
if ($phaseType !== null && $phaseType !== '') {
|
||||
return view($response, 'admin/domains/createDomain.twig', [
|
||||
'domainName' => $domainName,
|
||||
'error' => 'The launch phase ' . $phaseType . ' is improperly configured. Please check the settings or contact support.',
|
||||
'registrars' => $registrars,
|
||||
'registrar' => $registrar,
|
||||
]);
|
||||
}
|
||||
} else if ($phaseType !== null && $phaseType !== '') {
|
||||
return view($response, 'admin/domains/createDomain.twig', [
|
||||
'domainName' => $domainName,
|
||||
'error' => 'The launch phase ' . $phaseType . ' is improperly configured. Please check the settings or contact support.',
|
||||
'registrars' => $registrars,
|
||||
'registrar' => $registrar,
|
||||
]);
|
||||
}
|
||||
|
||||
$domain_already_reserved = $db->selectValue(
|
||||
'SELECT id FROM reserved_domain_names WHERE name = ? LIMIT 1',
|
||||
[$label]
|
||||
|
@ -423,7 +458,9 @@ class DomainsController extends Controller
|
|||
'acid' => null,
|
||||
'acdate' => null,
|
||||
'rgpstatus' => 'addPeriod',
|
||||
'addPeriod' => $date_add
|
||||
'addPeriod' => $date_add,
|
||||
'tm_phase' => $phaseType,
|
||||
'tm_smd_id' => $smd
|
||||
]);
|
||||
$domain_id = $db->getlastInsertId();
|
||||
|
||||
|
|
|
@ -232,6 +232,23 @@
|
|||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="mb-3">
|
||||
<label for="phaseType" class="form-label">Phase Type</label>
|
||||
<select class="form-select" id="phaseType" name="phaseType">
|
||||
<option value="">N/A</option>
|
||||
<option value="sunrise">Sunrise</option>
|
||||
<option value="landrush">Landrush</option>
|
||||
<option value="claims">Claims</option>
|
||||
<option value="open">Open</option>
|
||||
<option value="custom">Custom</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Signed Mark Information</label>
|
||||
<textarea class="form-control" data-bs-toggle="autosize" name="smd" placeholder="Paste SMD contents…"></textarea>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-footer">
|
||||
<div class="row align-items-center">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue