mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2025-04-19 21:42:24 +00:00
bug fix
This commit is contained in:
parent
020d1adc55
commit
4593147b65
2 changed files with 19 additions and 8 deletions
|
@ -90,7 +90,6 @@
|
||||||
const hideDragImage = this.$el.cloneNode(true);
|
const hideDragImage = this.$el.cloneNode(true);
|
||||||
hideDragImage.id = "hideDragImage-hide";
|
hideDragImage.id = "hideDragImage-hide";
|
||||||
hideDragImage.style.opacity = 0;
|
hideDragImage.style.opacity = 0;
|
||||||
document.body.appendChild(hideDragImage);
|
|
||||||
e.dataTransfer.setDragImage(hideDragImage, 0, 0);
|
e.dataTransfer.setDragImage(hideDragImage, 0, 0);
|
||||||
},
|
},
|
||||||
dragStopHandler(e, index) {
|
dragStopHandler(e, index) {
|
||||||
|
|
|
@ -1407,16 +1407,28 @@
|
||||||
templateSettings: {
|
templateSettings: {
|
||||||
get: function () {
|
get: function () {
|
||||||
const parsedSettings = this.xraySetting ? JSON.parse(this.xraySetting) : null;
|
const parsedSettings = this.xraySetting ? JSON.parse(this.xraySetting) : null;
|
||||||
const setLogPath = (type, defaultValue) => parsedSettings?.log?.[type] !== "none" ? parsedSettings.log[type] : defaultValue;
|
let accessLogPath = "./access.log";
|
||||||
this.access = ["none", setLogPath("access", "./access.log")];
|
let errorLogPath = "./error.log";
|
||||||
this.error = ["none", setLogPath("error", "./error.log")];
|
|
||||||
|
if (parsedSettings && parsedSettings.log) {
|
||||||
|
if (parsedSettings.log.access && parsedSettings.log.access !== "none") {
|
||||||
|
accessLogPath = parsedSettings.log.access;
|
||||||
|
}
|
||||||
|
if (parsedSettings.log.error && parsedSettings.log.error !== "none") {
|
||||||
|
errorLogPath = parsedSettings.log.error;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
this.access = ["none", accessLogPath];
|
||||||
|
this.error = ["none", errorLogPath];
|
||||||
return parsedSettings;
|
return parsedSettings;
|
||||||
},
|
},
|
||||||
set: function (newValue) {
|
set: function (newValue) {
|
||||||
|
if (newValue && newValue.log) {
|
||||||
this.xraySetting = JSON.stringify(newValue, null, 2);
|
this.xraySetting = JSON.stringify(newValue, null, 2);
|
||||||
const setLogPath = (type, defaultValue) => newValue.log?.[type] ? newValue.log[type] : defaultValue;
|
this.access = ["none", newValue.log.access || "./access.log"];
|
||||||
this.access = ["none", setLogPath("access", "./access.log")];
|
this.error = ["none", newValue.log.error || "./error.log"];
|
||||||
this.error = ["none", setLogPath("error", "./error.log")];
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
inboundSettings: {
|
inboundSettings: {
|
||||||
|
|
Loading…
Reference in a new issue