Exemple #1
0
        internal static EditStudentModel MapToEditStudentModel(Student student)
        {
            var model = new EditStudentModel();
            model.CbseRollNo = student.CBSERollNo;
            model.RollNo = student.RollNo;

            model.Dental = student.HealthInformations.Dental;
            model.Height = student.HealthInformations.Height;
            model.Teeth = student.HealthInformations.Teeth;
            model.VisionL = student.HealthInformations.VisionL;
            model.VisionR = student.HealthInformations.VisionR;
            model.Weight = student.HealthInformations.Weight;
            model.ClassId = student.Class_Id;
            model.HouseId = student.House_Id;
            model.CategoryId = student.StudentMaster.Category_Id;
            model.MinorityId = student.StudentMaster.Minority_Id;

            model.AdmissionNo = student.StudentMaster.AdmissionNo;
            model.BloodGroup = student.StudentMaster.BloodGroup;
            model.City = student.StudentMaster.City;
            model.Country = student.StudentMaster.Country;
            model.DOB = student.StudentMaster.DOB;
            model.EmailId = student.StudentMaster.EmailId;
            model.EWS = student.StudentMaster.EWS;
            model.FamilyIncome = student.StudentMaster.FamilyIncome;
            model.FatherName = student.StudentMaster.FatherName;
            model.FirstName = student.StudentMaster.FirstName;
            model.LastName = student.StudentMaster.LastName;
            model.MobileNo = student.StudentMaster.MobileNo;
            model.MotherName = student.StudentMaster.MotherName;
            model.Nationality = student.StudentMaster.Nationality;
            model.PhoneNo = student.StudentMaster.PhoneNo;
            model.PinCode = student.StudentMaster.PinCode;
            model.State = student.StudentMaster.State;
            model.StreetAddress = student.StudentMaster.StreetAddress;
            model.ModeofTransport = student.StudentMaster.Transport;
            return model;
        }
Exemple #2
0
        internal static void MapToStudent(EditStudentModel model, Student student)
        {
            student.BoardRegistrationNo = model.BoardRegNo;
            student.CBSERollNo = model.CbseRollNo;
            student.RollNo = model.RollNo;
            student.Class_Id = model.ClassId;
            student.House_Id = model.HouseId;

            student.HealthInformations.Dental = model.Dental;
            student.HealthInformations.Height = model.Height;
            student.HealthInformations.Teeth = model.Teeth;
            student.HealthInformations.VisionL = model.VisionL;
            student.HealthInformations.VisionR = model.VisionR;
            student.HealthInformations.Weight = model.Weight;

            student.StudentMaster.AdmissionNo = model.AdmissionNo;
            student.StudentMaster.BloodGroup = model.BloodGroup;
            student.StudentMaster.City = model.City;
            student.StudentMaster.Country = model.Country;
            student.StudentMaster.DOB = model.DOB;
            student.StudentMaster.EmailId = model.EmailId;
            student.StudentMaster.EWS = model.EWS;
            student.StudentMaster.FamilyIncome = model.FamilyIncome;
            student.StudentMaster.FatherName = model.FatherName;
            student.StudentMaster.FirstName = model.FirstName;
            student.StudentMaster.LastName = model.LastName;
            student.StudentMaster.MobileNo = model.MobileNo;
            student.StudentMaster.MotherName = model.MotherName;
            student.StudentMaster.Nationality = model.Nationality;
            student.StudentMaster.PhoneNo = model.PhoneNo;
            student.StudentMaster.PinCode = model.PinCode;
            student.StudentMaster.State = model.State;
            student.StudentMaster.StreetAddress = model.StreetAddress;
            student.StudentMaster.Transport = model.ModeofTransport;
            student.StudentMaster.Category_Id = model.CategoryId;
            student.StudentMaster.Minority_Id = model.MinorityId;
        }