From: <ki...@us...> - 2009-10-12 02:46:19
|
Revision: 434 http://xc-tokai.svn.sourceforge.net/xc-tokai/?rev=434&view=rev Author: kilica Date: 2009-10-12 02:46:12 +0000 (Mon, 12 Oct 2009) Log Message: ----------- update for google chart api Modified Paths: -------------- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/actions/PollDetailAction.class.php modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/blocks/PollOneBlock.class.php modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/class/AbstractAction.class.php modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/english/modinfo.php modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/ja_utf8/modinfo.php modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/templates/bizpoll_poll_detail.html modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/xoops_version.php Modified: modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/actions/PollDetailAction.class.php =================================================================== --- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/actions/PollDetailAction.class.php 2009-10-02 09:54:07 UTC (rev 433) +++ modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/actions/PollDetailAction.class.php 2009-10-12 02:46:12 UTC (rev 434) @@ -119,8 +119,8 @@ //for Google Chart API $choiceArr = explode(',', $this->mObjects[$key]->get('choice_id')); foreach(array_keys($choiceArr) as $keyC){ - $this->mChart['count'][$choiceArr[$keyC]]++; - $this->mChart['title'][$choiceArr[$keyC]] = $this->mObjects[$key]->mChoice[$keyC]->getShow('title'); + @$this->mChart['count'][$choiceArr[$keyC]]++; + $this->mChart['title'][$choiceArr[$keyC]] = $this->mObjects[$key]->mChoice[$keyC]->getShow('title') . ' ('. $this->mChart['count'][$choiceArr[$keyC]] .')'; } } $this->mChart['total'] = count($this->mChart['title']); @@ -140,6 +140,7 @@ $render->setAttribute('enq', $this->mEnq); $render->setAttribute('chart', $this->mChart); $render->setAttribute('pageNavi', $this->mFilter->mNavi); + $render->setAttribute('chartSetting', explode(',', $this->getConfig('chart'))); } } Modified: modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/blocks/PollOneBlock.class.php =================================================================== --- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/blocks/PollOneBlock.class.php 2009-10-02 09:54:07 UTC (rev 433) +++ modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/blocks/PollOneBlock.class.php 2009-10-12 02:46:12 UTC (rev 434) @@ -49,6 +49,8 @@ **/ function prepare() { + $root = XCube_Root::getSingleton(); + $root->mLanguageManager->loadModuleMessageCatalog($this->_mBlock->get('dirname')); return parent::prepare() && $this->_parseOptions() && $this->_setupObject(); } Modified: modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/class/AbstractAction.class.php =================================================================== --- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/class/AbstractAction.class.php 2009-10-02 09:54:07 UTC (rev 433) +++ modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/class/AbstractAction.class.php 2009-10-12 02:46:12 UTC (rev 434) @@ -165,7 +165,7 @@ function getConfig($config) { $configHandler =& Bizpoll_Utils::getXoopsHandler('config'); - $configArr =& $configHandler->getConfigsByDirname($this->mDirname); + $configArr =& $configHandler->getConfigsByDirname($this->mAsset->mDirname); return $configArr[$config]; } Modified: modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/english/modinfo.php =================================================================== --- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/english/modinfo.php 2009-10-02 09:54:07 UTC (rev 433) +++ modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/english/modinfo.php 2009-10-12 02:46:12 UTC (rev 434) @@ -64,5 +64,26 @@ define('_MI_BIZPOLL_TPL_CHOICE_EDIT', "CHOICE_EDIT"); define('_MI_BIZPOLL_TPL_CHOICE_DELETE', "CHOICE_DELETE"); define('_MI_BIZPOLL_TPL_CHOICE_VIEW', "CHOICE_VIEW"); +define('_MI_BIZPOLL_TITLE_GR_ID', "XCat Group ID"); +define('_MI_BIZPOLL_DESC_GR_ID', "Set 0 if you won't use XCat category"); +define('_MI_BIZPOLL_TITLE_CSS_FILE', "css file"); +define('_MI_BIZPOLL_DESC_CSS_FILE', "css file location"); +define('_MI_BIZPOLL_TITLE_PERMIT', "permission titles"); +define('_MI_BIZPOLL_DESC_PERMIT', "set permission title if you use xcat in order viewer|poster|editor|poller, separated with '|'. default value:viewer|poster|editor|viewer"); +define('_MI_BIZPOLL_TITLE_SHOW_RSS', "RSS Output"); +define('_MI_BIZPOLL_DESC_SHOW_RSS', "RSS output"); +define('_MI_BIZPOLL_TITLE_EDITOR', "Editor"); +define('_MI_BIZPOLL_DESC_EDITOR', "Select Editor"); +define('_MI_BIZPOLL_LANG_NOEDITOR', "No Editor Use"); +define('_MI_BIZPOLL_TITLE_IP_PERIOD', "Poll Interval from the same IP address(hour)"); +define('_MI_BIZPOLL_DESC_IP_PERIOD', "Poll Interval from the same IP address(hour)"); +define('_MI_BIZPOLL_BLOCK_NAME_ENQ', "Enquete List"); +define('_MI_BIZPOLL_BLOCK_DESC_ENQ', "Enquete List"); +define('_MI_BIZPOLL_BLOCK_NAME_POLLONE', "Enquete Poll"); +define('_MI_BIZPOLL_BLOCK_DESC_POLLONE', ""); +define('_MI_BIZPOLL_BLOCK_NAME_POLLNEW', "Latest Enquete"); +define('_MI_BIZPOLL_BLOCK_DESC_POLLNEW', ""); +define('_MI_BIZPOLL_TITLE_CHART', "Google Chart API Setting"); +define('_MI_BIZPOLL_DESC_CHART', "Set Chart Type, Width(px), Height(px), separated with ','. Default Value:"p,400,100". 'Type' is bhs(Horizontal Bar), bvs(Vertical Bar), p(Pie) or p3(3D Pie)"); ?> Modified: modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/ja_utf8/modinfo.php =================================================================== --- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/ja_utf8/modinfo.php 2009-10-02 09:54:07 UTC (rev 433) +++ modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/language/ja_utf8/modinfo.php 2009-10-12 02:46:12 UTC (rev 434) @@ -84,4 +84,7 @@ define('_MI_BIZPOLL_BLOCK_DESC_POLLONE', "複数の投票ブロックを同じページに表示させると投票できなくなります(^ ^;"); define('_MI_BIZPOLL_BLOCK_NAME_POLLNEW', "最新のアンケート"); define('_MI_BIZPOLL_BLOCK_DESC_POLLNEW', "複数の投票ブロックを同じページに表示させると投票できなくなります(^ ^;"); +define('_MI_BIZPOLL_TITLE_CHART', "Google Chart API 設定"); +define('_MI_BIZPOLL_DESC_CHART', "チャートの種類、幅(px)、高さ(px)をカンマ区切り(,)で指定します。初期値は、p,400,100。種類は、bhs(横棒グラフ)、bvs(縦棒グラフ)、p(円グラフ)、p3(立体円グラフ)が指定できます"); + ?> Modified: modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/templates/bizpoll_poll_detail.html =================================================================== --- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/templates/bizpoll_poll_detail.html 2009-10-02 09:54:07 UTC (rev 433) +++ modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/templates/bizpoll_poll_detail.html 2009-10-12 02:46:12 UTC (rev 434) @@ -5,6 +5,7 @@ <{foreach item=pCount from=$chart.count key=pKey}> <div style="float:left;width:<{$pCount*10}>px;height:10px;background-color:#000000;margin:10px 30px 10px 5px;"></div><{$chart.title[$pKey]}> (<{$smarty.const._MD_BIZPOLL_LANG_POLL_COUNT}>: <{$pCount}>)<br style="clear:left;" /> <{/foreach}> +<img src="http://chart.apis.google.com/chart?cht=<{$chartSetting[0]}>&chd=t:<{','|implode:$chart.count}>&chs=<{$chartSetting[1]}>x<{$chartSetting[2]}>&chl=<{'|'|implode:$chart.title|escape:'url'}>" alt="chart" width="<{$chartSetting[1]}>" height="<{$chartSetting[2]}>" /> <h2><{$smarty.const._MD_BIZPOLL_LANG_POLL_RESULT}></h2> <div class="pagenavi"><{xoops_pagenavi pagenavi=$pageNavi}></div> Modified: modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/xoops_version.php =================================================================== --- modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/xoops_version.php 2009-10-02 09:54:07 UTC (rev 433) +++ modules_bizpoll/trunk/xoops_trust_path/modules/bizpoll/xoops_version.php 2009-10-12 02:46:12 UTC (rev 434) @@ -21,7 +21,7 @@ // Define a basic manifesto. // $modversion['name'] = _MI_BIZPOLL_LANG_BIZPOLL; -$modversion['version'] = 0.16; +$modversion['version'] = 0.20; $modversion['description'] = _MI_BIZPOLL_DESC_BIZPOLL; $modversion['author'] = _MI_BIZPOLL_LANG_AUTHOR; $modversion['credits'] = _MI_BIZPOLL_LANG_CREDITS; @@ -182,6 +182,15 @@ 'options' => array(), 'default' => '24' ), + array( + 'name' => 'chart', + 'title' => "_MI_BIZPOLL_TITLE_CHART", + 'description' => "_MI_BIZPOLL_DESC_CHART", + 'formtype' => 'textbox', + 'valuetype' => 'text', + 'options' => array(), + 'default' => 'p,400,100' + ), /* array( 'name' => 'xxxx', This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |