diff --git a/ds-wms-service/DS.WMS.Core/TaskInteraction/Entity/BusinessDataProvider.cs b/ds-wms-service/DS.WMS.Core/TaskInteraction/Entity/BusinessDataProvider.cs
index f895e472..adb58ccd 100644
--- a/ds-wms-service/DS.WMS.Core/TaskInteraction/Entity/BusinessDataProvider.cs
+++ b/ds-wms-service/DS.WMS.Core/TaskInteraction/Entity/BusinessDataProvider.cs
@@ -1,5 +1,4 @@
-using System.ComponentModel;
-using SqlSugar;
+using SqlSugar;
namespace DS.WMS.Core.TaskInteraction.Entity
{
diff --git a/ds-wms-service/DS.WMS.Core/TaskInteraction/Interface/ITaskMailService.cs b/ds-wms-service/DS.WMS.Core/TaskInteraction/Interface/ITaskMailService.cs
index df95039b..6afa3cef 100644
--- a/ds-wms-service/DS.WMS.Core/TaskInteraction/Interface/ITaskMailService.cs
+++ b/ds-wms-service/DS.WMS.Core/TaskInteraction/Interface/ITaskMailService.cs
@@ -28,6 +28,13 @@ namespace DS.WMS.Core.TaskInteraction.Interface
/////
//Task>> GetMailContentAsync(string customerNO, DocumentType docType, string? templateName = null);
+ ///
+ /// 获取数据提供程序
+ ///
+ /// 查询条件
+ ///
+ Task>> GetProvidersAsync(string? query);
+
///
/// 获取分页列表
///
diff --git a/ds-wms-service/DS.WMS.Core/TaskInteraction/Method/TaskMailService.cs b/ds-wms-service/DS.WMS.Core/TaskInteraction/Method/TaskMailService.cs
index 78389f83..1cbf38f3 100644
--- a/ds-wms-service/DS.WMS.Core/TaskInteraction/Method/TaskMailService.cs
+++ b/ds-wms-service/DS.WMS.Core/TaskInteraction/Method/TaskMailService.cs
@@ -1,9 +1,11 @@
-using DS.Module.Core;
+using System.Reflection;
+using DS.Module.Core;
using DS.Module.Core.Data;
using DS.Module.Core.Extensions;
using DS.WMS.Core.TaskInteraction.Entity;
using DS.WMS.Core.TaskInteraction.Interface;
using Microsoft.Extensions.DependencyInjection;
+using SqlSugar;
namespace DS.WMS.Core.TaskInteraction.Method
{
@@ -74,6 +76,29 @@ namespace DS.WMS.Core.TaskInteraction.Method
// return DataResult>.Success(new Tuple(title, content));
//}
+ ///
+ /// 获取数据提供程序
+ ///
+ /// 查询条件
+ ///
+ public async Task>> GetProvidersAsync(string? query)
+ {
+ List conditionals = [];
+ if (!string.IsNullOrEmpty(query))
+ conditionals = Db.Utilities.JsonToConditionalModels(query);
+
+ var list = await TenantDb.Queryable()
+ .Where(conditionals).ToListAsync();
+
+ var result = DataResult>.Success(list);
+ result.AdditionalData ??= [];
+ var types = Array.FindAll(Assembly.GetExecutingAssembly().GetTypes(),
+ x => x.IsClass && typeof(IDataProvider).IsAssignableFrom(x));
+ result.AdditionalData["AvailableTypes"] = types.Select(x => x.FullName);
+
+ return result;
+ }
+
///
/// 获取分页列表
///
diff --git a/ds-wms-service/DS.WMS.OpApi/Controllers/TaskMailController.cs b/ds-wms-service/DS.WMS.OpApi/Controllers/TaskMailController.cs
index a444ee31..87938ea0 100644
--- a/ds-wms-service/DS.WMS.OpApi/Controllers/TaskMailController.cs
+++ b/ds-wms-service/DS.WMS.OpApi/Controllers/TaskMailController.cs
@@ -1,6 +1,7 @@
using DS.Module.Core;
using DS.Module.Core.Data;
using DS.Module.Core.Extensions;
+using DS.WMS.Core.Invoice.Dtos;
using DS.WMS.Core.Sys.Entity;
using DS.WMS.Core.TaskInteraction.Entity;
using DS.WMS.Core.TaskInteraction.Interface;
@@ -70,6 +71,17 @@ namespace DS.WMS.OpApi.Controllers
// return File(Encoding.UTF8.GetBytes(result.Data.Item2), "application/octet-stream", customerNO + ".htm");
//}
+ ///
+ /// 获取数据提供程序
+ ///
+ /// 查询条件
+ ///
+ [HttpGet, HttpPost, Route("GetProviders")]
+ public async Task>> GetProvidersAsync(string? query)
+ {
+ return await service.GetProvidersAsync(query);
+ }
+
///
/// 获取分页列表
///