-
Notifications
You must be signed in to change notification settings - Fork 22
Expand file tree
/
Copy pathICoursesServiceClient.cs
More file actions
59 lines (56 loc) · 3.39 KB
/
ICoursesServiceClient.cs
File metadata and controls
59 lines (56 loc) · 3.39 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
using System.Threading.Tasks;
using HwProj.Models.AuthService.DTO;
using HwProj.Models.CoursesService.DTO;
using HwProj.Models.CoursesService.ViewModels;
using HwProj.Models.Result;
namespace HwProj.CoursesService.Client
{
public interface ICoursesServiceClient
{
Task<CoursePreview[]> GetAllCourses();
Task<CourseDTO?> GetCourseById(long courseId);
Task<Result<CourseDTO>> GetCourseByIdForMentor(long courseId, string mentorId);
Task<Result<CourseDTO>> GetAllCourseData(long courseId);
Task<CourseDTO?> GetCourseByTask(long taskId);
Task<Result> DeleteCourse(long courseId);
Task<Result<long>> CreateCourse(CreateCourseViewModel model);
Task<Result> UpdateCourse(UpdateCourseViewModel model, long courseId);
Task SignInCourse(long courseId, string studentId);
Task<Result> AcceptStudent(long courseId, string studentId);
Task<Result> RejectStudent(long courseId, string studentId);
Task<Result> UpdateStudentCharacteristics(long courseId, string studentId,
StudentCharacteristicsDto characteristics);
Task<CourseDTO[]> GetAllUserCourses();
Task<TaskDeadlineDto[]> GetTaskDeadlines();
Task<Result<HomeworkViewModel>> AddHomeworkToCourse(CreateHomeworkViewModel model, long courseId);
Task<HomeworkViewModel> GetHomework(long homeworkId);
Task<HomeworkViewModel> GetForEditingHomework(long homeworkId);
Task<Result<HomeworkViewModel>> UpdateHomework(long homeworkId, CreateHomeworkViewModel model);
Task<Result> DeleteHomework(long homeworkId);
Task<HomeworkTaskViewModel> GetTask(long taskId);
Task<HomeworkTaskForEditingViewModel> GetForEditingTask(long taskId);
Task<Result<HomeworkTaskViewModel>> AddTask(long homeworkId, CreateTaskViewModel taskViewModel);
Task<Result> DeleteTask(long taskId);
Task<Result<HomeworkTaskViewModel>> UpdateTask(long taskId, CreateTaskViewModel taskViewModel);
Task<GroupViewModel[]> GetAllCourseGroups(long courseId);
Task<long> CreateCourseGroup(CreateGroupViewModel model, long courseId);
Task DeleteCourseGroup(long courseId, long groupId);
Task UpdateCourseGroup(UpdateGroupViewModel model, long courseId, long groupId);
Task<GroupViewModel> GetCourseGroupsById(long courseId, string userId);
Task AddStudentInGroup(long courseId, long groupId, string userId);
Task RemoveStudentFromGroup(long courseId, long groupId, string userId);
Task<GroupViewModel[]> GetGroupsById(params long[] groupIds);
Task<long[]> GetGroupTasks(long groupId);
Task<Result> AcceptLecturer(long courseId, string lecturerEmail, string lecturerId);
Task<Result<AccountDataDto[]>> GetLecturersAvailableForCourse(long courseId);
Task<string[]> GetCourseLecturersIds(long courseId);
Task<Result<string[]>> GetAllTagsForCourse(long courseId);
Task<Result<long>> CreateOrUpdateCourseFilter(long courseId, CreateCourseFilterDTO model);
Task AddQuestionForTask(AddTaskQuestionDto question);
Task<GetTaskQuestionDto[]> GetQuestionsForTask(long taskId);
Task AddAnswerForQuestion(AddAnswerForQuestionDto answer);
Task<MentorToAssignedStudentsDTO[]> GetMentorsToAssignedStudents(long courseId);
Task<bool> Ping();
Task<Result> SignInAndAcceptStudent(long courseId, string studentId);
}
}