From 9a886d711d8b21adc335fdf8c39350584c7ba6fd Mon Sep 17 00:00:00 2001
From: wangxinhui <wangxinhui@hnkhzn.com>
Date: 星期二, 14 十月 2025 02:12:14 +0800
Subject: [PATCH] 更新代码,取消MES出库单号同步标识,平库转立库功能,寄售周期判断取消,精品标识等
---
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Stock/StockViewController.cs | 37 ++++++++++++++++++++++++++++++++++++-
1 files changed, 36 insertions(+), 1 deletions(-)
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Stock/StockViewController.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Stock/StockViewController.cs"
index bbd9d96..4bd93c8 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Stock/StockViewController.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Stock/StockViewController.cs"
@@ -1,7 +1,10 @@
-锘縰sing Microsoft.AspNetCore.Authorization;
+锘縰sing Autofac.Core;
+using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Options;
+using SqlSugar;
+using System.Reflection;
using WIDESEA_Core;
using WIDESEA_Core.BaseController;
using WIDESEA_DTO.Stock;
@@ -10,6 +13,9 @@
namespace WIDESEA_WMSServer.Controllers.Stock
{
+ /// <summary>
+ /// 搴撳瓨瑙嗗浘
+ /// </summary>
[Route("api/StockView")]
[Authorize, ApiController]
public class StockViewController : Controller
@@ -31,5 +37,34 @@
{
return _stockViewService.GetDetailPage(pageData);
}
+
+ /// <summary>
+ /// 瀵煎嚭鏁版嵁
+ /// </summary>
+ /// <param name="loadData"></param>
+ /// <returns></returns>
+ [HttpPost, Route("Export")]
+ public virtual ActionResult Export([FromBody] PageDataOptions loadData)
+ {
+ WebResponseContent result = InvokeService("Export", new object[] { loadData }) as WebResponseContent;
+ if (result.Status)
+ return File(
+ System.IO.File.ReadAllBytes(result.Data.ToString()),
+ System.Net.Mime.MediaTypeNames.Application.Octet,
+ Path.GetFileName(result.Data.ToString())
+ );
+ return Json(result);
+ }
+ private object InvokeService(string methodName, object[] parameters)
+ {
+ Type t = _stockViewService.GetType();
+ List<Type> types = new List<Type>();
+ foreach (var param in parameters)
+ {
+ types.Add(param.GetType());
+ }
+ MethodInfo method = t.GetMethod(methodName, types.ToArray());
+ return method.Invoke(_stockViewService, parameters);
+ }
}
}
--
Gitblit v1.9.3