From 96b22db20a74963e39e490e94bf969cc60ef1b04 Mon Sep 17 00:00:00 2001
From: cnf <3200815559@qq.com>
Date: 星期一, 12 五月 2025 17:45:49 +0800
Subject: [PATCH] 最新

---
 StandardInterface/MESApplication/Controllers/PLM/PLMController.cs |   30 ++++++++++++++++++++++++++++++
 .vs/HM-C#/v17/.wsuo                                               |    0 
 .vs/HM-C#/v17/DocumentLayout.backup.json                          |   23 +++++++++++++++++++++++
 .vs/HM-C#/v17/DocumentLayout.json                                 |    2 +-
 4 files changed, 54 insertions(+), 1 deletions(-)

diff --git "a/.vs/HM-C\043/v17/.wsuo" "b/.vs/HM-C\043/v17/.wsuo"
index ffcd3b5..f077e22 100644
--- "a/.vs/HM-C\043/v17/.wsuo"
+++ "b/.vs/HM-C\043/v17/.wsuo"
Binary files differ
diff --git "a/.vs/HM-C\043/v17/DocumentLayout.backup.json" "b/.vs/HM-C\043/v17/DocumentLayout.backup.json"
new file mode 100644
index 0000000..7f931ec
--- /dev/null
+++ "b/.vs/HM-C\043/v17/DocumentLayout.backup.json"
@@ -0,0 +1,23 @@
+{
+  "Version": 1,
+  "WorkspaceRootPath": "D:\\VISUAL STUDIOS JOB\\HM\\HM-C#\\",
+  "Documents": [],
+  "DocumentGroupContainers": [
+    {
+      "Orientation": 0,
+      "VerticalTabListWidth": 256,
+      "DocumentGroups": [
+        {
+          "DockedWidth": 200,
+          "SelectedChildIndex": -1,
+          "Children": [
+            {
+              "$type": "Bookmark",
+              "Name": "ST:0:0:{1c4feeaa-4718-4aa9-859d-94ce25d182ba}"
+            }
+          ]
+        }
+      ]
+    }
+  ]
+}
\ No newline at end of file
diff --git "a/.vs/HM-C\043/v17/DocumentLayout.json" "b/.vs/HM-C\043/v17/DocumentLayout.json"
index 7f931ec..1c8f969 100644
--- "a/.vs/HM-C\043/v17/DocumentLayout.json"
+++ "b/.vs/HM-C\043/v17/DocumentLayout.json"
@@ -1,6 +1,6 @@
 {
   "Version": 1,
-  "WorkspaceRootPath": "D:\\VISUAL STUDIOS JOB\\HM\\HM-C#\\",
+  "WorkspaceRootPath": "D:\\VISUAL STUDIOS JOB\\HM\\HM-c#\\",
   "Documents": [],
   "DocumentGroupContainers": [
     {
diff --git a/StandardInterface/MESApplication/Controllers/PLM/PLMController.cs b/StandardInterface/MESApplication/Controllers/PLM/PLMController.cs
index 902e37a..ea5a72b 100644
--- a/StandardInterface/MESApplication/Controllers/PLM/PLMController.cs
+++ b/StandardInterface/MESApplication/Controllers/PLM/PLMController.cs
@@ -4,6 +4,7 @@
 using Microsoft.AspNetCore.Mvc;
 using System.Dynamic;
 using System.IO;
+using System.Net.Http.Headers;
 
 namespace MESApplication.Controllers.PLM;
 
@@ -122,4 +123,33 @@
             });
         }
     }
+
+    //MP-O鍨嬪湀-83070100066鏍峰搧1-83070100068鏍峰搧2.pdf
+    //e18f53b6-6615-8140-11ee-423d1dd32487
+    //RetrieveDrawings  璋冨彇鍥剧焊 get鏂瑰紡
+    [HttpGet("OpenDrawingsGet")]
+    public IActionResult OpenDrawingsGet(string fileId, string fName)
+    {
+        try
+        {
+            var resultInfos = wdd.SendRequest("Download", fileId);
+
+            // 娣诲姞Content-Disposition鍝嶅簲澶�
+            var cd = new ContentDispositionHeaderValue("attachment");
+            cd.FileNameStar = fName; // 鑷姩澶勭悊缂栫爜
+            Response.Headers.Add("Content-Disposition", cd.ToString());
+
+            return File(resultInfos, "application/octet-stream", fName);
+        }
+        catch (Exception ex)
+        {
+            return StatusCode(500, new ResponseResult
+            {
+                status = 1,
+                message = ex.Message,
+                data = null
+            });
+        }
+    }
+
 }

--
Gitblit v1.9.3