Ejemplo n.º 1
0
 /// <summary>
 /// Construct the viewmodel
 /// </summary>
 /// <param name="vendor">Vendor entity</param>
 /// <param name="countries">Country query for selectionlist</param>
 public VendorEditViewModel(Model.Vendor vendor, List<Model.Country> countries)
 {
     Vendor = new VendorViewModel(vendor);
     CountryList = countries.ToSelectList(c => c.CountryCode, c => c.CountryName);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Construct the viewmodel
 /// </summary>
 /// <param name="countries">Country list for selectionlist</param>
 public VendorCreateViewModel(List<Model.Country> countries)
 {
     Vendor = new VendorViewModel(new Model.Vendor());
     CountryList = countries.ToSelectList(c => c.CountryCode, c => c.CountryName);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Construct the viewmodel
 /// </summary>
 /// <param name="vendor">Vendor entity</param>
 /// <param name="countries">Country query for selectionlist</param>
 public VendorEditViewModel(Model.Vendor vendor, List <Model.Country> countries)
 {
     Vendor      = new VendorViewModel(vendor);
     CountryList = countries.ToSelectList(c => c.CountryCode, c => c.CountryName);
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Construct the viewmodel
 /// </summary>
 /// <param name="countries">Country list for selectionlist</param>
 public VendorCreateViewModel(List <Model.Country> countries)
 {
     Vendor      = new VendorViewModel(new Model.Vendor());
     CountryList = countries.ToSelectList(c => c.CountryCode, c => c.CountryName);
 }