public function askIndex($request, $response)
    {/*{{{*/
        $space = AskSessionInfo::getBindSpace();
        $patient = AskSessionInfo::getBindPatient();
        $this->initialize($request, $response);

        $diseaseInfo = AskSessionInfo::getPatientInfos(NodeObj::NODE_DEFINE_DISEASE);
        AskSessionInfo::session_destroy();
        AskSessionInfo::setStartMarkSession();
        $this->unsetAskSession();

        if(false == $space->isNull())
        {
            AskSessionInfo::bindSpace($space->id);
        }
        if(false == $this->user->isNull())
        {
            AskSessionInfo::bindUser($this->user->id);
            $patientId = $request->patientId;
            if($patientId > 0 )
            {
                AskSessionInfo::bindPatient($patientId);
                AskSessionInfo::flushPatientInfos();
            }
        }
        //if(false == empty($diseaseInfo))
        //{
        //    $diseaseInfo = array_shift($diseaseInfo);
        //    $diseaseKey = AskSessionInfo::addPatientInfo(NodeObj::NODE_DEFINE_DISEASE, $diseaseInfo);
        //    AskSessionInfo::bindPatientInfos(NodeObj::NODE_DEFINE_DISEASE, array($diseaseKey));
        //}
        $response->askSpace = $space;
    }/*}}}*/
    public function askIndex($request, $response)
    {/*{{{*/
        $space = AskSessionInfo::getBindSpace();
        $patientId = $request->patientId;
        $spaceId = $space->id;
        if(false == empty($patientId) && false == $space->isNull())
        {
            $flow = FlowClient::getInstance()->getValidFlowRef($spaceId, $patientId);
            if(false == $flow->isNull())
            {
                $response->setRedirect($flow->getUrl());
            }

            $proposal = DAL::get()->find_by_spaceId_and_patientId_and_servicedef_and_status('proposal', $spaceId, $patientId, ServiceDef::TYPE_FLOW, Proposal::STATUS_NORMAL);
            if(false == $proposal->isNull())
            {
                $response->setRedirect($proposal->getUrl4User());
            }
        }
        
        $caseTitle = AskSessionInfo::getThreadTitle();

        $diseaseInfo = AskSessionInfo::getPatientInfos(NodeObj::NODE_DEFINE_DISEASE);
        AskSessionInfo::session_destroy();
        //设置开始标记
        AskSessionInfo::setStartMarkSession();
        // 先登录未选患者 标记
        if($request->beforelogin == 1)
        {
            AskSessionInfo::addBeforeLoginConfirmPatient();
        }
        if($caseTitle != '')
        {
            AskSessionInfo::addThreadTitle($caseTitle, false);
        }
        if(false == $space->isNull() && $space->host instanceof Doctor)
        {
            AskSessionInfo::bindSpace($space->id);
            if($space->modulecase->isLimitLess() == false)
            $response->allowNewMaxNumber = $space->modulecase->allowNewMaxNumber - $space->getUnProcessFlowPropoalCnt();
        }
        if(false == $this->_newUser->isNull())
        {
            AskSessionInfo::bindUser($this->_newUser->id);
            if($patientId > 0 )
            {
                AskSessionInfo::bindPatient($patientId);
                AskSessionInfo::flushPatientInfos();
            }
        }
        if(false == empty($diseaseInfo))
        {
            $diseaseInfo = array_shift($diseaseInfo);
            $diseaseKey = AskSessionInfo::addPatientInfo(NodeObj::NODE_DEFINE_DISEASE, $diseaseInfo);
            AskSessionInfo::bindPatientInfos(NodeObj::NODE_DEFINE_DISEASE, array($diseaseKey));
        }
        $response->askSpace = $space;
    }/*}}}*/