vue中删除时的弹框提示代码

Sikj_6590

关注

阅读 115

2022-04-13

this.$confirm('确认要删除该条数据吗?', '提示', { type: 'warning' })

                        .then(() => {

                            deleteDataById(userId).then(res => {

                                if (res && res.data.code == "200") {

                                    this.$notify({

                                        title: "删除成功",

                                        type: 'success'

                                    });

                                    this.queryList()

                                    this.$addOptLog('删除', '删除数据集【' + row.name + '】')

                                } else {

                                    this.$notify({

                                        title: res.data.msg,

                                        type: 'error'

                                    });

                                }

                            })

                        }).catch(() => { });

精彩评论(0)

0 0 举报