diff --git a/BBWY.Client/GlobalContext.cs b/BBWY.Client/GlobalContext.cs index 2471497c..aaad1213 100644 --- a/BBWY.Client/GlobalContext.cs +++ b/BBWY.Client/GlobalContext.cs @@ -8,6 +8,7 @@ namespace BBWY.Client public GlobalContext() { ShopServiceGroupList = new List(); + ShopServiceGroupLowerList = new List(); } private User user; @@ -20,6 +21,8 @@ namespace BBWY.Client public IList ShopServiceGroupList { get; set; } + public IList ShopServiceGroupLowerList { get; set; } + /// /// JD客户端 /// diff --git a/BBWY.Client/ViewModels/MainViewModel.cs b/BBWY.Client/ViewModels/MainViewModel.cs index d793b01b..7a8added 100644 --- a/BBWY.Client/ViewModels/MainViewModel.cs +++ b/BBWY.Client/ViewModels/MainViewModel.cs @@ -420,10 +420,15 @@ namespace BBWY.Client.ViewModels Environment.Exit(Environment.ExitCode); } GlobalContext.ShopServiceGroupList.Clear(); + GlobalContext.ShopServiceGroupLowerList.Clear(); if (apiResponse.Data != null && apiResponse.Data.Count() > 0) { foreach (var waiter in apiResponse.Data) + { GlobalContext.ShopServiceGroupList.Add(waiter.Name); + GlobalContext.ShopServiceGroupLowerList.Add(waiter.Name.ToLower()); + } + } } #endregion diff --git a/BBWY.Client/ViewModels/Order/OrderListViewModel.cs b/BBWY.Client/ViewModels/Order/OrderListViewModel.cs index 1dd42200..fa294bd4 100644 --- a/BBWY.Client/ViewModels/Order/OrderListViewModel.cs +++ b/BBWY.Client/ViewModels/Order/OrderListViewModel.cs @@ -559,8 +559,12 @@ namespace BBWY.Client.ViewModels var waiter = currentMachineServiceGroupList.Intersect(globalContext.ShopServiceGroupList)?.FirstOrDefault(); if (string.IsNullOrEmpty(waiter)) { - MessageBox.Show("未匹配到当前店铺客服组和本机咚咚客服账号的交集", "提示"); - return; + waiter = currentMachineServiceGroupList.Intersect(globalContext.ShopServiceGroupLowerList)?.FirstOrDefault(); + if (string.IsNullOrEmpty(waiter)) + { + MessageBox.Show("未匹配到当前店铺客服组和本机咚咚客服账号的交集", "提示"); + return; + } } //建立websocket连接 diff --git a/BBWY.Client/Views/MainWindow.xaml b/BBWY.Client/Views/MainWindow.xaml index 65a6c06a..d5973b3a 100644 --- a/BBWY.Client/Views/MainWindow.xaml +++ b/BBWY.Client/Views/MainWindow.xaml @@ -26,7 +26,7 @@ - + diff --git a/BBWY.sln b/BBWY.sln index 0b51312e..dd60519f 100644 --- a/BBWY.sln +++ b/BBWY.sln @@ -42,10 +42,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "InDll2", "InDll2\InDll2.csp EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BBWY.WebSocket.Server", "BBWY.WebSocket.Server\BBWY.WebSocket.Server.csproj", "{4E08D6A8-5670-4890-B775-2A10017201FD}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test1", "Test1\Test1.csproj", "{F4B81328-2000-4783-834C-CFB92B1C9D36}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test2", "Test2\Test2.csproj", "{12241ECC-BB66-40AC-85F0-D01537E3DA3B}" -EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -166,22 +162,6 @@ Global {4E08D6A8-5670-4890-B775-2A10017201FD}.Release|Any CPU.Build.0 = Release|Any CPU {4E08D6A8-5670-4890-B775-2A10017201FD}.Release|x86.ActiveCfg = Release|Any CPU {4E08D6A8-5670-4890-B775-2A10017201FD}.Release|x86.Build.0 = Release|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Debug|Any CPU.Build.0 = Debug|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Debug|x86.ActiveCfg = Debug|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Debug|x86.Build.0 = Debug|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Release|Any CPU.ActiveCfg = Release|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Release|Any CPU.Build.0 = Release|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Release|x86.ActiveCfg = Release|Any CPU - {F4B81328-2000-4783-834C-CFB92B1C9D36}.Release|x86.Build.0 = Release|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Debug|Any CPU.Build.0 = Debug|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Debug|x86.ActiveCfg = Debug|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Debug|x86.Build.0 = Debug|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Release|Any CPU.ActiveCfg = Release|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Release|Any CPU.Build.0 = Release|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Release|x86.ActiveCfg = Release|Any CPU - {12241ECC-BB66-40AC-85F0-D01537E3DA3B}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -200,8 +180,6 @@ Global {FB4BF1A9-DA81-446F-903C-89D3F905B7B8} = {D097AEA5-A7B1-414D-B82D-F70F177D0D8D} {1FD36D27-9BED-4E72-B81C-CBC0C4A3120E} = {D097AEA5-A7B1-414D-B82D-F70F177D0D8D} {4E08D6A8-5670-4890-B775-2A10017201FD} = {B545F3FA-E6A7-4CB1-B92D-801C66357CF5} - {F4B81328-2000-4783-834C-CFB92B1C9D36} = {D097AEA5-A7B1-414D-B82D-F70F177D0D8D} - {12241ECC-BB66-40AC-85F0-D01537E3DA3B} = {D097AEA5-A7B1-414D-B82D-F70F177D0D8D} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {CC045257-4D86-45FD-A1F0-2715C024F1B5} diff --git a/Test1/Program.cs b/Test1/Program.cs deleted file mode 100644 index d8fb49ba..00000000 --- a/Test1/Program.cs +++ /dev/null @@ -1,15 +0,0 @@ -// See https://aka.ms/new-console-template for more information -using System.Diagnostics; -using System.Reflection; -using System.Text; - -var str = new StringBuilder(); -str.Append("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxNTM1MzMwMzI4ODkyMTQ5NzYwIiwidGVhbUlkIjoiMTUxNjk3NDI1MDU0MjUwMTg4OCIsInNvblRlYW1JZHMiOiIxNDM2Mjg4NTAwMjM1MjQzNTIwIiwiZXhwIjoxNzA2NjAxNTIyfQ.RCtG71JQ-N1vVt4W-qQhwe5bFOI-T5wDkL74jhNnj1M"); -Console.WriteLine("Test1"); -var pi = new ProcessStartInfo(); -pi.FileName = Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location), "Test2.exe"); -pi.Arguments = $"{str}"; -pi.UseShellExecute = true; -Process.Start(pi); -Console.WriteLine($"{str}"); -Console.ReadKey(); \ No newline at end of file diff --git a/Test1/Test1.csproj b/Test1/Test1.csproj deleted file mode 100644 index 74abf5c9..00000000 --- a/Test1/Test1.csproj +++ /dev/null @@ -1,10 +0,0 @@ - - - - Exe - net6.0 - enable - enable - - - diff --git a/Test2/Program.cs b/Test2/Program.cs deleted file mode 100644 index bed8270e..00000000 --- a/Test2/Program.cs +++ /dev/null @@ -1,4 +0,0 @@ -// See https://aka.ms/new-console-template for more information -Console.WriteLine("Test2"); -Console.WriteLine(string.Join(string.Empty, args)); -Console.ReadKey(); \ No newline at end of file diff --git a/Test2/Test2.csproj b/Test2/Test2.csproj deleted file mode 100644 index 74abf5c9..00000000 --- a/Test2/Test2.csproj +++ /dev/null @@ -1,10 +0,0 @@ - - - - Exe - net6.0 - enable - enable - - -