Exemplo n.º 1
0
 public function show($id)
 {
     $curr['name'] = $this->lists['show']['name'];
     $curr['url'] = $this->lists['show']['url'];
     $result = ['data' => TalksModel::find($id), 'lists' => $this->lists, 'curr' => $curr];
     return view('member.talk.show', $result);
 }
Exemplo n.º 2
0
 public function show($id)
 {
     $curr['name'] = $this->crumb['show']['name'];
     $curr['url'] = $this->crumb['show']['url'];
     $result = ['data' => TalksModel::find($id), 'crumb' => $this->crumb, 'curr' => $curr];
     return view('admin.talk.show', $result);
 }
Exemplo n.º 3
0
 /**
  * 一些操作限制
  */
 public function tolimit($id, $msg)
 {
     $this->islogin();
     $talkModel = TalksModel::find($id);
     if ($this->userid == $talkModel->uid) {
         echo "<script>alert('" . $msg . "!');history.go(-1);</script>";
         exit;
     }
     return array('talkid' => $id, 'uid' => $this->userid);
 }
Exemplo n.º 4
0
 public function parent()
 {
     $pid = $this->pid ? $this->pid : 0;
     $parent = TalksModel::find($pid);
     return $parent ? $parent : '';
 }