:fix: the preference button does not render correctly in time.

This commit is contained in:
Zeeland 2022-11-01 02:27:57 +08:00
parent 5f536250ea
commit f24bdbb1dc
2 changed files with 12 additions and 24 deletions

View File

@ -157,18 +157,12 @@ export default {
idArticle: idArticle,
articlePerfect: '1'
}).then(function (res) {
if (res) {
if (res.success) {
_ts.$store.commit('admin/updateArticlePreference', {
index: index,
idArticle: idArticle,
articlePerfect: '1'
})
_ts.$message.success("设置成功!");
} else {
_ts.$message.error(_ts.message);
}
}
_ts.$store.commit('admin/updateArticlePreference', {
index: index,
idArticle: idArticle,
articlePerfect: '1'
})
_ts.$message.success("设置成功!");
})
},
cancelPreference(index, idArticle) {

View File

@ -503,18 +503,12 @@ export default {
idArticle: idArticle,
articlePerfect: '1'
}).then(function (res) {
if (res) {
if (res.success) {
_ts.$store.commit('admin/updateArticlePreference', {
index: index,
idArticle: idArticle,
articlePerfect: '1'
})
_ts.$message.success("设置成功!");
} else {
_ts.$message.error(_ts.message);
}
}
_ts.$store.commit('admin/updateArticlePreference', {
index: index,
idArticle: idArticle,
articlePerfect: '1'
})
_ts.$message.success("设置成功!");
})
},
cancelPreference(index, idArticle) {