Ejemplo n.º 1
0
        /// <summary>
        /// Sets the model.
        /// </summary>
        /// <param name="model">The model.</param>
        public void SetModel(ProcessViewEdit model)
        {
            Model = model;
            Sections.Clear();

            if (Model != null)
            {
                foreach (var section in Model.SectionList)
                {
                    var sectionViewModel = new ProcessViewSectionViewModel(section, this);

                    Sections.Add(sectionViewModel);
                }
            }
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ProcessViewFieldViewModel"/> class.
 /// </summary>
 /// <param name="model">The model.</param>
 /// <param name="parentViewModel">The parent view model.</param>
 public ProcessViewFieldViewModel(ProcessViewFieldEdit model, ProcessViewSectionViewModel parentViewModel)
 {
     Parent = parentViewModel;
     SetModel(model);
 }