diff --git a/RIZO_Application/Modules/RIZO_Application.Modules.ModuleName/ViewModels/MqttControlViewModel.cs b/RIZO_Application/Modules/RIZO_Application.Modules.ModuleName/ViewModels/MqttControlViewModel.cs index 56f86f7..cf642e3 100644 --- a/RIZO_Application/Modules/RIZO_Application.Modules.ModuleName/ViewModels/MqttControlViewModel.cs +++ b/RIZO_Application/Modules/RIZO_Application.Modules.ModuleName/ViewModels/MqttControlViewModel.cs @@ -172,7 +172,7 @@ namespace RIZO_Application.Modules.ModuleName.ViewModels _eventAggregator.GetEvent().Publish(message); if (retries>=maxRetries) { - MessageBox.Show("MQTT已掉线,请停止扫码"); + MessageBox.Show("MQTT服务器已掉线,请停止扫码并重启系统"); } } public async void Destroy() diff --git a/RIZO_Application/RIZO_Application.Infrastructure/Util/MqttHelper/MqttHelper.cs b/RIZO_Application/RIZO_Application.Infrastructure/Util/MqttHelper/MqttHelper.cs index 1edfe7f..701cefb 100644 --- a/RIZO_Application/RIZO_Application.Infrastructure/Util/MqttHelper/MqttHelper.cs +++ b/RIZO_Application/RIZO_Application.Infrastructure/Util/MqttHelper/MqttHelper.cs @@ -25,7 +25,7 @@ namespace RIZO_Helper.Tools public Action Disconnected; - public MqttHelper(string server, int port = 1883, string clientId = "wpf-demo", bool cleanSession = true) + public MqttHelper(string server, int port = 1883, string clientId = "wpf-demo", bool cleanSession = false) { if (string.IsNullOrEmpty(server)) throw new ArgumentNullException(nameof(server), "MQTT服务器地址不能为空");