批量刪除跟單刪
/// <summary>
/// 刪除
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
public int DeleteId(int id)
{
int i = bll.Delete(id);
if (i > 0)
{
Response.Write("<script>alert(‘刪除成功!‘);location.href=‘/Index/Index‘</script>");
}
else
{
Response.Write("<script>alert(‘刪除失敗!‘);location.href=‘/Index/Index‘</script>");
}
return i;
}
/// <summary>
/// 批量刪除
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
public int DeleteIds(string id)
{
if (bll.DeleteIds(id) > 0)
{
return 1;
}
else
{
return 0;
}
}
批量刪除跟單刪