Home\Controller\ItemController::showByUid PHP Method

showByUid() public method

我公开的项目列表
public showByUid ( )
    public function showByUid()
    {
        $login_user = $this->checkLogin(false);
        //如果用户有登录,则赋值给$login_user
        $uid = I("uid/d");
        $show_user = D("User")->where(" uid = '{$uid}' ")->find();
        if ($show_user) {
            $items = D("Item")->where(" password = '' and  ( uid = '{$show_user['uid']}' or item_id in ( select item_id from " . C('DB_PREFIX') . "item_member where uid = '{$show_user['uid']}' ) ) ")->select();
            $this->assign("items", $items);
            $this->assign("show_user", $show_user);
            $this->assign("login_user", $login_user);
        }
        if (LANG_SET == 'en-us') {
            $help_url = "http://www.showdoc.cc/help-en";
        } else {
            $help_url = "http://www.showdoc.cc/help";
        }
        $this->assign("help_url", $help_url);
        $this->display();
    }