使用报表判断用户参数是否为空

This commit is contained in:
maqiao 2025-01-06 13:11:57 +08:00
parent b58309a583
commit 58a6035add
1 changed files with 3 additions and 3 deletions

View File

@ -14,7 +14,7 @@ using System.Threading.Tasks;
namespace DM_Weight.ViewModels namespace DM_Weight.ViewModels
{ {
public class UseAccountWindowViewModel:BindableBase,INavigationAware public class UseAccountWindowViewModel : BindableBase, INavigationAware
{ {
private DateTime? _startDate = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day); private DateTime? _startDate = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day);
@ -103,7 +103,7 @@ namespace DM_Weight.ViewModels
{ {
get => new DelegateCommand(() => get => new DelegateCommand(() =>
{ {
GridReportUtil.UserAccount(StartDate, EndDate, User.Nickname ?? ""); GridReportUtil.UserAccount(StartDate, EndDate, User == null ? "" : User.Nickname);
}); });
} }