Lines Matching refs:prow

7     public $prow;  variable in CommentInfo
37 function __construct($x, PaperInfo $prow = null, Conf $conf = null) { argument
38 $this->merge(is_object($x) ? $x : null, $prow, $conf);
41 private function merge($x, PaperInfo $prow = null, Conf $conf = null) { argument
42 assert(($prow || $conf) && (!$prow || !$conf || $prow->conf === $conf));
43 $this->conf = $prow ? $prow->conf : $conf;
44 $this->prow = $prow;
56 static function fetch($result, PaperInfo $prow = null, Conf $conf = null) { argument
59 $cinfo = $result->fetch_object("CommentInfo", [null, $prow, $conf]);
61 $cinfo->merge(null, $prow, $conf);
65 static function make_response_template($round, PaperInfo $prow) { argument
66 …new CommentInfo((object) ["commentType" => COMMENTTYPE_RESPONSE, "commentRound" => $round], $prow);
69 function set_prow(PaperInfo $prow) { argument
70 assert(!$this->prow && $this->paperId === $prow->paperId && $this->conf === $prow->conf);
71 $this->prow = $prow;
75 static function echo_script($prow) { argument
79 $crow = new CommentInfo(null, $prow, $prow->conf);
81 foreach ($prow->conf->resp_rounds() as $rrd) {
84 if ($Me->can_respond($prow, $crow)
85 && ($m = $rrd->instructions($prow->conf)) !== false)
149 if ($user->can_view_comment_identity($cr->prow, $cr)
188 } else if (($rrow = $this->prow->review_of_user($this->contactId))
190 && $user->can_view_review($this->prow, $rrow)) {
198 if ($user->can_view_comment_identity($this->prow, $this))
209 if ($user->can_view_comment_identity($this->prow, $this))
221 && $user->can_view_comment_tags($this->prow, $this))
222 return $this->conf->tags()->strip_nonviewable($this->commentTags, $user, $this->prow);
229 && $user->can_view_comment_tags($this->prow, $this)) {
230 $tags = $this->conf->tags()->strip_nonviewable($this->commentTags, $user, $this->prow);
244 if ($this->commentId && !$contact->can_view_comment($this->prow, $this))
249 if (!$contact->can_comment($this->prow, $this))
251 $cj = (object) ["pid" => $this->prow->paperId, "is_new" => true, "editable" => true];
256 else if (($token = $contact->active_review_token_for($this->prow)))
262 $cj = (object) array("pid" => $this->prow->paperId, "cid" => $this->commentId);
275 if ($contact->can_comment($this->prow, $this))
286 $idable = $contact->can_view_comment_identity($this->prow, $this);
287 $idable_override = $idable || $contact->can_view_comment_identity($this->prow, $this, true);
296 && ($rrows = $this->prow->reviews_of_user(-1, $contact->review_tokens())))
332 if ($contact->can_view_comment_identity($this->prow, $this, false)) {
340 $prow = $this->prow;
341 $x .= prefix_word_wrap("* ", "Paper: #{$prow->paperId} {$prow->title}", 2);
365 . htmlspecialchars(UnicodeHelper::utf8_abbreviate($this->prow->title, 80))
367 $idable = $contact->can_view_comment_identity($this->prow, $this, false);
368 if ($idable || $contact->can_view_comment_time($this->prow, $this))
388 where $LinkTable.$LinkColumn={$this->prow->$LinkColumn}
398 $Table = $this->prow->comment_table_name();
399 $LinkTable = $this->prow->table_name();
400 $LinkColumn = $this->prow->id_column();
411 } else if ($contact->act_author_view($this->prow)) {
421 ? $this->prow->blind
426 : $contact->contactId == $this->prow->shepherdContactId)
436 && !$contact->act_author_view($this->prow)) {
463 $qb = [$contact->contactId, $this->prow->$LinkColumn, $ctype, "?", "?", $Now, 0];
487 where $LinkTable.$LinkColumn={$this->prow->$LinkColumn} limit 1) t
521 …->log_activity("Comment $cmtid " . ($text !== "" ? "saved" : "deleted"), $this->prow->$LinkColumn);
529 $comments = $this->prow->fetch_comments("commentId=$cmtid");
530 $this->merge($comments[$cmtid], $this->prow);
532 $this->prow->notify_reviews([$this, "watch_callback"], $contact);
542 function watch_callback($prow, $minic) { argument
550 if ($minic->can_view_comment($prow, $this)
553 && ($tmpl !== "@responsedraftnotify" || $minic->act_author_view($prow)))
554 HotCRPMailer::send_to($minic, $tmpl, $prow, array("comment_row" => $this));