layer实现删除确认及操作完成后弹出提醒,然后刷新本页面

layer.confirm("确认要删除吗,删除后不能恢复", { title: "删除确认" }, function (index) {
                layer.close(index);
                $.post("/admin/customer/DeleteCustomer", { gid: $(e.currentTarget).data("gid") }, function (data) {
                    layer.alert(data, {
                        title: "删除操作",
                        btn: ['确定']
                    },
                        function (index, item) {
                            //layer.close(index);
                            location.reload();
                        });
                });
            }); 

你可能感兴趣的:(javascript,jquery)