private void btnExport_Click(object sender, EventArgs e) { if ((!this._includeUnSales && !this._includeOnSales) && !this._includeInStock) { this.ShowMsg("至少要选择包含一个商品状态", false); } else { string selectedValue = this.dropExportVersions.SelectedValue; if (string.IsNullOrEmpty(selectedValue) || (selectedValue.Length == 0)) { this.ShowMsg("请选择一个导出版本", false); } else { bool includeCostPrice = false; bool includeStock = this.chkExportStock.Checked; bool flag3 = true; string str2 = "http://" + HttpContext.Current.Request.Url.Host + ((HttpContext.Current.Request.Url.Port == 80) ? "" : (":" + HttpContext.Current.Request.Url.Port)) + Globals.ApplicationPath; string applicationPath = Globals.ApplicationPath; DataSet set = ProductHelper.GetExportProducts(this.GetQuery(), includeCostPrice, includeStock, (string)this.ViewState["RemoveProductIds"]); TransferHelper.GetExporter(selectedValue, new object[] { set, includeCostPrice, includeStock, flag3, str2, applicationPath }).DoExport(); } } }
private void btnExport_Click(object sender, System.EventArgs e) { if (!this._includeUnSales && !this._includeOnSales && !this._includeInStock) { this.ShowMsg("至少要选择包含一个商品状态", false); return; } string selectedValue = this.dropExportVersions.SelectedValue; if (!string.IsNullOrEmpty(selectedValue) && selectedValue.Length != 0) { bool flag = false; bool @checked = this.chkExportStock.Checked; bool flag2 = true; string text = "http://" + System.Web.HttpContext.Current.Request.Url.Host + ((System.Web.HttpContext.Current.Request.Url.Port == 80) ? "" : (":" + System.Web.HttpContext.Current.Request.Url.Port)) + Globals.ApplicationPath; string applicationPath = Globals.ApplicationPath; System.Data.DataSet exportProducts = ProductHelper.GetExportProducts(this.GetQuery(), flag, @checked, (string)this.ViewState["RemoveProductIds"]); ExportAdapter exporter = TransferHelper.GetExporter(selectedValue, new object[] { exportProducts, flag, @checked, flag2, text, applicationPath }); exporter.DoExport(); return; } this.ShowMsg("请选择一个导出版本", false); }
protected void btnExport_Click(object sender, EventArgs e) { string selectedValue = dropExportVersions.SelectedValue; if (string.IsNullOrEmpty(selectedValue) || (selectedValue.Length == 0)) { ShowMsg("请选择一个导出版本", false); } else { bool includeCostPrice = false; bool includeStock = chkExportStock.Checked; DataSet exportData = ProductHelper.GetExportProducts(GetQuery(), includeCostPrice, includeStock, (string)ViewState["RemoveProductIds"]); TransferHelper.GetExporter(selectedValue, exportData, includeCostPrice, includeStock, true).DoExport(); } }
private void btnExport_Click(object sender, EventArgs e) { string selectedValue = this.dropExportVersions.SelectedValue; if (string.IsNullOrEmpty(selectedValue) || (selectedValue.Length == 0)) { this.ShowMsg("请选择一个导出版本", false); } else { bool includeCostPrice = false; bool includeStock = this.chkExportStock.Checked; bool flag3 = true; DataSet set = SubSiteProducthelper.GetExportProducts(this.GetQuery(), includeCostPrice, includeStock, (string)this.ViewState["RemoveProductIds"]); TransferHelper.GetExporter(selectedValue, new object[] { set, includeCostPrice, includeStock, flag3 }).DoExport(); } }
private void Export(HttpContext context) { string text = context.Request["adapterName"]; if (string.IsNullOrEmpty(text) || text.Length == 0) { throw new HidistroAshxException("请选择一个导出版本!"); } bool flag = false; bool value = base.GetBoolParam(context, "exportStock", true).Value; bool flag2 = true; string empty = string.Empty; string text2 = "http://" + HttpContext.Current.Request.Url.Host; string empty2 = string.Empty; empty = (string.IsNullOrEmpty(context.Request["RemoveProductId"]) ? "" : context.Request["RemoveProductId"]); DataSet exportProducts = ProductHelper.GetExportProducts(this.GetQuery(context), flag, value, empty); ExportAdapter exporter = TransferHelper.GetExporter(text, exportProducts, flag, value, flag2, text2, empty2); exporter.DoExport(); }