//Dispaly All Skill public static DataTable LoadCatSkill_BL() { DataTable cat = null; try { cat = Skill_DAL.LoadCategory(); } catch (SqlException ex) { throw ex; } catch (HRMSException ex) { throw ex; } return(cat); }
//Dispaly All Skill public static DataTable DisplaySkill_BL() { DataTable skill = null; try { skill = Skill_DAL.DisplayAllSkills(); } catch (SqlException ex) { throw ex; } catch (HRMSException ex) { throw ex; } return(skill); }
//Search Skill By Id public static DataTable SearchSkillById_BL(int Skillid) { DataTable skill = null; try { skill = Skill_DAL.SearchSkillById(Skillid); } catch (SqlException ex) { throw ex; } catch (HRMSException ex) { throw ex; } return(skill); }
//Delete Skill public static int DeleteSkill_BL(int Skillid) { int rowsAffected = 0; try { rowsAffected = Skill_DAL.DeleteSkill(Skillid); } catch (SqlException ex) { throw ex; } catch (HRMSException ex) { throw ex; } return(rowsAffected); }
//Get Autogenerated ID public static int GetAutogeneratedSkillID_BL() { int Skillid = 0; try { Skillid = Skill_DAL.GetAutoGeneratedSkillId(); } catch (SqlException ex) { throw ex; } catch (HRMSException ex) { throw ex; } return(Skillid); }
//Calling Update Skill public static int UpdateSkill_BL(Skill newSkill) { int rowsAffected = 0; try { if (ValidatSkill(newSkill)) { rowsAffected = Skill_DAL.UpdateSkill(newSkill); } } catch (SqlException ex) { throw ex; } catch (HRMSException ex) { throw ex; } return(rowsAffected); }