diff --git a/BPA.SAAS.KitChenManage.Application/Device/DevicePushRecodeServices.cs b/BPA.SAAS.KitChenManage.Application/Device/DevicePushRecodeServices.cs index 4c34bf7..d855a6f 100644 --- a/BPA.SAAS.KitChenManage.Application/Device/DevicePushRecodeServices.cs +++ b/BPA.SAAS.KitChenManage.Application/Device/DevicePushRecodeServices.cs @@ -17,9 +17,9 @@ namespace BPA.SAAS.KitChenManage.Application.Device { _devicePushRecodeService= devicePushRecodeService; } - public async Task Test() + public async Task Test() { - return await _devicePushRecodeService.Test(); + await _devicePushRecodeService.Test(); } /// /// 分页 diff --git a/BPA.SAAS.KitChenManage.Application/Device/Services/DevicePushRecodeService.cs b/BPA.SAAS.KitChenManage.Application/Device/Services/DevicePushRecodeService.cs index 888aa61..c31c431 100644 --- a/BPA.SAAS.KitChenManage.Application/Device/Services/DevicePushRecodeService.cs +++ b/BPA.SAAS.KitChenManage.Application/Device/Services/DevicePushRecodeService.cs @@ -42,18 +42,11 @@ namespace BPA.SAAS.KitChenManage.Application.Device.Services _mqttClient=mqttClient; mqttServer = new(mqttClient); } - public async Task Test() + public async Task Test() { - var getGoodsAttributeurl = "http://localhost:5009/api/ExternalPlatform/Goods/GetGoodsPageList";//获取商品属性 - var key = "47e5c071-6283-4d9d-8dcb-36ba95aa8db9"; - var str = "current=1&pageSize=10&"+ key; - var sign = MD5Encryption.Encrypt(str.ToUpper()); - var respon = await getGoodsAttributeurl.SetHeaders(new - { - sign= sign, - key = key - }).SetHttpMethod(HttpMethod.Get).SetBody("{\"current\":1,\"pageSize\":10}", "application/json").PostAsStringAsync(); - return respon; + string Topic = "2222"; + var sd=await mqttServer.Publish(Topic, new PushData() { Data = "123456"}, "1"); + //return respon; } /// /// 分页 diff --git a/BPA.SAAS.KitChenManage.Application/Device/Services/IDevicePushRecodeService.cs b/BPA.SAAS.KitChenManage.Application/Device/Services/IDevicePushRecodeService.cs index 2ed832a..6c6d85d 100644 --- a/BPA.SAAS.KitChenManage.Application/Device/Services/IDevicePushRecodeService.cs +++ b/BPA.SAAS.KitChenManage.Application/Device/Services/IDevicePushRecodeService.cs @@ -10,7 +10,7 @@ namespace BPA.SAAS.KitChenManage.Application.Device.Services { public interface IDevicePushRecodeService { - Task Test(); + Task Test(); /// /// 分页 /// diff --git a/BPA.SAAS.KitChenManage.Web.Entry/Properties/launchSettings.json b/BPA.SAAS.KitChenManage.Web.Entry/Properties/launchSettings.json index 470db2e..8f67248 100644 --- a/BPA.SAAS.KitChenManage.Web.Entry/Properties/launchSettings.json +++ b/BPA.SAAS.KitChenManage.Web.Entry/Properties/launchSettings.json @@ -22,7 +22,7 @@ "dotnetRunMessages": true, "launchBrowser": true, "launchUrl": "", - "applicationUrl": "http://192.168.1.19:5007", + "applicationUrl": "http://localhost:5007", "environmentVariables": { "ASPNETCORE_ENVIRONMENT": "Development" } diff --git a/BPA.SAAS.KitChenManage.Web.Entry/appsettings.json b/BPA.SAAS.KitChenManage.Web.Entry/appsettings.json index 2b2e5b1..89e109c 100644 --- a/BPA.SAAS.KitChenManage.Web.Entry/appsettings.json +++ b/BPA.SAAS.KitChenManage.Web.Entry/appsettings.json @@ -8,7 +8,7 @@ } }, "AllowedHosts": "*", - "baseurl": "http://192.168.1.19:5006/", + "baseurl": "http://localhost:5006/", "ConnectionConfigs": [ { "ConnectionString": "server=10.2.1.21;Database=bpa_kitchen_kitchenmanage;Uid=root;Pwd=cygadmin;Allow Zero Datetime=True;Convert Zero Datetime=True;",