Категории услуг и удаление latest из блога
This commit is contained in:
@@ -442,6 +442,12 @@ class ControllerBlogArticle extends Controller {
|
||||
$data['error_keyword'] = '';
|
||||
}
|
||||
|
||||
if (isset($this->error['category'])) {
|
||||
$data['error_category'] = $this->error['category'];
|
||||
} else {
|
||||
$data['error_category'] = '';
|
||||
}
|
||||
|
||||
$url = '';
|
||||
|
||||
if (isset($this->request->get['filter_name'])) {
|
||||
@@ -596,8 +602,8 @@ class ControllerBlogArticle extends Controller {
|
||||
$data['main_blog_category_id'] = 0;
|
||||
}
|
||||
|
||||
if (isset($this->request->post['article_blog_category'])) {
|
||||
$categories = $this->request->post['article_blog_category'];
|
||||
if (isset($this->request->post['article_category'])) {
|
||||
$categories = $this->request->post['article_category'];
|
||||
} elseif (isset($this->request->get['article_id'])) {
|
||||
$categories = $this->model_blog_article->getArticleCategories($this->request->get['article_id']);
|
||||
} else {
|
||||
@@ -756,6 +762,10 @@ class ControllerBlogArticle extends Controller {
|
||||
$this->error['meta_h1'][$language_id] = $this->language->get('error_meta_h1');
|
||||
}
|
||||
}
|
||||
|
||||
if (empty($this->request->post['article_category'])) {
|
||||
$this->error['category'] = $this->language->get('error_category');
|
||||
}
|
||||
|
||||
if (isset($this->request->post['article_seo_url']) && is_array($this->request->post['article_seo_url'])) {
|
||||
foreach ($this->request->post['article_seo_url'] as $store_id => &$languages) {
|
||||
@@ -932,4 +942,4 @@ class ControllerBlogArticle extends Controller {
|
||||
$this->response->addHeader('Content-Type: application/json');
|
||||
$this->response->setOutput(json_encode($json));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,12 +41,6 @@ class ControllerBlogSetting extends Controller {
|
||||
$data['entry_image_related'] = $this->language->get('entry_image_related');
|
||||
$data['entry_width'] = $this->language->get('entry_width');
|
||||
$data['entry_height'] = $this->language->get('entry_height');
|
||||
$data['entry_name'] = $this->language->get('entry_name');
|
||||
$data['entry_html_h1'] = $this->language->get('entry_html_h1');
|
||||
$data['entry_meta_title'] = $this->language->get('entry_meta_title');
|
||||
$data['entry_meta_description'] = $this->language->get('entry_meta_description');
|
||||
$data['entry_meta_keyword'] = $this->language->get('entry_meta_keyword');
|
||||
|
||||
$data['help_comment'] = $this->language->get('help_comment');
|
||||
$data['help_article_limit'] = $this->language->get('help_article_limit');
|
||||
$data['help_article_description_length'] = $this->language->get('help_article_description_length');
|
||||
@@ -222,36 +216,6 @@ class ControllerBlogSetting extends Controller {
|
||||
$data['configblog_image_related_height'] = $this->config->get('configblog_image_related_height');
|
||||
}
|
||||
|
||||
if (isset($this->request->post['configblog_name'])) {
|
||||
$data['configblog_name'] = $this->request->post['configblog_name'];
|
||||
} else {
|
||||
$data['configblog_name'] = $this->config->get('configblog_name');
|
||||
}
|
||||
|
||||
if (isset($this->request->post['configblog_html_h1'])) {
|
||||
$data['configblog_html_h1'] = $this->request->post['configblog_html_h1'];
|
||||
} else {
|
||||
$data['configblog_html_h1'] = $this->config->get('configblog_html_h1');
|
||||
}
|
||||
|
||||
if (isset($this->request->post['configblog_meta_title'])) {
|
||||
$data['configblog_meta_title'] = $this->request->post['configblog_meta_title'];
|
||||
} else {
|
||||
$data['configblog_meta_title'] = $this->config->get('configblog_meta_title');
|
||||
}
|
||||
|
||||
if (isset($this->request->post['configblog_meta_description'])) {
|
||||
$data['configblog_meta_description'] = $this->request->post['configblog_meta_description'];
|
||||
} else {
|
||||
$data['configblog_meta_description'] = $this->config->get('configblog_meta_description');
|
||||
}
|
||||
|
||||
if (isset($this->request->post['configblog_meta_keyword'])) {
|
||||
$data['configblog_meta_keyword'] = $this->request->post['configblog_meta_keyword'];
|
||||
} else {
|
||||
$data['configblog_meta_keyword'] = $this->config->get('configblog_meta_keyword');
|
||||
}
|
||||
|
||||
$data['header'] = $this->load->controller('common/header');
|
||||
$data['column_left'] = $this->load->controller('common/column_left');
|
||||
$data['footer'] = $this->load->controller('common/footer');
|
||||
@@ -294,4 +258,4 @@ class ControllerBlogSetting extends Controller {
|
||||
|
||||
return !$this->error;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user