public ServiceResult <bool> ScanLogin(ScanQRCodeIM im) { return(new ServiceResult <bool> { Data = new PosShopComponent().ScanLogin(im.Code, this.GetUser().Id) }); }
public async Task <ServiceResult <ScanMerchantQRCodeModel> > ScanMerchantQRCode(ScanQRCodeIM im) { ScanMerchantQRCodeOM om = await new OrderComponent().ScanMerchantQRCode(this.GetUser(), im.Code); ScanMerchantQRCodeModel result = new ScanMerchantQRCodeModel(); result.MerchantId = om.MerchantId; result.MerchantName = om.MerchantName; result.Avatar = om.Avatar; result.L1VerifyStatus = om.L1VerifyStatus; result.L2VerifyStatus = om.L2VerifyStatus; result.FiatCurrency = om.FiatCurrency; result.MarkupRate = om.MarkupRate; if (om.WaletInfoList != null) { result.WaletInfoList = new System.Collections.Generic.List <WalletInfo>(); foreach (var item in om.WaletInfoList) { result.WaletInfoList.Add(new WalletInfo { Id = item.Id, IconUrl = item.IconUrl, NewStatus = item.NewStatus, Code = item.Code, Name = item.Name, UseableBalance = item.UseableBalance, FrozenBalance = item.FrozenBalance, ExchangeRate = item.ExchangeRate, FiatBalance = item.FiatBalance, MerchantSupported = item.MerchantSupported, DecimalPlace = item.DecimalPlace, CryptoEnable = item.CryptoEnable }); } } return(new ServiceResult <ScanMerchantQRCodeModel> { Data = result }); }