public static List <ProgramBranchAssociation> UpdateProgramBranchAssociation(ProgramBranchAssociation programBranchAssociation)
        {
            AdoHelper objHelper = new AdoHelper(ConfigurationManager.ConnectionStrings["con"].ToString());
            DataSet   ds        = new DataSet();

            SqlParameter[] sqlParameter =
            {
                new SqlParameter("@SetAction", programBranchAssociation.SetAction.ToUpper()),
                new SqlParameter("@BranchIds", programBranchAssociation.BranchIds),
                new SqlParameter("@ProgramId", programBranchAssociation.ProgramId)
            };

            ds = objHelper.ExecDataSetProc("Gkl_USP_UpdateProgramBranchAssociation", sqlParameter);

            List <ProgramBranchAssociation> objlm = null;

            objlm = ds.Tables[0].AsEnumerable()
                    .Select(row => new ProgramBranchAssociation
            {
                ProgramId  = row.Field <int>("ProgramId"),
                BranchId   = row.Field <int>("BranchId"),
                BranchCode = Common.ConvertFromDBVal <string>(row["BranchCode"]),
                BranchName = Common.ConvertFromDBVal <string>(row["BranchName"])
            }).ToList();

            return(objlm);
        }
 public List <ProgramBranchAssociation> UpdateProgramBranchAssociation(ProgramBranchAssociation programBranchAssociation)
 {
     return(ProgramBranchAssociationDS.UpdateProgramBranchAssociation(programBranchAssociation));
 }
 public IHttpActionResult UpdateProgramBranchAssociation(ProgramBranchAssociation programBranchAssociation)
 {
     return(Ok(new { results = programBranchAssociationService.UpdateProgramBranchAssociation(programBranchAssociation) }));
 }