예제 #1
0
    public int InsertUserEntry(PlUserCreation pl)
    {
        cmd             = new SqlCommand("SPLoginDetails", con);
        cmd.CommandType = CommandType.StoredProcedure;
        cmd.Parameters.AddWithValue("@Ind", pl.Ind);
        cmd.Parameters.AddWithValue("@UserTypeID", pl.UserType);
        cmd.Parameters.AddWithValue("@UserName", pl.UserName);
        cmd.Parameters.AddWithValue("@UserState", pl.State);
        cmd.Parameters.AddWithValue("@UserCity", pl.City);
        cmd.Parameters.AddWithValue("@UserAddress", pl.Address);
        cmd.Parameters.AddWithValue("@UserMobileNo", pl.ContactNo);
        cmd.Parameters.AddWithValue("@UserEmailAddr", pl.Email);
        cmd.Parameters.AddWithValue("@UserLoginID", pl.LoginId);
        cmd.Parameters.AddWithValue("@UserLoginPwd", pl.Pwd);
        cmd.Parameters.AddWithValue("@IsOutSideUser", pl.IsOutSideUser);
        cmd.Parameters.AddWithValue("@IsActive", pl.IsActive);
        cmd.Parameters.AddWithValue("@CreationDate", pl.CreationDate);
        cmd.Parameters.AddWithValue("@UserLoginStatus", pl.LoginStatus);
        //con.Open();
        SqlDataAdapter ad = new SqlDataAdapter(cmd);

        dt = new DataTable();
        ad.Fill(dt);
        int i = Convert.ToInt32(dt.Rows[0][0].ToString());



        //  con.Close();
        return(i);
    }
예제 #2
0
 public DataTable GetLockedUsers(PlUserCreation pl)
 {
     cmd             = new SqlCommand("SPLoginDetails", con);
     cmd.CommandType = CommandType.StoredProcedure;
     cmd.Parameters.AddWithValue("@Ind", pl.Ind);
     cmd.Parameters.AddWithValue("@UserId", pl.UserId);
     da = new SqlDataAdapter(cmd);
     dt = new DataTable();
     da.Fill(dt);
     return(dt);
 }
예제 #3
0
    public int UpdateUnlockedUser(PlUserCreation pl)
    {
        cmd             = new SqlCommand("SPLoginDetails", con);
        cmd.CommandType = CommandType.StoredProcedure;
        cmd.Parameters.AddWithValue("@Ind", pl.Ind);
        cmd.Parameters.AddWithValue("@UserId", pl.UserId);
        con.Open();
        int i = cmd.ExecuteNonQuery();

        con.Close();
        return(i);
    }
예제 #4
0
    public int InsertUserEntry(PlUserCreation pl)
    {
        cmd             = new SqlCommand("SPLoginDetails", con);
        cmd.CommandType = CommandType.StoredProcedure;
        cmd.Parameters.AddWithValue("@Ind", pl.Ind);
        cmd.Parameters.AddWithValue("@UserTypeID", pl.UserType);
        cmd.Parameters.AddWithValue("@UserName", pl.UserName);
        cmd.Parameters.AddWithValue("@UserState", pl.State);
        cmd.Parameters.AddWithValue("@UserCity", pl.City);
        cmd.Parameters.AddWithValue("@UserAddress", pl.Address);
        cmd.Parameters.AddWithValue("@UserMobileNo", pl.ContactNo);
        cmd.Parameters.AddWithValue("@UserEmailAddr", pl.Email);
        cmd.Parameters.AddWithValue("@UserLoginID", pl.LoginId);
        cmd.Parameters.AddWithValue("@UserLoginPwd", pl.Pwd);
        cmd.Parameters.AddWithValue("@IsOutSideUser", pl.IsOutSideUser);
        cmd.Parameters.AddWithValue("@IsActive", pl.IsActive);
        cmd.Parameters.AddWithValue("@CreationDate", pl.CreationDate);
        cmd.Parameters.AddWithValue("@UserLoginStatus", pl.UserLoginStatus);
        con.Open();
        int i = cmd.ExecuteNonQuery();

        con.Close();
        return(i);
    }
 public int UpdateUnlockedUser(PlUserCreation pl)
 {
     return(dl.UpdateUnlockedUser(pl));
 }
 public int InserUser(PlUserCreation pl)
 {
     return(dl.InsertUserEntry(pl));
 }