Skip to content

Commit

Permalink
add Быстрый старт
Browse files Browse the repository at this point in the history
add Быстрый старт
  • Loading branch information
CB9TOIIIA committed Jun 20, 2018
1 parent 91d142f commit 1f35b57
Show file tree
Hide file tree
Showing 9 changed files with 100 additions and 4 deletions.
10 changes: 10 additions & 0 deletions config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,16 @@
<option value="yes">Да</option>
<option value="no">Нет</option>
</field>
<field
name="fastboot"
type="radio"
label="Быстрый старт?"
description="com_content юзаешь?"
class="btn-group btn-group-yesno"
default="no">
<option value="yes">Да</option>
<option value="no">Нет</option>
</field>
<field
name="enablecommerce"
type="radio"
Expand Down
1 change: 1 addition & 0 deletions elements/paramsetc.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@
$oksocialname = $params->oksocialname;
$twittersocialname = $params->twittersocialname;
$youtubesocialname = $params->youtubesocialname;
$fastboot = $params->fastboot;

$httpClientj = JHttpFactory::getHttp();

Expand Down
2 changes: 1 addition & 1 deletion myjbzoostat.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<authorUrl>http://cb9t.ru</authorUrl>
<copyright></copyright>
<license></license>
<version>2.7.0</version>
<version>2.7.1</version>
<description><![CDATA[MyJBZooStat - это компонент статистики и менеджер системы комментирования Disqus.<br><br><iframe frameborder='0' allowtransparency='true' scrolling='no' src='https://tpv.sr/1QoBNn1/' width='510' height='300'></iframe>]]> </description>
<creationDate>28 June 2016</creationDate>
<administration>
Expand Down
5 changes: 3 additions & 2 deletions views/index/tmpl/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,8 @@ function nice_num($n) {


<?php
if(count($DataResponceApiYandexexternalReferer->data) > 1) :

if(count($DataResponceApiYandexexternalReferer->data) > 1 && $fastboot != 'yes') :
echo "<h2 class='uk-text-bold uk-text-center'>Переходы по ссылкам на сайтах</h2>";
echo "<table id='myTable344' class='zebratable'>";
echo "<thead>";
Expand Down Expand Up @@ -525,7 +526,7 @@ function nice_num($n) {
<br>

<?php
if(count($DataResponceApiYandexSearchPhrase->data) > 1) :
if(count($DataResponceApiYandexSearchPhrase->data) > 1 && $fastboot != 'yes') :
echo "<h2 class='uk-text-bold uk-text-center'>Переходы по фразам</h2>";
echo "<table id='myTable3454' class='zebratable'>";
echo "<thead>";
Expand Down
2 changes: 1 addition & 1 deletion views/nodubles/tmpl/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@
if (!empty($dublesd)) {
foreach ($dublesd as $keyg) {
$urll = urlencode($keyg);
echo '<li><a target="_blank" href="/?e%5B1331309a-133d-4208-9250-4330706af965%5D='.$urll.'&limit=20&order%5Bfield%5D=_none&order%5Bmode%5D=s&order%5Border%5D=asc&logic=and&send-form=%D0%98%D1%81%D0%BA%D0%B0%D1%82%D1%8C&exact=1&controller=search&option=com_zoo&task=filter&type=realty&app_id=1&Itemid=105">'.$keyg.'</a></li>';
echo '<li><a target="_blank" href="http://dom813.ru/?e%5B1331309a-133d-4208-9250-4330706af965%5D='.$urll.'&limit=20&order%5Bfield%5D=_none&order%5Bmode%5D=s&order%5Border%5D=asc&logic=and&send-form=%D0%98%D1%81%D0%BA%D0%B0%D1%82%D1%8C&exact=1&controller=search&option=com_zoo&task=filter&type=realty&app_id=1&Itemid=105">'.$keyg.'</a></li>';
}
}

Expand Down
Empty file added views/tags/autors/index.html
Empty file.
42 changes: 42 additions & 0 deletions views/tags/autors/tmpl/default.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?php
/** @var $this MyjbzoostatViewAutors */
defined( '_JEXEC' ) or die; // No direct access
?>
<?php

require_once JPATH_ADMINISTRATOR . '/components/com_zoo/config.php';
require_once JPATH_ROOT . '/media/zoo/applications/jbuniversal/framework/jbzoo.php';
require_once JPATH_ROOT . '/media/zoo/applications/jbuniversal/framework/classes/jbmodulehelper.php';
require_once JPATH_ROOT . '/media/zoo/applications/jbuniversal/framework/classes/jbtemplate.php';
$app = App::getInstance('zoo');

//JUST DO IT $this->app ----> $app
?>

<div class="item-page">

<style>.tagsstat .zebra { display: inline-flex; flex-wrap: wrap; width: 98%; height: 500px; flex-direction: column; list-style: none; padding: 0;} .tagsstat .zebra li { padding: 5px; margin-right: 5px; } .tagsstat .zebra li:nth-child(odd) { background: #EFEFEF; }
.tagsstat .zebra li:nth-child(even) { background: white; }</style>
<div class="tagsstat">
<ul class="zebra">
<?php

$db = JFactory::getDBO();
$appId = 1;
$querycounttagalltags = $db->getQuery(true);

$querycounttagalltags = "SELECT name FROM " . ZOO_TABLE_TAG ." ORDER BY name";

$tagsArraytagalltags = array_unique($app->table->tag->database->queryResultArray($querycounttagalltags));

foreach ($tagsArraytagalltags as $tag) {

$querycounttagalltagss = "SELECT COUNT(name) FROM " . ZOO_TABLE_TAG ." WHERE name = '$tag'";

$tagsArraytagalltagss = array_unique($app->table->tag->database->queryResultArray($querycounttagalltagss));

echo '<li><a target="_blank" href="' . JRoute::_($app->route->tag($appId, $tag)) . '">' . $tag . '</a>' .' - '. $tagsArraytagalltagss[0].'</li> ';}
?>
</ul>
</div>
</div>
Empty file.
42 changes: 42 additions & 0 deletions views/tags/autors/view.html.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?php
defined( '_JEXEC' ) or die; // No direct access

/**
* View for current element
* @author CB9TOIIIA
*/



class MyjbzoostatViewAutors extends JViewLegacy
{

public function display( $tpl = null )
{
$this->_setToolBar();
parent::display( $tpl );
}
/**
* Method to display the toolbar
*/
protected function _setToolBar()
{
JToolBarHelper::title( JText::_( 'Статистика тегов' ) );
JToolbarHelper::divider();

$bar = JToolBar::getInstance('toolbar'); //ссылка на объект JToolBar
$title = JText::_('Статьи'); //Надпись на кнопке
$dhtml = "<a href=\"/administrator/index.php?option=com_myjbzoostat&view=articles\" class=\"btn btn-small\"><i class=\"icon-list\" title=\"$title\"></i>$title</a>"; //HTML нашей кнопки
$bar->appendButton('Custom', $dhtml, 'list');//давляем ее на тулбар

JToolBarHelper::divider();

$bar = JToolBar::getInstance('toolbar'); //ссылка на объект JToolBar
$title = JText::_('Авторы'); //Надпись на кнопке
$dhtml = "<a href=\"/administrator/index.php?option=com_myjbzoostat&view=autors\" class=\"btn btn-small\"><i class=\"icon-tags\" title=\"$title\"></i>$title</a>"; //HTML нашей кнопки
$bar->appendButton('Custom', $dhtml, 'list');//давляем ее на тулбар


}

}

0 comments on commit 1f35b57

Please sign in to comment.