Example #1
0
 public void PopulateQuestionData()
 {
     foreach (CupeQuestion question in owner.Questions)
     {
         CupeQuestionData data = new CupeQuestionData();
         data.CurrentValue = "";
         data.FutureValue  = "";
         data.ID           = question.ID;
         questionData.Add(data);
     }
 }
Example #2
0
        public override List<CupeQuestionData> GetCUPEQuestionData()
        {
            List<CUPEQUESTION> cupeQuestionEntList = (from ent in dbo.CUPEQUESTION
                                                      select ent).ToList();

            List<CupeQuestionData> cupeQuestionDataList = new List<CupeQuestionData>();
            CupeQuestionData cupeQuestionData;
            CupeQuestionStringData cupeQuestionStringData;
            foreach (CUPEQUESTION cupeQuestionEnt in cupeQuestionEntList)
            {
                cupeQuestionStringData = new CupeQuestionStringData();
                cupeQuestionStringData.OriginalQuestionText = cupeQuestionEnt.NAME.TrimEnd();
                cupeQuestionStringData.QuestionText = cupeQuestionEnt.NAME.TrimEnd();
                cupeQuestionStringData.ChoiceA = cupeQuestionEnt.COMMODITY.TrimEnd();
                cupeQuestionStringData.ChoiceB = cupeQuestionEnt.UTILITY.TrimEnd();
                cupeQuestionStringData.ChoiceC = cupeQuestionEnt.PARTNER.TrimEnd();
                cupeQuestionStringData.ChoiceD = cupeQuestionEnt.ENABLER.TrimEnd();
                cupeQuestionData = new CupeQuestionData();
                cupeQuestionData.StringData = cupeQuestionStringData;
                cupeQuestionData.InDefault20 = cupeQuestionEnt.INTWENTY == "Y";
                cupeQuestionData.InDefault10 = cupeQuestionEnt.INTEN == "Y";

                cupeQuestionDataList.Add(cupeQuestionData);
            }

            return cupeQuestionDataList;
        }
Example #3
0
        public void PopulateQuestionData()
        {
            foreach (CupeQuestion question in owner.Questions)
            {
                CupeQuestionData data = new CupeQuestionData();
                data.CurrentValue = "";
                data.FutureValue = "";
                data.ID = question.ID;
                questionData.Add(data);

            }
        }
Example #4
0
        public override List<CupeQuestionData> GetCUPEQuestionData()
        {
            List<XElement> cupeQuestionEntList = (from ent in dbo.Element("CUPEQUESTIONS").Elements("CUPEQUESTION")
                                                  select ent).ToList();

            List<CupeQuestionData> cupeQuestionDataList = new List<CupeQuestionData>();
            CupeQuestionData cupeQuestionData;
            CupeQuestionStringData cupeQuestionStringData;
            foreach (XElement cupeQuestionEnt in cupeQuestionEntList)
            {
                cupeQuestionStringData = new CupeQuestionStringData();
                cupeQuestionStringData.OriginalQuestionText = cupeQuestionStringData.QuestionText = cupeQuestionEnt.Element("NAME").Value;
                cupeQuestionStringData.ChoiceA = cupeQuestionEnt.Element("COMMODITY").Value;
                cupeQuestionStringData.ChoiceB = cupeQuestionEnt.Element("UTILITY").Value;
                cupeQuestionStringData.ChoiceC = cupeQuestionEnt.Element("PARTNER").Value;
                cupeQuestionStringData.ChoiceD = cupeQuestionEnt.Element("ENABLER").Value;
                cupeQuestionData = new CupeQuestionData();
                cupeQuestionData.StringData = cupeQuestionStringData;
                cupeQuestionData.InDefault20 = cupeQuestionEnt.Element("INTWENTY").Value == "Y";
                cupeQuestionData.InDefault10 = cupeQuestionEnt.Element("INTEN").Value == "Y";
                cupeQuestionDataList.Add(cupeQuestionData);
            }

            return cupeQuestionDataList;
        }