示例#1
0
        public JsonResult FilteredInvoice(Cms.PartnerInfo.Models.GetInvoiceInfo request)
        {
            CompanyGroup.Dto.ServiceRequest.GetInvoiceInfo req = new CompanyGroup.Dto.ServiceRequest.GetInvoiceInfo()
            {
                LanguageId = this.ReadLanguageFromCookie(),
                VisitorId = this.ReadObjectIdFromCookie(),
                PaymentType = request.PaymentType
            };

            List<CompanyGroup.Dto.PartnerModule.InvoiceInfo> response = this.PostJSonData<List<CompanyGroup.Dto.PartnerModule.InvoiceInfo>>("CustomerService", "GetInvoiceInfo", req);

            List<Cms.PartnerInfo.Models.InvoiceInfo> invoiceInfoList = new List<Cms.PartnerInfo.Models.InvoiceInfo>();

            invoiceInfoList.AddRange(response.ConvertAll(x => ConverInvoiceInfoToInvoiceInfo(x)));

            Cms.PartnerInfo.Models.InvoiceInfoList model = new Cms.PartnerInfo.Models.InvoiceInfoList(invoiceInfoList);

            return Json(model, "application/json; charset=utf-8", System.Text.Encoding.UTF8, JsonRequestBehavior.DenyGet);
        }
示例#2
0
        public ActionResult Index()
        {
            CompanyGroup.Dto.ServiceRequest.GetInvoiceInfo request = new CompanyGroup.Dto.ServiceRequest.GetInvoiceInfo()
            {
                LanguageId = this.ReadLanguageFromCookie(),
                VisitorId = this.ReadObjectIdFromCookie(), 
                PaymentType = 1
            };

            List<CompanyGroup.Dto.PartnerModule.InvoiceInfo> response = this.PostJSonData<List<CompanyGroup.Dto.PartnerModule.InvoiceInfo>>("CustomerService", "GetInvoiceInfo", request);

            List<Cms.PartnerInfo.Models.InvoiceInfo> invoiceInfoList = new List<Cms.PartnerInfo.Models.InvoiceInfo>();

            invoiceInfoList.AddRange(response.ConvertAll(x => ConverInvoiceInfoToInvoiceInfo(x)));

            Cms.PartnerInfo.Models.InvoiceInfoList model = new Cms.PartnerInfo.Models.InvoiceInfoList(invoiceInfoList);

            return View("Index", model);
        }