[Domain] fix api request getting dns records
This commit is contained in:
@@ -194,6 +194,10 @@ include(realpath(dirname(__FILE__) . "/../../$mfLayoutPackage") . "/header.php")
|
|||||||
methods: {
|
methods: {
|
||||||
async showDnsRecordsModal(domain) {
|
async showDnsRecordsModal(domain) {
|
||||||
this.dnsRecordsModalLoading = domain
|
this.dnsRecordsModalLoading = domain
|
||||||
|
this.dnsRecordsModal = {
|
||||||
|
domain: null,
|
||||||
|
records: []
|
||||||
|
}
|
||||||
const response = await axios.get(window['TT_CONFIG']['DOMAIN_API_URL'] + '?do=getDnsRecords&domain=' + domain)
|
const response = await axios.get(window['TT_CONFIG']['DOMAIN_API_URL'] + '?do=getDnsRecords&domain=' + domain)
|
||||||
this.dnsRecordsModal.domain = domain
|
this.dnsRecordsModal.domain = domain
|
||||||
this.dnsRecordsModal.records = response.data.map(record => {
|
this.dnsRecordsModal.records = response.data.map(record => {
|
||||||
|
|||||||
@@ -142,7 +142,7 @@ class DomainController extends mfBaseController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private function getDnsRecords() {
|
private function getDnsRecords() {
|
||||||
if (!isset($this->request->domain)) {
|
if (!empty($this->request->domain)) {
|
||||||
return ["status" => "error", "message" => "No domain specified."];
|
return ["status" => "error", "message" => "No domain specified."];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user