From e32be099ebb0df6a0c7bf48f0abbb4c1bce901d1 Mon Sep 17 00:00:00 2001
From: Hinse <756681202@qq.com>
Date: Fri, 20 May 2022 16:33:17 +0800
Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E8=AF=95=E6=8E=A8=E9=80=81?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Waste.Application/Test/TestAppService.cs | 28 ++++++++++++++++++-
.../ThirdApiInfo/OpenAppService.cs | 2 --
Waste.Application/Waste.Application.xml | 11 ++++++++
3 files changed, 38 insertions(+), 3 deletions(-)
diff --git a/Waste.Application/Test/TestAppService.cs b/Waste.Application/Test/TestAppService.cs
index b77fb61..5cdd8e6 100644
--- a/Waste.Application/Test/TestAppService.cs
+++ b/Waste.Application/Test/TestAppService.cs
@@ -9,6 +9,7 @@ using System.Linq;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;
+using Waste.Application.SubscribeInfo;
namespace Waste.Application
{
@@ -23,10 +24,12 @@ namespace Waste.Application
private static string ApiSecretHash = App.Configuration["SZDevPlatSetting:ApiSecretHash"];
private readonly IHttpClientFactory _clientFactory;
private readonly ILoggerService _loggerService;
- public TestAppService(ILoggerService loggerService, IHttpClientFactory clientFactory)
+ private readonly ISubscribeService _subscribeService;
+ public TestAppService(ILoggerService loggerService, IHttpClientFactory clientFactory, ISubscribeService subscribeService)
{
_loggerService = loggerService;
_clientFactory = clientFactory;
+ _subscribeService = subscribeService;
}
///
/// 接收测试
@@ -47,6 +50,29 @@ namespace Waste.Application
{
}
+ ///
+ ///
+ ///
+ ///
+ [HttpGet]
+ public async Task TestThirdSendAsync()
+ {
+ await _subscribeService.SeedThirdMessageAsync(new SendThirdMessageSubscriDto {
+ Url= "https://localhost:44335/api/test/recv",
+ WasteType= "\u0000\u0000\u0000\u0000纸壳",
+ Weight="20.9",
+ TrashCode="0",
+ Time= 1653033312,
+ Body="",
+ DeviceId= Guid.Parse("39fcdce8-9e54-b87f-fc8e-616a9072c224")
+ });
+ }
+
+ [HttpPost]
+ public void Recv(SendMessageToThirdS2CDto input)
+ {
+ var a = input;
+ }
[HttpGet]
public async Task TestSendAsync()
diff --git a/Waste.Application/ThirdApiInfo/OpenAppService.cs b/Waste.Application/ThirdApiInfo/OpenAppService.cs
index 7416f86..09264ea 100644
--- a/Waste.Application/ThirdApiInfo/OpenAppService.cs
+++ b/Waste.Application/ThirdApiInfo/OpenAppService.cs
@@ -9,10 +9,8 @@ using Microsoft.Net.Http.Headers;
using Nirvana.Common;
using Nirvana.Common.File;
using System;
-using System.Collections.Generic;
using System.IO;
using System.Linq;
-using System.Text;
using System.Threading.Tasks;
using Waste.Application.SubscribeInfo;
diff --git a/Waste.Application/Waste.Application.xml b/Waste.Application/Waste.Application.xml
index a964d9f..7934a27 100644
--- a/Waste.Application/Waste.Application.xml
+++ b/Waste.Application/Waste.Application.xml
@@ -2163,6 +2163,11 @@
额外信息
+
+
+ 设备ID
+
+
CAP订阅相关接口
@@ -2556,6 +2561,12 @@
+
+
+
+
+
+
心跳包上报数据