Uncaught (in promise) cancel
2020-11-27 本文已影响0人
她与星河皆遗憾
Uncaught (in promise) cancel
这是因为你点击了取消或者是关闭弹窗,但是你没有写catch
this.$confirm('确定替换原有数据?', '提示', {
type: 'warning'
}).then(() => {
localStorage.setItem('chosedResourceids',"");
localStorage.setItem('PaperMsg',"");
if( sessionStorage.getItem('PaperMsg')==''){
this.$message({
message: '替换成功',
type: 'success'
});
this.$router.push({name:'success',query:{customerId:40}})
}
}).catch(() => {}); //一定别忘了这个