修复账号ID导致的BUG

This commit is contained in:
eoao
2026-01-07 22:02:00 +08:00
parent dc78582509
commit 5ae8800ed7
5 changed files with 7 additions and 7 deletions
+3 -3
View File
@@ -26,7 +26,7 @@
<el-dropdown-menu>
<el-dropdown-item v-if="hasPerm('email:send')" @click="openSetName(item)">{{ $t('rename') }}
</el-dropdown-item>
<el-dropdown-item v-if="item.accountId !== userStore.user.accountId && hasPerm('account:delete')"
<el-dropdown-item v-if="item.accountId !== userStore.user.account.accountId && hasPerm('account:delete')"
@click="remove(item)">{{ $t('delete') }}
</el-dropdown-item>
</el-dropdown-menu>
@@ -238,7 +238,7 @@ function setName() {
account.name = name
setNameShow.value = false
if (account.accountId === userStore.user.accountId) {
if (account.accountId === userStore.user.account.accountId) {
userStore.user.name = name
}
@@ -281,7 +281,7 @@ function setAllReceive(account) {
function showNullSetting(item) {
return !hasPerm('email:send') && !(item.accountId !== userStore.user.accountId && hasPerm('account:delete'))
return !hasPerm('email:send') && !(item.accountId !== userStore.user.account.accountId && hasPerm('account:delete'))
}
function itemBg(accountId) {
+1 -1
View File
@@ -486,7 +486,7 @@ function formatImage(content) {
function open() {
if (!accountStore.currentAccount.email) {
form.sendEmail = userStore.user.email;
form.accountId = userStore.user.accountId;
form.accountId = userStore.user.account.accountId;
form.name = userStore.user.name;
} else {
form.sendEmail = accountStore.currentAccount.email;
+1 -1
View File
@@ -93,7 +93,7 @@ function setName() {
userStore.user.name = accountName.value
accountSetName(userStore.user.accountId,name).then(() => {
accountSetName(userStore.user.account.accountId,name).then(() => {
ElMessage({
message: t('saveSuccessMsg'),
type: 'success',
+1 -1
View File
@@ -1306,7 +1306,7 @@ function editSetting(settingForm, refreshStatus = true) {
plain: true
})
if (setting.value.manyEmail === 1) {
accountStore.currentAccountId = userStore.user.accountId;
accountStore.currentAccountId = userStore.user.account.accountId;
}
if (refreshStatus) {
getSettings()
+1 -1
View File
@@ -435,7 +435,7 @@ function deleteAccount(account) {
userDeleteAccount(account.accountId).then(() => {
getAccountList()
ElMessage({
message: t('删除成功'),
message: t('delSuccessMsg'),
type: "success",
plain: true
})