Esempio n. 1
0
  private static void letterInformation(final PhdCandidacyReferee referee, final Page page)
      throws IOException {

    final PhdCandidacyRefereeLetter letter = referee.getLetter();

    page.h(3, "Reference Letter", "mtop2");
    page.tableStart("tstyle2 thwhite thnowrap thlight thleft thtop ulnomargin");

    page.rowStart()
        .headerStartWithStyle("width: 200px;")
        .write("How long have you known the applicant?")
        .headerEnd()
        .column(string(letter.getHowLongKnownApplicant()) + " months")
        .rowEnd();
    page.rowStart().header("In what capacity?").column(string(letter.getCapacity())).rowEnd();
    page.rowStart()
        .header("Comparison group:")
        .column(string(letter.getComparisonGroup()))
        .rowEnd();
    page.rowStart()
        .header("Rank in class (if applicable):")
        .column(string(letter.getRankInClass()))
        .rowEnd();
    page.rowStart()
        .header("Academic performance:")
        .column(string(letter.getAcademicPerformance().getLocalizedName()))
        .rowEnd();
    page.rowStart()
        .header("Social and Communication Skills:")
        .column(string(letter.getSocialAndCommunicationSkills().getLocalizedName()))
        .rowEnd();
    page.rowStart()
        .header("Potential to excel in a PhD:")
        .column(string(letter.getPotencialToExcelPhd().getLocalizedName()))
        .rowEnd();

    page.rowStart().header("Recomendation letter:");
    if (letter.getFile() != null) {
      page.column(letter.getFile().getDisplayName() + " (file is inside documents zip file)");
    } else {
      page.column("-");
    }
    page.rowEnd();

    page.rowStart().header("Comments:").column(string(letter.getComments())).rowEnd();
    page.rowStart().header("Name:").column(string(letter.getRefereeName())).rowEnd();
    page.rowStart().header("Position/Title:").column(string(letter.getRefereePosition())).rowEnd();
    page.rowStart().header("Institution:").column(string(letter.getRefereeInstitution())).rowEnd();
    page.rowStart().header("Address:").column(string(letter.getRefereeInstitution())).rowEnd();
    page.rowStart().header("City:").column(string(letter.getRefereeCity())).rowEnd();
    page.rowStart().header("Zip code:").column(string(letter.getRefereeZipCode())).rowEnd();
    page.rowStart()
        .header("Country:")
        .column(
            letter.getRefereeCountry() != null
                ? letter.getRefereeCountry().getLocalizedName().getContent()
                : "-")
        .rowEnd();
    page.rowStart().header("Email:").column(string(letter.getRefereeEmail())).rowEnd();

    page.tableEnd();
  }