- Cloudflare e configurazione dominio DNS (host, host_test, host_ip, ecc...)

This commit is contained in:
Surya Paolo
2024-09-09 21:49:31 +02:00
parent e9ac281125
commit 16ddb8095e
39 changed files with 438 additions and 64 deletions

View File

@@ -1255,9 +1255,9 @@ export const colAttivita = [
numpag_carousel: 3,
}),
AddCol({
name: 'coordinate_gps',
label_trans: 'attivita.coordinate_gps',
fieldtype: costanti.FieldType.coordinates,
name: 'coordinate_gps',
label_trans: 'attivita.coordinate_gps',
fieldtype: costanti.FieldType.coordinates,
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView_OnlyifExist,
required: false,
}),
@@ -1875,7 +1875,13 @@ export const colTableSites = [
AddCol({ name: 'manageremail', label_trans: 'sites.manageremail', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'replyTo', label_trans: 'sites.replyTo', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'host', label_trans: 'sites.host', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'host_ip', label_trans: 'sites.host_ip', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'host_test', label_trans: 'sites.host_test', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'host_test_ip', label_trans: 'sites.host_test_ip', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'host_testapi', label_trans: 'sites.host_testapi', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'host_testapi_ip', label_trans: 'sites.host_testapi_ip', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'cf_token', label_trans: 'sites.cf_token', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'cf_zoneId', label_trans: 'sites.cf_zoneId', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'portapp', label_trans: 'sites.portapp', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'dir', label_trans: 'sites.dir' }),
AddCol({ name: 'dir_test', label_trans: 'sites.dir_test', fieldtype: costanti.FieldType.string }),

View File

@@ -5235,6 +5235,16 @@ export const tools = {
return (site.confpages.enableDebugOn)
},
getDomainSite(): string {
const globalStore = useGlobalStore()
const site = globalStore.site
if (site) {
return site.host!
}
return ''
},
isVerified(): boolean {
const globalStore = useGlobalStore()
const site = globalStore.site
@@ -8735,6 +8745,28 @@ export const tools = {
return `Coordinate: ${lng}, Lat: ${lat}`
}
}
},
getHostPuntamento(arrDNS: any, tofind: string, paramsulServer: string): any {
let checkDomain = ''
let indrec = arrDNS.findIndex((rec: any) => rec.name === tofind && rec.type === 'A')
let color = 'red'
let ok = false
if (indrec >= 0) {
checkDomain = tofind + ' -> ' + arrDNS[indrec].content
let giusto = (paramsulServer === arrDNS[indrec].content)
color = giusto ? 'green' : 'red'
if (!giusto) {
checkDomain += ' (<strong>al posto di -> ' + paramsulServer + '</strong>)'
} else {
ok = true
}
} else {
checkDomain = tofind + ' N/A'
}
return { text: '<span style="color: ' + color + ';">' + checkDomain + '</span><br>', ok }
}
// FINE !