From 176bd353ef510be1ae51905d9c78206fc56820e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?old=E6=98=93?= <156663459@qq.com> Date: Sat, 23 Mar 2024 11:39:35 +0800 Subject: [PATCH] feat:bug fixed --- New_College.Services/V_CustomerInfoServices.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/New_College.Services/V_CustomerInfoServices.cs b/New_College.Services/V_CustomerInfoServices.cs index e231ce1..75eee6b 100644 --- a/New_College.Services/V_CustomerInfoServices.cs +++ b/New_College.Services/V_CustomerInfoServices.cs @@ -323,7 +323,13 @@ namespace New_College.Services if (info == null || info.IsDelete) return new MessageModel() { success = false, msg = "获取失败,用户信息为空" }; var years = info.Year > 2023 ? 2023 : info.Year; - var typename = info.subjectgroupName.Length > 2 ? "综合" : info.subjectgroupName; + + string typename = "综合"; + if (info.subjectgroupName != null) + { + typename = info.subjectgroupName.Length > 2 ? "综合" : info.subjectgroupName; + + } var batchlist = await t_BatchlineRepository.Query(c => c.Year == years && c.AreaName == info.AreaName && c.Type_name == typename); string BatchName = string.Empty; if (info.AreaName == "河南省")