feat(uigf): support UIGFv4.0(Beta)

Users don't have to delete their data. New data structure is used automatically when new data is fetched

- Set `count` to `"1"` as default for old data
- Record `count` from API
- Link to the UIGF website

BREAKING CHANGE: SRGF is no longer supported, use UIGFv4.0(Beta) instead
This commit is contained in:
2024-07-23 11:10:27 +08:00
parent f1e3b76d85
commit 0e4f3599c9
9 changed files with 43 additions and 30 deletions

View File

@@ -11,7 +11,7 @@
<template #dropdown>
<el-dropdown-menu>
<el-dropdown-item command="excel">{{ui.button.excel}}</el-dropdown-item>
<el-dropdown-item command="srgf-json">{{ui.button.srgf}}</el-dropdown-item>
<el-dropdown-item command="uigf-json">{{ui.button.uigf}}</el-dropdown-item>
</el-dropdown-menu>
</template>
</el-dropdown>
@@ -238,15 +238,15 @@ const saveExcel = async () => {
await ipcRenderer.invoke('SAVE_EXCEL')
}
const exportSRGFJSON = () => {
ipcRenderer.invoke('EXPORT_SRGF_JSON')
const exportUIGFJSON = () => {
ipcRenderer.invoke('EXPORT_UIGF_JSON')
}
const exportCommand = (type) => {
if (type === 'excel') {
saveExcel()
} else if (type === 'srgf-json') {
exportSRGFJSON()
} else if (type === 'uigf-json') {
exportUIGFJSON()
}
}