//绑定数据到买家数据 private void BuyerInforDetail(string customTid) { string buyerNick = TradeService.GetTrade(customTid).buyer_nick; List <Alading.Entity.Consumer> buyerList = ConsumerService.GetConsumer(p => p.nick == buyerNick); if (buyerList.Count > 0) { BuyerNick.Text = buyerNick; Birthday.Text = (buyerList.First().birthday ?? DateTime.Parse(Alading.Taobao.Constants.DEFAULT_TIME)).ToString("yyyy-MM-dd"); register.Text = (buyerList.First().created ?? DateTime.Parse(Alading.Taobao.Constants.DEFAULT_TIME)).ToString("yyyy-MM-dd"); lastLogin.Text = (buyerList.First().last_visit ?? DateTime.Parse(Alading.Taobao.Constants.DEFAULT_TIME)).ToString("yyyy-MM-dd"); zip.Text = buyerList.First().buyer_zip; if (buyerList.First().sex == "f") { sex.SelectedIndex = 0; } else if (buyerList.First().sex == "m") { sex.SelectedIndex = 1; } level.Text = "信用等级:" + buyerList.First().level.ToString(); score.Text = "信用总分:" + buyerList.First().score.ToString(); total.Text = buyerList.First().buyer_total_num.ToString(); goodNum.Text = buyerList.First().buyer_good_num.ToString(); ((ILinearGauge)rating.Gauges[0]).Scales[0].Value = (float)buyerList.First().level * 90 / 20; } }
public Responses.Consumer GetConsumer(Guid consumerId) { return(_service.GetConsumer(consumerId)); }
public async Task <IEnumerable <DTOConsumer> > GetConsumer() { return(await _service.GetConsumer()); }