mirror of
https://github.com/gSpotx2f/ruantiblock_openwrt.git
synced 2026-05-14 22:50:58 +00:00
Minor fixes & improvements.
This commit is contained in:
@@ -171,6 +171,13 @@ return baseclass.extend({
|
||||
*/
|
||||
title : null,
|
||||
|
||||
/**
|
||||
* Enable auto refresh log.
|
||||
*
|
||||
* @property {bool} autoRefresh
|
||||
*/
|
||||
autoRefresh : false,
|
||||
|
||||
pollInterval : L.env.pollinterval,
|
||||
|
||||
logFacilities : {
|
||||
@@ -443,7 +450,7 @@ return baseclass.extend({
|
||||
* @param {string} logdata
|
||||
* @param {number} tail
|
||||
* @returns {Array<number, string|null, string|null, string|null, string|null, string|null>}
|
||||
* Returns an array of values: [ #, Timestamp, Host, Level, Facility, Message ].
|
||||
* Returns an array of values: [ #, Timestamp, Host, Facility, Level, Message ].
|
||||
*/
|
||||
parseLogData(logdata, tail) {
|
||||
throw new Error('parseLogData must be overridden by a subclass');
|
||||
@@ -885,7 +892,7 @@ return baseclass.extend({
|
||||
|
||||
load() {
|
||||
this.restoreSettingsFromLocalStorage();
|
||||
if(typeof(this.getLogHash) != 'function') {
|
||||
if(!this.autoRefresh || typeof(this.getLogHash) != 'function') {
|
||||
this.isAutorefresh = false;
|
||||
this.autoRefreshValue = false;
|
||||
};
|
||||
@@ -1026,13 +1033,7 @@ return baseclass.extend({
|
||||
if(this.fastTailValue > 0) {
|
||||
this.fastTailValue += this.fastTailIncrement;
|
||||
};
|
||||
return this.reloadLog(this.fastTailValue)/*.then(() => {
|
||||
if(this.logSortingValue == 'desc') {
|
||||
this.scrollToBottom();
|
||||
} else {
|
||||
this.scrollToTop();
|
||||
};
|
||||
});*/
|
||||
return this.reloadLog(this.fastTailValue);
|
||||
}),
|
||||
}, `+${this.fastTailIncrement}`);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user