public string Title() { var t = new TitleBuilder(); t.Append(ProductSku != null ? Product.Title() : "Addition"); t.Append(" for ").Append(Order != null? Order.CustomerName: "Customer"); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); string stars = "*****".Substring(0, Rating); t.Append(stars); return t.ToString(); }
public string Title() { var t = new TitleBuilder(); if (PayeeCompoundKey != null) { t.Append(Payee.Title()); } t.Append(Amount); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); if (NameStyle) { t.Append(LastName).Append(FirstName); } else { t.Append(FirstName).Append(LastName); } return t.ToString(); }
internal override string GetTitle(object obj, string format) { object referencedObject = property.GetValue(obj, new object[0]); if (referencedObject == null) { return(""); } else { #pragma warning disable 618 return(TitleBuilder.TitleOrToString(referencedObject, format)); #pragma warning restore 618 } }
public SpecialOfferProduct AssociateSpecialOfferWithProduct(SpecialOffer offer, Product product) { //First check if association already exists IQueryable<SpecialOfferProduct> query = from sop in Instances<SpecialOfferProduct>() where sop.SpecialOfferID == offer.SpecialOfferID && sop.ProductID == product.ProductID select sop; if (query.Count() != 0) { var t = new TitleBuilder(); t.Append(offer).Append(" is already associated with").Append(product); WarnUser(t.ToString()); return null; } var newSop = NewTransientInstance<SpecialOfferProduct>(); newSop.SpecialOffer = offer; newSop.Product = product; //product.SpecialOfferProduct.Add(newSop); Persist(ref newSop); return newSop; }
public override string ToString() { var t = new TitleBuilder(); t.Append(AddressLine1).Append("..."); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(Name).Append(",", this.AccountNumber); return t.ToString(); }
public SalesOrderDetail AddNewDetail(Product product, [DefaultValue((short)1), Range(1, 999)] short quantity) { int stock = product.NumberInStock(); if (stock < quantity) { var t = new TitleBuilder(); t.Append("Current inventory of").Append(product).Append(" is").Append(stock); Container.WarnUser(t.ToString()); } var sod = Container.NewTransientInstance<SalesOrderDetail>(); sod.SalesOrderHeader = this; sod.SalesOrderID = SalesOrderID; sod.OrderQty = quantity; sod.SpecialOfferProduct = product.BestSpecialOfferProduct(quantity); sod.Recalculate(); return sod; }
public override string ToString() { var t = new TitleBuilder(); t.Append(Rate, "C", null).Append(" from", RateChangeDate, "d", null); return t.ToString(); }
public void EnumAsArgumentWithMultipleWordsFormatted() { var t = new TitleBuilder(); t.Append(Sex.NotSpecified); Assert.AreEqual("Not Specified", t.ToString()); }
public void NewBuilder() { builder = new TitleBuilder(); }
public string Title() { TitleBuilder t = new TitleBuilder(); t.Append(Quantity).Append(" x", Product); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(FirstName).Append(LastName); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(StandardCost).Append(StartDate).Append("~"); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(ContactDetails); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(Contact).Append(",", AccountNumber); return t.ToString(); }
public void TestNewBuilderContainsUnmodifiedText() { builder = new TitleBuilder("Text"); AssertTitleIs("Text"); }
public override string ToString() { var t = new TitleBuilder(); t.Append(Contact).Append(":", ContactType); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(ObfuscatedNumber); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(Employee); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(AddressType).Append(":", Address); return t.ToString(); }
public string Title() { var t = new TitleBuilder(); t.Append(this.Description); return t.ToString(); }
public void EnumAsArgumentWithSingleWord() { var t = new TitleBuilder(); t.Append(Sex.Female); Assert.AreEqual("Female", t.ToString()); }
public override string ToString() { var t = new TitleBuilder(); t.Append(Quantity.ToString()).Append(" in", Location).Append(" -", Shelf); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(SalesReason); return t.ToString(); }
public string Title() { var t = new TitleBuilder(); t.Append(DrinkSku != null ? Drink.Title() : "Order"); t.Append(" for ").Append(CustomerName); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(OrderQty.ToString()).Append(" x", Product); return t.ToString(); }
public void NewBuilder() { builder = new TitleBuilder("Text"); }
public string Title() { var t = new TitleBuilder(); t.Append(Name); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(QuotaDate, "d", null).Append(SalesQuota, "C", null); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(Description); return t.ToString(); }
public override string ToString() { var t = new TitleBuilder(); t.Append(Department).Append(StartDate, "d", null); return t.ToString(); }