export default {
    methods: {
        //获取删除的id
        deletes(row){
            this.deleteData([row.id])
        },
        //删除数据
        deleteData(ids){
            this.$confirm('此操作将删除该产品类别, 是否继续?', '提示', {
            confirmButtonText: '确定',
            cancelButtonText: '取消',
            type: 'warning'
            }).then(() => {
            // 调用接口
            this.$api.deleteProduct(ids).then(res => {
                if (res.code == 200) {
                // this.getList()
                this.updateData()
                this.$message.success('删除成功!');
                }
            })
            }).catch(() => {
            });
        },
    },
}