Esempio n. 1
0
 private static Credit MapRowToObj(CreditRow row)
 {
     var existingItem = new Credit
     {
         CreditId = row.CreditId,
         ShowId = row.ShowId,
         PersonId = row.PersonId,
         CreditTypeId = row.CreditTypeId,
         Character = row.Character
     };
     existingItem.IsDirty = false;
     return existingItem;
 }
Esempio n. 2
0
        private static List<CreditRow> LoadCredits()
        {
            var maxId = 0;
            var list = new List<CreditRow>();
            CreditRow crd;
            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 1,
                PersonId = 1,
                CreditTypeId = 1,
                Character = "Philomena"
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 1,
                PersonId = 2,
                CreditTypeId = 2
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 1,
                PersonId = 3,
                CreditTypeId = 5
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 1,
                PersonId = 3,
                CreditTypeId = 1,
                Character = "Martin Sixsmith"
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 1,
                PersonId = 4,
                CreditTypeId = 1,
                Character = "Young Philomena"
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 1,
                PersonId = 5,
                CreditTypeId = 2
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 2,
                PersonId = 6,
                CreditTypeId = 2
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 2,
                PersonId = 6,
                CreditTypeId = 5
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 2,
                PersonId = 7,
                CreditTypeId = 1,
                Character = "Anna"
            };
            list.Add(crd);

            crd = new CreditRow
            {
                CreditId = ++maxId,
                ShowId = 2,
                PersonId = 8,
                CreditTypeId = 1,
                Character = "Olaf"
            };
            list.Add(crd);

            return list;
        }