修复导入

pull/733/head
lyswhut 2021-12-04 02:15:08 +08:00
parent 8949383ade
commit c9cb84a28d
2 changed files with 5 additions and 4 deletions

View File

@ -317,6 +317,7 @@ const mutations = {
id, id,
list: [], list: [],
source, source,
position,
sourceListId, sourceListId,
} }
addUserList(newList) addUserList(newList)

View File

@ -318,13 +318,13 @@ export default {
let list let list
switch (index) { switch (index) {
case -2: case -2:
list = { ...defaultList, list: getList(defaultList.id) } list = { ...this.defaultList, list: getList(this.defaultList.id) }
break break
case -1: case -1:
list = { ...loveList, list: getList(loveList.id) } list = { ...this.loveList, list: getList(this.loveList.id) }
break break
default: default:
list = userLists[index] list = this.userLists[index]
if (!list) return null if (!list) return null
list = { ...list, list: getList(list.id) } list = { ...list, list: getList(list.id) }
break break
@ -377,7 +377,7 @@ export default {
confirmButtonText: this.$t('lists__import_part_button_confirm'), confirmButtonText: this.$t('lists__import_part_button_confirm'),
}) })
if (confirm) { if (confirm) {
listData.data.name = list.name listData.data.name = targetList.name
this.setList({ this.setList({
name: listData.data.name, name: listData.data.name,
id: listData.data.id, id: listData.data.id,