當前位置: 首頁>>代碼示例>>PHP>>正文


PHP XString::convertCharacterSet方法代碼示例

本文整理匯總了PHP中XString::convertCharacterSet方法的典型用法代碼示例。如果您正苦於以下問題:PHP XString::convertCharacterSet方法的具體用法?PHP XString::convertCharacterSet怎麽用?PHP XString::convertCharacterSet使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在XString的用法示例。


在下文中一共展示了XString::convertCharacterSet方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: updateVisitEvaluate

    public function updateVisitEvaluate($request, $response)
    {/*{{{*/
        $telOrder = DAL::get()->find('telOrder', $request->telOrderId);
        $proposal = DAL::get()->find('proposal', $request->proposalId);
        //檢查訂單所有者是否當前用戶
        $this->checkOrderOwnerIsCurUser($telOrder);

        $telOrderId = $request->telOrderId;
        $score = $request->score;
        $score1 = $request->score1;
        $score = empty($score)?$score1:$score;
        $content = XString::convertCharacterSet($request->content, 'gbk');
        $curuser = UserClient::getInstance()->getCurrentUser();
        TelOrderClient::getInstance()->updateVisitEvaluate($curuser, $telOrderId, array('score'=>$score, 'content'=>$content, 'rank'=>0, 'mark'=>'pro'));
        $response->setRedirect($response->router->urlfor('proposal/showdetail', array('proposalid'=>$proposal->id)));
    }/*}}}*/
開發者ID:sdgdsffdsfff,項目名稱:hdf-client,代碼行數:16,代碼來源:telpaymentcontroller.php

示例2: ajaxOrderDiseaseInfo

    public function ajaxOrderDiseaseInfo($request, $response)
    {/*{{{*/
        $orderId = $request->orderid; 
        $order = DAL::get()->find('telorder', $orderId);
        if($order->isNull())
        {
			die('無效的訂單ID');
        }
        $response->order = $order;
        $doctorUser = DAL::get()->find('user', $order->executer->relatedObject->id);
        $doctorId = $doctorUser->space->host->id;
        $diseasesOfDoctor = DoctorClient::getInstance()->getDiseasesOfDoctor($doctorId); 
        $response->diseasesOfDoctor = $diseasesOfDoctor;
		$diseaseList = array();
        $diseaseName =  XString::convertCharacterSet($request->diseasename, 'gbk');
        if(false == empty($diseaseName))
        {
            $diseaseList = DAL::get()->find_all_similarDiseaseLimitName('disease', $diseaseName, array('isVoteSelf' => array(1)));
        }
        $response->diseaseList = $diseaseList;
        $response->diseaseName = $request->diseaseName;
        //取當前訂單醫生已審核訂單綁定的疾病 wk
        $bindsOrders = PaymentClient::getInstance()->getBindsOrdersOfDoctor('telorder', $order->executerid, array(TelOrder::STATUS_CONFIRM, TelOrder::STATUS_FINISHED, TelOrder::STATUS_CLOSED));
        $allDiseaseIdsOfConfirmOrder = array();
        foreach($bindsOrders as $result)
        {
            if(empty($result['diseaseid'])) continue;
            $allDiseaseIdsOfConfirmOrder[] = $result['diseaseid'];
        }
        $diseasesOfConfirmOrder = DAL::get()->find('disease', $allDiseaseIdsOfConfirmOrder);
        foreach($diseasesOfConfirmOrder as $disease)
        {
            if(Disease::ISVOTESELF_NO == $disease->isVoteSelf)
            {
                unset($diseasesOfConfirmOrder[$disease->id]);
            }
        }
        //當前訂單谘詢的大夫的所有投票疾病 wk
        $response->diseases = $diseasesOfConfirmOrder;
    }/*}}}*/
開發者ID:sdgdsffdsfff,項目名稱:hdf-client,代碼行數:40,代碼來源:telordercontroller.php


注:本文中的XString::convertCharacterSet方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。