mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-08-02 17:24:57 +02:00
Fix: Daily log file not adding newlines to logs, Add: Config log page loads last 5000 logs for the current day #72
This commit is contained in:
parent
6ccde8f66f
commit
8ca6c62a03
8 changed files with 87 additions and 54 deletions
|
@ -1,31 +0,0 @@
|
|||
export const state = () => ({
|
||||
isListening: false,
|
||||
logs: []
|
||||
})
|
||||
|
||||
export const getters = {
|
||||
|
||||
}
|
||||
|
||||
export const actions = {
|
||||
setLogListener({ state, commit, dispatch }) {
|
||||
dispatch('$nuxtSocket/emit', {
|
||||
label: 'main',
|
||||
evt: 'set_log_listener',
|
||||
msg: 0
|
||||
}, { root: true })
|
||||
commit('setIsListening', true)
|
||||
}
|
||||
}
|
||||
|
||||
export const mutations = {
|
||||
setIsListening(state, val) {
|
||||
state.isListening = val
|
||||
},
|
||||
logEvt(state, payload) {
|
||||
state.logs.push(payload)
|
||||
if (state.logs.length > 500) {
|
||||
state.logs = state.logs.slice(50)
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue