/// <summary> /// 查询打印的数据集合 /// </summary> /// <returns></returns> public ActionResult GetPrintSource() { string CompanyID = WebUtil.GetFormValue <string>("CompanyID"); string SnNum = WebUtil.GetFormValue <string>("SnNum"); Bill <InStorageEntity, InStorDetailEntity> bill = new InStorageOrder(CompanyID); DataSet ds = bill.GetPrint(SnNum); DataResult <DataSet> dataResult = new DataResult <DataSet>(); dataResult.Code = (int)EResponseCode.Success; dataResult.Message = "响应成功"; dataResult.Result = ds; return(Content(JsonHelper.SerializeObject(dataResult))); }
/// <summary> /// 查询数据集 /// </summary> /// <param name="entity"></param> /// <param name="list"></param> /// <returns></returns> public DataSet GetDataSource(ReportsEntity entity, List <ReportParamsEntity> list, int orderType, string orderNum) { DataSet ds = null; if (entity.ReportType == (int)EReportType.Report) { ds = this.Reports.GetDataSource(entity, list); } else { if (orderType == (int)EReportType.InBill) { Bill <InStorageEntity, InStorDetailEntity> bill = new InStorageOrder(this.CompanyID); ds = bill.GetPrint(orderNum); } else if (orderType == (int)EReportType.OutBill) { Bill <OutStorageEntity, OutStoDetailEntity> bill = new OutStorageOrder(this.CompanyID); ds = bill.GetPrint(orderNum); } else if (orderType == (int)EReportType.User) { AdminProvider provider = new AdminProvider(this.CompanyID); ds = provider.GetPrint(orderNum); } } if (ds != null) { foreach (DataTable table in ds.Tables) { if (table.Rows.Count == 0) { DataRow row = table.NewRow(); table.Rows.Add(row); } } } return(ds); }
/// <summary> /// 查询数据集 /// </summary> /// <param name="entity"></param> /// <param name="list"></param> /// <returns></returns> public DataSet GetDataSource(ReportsEntity entity, List <ReportParamsEntity> list, int orderType, string orderNum) { DataSet ds = null; if (entity.ReportType == (int)EReportType.Report) { ds = this.Reports.GetDataSource(entity, list); } else { if (orderType == (int)EOrder.InOrder) { Bill <InStorageEntity, InStorDetailEntity> bill = new InStorageOrder(); ds = bill.GetPrint(orderNum); } else if (orderType == (int)EOrder.OutOrder) { Bill <OutStorageEntity, OutStoDetailEntity> bill = new OutStorageOrder(); ds = bill.GetPrint(orderNum); } } return(ds); }
/// <summary> /// 查询数据集 /// </summary> /// <param name="entity"></param> /// <param name="list"></param> /// <returns></returns> public DataSet GetDataSource(ReportsEntity entity, List<ReportParamsEntity> list,int orderType,string orderNum) { DataSet ds = null; if (entity.ReportType == (int)EReportType.Report) { ds = this.Reports.GetDataSource(entity, list); } else { if (orderType == (int)EOrder.InOrder) { Bill<InStorageEntity, InStorDetailEntity> bill = new InStorageOrder(); ds = bill.GetPrint(orderNum); } else if (orderType == (int)EOrder.OutOrder) { Bill<OutStorageEntity, OutStoDetailEntity> bill = new OutStorageOrder(); ds = bill.GetPrint(orderNum); } } return ds; }