Example #1
0
        private void FixupTestimonial(Testimonial previousValue)
        {
            if (previousValue != null && previousValue.HistoryItems.Contains(this))
            {
                previousValue.HistoryItems.Remove(this);
            }

            if (Testimonial != null)
            {
                if (!Testimonial.HistoryItems.Contains(this))
                {
                    Testimonial.HistoryItems.Add(this);
                }
                if (TestimonialId != Testimonial.TestimonialId)
                {
                    TestimonialId = Testimonial.TestimonialId;
                }
            }
            else if (!_settingFK)
            {
                TestimonialId = null;
            }
        }
Example #2
0
        private void FixupTestimonial(Testimonial previousValue)
        {
            if (previousValue != null && previousValue.HistoryItems.Contains(this))
            {
                previousValue.HistoryItems.Remove(this);
            }

            if (Testimonial != null)
            {
                if (!Testimonial.HistoryItems.Contains(this))
                {
                    Testimonial.HistoryItems.Add(this);
                }
                if (TestimonialId != Testimonial.TestimonialId)
                {
                    TestimonialId = Testimonial.TestimonialId;
                }
            }
            else if (!_settingFK)
            {
                TestimonialId = null;
            }
        }
 public TestimonialPresentable(Testimonial testimonial)
 {
     _base = testimonial;
 }