public static AdTypeViewModel Get(AD_TYPE type) { return(new AdTypeViewModel( type == AD_TYPE.DONATION ? "Doando" : "Vendendo", type == AD_TYPE.DONATION ? "doacao" : "venda", type == AD_TYPE.DONATION ? "donation" : "sale", type.Equals(AD_TYPE.SALE), type)); }
public AdTypeViewModel(string name, string URL, string productTypeClass, bool isSale, AD_TYPE type) { this.Name = name; this.URL = URL; this.ProductTypeClass = productTypeClass; this.isSale = isSale; this.Type = type; }