public static OutputDeliveryViewModel New(OutputDeliveryInfo source) { OutputDeliveryViewModel obj = new OutputDeliveryViewModel(); obj.CopyFrom(source); return(obj); }
public static void Add(OutputDeliveryViewModel item) { OutputDelivery newItem = OutputDelivery.New(); item.CopyTo(newItem); newItem.Save(); item.CopyFrom(newItem); }
public static OutputDeliveryViewModel New() { OutputDeliveryViewModel obj = new OutputDeliveryViewModel(); obj.CopyFrom(OutputDeliveryInfo.New()); obj.Lines = new OutputDeliveryLineListViewModel(); return(obj); }
public static OutputDeliveryViewModel Get(long oid, bool childs = false) { OutputDeliveryViewModel obj = new OutputDeliveryViewModel(); OutputDeliveryInfo delivery = OutputDeliveryInfo.Get(oid, ETipoEntidad.Cliente, childs); if (delivery == null) { return(null); } obj.CopyFrom(delivery); if (childs) { obj.Lines = OutputDeliveryLineListViewModel.Get(delivery.Conceptos); } return(obj); }