Beispiel #1
0
 function sitemapAction()
 {
     $v_params['logined'] = LoginChecker::isLogined();
     $v_params['smap']['main'] = TRUE;
     $v_params['sys_name'] = SysPropertiesUtil::getPropertyValue("sys_name");
     $v_params['sys_slog'] = SysPropertiesUtil::getPropertyValue("sys_slog");
     $v_params['in_card_count'] = CardCounter::countGDSinCard();
     $v_params['sys_news_cats_HTML'] = SysNewsCatUtil::createTreeHTML("/" . SYS_BLOG_DIR . "?" . SYS_ART_CAT_PARAM_NAME . "=");
     if (0 != $_GET['code']) {
         $v_params['imags'] = TRUE;
         $region = AddrRegionUtil::getRegionByCode($_GET['code']);
         $v_params['title'] = "Список стендов для региона «" . $region['name'] . "»";
         $v_params['accounts'] = ImgAccountUtil::getImgAccountsByRegionCode($region['code'], TRUE);
     } else {
         $v_params['imags'] = FALSE;
         $v_params['title'] = "Список регионов";
         $v_params['regions'] = AddrRegionUtil::getRegions();
     }
     Application::fastView('main/sys_site_map', $v_params);
 }
Beispiel #2
0
 function articleAction()
 {
     $img_id = $_SESSION['imag_id'];
     $v_params['sys_name'] = SysPropertiesUtil::getPropertyValue("sys_name");
     $v_params['sys_slog'] = SysPropertiesUtil::getPropertyValue("sys_slog");
     $imgAccount = ImgAccountUtil::getImgAccountById($img_id, TRUE);
     $imgArticle = ImgBlogArtUtil::getImgBlogArtById($img_id, $_REQUEST[ART_PARAM_NAME]);
     if (NULL != $imgAccount && NULL != $imgArticle) {
         $v_params['logined'] = LoginChecker::isLogined();
         $v_params['in_card_count'] = CardCounter::countGDSinCard();
         if ($v_params['logined'] == $img_id) {
             $v_params['mysc']['main'] = TRUE;
         }
         $v_params['img_name'] = $imgAccount['img_name'];
         $v_params['img_slog'] = $imgAccount['img_slog'];
         $v_params['img_all_gds_cats_href'] = "/" . IMAG_PREFIX . $img_id . "/" . IMAG_DIR;
         $v_params['img_gds_cats_HTML'] = ImgGdsCatUtil::createTreeHTML($imgAccount['id'], "/" . IMAG_PREFIX . $img_id . "/" . IMAG_DIR . "?" . PROD_CAT_PARAM_NAME . "=");
         $v_params['img_all_blog_cats_href'] = "/" . IMAG_PREFIX . $img_id . "/" . BLOG_DIR;
         $v_params['img_blog_cats_HTML'] = ImgBlogCatUtil::createTreeHTML($imgAccount['id'], "/" . IMAG_PREFIX . $img_id . "/" . BLOG_DIR . "?" . ART_CAT_PARAM_NAME . "=");
         $v_params['img_blog_url'] = "/" . IMAG_PREFIX . $img_id . "/" . BLOG_DIR . "/";
         $v_params['img_blog_breadcrump_HTML'] = ImgBlogCatUtil::createBreadcrumpHTML($imgAccount['id'], $imgArticle['img_blog_cat_id']);
         $v_params['img_article'] = $imgArticle;
         $v_params['img_blog_art_blocks'] = ImgBlogArtBlockUtil::getImgBlogArtBlocksByArtId($imgArticle['id']);
         Application::fastView('imags/img_article', $v_params);
     } else {
         Application::fastView('main/sys_error', NULL);
     }
 }