void SetValues() { apiHelper = new TaskAPIHelper(); typeAPIHelper = new TaskTypeAPIHelper(); statusAPIHelper = new TaskStatusAPIHelper(); stampAPIHelper = new StampAPIHelper(); sheetAPIHelper = new SheetAPIHelper(); teamSiteManagersAPIHelper = new TeamSiteManagersAPIHelper(); taskMembersAPIHelper = new TaskMembersAPIHelper(); taskWatchersAPIHelper = new TaskWatchersAPIHelper(); logAPIHelper = new ActivityLogAPIHelper(); ToggleOperationCommand = new RelayCommand(OpenCloseOperations); new Action(async() => await GetTasks())(); new Action(async() => await GetTypes())(); new Action(async() => await GetStatuses())(); new Action(async() => await GetTeamMembers())(); new Action(async() => await GetStamps())(); new Action(async() => await GetSheets())(); SaveCommand = new RelayCommand(async delegate { await Task.Run(() => CreateTask()); }, () => CanSaveTask); DeleteCommand = new RelayCommand(async delegate { await Task.Run(() => DeleteTask()); }, () => CanDeleteTask); CheckCommand = new RelayCommand(SetCheckedText); DownloadCommand = new RelayCommand(DownloadFile); SearchCommand = new RelayCommand(SearchTask); CheckWatcherCommand = new RelayCommand(SetWatchersCheckedText); }
void SetValues() { apiHelper = new TaskTypeAPIHelper(); ToggleOperationCommand = new RelayCommand(OpenCloseOperations); new Action(async() => await GetTypes())(); SaveCommand = new RelayCommand(async delegate { await Task.Run(() => CreateType()); }, () => CanSaveType); DeleteCommand = new RelayCommand(async delegate { await Task.Run(() => DeleteType()); }, () => CanDeleteType); }