i have assignmentremark, assignment and assignmentsubmission table and there is teacher and student is also a diffrent table
now as a teacher i upload a assignment and that assignment student can submited on diffrent submissioncontroller and that give mark of that subitedassignment by teacher on assignment remark controller
so how i can merge this three controller in my proect to give best view in mvc.net step by step with example in controller
This is My AssignmentRemark Model code:
namespace VCS_MVC_Project1.Models
{
public class AssignmentRemark
{
[Required]
public int ID { get; set; }
[Required]
public int StudentId { get; set; }
public Student Student { get; set; }
[Required]
public int TeacherId { get; set; }
public Teacher Teacher { get; set; }
[Required]
public int Marks { get; set; }
[Required]
public int AssignmentId { get; set; }
public Assignment Asssignment { get; set; }
}
}
This is Assignment model Code:
namespace VCS_MVC_Project1.Models
{
public class Assignment
{
[Required]
public int ID { get; set; }
[Required]
public string Name { get; set; }
[Required]
[StringLength(300)]
public string Description { get; set; }
[Required]
[Display(Name = "Attechment")]
public string Attechment { get; set; }
[Required]
[DataType(DataType.Date)]
[DisplayFormat(DataFormatString = "{0:dd/MM/yyyy}", ApplyFormatInEditMode = true)]
[Display(Name = "Due Date")]
public DateTime Due_date { get; set; }
public Teacher Teacher { get; set; }
}
}
this is the AssignmentSubmission modelCode:
namespace VCS_MVC_Project1.Models
{
public class AssignmentSubmission
{
[Required]
public int ID { get; set; }
[Required]
[Display(Name = "Files")]
public string Files { get; set; }
[Required]
[DataType(DataType.Date)]
[DisplayFormat(DataFormatString = "{0:dd/MM/yyyy}", ApplyFormatInEditMode = true)]
[Display(Name = "Date")]
public DateTime Date { get; set; }
public Student Student { get; set; }
[Required]
[Display(Name = "Student Name ")]
public int StudentId { get; set; }
public Assignment Asssignment { get; set; }
[Required]
[Display(Name = "Assignment Name")]
public int AssignmentId { get; set; }
}
}
give the solution for quetion asked in first