예제 #1
0
function loadRows()
{
    global $Conf, $Me, $prow, $paperTable, $crow, $Error;
    $Conf->paper = $prow = PaperTable::paperRow($whyNot);
    if (!$prow) {
        exit_to_paper();
    }
    $paperTable = new PaperTable($prow, make_qreq());
    $paperTable->resolveReview(false);
    $paperTable->resolveComments();
    $cid = defval($_REQUEST, "commentId", "xxx");
    $crow = null;
    foreach ($paperTable->crows as $row) {
        if ($row->commentId == $cid || $cid == "response" && $row->commentType & COMMENTTYPE_RESPONSE) {
            $crow = $row;
        }
    }
    if (!$crow && $cid != "xxx" && $cid != "new" && $cid != "response" && $cid != "newresponse") {
        Conf::msg_error("No such comment.");
        $Conf->ajaxExit(array("ok" => false));
    }
    if (isset($Error["paperId"]) && $Error["paperId"] != $prow->paperId) {
        $Error = array();
    }
}
예제 #2
0
function loadRows()
{
    global $prow, $Conf, $Error;
    $Conf->paper = $prow = PaperTable::paperRow($whyNot);
    if (!$prow) {
        errorMsgExit(whyNotText($whyNot, "view"));
    }
    if (isset($Error["paperId"]) && $Error["paperId"] != $prow->paperId) {
        $Error = array();
    }
}
예제 #3
0
function loadRows()
{
    global $prow, $rrows, $Conf, $Me;
    $Conf->paper = $prow = PaperTable::paperRow($whyNot);
    if (!$prow) {
        errorMsgExit(whyNotText($whyNot, "view"));
    }
    if ($whyNot = $Me->perm_request_review($prow, false)) {
        $wnt = whyNotText($whyNot, "request reviews for");
        error_go(hoturl("paper", array("p" => $prow->paperId, "ls" => @$_REQUEST["ls"])), $wnt);
    }
    $rrows = $Conf->reviewRow(array('paperId' => $prow->paperId, 'array' => 1), $whyNot);
}
예제 #4
0
function loadRows()
{
    global $Conf, $Me, $prow, $paperTable, $editRrowLogname, $Error;
    $Conf->paper = $prow = PaperTable::paperRow($whyNot);
    if (!$prow) {
        errorMsgExit(whyNotText($whyNot, "view"));
    }
    $paperTable = new PaperTable($prow, make_qreq());
    $paperTable->resolveReview(true);
    if ($paperTable->editrrow && $paperTable->editrrow->contactId == $Me->contactId) {
        $editRrowLogname = "Review " . $paperTable->editrrow->reviewId;
    } else {
        if ($paperTable->editrrow) {
            $editRrowLogname = "Review " . $paperTable->editrrow->reviewId . " by " . $paperTable->editrrow->email;
        }
    }
    if (isset($Error["paperId"]) && $Error["paperId"] != $prow->paperId) {
        $Error = array();
    }
}