Beispiel #1
0
        public DataSet Search(Dictionary <Enumaration.SearchSlideCriteria, Object> criteria, int pageToRetrieve, String orderBy)
        {
            DataSet ds  = new DataSet();
            DASlide oDa = new DASlide();

            ds = oDa.Search(criteria, pageToRetrieve, orderBy, Enumaration.RecordsPerPage);

            return(ds);
        }
Beispiel #2
0
        public void PersistXML(DataRow drSlide)
        {
            DASlide oDASlide = new DASlide();

            string xmlId = "-1";

            if (drSlide[Entities.TrainingSlide.XML_ID] != DBNull.Value)
            {
                xmlId = drSlide[Entities.TrainingSlide.XML_ID].ToString();
            }
            Entities.SP_USP_SlideCultureXML sp = new Entities.SP_USP_SlideCultureXML(drSlide[Entities.TrainingSlide.SLIDE_ID].ToString(),
                                                                                     xmlId,
                                                                                     drSlide[Entities.TrainingSlide.SLIDE_TYPE].ToString()
                                                                                     );
            DataSet dsXML = oDASlide.ExecuteStoredProcedure(Entities.SP_USP_SlideCultureXML.SP_NAME, sp.ParamsList);

            if (xmlId.Equals("-1"))
            {
                drSlide[Entities.TrainingSlide.XML_ID] = Convert.ToInt64(dsXML.Tables[0].Rows[0][Entities.CultureXML.XML_ID].ToString());
                oDASlide.SaveSlides(null, drSlide);
            }
        }
Beispiel #3
0
        public void Save(DataSet ds, DbTransaction transaction)
        {
            DataRow            drSlide  = ds.Tables[Entities.TrainingSlide.TABLE_NAME].Rows[0];
            DASlide            oDASlide = new DASlide();
            DACultureResources oDACr    = new DACultureResources();

            //Saving culture resources for slide name:Start
            DataTable dtSlideCr = ds.Tables[Entities.CultureResources.TABLE_NAME];

            PersistSlideCultureText(transaction, drSlide, oDACr, dtSlideCr);
            //Saving culture resources for slide name:Finish

            //Saving culture resources for slide main details:Start
            SaveSlideFiles(ds, transaction, drSlide, oDACr);
            //Saving culture resources for slide main details:Finish

            //Saving slide Start
            oDASlide.SaveSlides(transaction, drSlide);
            Int64 slideId = Convert.ToInt64(drSlide[Entities.TrainingSlide.SLIDE_ID]);

            //Saving slide Finish


            switch (int.Parse(drSlide[Entities.TrainingSlide.SLIDE_TYPE].ToString()))
            {
            case (int)Enumaration.SlideType.Questionnaire:
            {
                SaveSurveyDetails(ds, transaction, oDACr, slideId);
                break;
            }

            case (int)Enumaration.SlideType.Navigation:
            {
                SaveNavigationDetails(ds, transaction, oDACr, slideId);
                break;
            }
            }
        }
Beispiel #4
0
        public Boolean IsSlideNameDuplicated(DataRow slideRow, DataRow cultureRes)
        {
            DASlide oDASlide = new DASlide();

            return(oDASlide.IsSlideNameDuplicated(slideRow, cultureRes));
        }
Beispiel #5
0
        public DataSet GetSlideById(string slideId)
        {
            DASlide oDASlide = new DASlide();

            return(oDASlide.GetSlideById(slideId));
        }