From 300c9b4910c8443d801801854190389357d2ab5a Mon Sep 17 00:00:00 2001 From: zhuyiyi <649091362@qq.com> Date: Sat, 4 Jul 2026 17:08:25 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BD=A6=E9=97=B4=E4=B8=8B=E8=BD=BD=E9=87=8D?= =?UTF-8?q?=E5=91=BD=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- copydownload.aspx.cs | 4 ++++ supplierBuildFile.aspx.cs | 19 +++++++++++++------ supplierDownload.aspx.cs | 4 ++++ 3 files changed, 21 insertions(+), 6 deletions(-) diff --git a/copydownload.aspx.cs b/copydownload.aspx.cs index ed3bda7..8b04809 100644 --- a/copydownload.aspx.cs +++ b/copydownload.aspx.cs @@ -129,6 +129,10 @@ public partial class copydownload : System.Web.UI.Page { rname = dealMemoName(rname); } + if ("138".Equals(dr["SupplierId"].ToString())) + { + rname = formatMemo(dr["seller_memo"]) + string.Format("《{0}》", dr["ctid"]) + ext; + } if (!hasFile) { if (File.Exists(fname)) diff --git a/supplierBuildFile.aspx.cs b/supplierBuildFile.aspx.cs index ae5209a..5beb50a 100644 --- a/supplierBuildFile.aspx.cs +++ b/supplierBuildFile.aspx.cs @@ -131,6 +131,11 @@ public partial class supplierBuildFile : System.Web.UI.Page break; } string fname = df_name + ext; + string rname = formatMemo(row["seller_memo"]) + ext; + if (supplierId == 138) + { + rname = formatMemo(row["seller_memo"]) + string.Format("《{0}》", ctid) + ext; + } if (Convert.ToInt16(row["OrderState"]) != 6) { updateSql += string.Format("update CE_ErpPackDataItem set message = '订单状态不正确!' where packId= {0} and ctid='{1}' ;", packId, ctid); @@ -168,7 +173,8 @@ public partial class supplierBuildFile : System.Web.UI.Page } try { - copyFile(getDesignDate(row["FinishDesignTime"]), suppierName, fname, zipFileName.Replace(".zip", "")); + + copyFile(getDesignDate(row["FinishDesignTime"]), suppierName, fname, rname, zipFileName.Replace(".zip", "")); writeLog("打包复制文件!" + zipFileName.Replace(".zip", "") + ":" + fname); files.Add(fname); supplierId = 0; @@ -253,7 +259,7 @@ public partial class supplierBuildFile : System.Web.UI.Page return name; } - + private string formatMemo(object memo) { string m = memo.ToString(); @@ -261,16 +267,16 @@ public partial class supplierBuildFile : System.Web.UI.Page return m; } - private void copyFile(string date, string supplier, string file, string zipName = "") + private void copyFile(string date, string supplier, string file, string rname, string zipName = "") { string path = getCopyPath(date, supplier, zipName); if (!Directory.Exists(path)) Directory.CreateDirectory(path); string fname = Path.GetFileName(file); - File.Copy(file, path + "\\" + fname, true); - if (!File.Exists(path + "\\" + fname)) + File.Copy(file, path + "\\" + rname, true); + if (!File.Exists(path + "\\" + rname)) { - File.Copy(file, path + "\\" + fname, true); + File.Copy(file, path + "\\" + rname, true); } } @@ -623,6 +629,7 @@ public partial class supplierBuildFile : System.Web.UI.Page { fileName = dealMemoName(fileName); } + foreach (var rule in replaceRules) { fileName = fileName.Replace(rule.Key, rule.Value); diff --git a/supplierDownload.aspx.cs b/supplierDownload.aspx.cs index fd579d6..5d0a9ad 100644 --- a/supplierDownload.aspx.cs +++ b/supplierDownload.aspx.cs @@ -176,6 +176,10 @@ public partial class supplierDownload : System.Web.UI.Page { rname = dealMemoName(rname); } + if ("138".Equals(dr["SupplierId"].ToString())) + { + rname = formatMemo(dr["seller_memo"]) + string.Format("《{0}》", dr["ctid"]) + ext; + } int IsFileEncrypt = IsFileEncrypted(fname); if (IsFileEncrypt == 1 && File.Exists(fname)) {