Beispiel #1
0
		/// <summary>
		/// Creates a productRework viewModel for the given model (ignores productGroup)
		/// <para>Use this constructor if you don't care for the links between the same products</para>
		/// <para>It automatically create a new ProductVm for each instance or ProductReworkVm</para>
		/// </summary>
		/// <param name="model"></param>
		public ProductReworkVm(Model.ProductRework model)
		{
			Id = model.Id;
			Name = model.Name;
			Code = model.Code;
			Product = new ProductVm(model.Product, null);
			Rework = new ReworkVm(model.Rework);
		}
Beispiel #2
0
		public ProductReworkVm(Model.ProductRework model, ProductVm parentVm)
		{
			Id = model.Id;
			Name = model.Name;
			Code = model.Code;
			Product = parentVm;
			Rework = new ReworkVm(model.Rework);
		}