Package net.sf.esims.model.entity

Examples of net.sf.esims.model.entity.Student


          .createStudentDetailsFromApplicationForm(applicationForms
              .get(0));

      Date dateOfAdmission = new Date();

      Student studentToBeAdmitted = new Student(this.admissionNumber,
          this.applicationFormNumber, standardOfAdmission,
          dateOfAdmission, studentDetails);
      if (this.studentService
          .checkIfDuplicate(this.applicationFormNumber)) {
        message = EsimsUtils.createInfoMessage(this.getContext()
            .getContextPath(), "Form # "
            + studentToBeAdmitted.getApplicationFormNumber()
            + " already exists for another student");
      } else {
        this.studentService.save(studentToBeAdmitted);
        message = EsimsUtils.createInfoMessage(this.getContext()
            .getContextPath(), (studentToBeAdmitted
            .getStudentDetails().getFirstName()
            + " has been admitted to " + standardOfAdmission
            .getName()));
      }
    }
View Full Code Here


          "/WEB-INF/pages/_basic_data_missing.jsp");

    List<Standard> listOfStandards=this.standardService.getAll();
    List<Division> listOfDivisions=this.divisionService.getAll();
   
    Student student = listOfStudents.get(0);
    String buttonName = "showStudentDetailsPage";
    String buttonValue = "Continue";
    this.getContext().setAttributeToSession("buttonName", buttonName);
    this.getContext().setAttributeToSession("buttonValue", buttonValue);
    this.getContext().setAttributeToSession("student", student);
View Full Code Here

  @HandlesEvent("saveStudentDetails")
  public Resolution saveStudentDetails(){
    // updating the changed details
    String message = EsimsConstants._BLANK_STRING;
   
      Student updatedStudent = updateStudentsDetails();
      this.studentService.save(updatedStudent);
      message = EsimsUtils.createInfoMessage(this.getContext().getContextPath(),
          "The student with admission #"+updatedStudent.getAdmissionNumber()+" was saved succesfully.");
      this.getContext().removeAttributeFromSession("student");
      FlashScope.getCurrent(this.getContext().getRequest(),true).put("message", message);
      return new RedirectResolution(DisplayMessageAction.class,  "forwardToMessagePage");
  }
View Full Code Here

      return new RedirectResolution(DisplayMessageAction.class,  "forwardToMessagePage");
  }

  //helper method that does the updation of the student with the newly supplied values.
  private Student updateStudentsDetails() {
    Student student = (Student) this.getContext().getAttributeFromSession(
        "student");
    StudentDetails studentDetails = student.getStudentDetails();

    Standard standard = this.standardService.getById(this.standardId);
    Division division = this.divisionService
        .getDivisionById(this.divisionId);
    student.setStandard(standard);
    student.setDivision(division);

    studentDetails.setAcademicAchievements(this.academicAchievements);
    studentDetails.setBelowPovertyLine(this.belowPovertyLine);
    studentDetails.setCaste(this.caste);
    studentDetails.setDateOfBirth(this.dateOfBirth);
    studentDetails.setFatherFirstName(this.fatherFirstName);
    studentDetails.setFatherLastName(this.fatherLastName);
    studentDetails.setFatherMiddleName(this.fatherMiddleName);
    studentDetails.setFirstName(this.firstName);
    studentDetails.setGrossHouseHoldIncome(this.grossHouseHoldIncome);
    studentDetails.setLastName(this.lastName);
    studentDetails.setLocalGuardianFirstName(this.localGuardianFirstName);
    studentDetails.setLocalGuardianLastName(this.localGuardianLastName);
    studentDetails.setLocalGuardianMiddleName(this.localGuardianMiddleName);
    studentDetails.setMiddleName(this.middleName);
    studentDetails.setMotherFirstName(this.motherFirstName);
    studentDetails.setMotherLastName(this.motherLastName);
    studentDetails.setMotherMiddleName(this.motherMiddleName);
    studentDetails.setMotherTounge(this.motherTounge);
    studentDetails.setNationality(this.nationality);
    studentDetails.setNonAcademicAchievements(this.nonAcademicAchievements);
    studentDetails.setOtherBackwardCaste(this.otherBackwardCaste);
    studentDetails
        .setPermanentHouseNameOrNumber(this.permanentHouseNameOrNumber);
    studentDetails.setPermanentPhoneNumber(this.permanentPhoneNumber);
    studentDetails.setPermanentPinCode(this.permanentPinCode);
    studentDetails.setPermanentState(this.permanentState);
    studentDetails.setPermanentStreet(this.permanentStreet);
    studentDetails
        .setPermanentVillageOrTownOrCity(this.permanentVillageOrTownOrCity);
    studentDetails.setPlaceOfBirth(this.placeOfBirth);
    studentDetails
        .setPresentHouseNameOrNumber(this.presentHouseNameOrNumber);
    studentDetails.setPresentPhoneNumber(this.presentPhoneNumber);
    studentDetails.setPresentPinCode(this.presentPinCode);
    studentDetails.setPresentState(this.presentState);
    studentDetails.setPresentStreet(this.presentStreet);
    studentDetails
        .setPresentVillageOrTownOrCity(this.presentVillageOrTownOrCity);
    studentDetails.setReligion(this.religion);
    studentDetails.setScheduledCasteOrTribe(this.scheduledCasteOrTribe);
    studentDetails.setSubcaste(this.subcaste);

    student.setStudentDetails(studentDetails);

    return student;
  }
View Full Code Here

    Division division = new Division("A",standard,"paplubhai",new Integer(50),new Integer(20),new Date());
    this.divisionService.save(division);
   
    StudentDetails studentDetails = UtilsForTestCases.createStudentDetailsForTest();
    Date dateOfAdmission = new Date();
    Student student = new Student("123","345",standard,dateOfAdmission,studentDetails);
    this.studentService.save(student);
   
    assertNotNull(this.studentService.getByFormNumber("345"));
   
    this.studentService.delete(student);
View Full Code Here

    Division division = new Division("A",standard,"paplubhai",new Integer(50),new Integer(20),new Date());
    this.divisionService.save(division);
   
    StudentDetails studentDetails = UtilsForTestCases.createStudentDetailsForTest();
    Date dateOfAdmission = new Date();
    Student student = new Student("123","345",standard,dateOfAdmission,studentDetails);
    this.studentService.save(student);
   
    assertNotNull(this.studentService.getByAdmissionNumber("123"));
   
    this.studentService.delete(student);
View Full Code Here

    Division division = new Division("A",standard,"paplubhai",new Integer(50),new Integer(20),new Date());
    this.divisionService.save(division);
   
    StudentDetails studentDetails = UtilsForTestCases.createStudentDetailsForTest();
    Date dateOfAdmission = new Date();
    Student student = new Student("123","345",standard,dateOfAdmission,studentDetails);
    this.studentService.save(student);
   
    assertNotNull(this.studentService.getByStandard(standard));
   
    this.studentService.delete(student);
View Full Code Here

    Division division = new Division("A",standard,"paplubhai",new Integer(50),new Integer(20),new Date());
    this.divisionService.save(division);
   
    StudentDetails studentDetails = UtilsForTestCases.createStudentDetailsForTest();
    Date dateOfAdmission = new Date();
    Student student = new Student("123","345",standard,dateOfAdmission,studentDetails);
    this.studentService.save(student);
   
    assertNotNull(this.studentService.getByStandardAndDivision(standard, division));
   
    this.studentService.delete(student);
View Full Code Here

    Division division = new Division("A",standard,"paplubhai",new Integer(50),new Integer(20),new Date());
    this.divisionService.save(division);
   
    StudentDetails studentDetails = UtilsForTestCases.createStudentDetailsForTest();
    Date dateOfAdmission = new Date();
    Student student = new Student("123","345",standard,dateOfAdmission,studentDetails);
    this.studentService.save(student);
   
    assertNotNull(this.studentService.getById(student.getStudentId()));
   
    this.studentService.delete(student);
    this.divisionService.delete(division);
    this.standardService.delete(standard);
    this.academicYearService.deleteAcademicYear(academicYear);
View Full Code Here

    Division division = new Division("A",standard,"paplubhai",new Integer(50),new Integer(20),new Date());
    this.divisionService.save(division);
   
    StudentDetails studentDetails = UtilsForTestCases.createStudentDetailsForTest();
    Date dateOfAdmission = new Date();
    Student student = new Student("123","345",standard,dateOfAdmission,studentDetails);
    this.studentService.save(student);
   
    assertNotNull(this.studentService.getByFormNumber("345"));
    assertEquals(1, this.studentService.getByFormNumber("345").size());
   
View Full Code Here

TOP

Related Classes of net.sf.esims.model.entity.Student

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.