function initMyProjectLayout($role)
{
    $title = hasRole(array(_STUDENT_TYPE)) ? t('My accepted project') : t('My accepted projects');
    drupal_set_title($title);
    switch ($role) {
        case _STUDENT_TYPE:
            getSingleAcceptedProjectView(Agreement::getInstance()->getSingleStudentsAgreement(true));
            break;
        case _SUPERVISOR_TYPE:
        case _INSTADMIN_TYPE:
        case _MENTOR_TYPE:
        case _ORGADMIN_TYPE:
            getListView();
            break;
    }
}
        break;
    case 'list_search':
        if (Users::isSuperVisor()) {
            //Return result to jTable
            $recs = Agreement::getInstance()->getAgreementsForSupervisorBySearchCriteria(true, $_GET["jtSorting"], $_GET["jtStartIndex"], $_GET["jtPageSize"]);
            $cnt = Agreement::getInstance()->getProjectAgreementsRowCount($GLOBALS['user']->uid, '');
        } else {
            if (Users::isMentor()) {
                $recs = Agreement::getInstance()->getAgreementsForMentorBySearchCriteria(true, $_GET["jtSorting"], $_GET["jtStartIndex"], $_GET["jtPageSize"]);
                $cnt = Agreement::getInstance()->getProjectAgreementsRowCount('', $GLOBALS['user']->uid);
            }
        }
        jsonGoodResultJT($recs, $cnt);
        break;
    case 'render_project_for_id':
        $id = altSubValue($_POST, 'id');
        $target = altSubValue($_POST, 'target', '');
        $agreement = Agreement::getInstance()->getSingleAgreementById($id, true);
        echo getSingleAcceptedProjectView($agreement);
        break;
    case 'render_agreement_for_id':
        $id = altSubValue($_POST, 'id');
        $target = altSubValue($_POST, 'target', '');
        $agreement = Agreement::getInstance()->getSingleAgreementById($id, true);
        echo "<div id='admin_container' class='tabs_container'>";
        echo showAgreement($agreement);
        echo "</div>";
        break;
    default:
        echo "No such action: " . $_GET['action'];
}