设置页面,也添加日志按钮。

pull/333/head
王良 2024-08-14 14:02:11 +08:00
parent 986fead402
commit b29b803869
2 changed files with 10 additions and 4 deletions

View File

@ -11,6 +11,7 @@
<a-checkbox v-model="config.app.autoStart.enabled" @change="onAutoStartChange"> <a-checkbox v-model="config.app.autoStart.enabled" @change="onAutoStartChange">
本应用开机自启 本应用开机自启
</a-checkbox> </a-checkbox>
<a-button class="md-mr-10" icon="profile" @click="openLog()"></a-button>
<div class="form-help"> <div class="form-help">
windows下建议开启开机自启<a @click="openExternal('https://github.com/docmirror/dev-sidecar/blob/master/doc/recover.md')"></a> windows下建议开启开机自启<a @click="openExternal('https://github.com/docmirror/dev-sidecar/blob/master/doc/recover.md')"></a>
</div> </div>
@ -143,6 +144,10 @@ export default {
ready (config) { ready (config) {
this.themeBackup = config.app.theme this.themeBackup = config.app.theme
}, },
async openLog () {
const dir = await this.$api.info.getConfigDir()
this.$api.ipc.openPath(dir + '/logs/')
},
async applyAfter () { async applyAfter () {
// //
if (this.config.app.theme !== this.themeBackup) { if (this.config.app.theme !== this.themeBackup) {

View File

@ -15,11 +15,12 @@ class IpCache extends DynamicChoice {
} }
/** /**
* 获取到新的ipList * 设置新的ipList
* @param ipList *
* @param newBackupList
*/ */
setBackupList (ipList) { setBackupList (newBackupList) {
super.setBackupList(ipList) super.setBackupList(newBackupList)
this.lookupCount++ this.lookupCount++
} }
} }