/// <summary> /// Search By Criteria - iQuran version instances as IList with paging /// </summary> /// <param name="WithSuras"> used to retrive the QuranSuras - Sura - instances of the Quran Revesion </param> /// <param name="siteId"></param> /// <param name="isActive"></param> /// <param name="pageNumber"></param> /// <param name="pageSize"></param> /// <param name="totalPages"></param> /// <returns></returns> public static List <Quran> GetPage_iQuran_ByActive(bool WithSuras, int siteId, bool isActive, int pageNumber, int pageSize, out int totalPages) { totalPages = 1; IDataReader reader = DBiQuran.iQuran_GetPage_ByActive(siteId, isActive, pageNumber, pageSize, out totalPages); return(LoadListFromReader(reader, WithSuras)); }
private void GetCounts_ByRoot_Table(int siteId, int quranID, int strtSuraOrder, int endSuraOrder, int strtVerseOrder, int endVerseOrder, string TextWordRoot) { using (IDataReader reader = DBiQuran.iSearch_GetCounts_Default_ByRoot_Table_Dr(siteId, quranID, strtSuraOrder, endSuraOrder, strtVerseOrder, endVerseOrder, TextWordRoot)) { if (reader.Read()) { this.verseQty = reader["VerseQty"].ToString(); this.wordQty = reader["WordQty"].ToString(); this.searchedWords = reader["SearchedWords"].ToString().Replace("--", "-"); if (this.searchedWords.Contains("-")) { this.searchedWords = searchedWords.Substring(1, searchedWords.Length - 1); } } else { if (log.IsErrorEnabled) { log.Error("IDataReader didn't read in Quran.GetiQuran"); } } } }
private void GetiQuran(int siteId, int quranId) { using (IDataReader reader = DBiQuran.iQuran_GetiQuran(siteId, quranId)) { if (reader.Read()) { this.quranID = int.Parse(reader["QuranID"].ToString()); this.siteID = int.Parse(reader["SiteID"].ToString()); this.title = reader["Title"].ToString().Trim(); this.description = reader["Description"].ToString(); this.tRanslatorDetUrl = reader["TRanslatorDetUrl"].ToString(); this.translationSrc = reader["TranslationSrc"].ToString(); this.suraCount = int.Parse(reader["SuraCount"].ToString()); string isdefault = reader["IsDefault"].ToString(); this.isDefault = (isdefault == "True" || isdefault == "1"); this.qLanguage = reader["QLanguage"].ToString().Trim(); string active = reader["IsActive"].ToString(); this.isActive = (active == "True" || active == "1"); this.createdDate = Convert.ToDateTime(reader["CreatedDate"]); this.createdByUserName = reader["UserName"].ToString().Trim(); this.createdByUserID = int.Parse(reader["CreatedBy"].ToString()); } else { if (log.IsErrorEnabled) { log.Error("IDataReader didn't read in Quran.GetiQuran"); } } } }
/// <summary> /// Search By Criteria - iSura version instances as IList with paging /// </summary> /// <param name="WithVerses"> used to retrive the SuraVerse - Verse - instances of the Sura </param> /// <param name="siteId"></param> /// <param name="quranID"></param> /// <param name="isActive"></param> /// <param name="pageNumber"></param> /// <param name="pageSize"></param> /// <param name="totalPages"></param> /// <returns></returns> public static List <QuranSura> GetPage_iSura_ByActive(bool WithVerses, int siteId, int quranID, bool isActive, int pageNumber, int pageSize, out int totalPages) { totalPages = 1; IDataReader reader = DBiQuran.iSura_GetPage_ByActive(siteId, quranID, isActive, pageNumber, pageSize, out totalPages); return(LoadListFromReader(reader, WithVerses)); }
/// <summary> /// Search By Criteria - iVerse version instances as IList with paging /// </summary> /// <param name="siteId"></param> /// <param name="quranID"></param> /// <param name="suraID"></param> /// <param name="isActive"></param> /// <param name="isTranslation"> To tell SP to search within the translation or the arabic texts</param> /// <param name="pageNumber"></param> /// <param name="pageSize"></param> /// <param name="totalPages"></param> /// <returns></returns> public static List <QuranVerse> GetPage_iVerse_ByActive(int siteId, int quranID, int suraID, bool isActive, bool isTranslation, int pageNumber, int pageSize, out int totalPages) { totalPages = 1; IDataReader reader = DBiQuran.iVerse_GetPage_ByActive(siteId, quranID, suraID, isActive, isTranslation, pageNumber, pageSize, out totalPages); return(LoadListFromReader(reader, isTranslation)); }
/// <summary> /// Search Arabic Quran for Word root /// </summary> public static List <iQuranSearch> iSearch_GetPage_Default_ByRoot(string searchCriteria, int siteId, int quranID, int strtSuraID, int endSuraID, int strtVerseOrder, int endVerseOrder, string TextSearchWord, int pageNumber, int pageSize, out int totalPages) { totalPages = 1; IDataReader reader = DBiQuran.iSearch_GetPage_Default_ByRoot(searchCriteria, siteId, quranID, strtSuraID, endSuraID, strtVerseOrder, endVerseOrder, TextSearchWord, pageNumber, pageSize, out totalPages); return(LoadListFromReader(reader, 0, false)); }
/// <summary> /// Search Translation for word or sentence or part from /// </summary> public static List <iQuranSearch> iSearch_GetPage_Translation_ByWordSentence(int siteId, int quranID, int strtSuraID, int endSuraID, int strtVerseOrder, int endVerseOrder, string TextSearchWord, int pageNumber, int pageSize, out int totalPages) { totalPages = 1; IDataReader reader = DBiQuran.iSearch_GetPage_Translation_ByWordSentence(siteId, quranID, strtSuraID, endSuraID, strtVerseOrder, endVerseOrder, TextSearchWord, pageNumber, pageSize, out totalPages); return(LoadListFromReader(reader, 0, true)); }
private bool Create() { int newID = -1; newID = DBiQuran.iQuran_Create(this.siteID, this.title, this.description, this.isDefault, this.qLanguage, this.tRanslatorDetUrl, this.translationSrc, this.isActive, this.createdByUserID); this.quranID = newID; return(newID > -1); }
private bool Create() { int newID = -1; newID = DBiQuran.iSura_Create(this.siteID, this.quranID, this.title, this.place, this.suraOrder, this.isActive, this.createdByUserID); DBiQuran.iQuran_Increment_SuraCount(this.siteID, this.quranID); this.suraID = newID; return(newID > -1); }
private bool Update() { if (this.qLanguage == "ar") { return(DBiQuran.iVerse_UpdateVerse_Text(this.siteID, this.quranID, this.suraID, this.verseID, this.verseOrder, this.suraOrder, this.halfNo, this.partNo, this.hizbNo, this.quraterNo, this.place, this.startTime, this.endTime, this.endTimeText, this.isActive, this.createdByUserID, this.verseText, this.quranVerseTxt.VerseTextNM, this.quranVerseTxt.VerseTextNMAlif)); } else { return(DBiQuran.iVerse_UpdateVerse_Transl(this.siteID, this.quranID, this.suraID, this.verseID, this.suraOrder, this.verseOrder, this.VerseText)); } }
private void GetOthmaniVerse(int siteId, int verseid) { using (IDataReader reader = DBiQuran.iVerse_GetOthmaniVerseDetails(siteId, verseid)) { if (reader.Read()) { this.verseID = int.Parse(reader["VerseID"].ToString()); this.suraID = int.Parse(reader["SuraID"].ToString()); this.quranID = int.Parse(reader["QuranID"].ToString()); this.siteID = int.Parse(reader["SiteID"].ToString()); this.verseOrder = int.Parse(reader["VerseOrder"].ToString()); this.suraOrder = int.Parse(reader["SuraOrder"].ToString()); this.sortOrderInQuran = int.Parse(reader["SortOrderInQuran"].ToString()); this.halfNo = int.Parse(reader["HalfNo"].ToString()); this.partNo = int.Parse(reader["PartNo"].ToString()); this.hizbNo = int.Parse(reader["HizbNo"].ToString()); this.quraterNo = int.Parse(reader["QuraterNo"].ToString()); this.place = reader["Place"].ToString().Trim(); this.startTime = float.Parse(reader["StartTime"].ToString()); this.endTime = float.Parse(reader["EndTime"].ToString()); this.endTimeText = reader["EndTimeText"].ToString().Trim(); string active = reader["IsActive"].ToString(); this.isActive = (active == "True" || active == "1"); this.createdDate = Convert.ToDateTime(reader["CreatedDate"]); this.createdByUserName = reader["UserName"].ToString().Trim(); this.createdByUserID = int.Parse(reader["CreatedBy"].ToString()); this.qLanguage = reader["QLanguage"].ToString().Trim(); this.verseText = reader["VerseText"].ToString(); this.quranVerseTxt.VerseText = reader["VerseText"].ToString(); this.quranVerseTxt.VerseTextNM = reader["VerseTextNM"].ToString(); this.quranVerseTxt.VerseTextNMAlif = reader["VerseTextNMAlif"].ToString(); } else { if (log.IsErrorEnabled) { log.Error("IDataReader didn't read in Quran.GetVerse"); } } } }
private void GetQuranPage(int siteId, int quranId, int pagenumber, bool isTranslation) { using (IDataReader reader = DBiQuran.iQuran_FrontEnd_GetPage_Header(siteId, quranId, pagenumber, isTranslation)) { if (reader.Read()) { this.partNo = int.Parse(reader["PartNo"].ToString()); this.titles = reader["Titles"].ToString(); } else { if (log.IsErrorEnabled) { log.Error("IDataReader didn't read in QuranPage.GetQuranPage"); } } } }
private bool Create() { int newID = -1; if (this.qLanguage == "ar") { newID = DBiQuran.iVerse_CreateVerse_Text(this.siteID, this.quranID, this.suraID, this.verseOrder, this.suraOrder, halfNo, this.partNo, this.hizbNo, this.quraterNo, this.place, this.startTime, this.endTime, this.endTimeText, this.isActive, this.createdByUserID, this.quranVerseTxt.VerseText, this.quranVerseTxt.VerseTextNM, this.quranVerseTxt.VerseTextNMAlif); } else { newID = DBiQuran.iVerse_CreateVerse_Transl(this.siteID, this.quranID, this.suraID, this.verseID, this.suraOrder, this.verseOrder, this.VerseText); } DBiQuran.iQuran_iSura_Increment_VerseCount(this.siteID, this.quranID, this.suraID); this.verseID = newID; return(newID > -1); }
private void GetVerseTranslation(int siteId, int quranId, int verseId) { using (IDataReader reader = DBiQuran.iVerse_GetVerse_Translation_Dr(siteId, quranId, verseId)) { if (reader.Read()) { this.verseID = int.Parse(reader["VerseID"].ToString()); this.suraID = int.Parse(reader["SuraID"].ToString()); this.quranID = int.Parse(reader["QuranID"].ToString()); this.siteID = int.Parse(reader["SiteID"].ToString()); this.suraOrder = int.Parse(reader["SuraOrder"].ToString()); this.verseOrder = int.Parse(reader["VerseOrder"].ToString()); this.VerseText = reader["VerseText"].ToString(); } else { if (log.IsErrorEnabled) { log.Error("IDataReader didn't read in Quran.GetiQuran"); } } } }
public static bool CheckTranslationStatus(int siteId, int quranId, int suraId, int verseid) { return(DBiQuran.iVerse_Translation_CheckStatus(siteId, quranId, suraId, verseid)); }
/// <summary> /// Used to retrive the original arabic verse id from it's order /// </summary> public static int GetDefaultVerseID(int siteId, int suraOrder, int OrigVerseOrder) { return(DBiQuran.iVerse_GetVerseDefaultID(siteId, suraOrder, OrigVerseOrder)); }
public static IDataReader GetVersesTexts(int siteId, int suraid) { return(DBiQuran.iVerse_GetVersesTexts(siteId, suraid)); }
public static bool DeleteVerse_Translation(int siteId, int quranId, int suraId, int verseid) { DBiQuran.iQuran_iSura_Decrement_VerseCount(siteId, quranId, suraId); return(DBiQuran.iVerse_Delete_Translation(siteId, quranId, suraId, verseid)); }
public static bool OrderExists_Translation(int siteId, int quranID, int suraID, int verseID, int verseOrder) { return(DBiQuran.iVerse_OrderExists_Translation(siteId, quranID, suraID, verseID, verseOrder)); }
public static List <iQuranSearch> GetFrontEndPage_iSura(int siteId, int quranID, int suraID, int selectedVerseID, int pageNumber, bool isTranslation) { IDataReader reader = DBiQuran.iSura_GetFrontPage_Sura(siteId, quranID, suraID, pageNumber, isTranslation); return(LoadListFromReader(reader, selectedVerseID, isTranslation)); }
public static int GetSuraVersesCount(int siteId, int suraid) { return(DBiQuran.iSura_GetSura_VersesCount(siteId, suraid)); }
public static IDataReader GetSuras(int siteId, int quranid) { return(DBiQuran.iSura_GetSuras_Dr(siteId, quranid)); }
public static bool DeleteSura(int siteId, int quranID, int suraid) { DBiQuran.iQuran_Decrement_SuraCount(siteId, quranID); return(DBiQuran.iSura_Delete(siteId, quranID, suraid)); }
public static List <QuranSura> GetiSura_All(int siteId, int quranID) { IDataReader reader = DBiQuran.iSura_FrontEnd_GetSurasIndex(siteId, quranID); return(LoadListFromReader(reader, false)); }
public static int GetSuraIdFromPageNumber(int siteId, int quranId, int pageNumber, bool isTranslation) { return(DBiQuran.iVerse_GetSuraIdFromPageNumber(siteId, quranId, pageNumber, isTranslation)); }
public static int GetVersePageNumber(int siteId, int suraId, int verseid) { return(DBiQuran.iVerse_GetVersePageNumber(siteId, suraId, verseid)); }
public static string GetVerseBism(int siteId, int quranId, bool isTranslation) { return(DBiQuran.iVerse_GetVerseBism(siteId, quranId, isTranslation)); }
public static bool Exists(int siteId, int quranID, int suraID, int verseID, string verseTextNMAlif) { return(DBiQuran.iVerse_Exists(siteId, quranID, suraID, verseID, verseTextNMAlif)); }
public static bool Exists_Translation(int siteId, int quranID, int suraID, int verseID, string verseText) { return(DBiQuran.iVerse_Exists_Translation(siteId, quranID, suraID, verseID, verseText)); }
/// <summary> /// View Page of Quran for reading in front end with selected searched verse /// </summary> public static List <iQuranSearch> GetFrontEnd_QuranPage_WithSearchVerse(int siteId, int quranID, int selectedVerseID, int pageNumber, bool isTranslation) { IDataReader reader = DBiQuran.iQuran_FrontEnd_GetPage(siteId, quranID, pageNumber, isTranslation); return(LoadListFromReader(reader, selectedVerseID, isTranslation)); }