Esempio n. 1
0
    protected void DeleteButton_Click(object sender, EventArgs e)
    {
        //DELETE FROM DonorDetails FROM DonorDetails INNER JOIN Records ON DonorDetails.DonorID = Records.DonorID INNER JOIN RegisteredDonor ON DonorDetails.DonorID = RegisteredDonor.DonorID Where RegisteredDonor.DonorID = DonorID
        int RNO = Convert.ToInt32(RequesterDetails.Rows[7].Cells[1].Text);
        RequestStatusDAO rsDAO = new RequestStatusDAO();

        rsDAO.DeleteRequest(RNO);
        Response.Redirect("AdminPage.aspx");
    }
Esempio n. 2
0
    private void saveStatus(string status)
    {
        //get the RId from the GridView for getting data from database
        int ID = Convert.ToInt32(RequesterDetails.Rows[7].Cells[1].Text);
        RequestStatusDAO rsDAO = new RequestStatusDAO();

        rsDAO.UpdateStatus(new RequestStatusDTO(ID, status));

        //Response.Redirect("ViewRequest.aspx");
    }
    protected void Button1_Click(object sender, EventArgs e)
    {
        InsertRequestDAO insertRequestDao = new InsertRequestDAO();

        string RequiredGroup = BRDropDown.Text;
        string Amount        = AmountText.Text;
        string Location      = LocationText.Text;
        string image         = InsertImage();
        string Email         = Session["Requester"].ToString();



        //insertRequestDao.InsertRequest(new InsertRequestDTO(BloodRequest, Amount, Location, Email, image));
        RequestStatusDAO rsDAO = new RequestStatusDAO();

        rsDAO.InsertNewRequest(new InsertRequestDTO(Email, RequiredGroup, Amount, Location, image));
        Response.Write("Your Registration is Successful");
        Response.Redirect("EditRequest.aspx");
    }