Added proxy template for support proxy request from nginx to another service
This commit is contained in:
@@ -53,6 +53,7 @@ export default function handleEditWebListeners() {
|
||||
// show "Purge Nginx Cache" button if "caching" selected
|
||||
const proxyTemplateSelect = document.querySelector('.js-proxy-template-select');
|
||||
const clearCacheButton = document.querySelector('.js-clear-cache-button');
|
||||
const proxyConnect = document.querySelector('.js-proxy-connect')
|
||||
if (proxyTemplateSelect && clearCacheButton) {
|
||||
proxyTemplateSelect.addEventListener('change', () => {
|
||||
// NOTE: Match "caching" and "caching-*" values
|
||||
@@ -63,4 +64,16 @@ export default function handleEditWebListeners() {
|
||||
}
|
||||
});
|
||||
}
|
||||
if (proxyTemplateSelect && proxyConnect) {
|
||||
proxyTemplateSelect.addEventListener('change', () => {
|
||||
if (proxyTemplateSelect.value === "srvproxy") {
|
||||
proxyConnect.style.display = 'block';
|
||||
} else {
|
||||
proxyConnect.style.display = 'none';
|
||||
}
|
||||
});
|
||||
}
|
||||
if (proxyTemplateSelect.value === "srvproxy") {
|
||||
proxyConnect.style.display = 'block';
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user