public Section Map(CreateOrEditViewModel createOrEdit)
        {
            Section section = new Section();

              if (createOrEdit.Id != null)
            section = this.handler.Storage.GetRepository<ISectionRepository>().WithKey((int)createOrEdit.Id);

              section.Code = createOrEdit.Code;
              section.Name = createOrEdit.Name;
              return section;
        }
 public SectionViewModel Build(Section section)
 {
     return new SectionViewModel()
       {
     Id = section.Id,
     Name = section.Name,
     Variables = this.handler.Storage.GetRepository<IVariableRepository>().FilteredBySectionId(section.Id).Select(
       v => new VariableViewModelBuilder(this.handler).Build(v)
     )
       };
 }