当前位置: 首页>>代码示例>>PHP>>正文


PHP Ibos::getCurrentModuleName方法代码示例

本文整理汇总了PHP中Ibos::getCurrentModuleName方法的典型用法代码示例。如果您正苦于以下问题:PHP Ibos::getCurrentModuleName方法的具体用法?PHP Ibos::getCurrentModuleName怎么用?PHP Ibos::getCurrentModuleName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Ibos的用法示例。


在下文中一共展示了Ibos::getCurrentModuleName方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getModule

 public function getModule()
 {
     if ($this->_module !== null) {
         return $this->_module;
     } else {
         return Ibos::getCurrentModuleName();
     }
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:8,代码来源:IWComment.php

示例2: getView

 public static function getView($view)
 {
     $currentController = Yii::app()->getController();
     $basePath = "application.modules.vote.views.default.";
     $relatedModule = Ibos::getCurrentModuleName();
     $relatedId = EnvUtil::getRequest($relatedModule . "id");
     if ($view == "articleView") {
         $voteData = Vote::model()->fetchVote($relatedModule, $relatedId);
         $votes = VoteUtil::processVoteData($voteData);
         if (!empty($votes)) {
             $voteItemList = $votes["voteItemList"];
             $voteType = $voteItemList[0]["type"];
             if ($voteType == 1) {
                 $view = "articleTextView";
             } elseif ($voteType == 2) {
                 $view = "articleImageView";
             }
             $selectView = $basePath . $view;
             $votePeopleNumber = Vote::model()->fetchUserVoteCount($relatedModule, $relatedId);
             $userHasVote = VoteUtil::checkVote($relatedModule, $relatedId);
             $mothedName = "get" . ucfirst($relatedModule) . "Vote";
             $voteStatus = ICVotePlugManager::$mothedName()->getStatus($relatedModule, $relatedId, $votes["vote"]);
             $votes["vote"]["subject"] = StringUtil::cutStr($votes["vote"]["subject"], 60);
             $data = array("voteData" => $votes, "votePeopleNumber" => $votePeopleNumber, "userHasVote" => $userHasVote, "voteStatus" => $voteStatus, "attachUrl" => Yii::app()->setting->get("setting/attachurl"));
             if ($voteStatus == 2) {
                 $partView = null;
             } else {
                 $partView = $currentController->renderPartial($selectView, $data, true);
             }
         } else {
             $partView = null;
         }
     } elseif ($view == "articleAdd") {
         $selectView = $basePath . $view;
         $partView = $currentController->renderPartial($selectView, array("uploadConfig" => AttachUtil::getUploadConfig()), true);
     } elseif ($view == "articleEdit") {
         $selectView = $basePath . $view;
         $voteData = Vote::model()->fetchVote($relatedModule, $relatedId);
         if (!empty($voteData) && isset($voteData["voteItemList"])) {
             foreach ($voteData["voteItemList"] as $k => $voteItem) {
                 $voteData["voteItemList"][$k]["thumburl"] = FileUtil::fileName($voteItem["picpath"]);
             }
         }
         $data = array("voteData" => $voteData, "uploadConfig" => AttachUtil::getUploadConfig());
         $partView = $currentController->renderPartial($selectView, $data, true);
     }
     return $partView;
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:48,代码来源:ICVote.php

示例3: getAssetUrl

 public function getAssetUrl($module = "")
 {
     if (empty($this->_assetUrl)) {
         if (empty($module)) {
             $module = Ibos::getCurrentModuleName();
         }
         $this->_assetUrl = Ibos::app()->assetManager->getAssetsUrl($module);
     }
     return $this->_assetUrl;
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:10,代码来源:ICController.php


注:本文中的Ibos::getCurrentModuleName方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。