BLaDe
OpenCart-TR
- Katılım
- 4 Şub 2010
- Mesajlar
- 459
- Tepkime puanı
- 0
- Puanları
- 0
- Yaş
- 37
- Konum
- izmir
- Web sitesi
- www.ondermedikal.com
Merhaba arkadaşlar;
vereceğim kodlar biraz uzun olabilir ama bazı arkadaşlarımız çok işine yarayacağı bir eklentidir. Şahsen benim çok işeme yarıyor...
Özellikle belirtiyorum arkadaşlar sadece ; 1.5.1 Sürümü için geçerlidir.
admin/language/turkish/turkish.php
Bul;
Altına Ekle;
admin/model/catalog/category.php
Bul;
Önüne;
admin/controller/catalog/category.php
Bul;
Sonrasına;
Bul;
Sonrasına;
Bul;
Öncesine;
admin/view/template/catalog/category_list.tpl
Bul;
Değiştir;
admin/model/catalog/product.php
Bul;
Öncesine;
admin/controller/catalog/product.php
Bul;
Sonrasına;
Bul;
Sonrasına;
Bul;
Öncesine;
admin/view/template/catalog/product_list.tpl
Bul;
Değiştir;
admin/controller/catalog/review.php
Bul;
Sonrasına;
Bul;
Sonrasına;
Bul;
Öncesine;
admin/view/template/catalog/review_list.tpl
Bul;
Değiştir;
admin/model/catalog/information.php
Bul;
Öncesine;
admin/controller/catalog/information.php
Bul;
Sonrasına;
Bul;
Sonrasına;
Bul;
Öncesine;
admin/view/template/catalog/information_list.tpl
Bul;
Değiştir;
Hepsi bu kadar...
Kolay Gelsin.
vereceğim kodlar biraz uzun olabilir ama bazı arkadaşlarımız çok işine yarayacağı bir eklentidir. Şahsen benim çok işeme yarıyor...
Özellikle belirtiyorum arkadaşlar sadece ; 1.5.1 Sürümü için geçerlidir.
admin/language/turkish/turkish.php
Bul;
PHP:
$_['button_reset'] = 'Sıfırla';
Altına Ekle;
PHP:
$_['button_enable'] = 'Açık';
$_['button_disable'] = 'Kapalı';
admin/model/catalog/category.php
Bul;
PHP:
public function deleteCategory($category_id) {
Önüne;
PHP:
public function editCategoryStatus($category_id, $status) {
$this->db->query("UPDATE " . DB_PREFIX . "category SET status = '" . (int)$status . "', date_modified = NOW() WHERE category_id = '" . (int)$category_id . "'");
$this->cache->delete('category');
}
admin/controller/catalog/category.php
Bul;
PHP:
$this->data['delete'] = $this->url->link('catalog/category/delete', 'token=' . $this->session->data['token'], 'SSL');
Sonrasına;
PHP:
$this->data['enabled'] = $this->url->link('catalog/category/enable', 'token=' . $this->session->data['token'], 'SSL');
$this->data['disabled'] = $this->url->link('catalog/category/disable', 'token=' . $this->session->data['token'], 'SSL');
Bul;
PHP:
$this->data['button_delete'] = $this->language->get('button_delete');
Sonrasına;
PHP:
$this->data['button_enable'] = $this->language->get('button_enable');
$this->data['button_disable'] = $this->language->get('button_disable');
Bul;
PHP:
private function validateDelete() {
Öncesine;
PHP:
public function enable() {
$this->load->language('catalog/category');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/category');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $category_id) {
$this->model_catalog_category->editCategoryStatus($category_id, 1);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/category', 'token=' . $this->session->data['token'], 'SSL'));
}
$this->getList();
}
public function disable() {
$this->load->language('catalog/category');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/category');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $category_id) {
$this->model_catalog_category->editCategoryStatus($category_id, 0);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/category', 'token=' . $this->session->data['token'], 'SSL'));
}
$this->getList();
}
admin/view/template/catalog/category_list.tpl
Bul;
PHP:
<div class="buttons"><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('#form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
Değiştir;
PHP:
<div class="buttons"><a onclick="$('#form').attr('action', '<?php echo $enabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_enable; ?></span></a><a onclick="$('#form').attr('action', '<?php echo $disabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_disable; ?></span></a><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('#form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
admin/model/catalog/product.php
Bul;
PHP:
public function copyProduct($product_id) {
Öncesine;
PHP:
public function editProductStatus($product_id, $status) {
$this->db->query("UPDATE " . DB_PREFIX . "product SET status = '" . (int)$status . "', date_modified = NOW() WHERE product_id = '" . (int)$product_id . "'");
$this->cache->delete('product');
}
admin/controller/catalog/product.php
Bul;
PHP:
$this->data['button_filter'] = $this->language->get('button_filter');
Sonrasına;
PHP:
$this->data['button_enable'] = $this->language->get('button_enable');
$this->data['button_disable'] = $this->language->get('button_disable');
Bul;
PHP:
$this->data['delete'] = $this->url->link('catalog/product/delete', 'token=' . $this->session->data['token'] . $url, 'SSL');
Sonrasına;
PHP:
$this->data['enabled'] = $this->url->link('catalog/product/enable', 'token=' . $this->session->data['token'] . $url, 'SSL');
$this->data['disabled'] = $this->url->link('catalog/product/disable', 'token=' . $this->session->data['token'] . $url, 'SSL');
Bul;
PHP:
private function validateDelete() {
Öncesine;
PHP:
public function enable() {
$this->load->language('catalog/product');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/product');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $product_id) {
$this->model_catalog_product->editProductStatus($product_id, 1);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/product', 'token=' . $this->session->data['token'] . $url, 'SSL'));
}
$this->getList();
}
public function disable() {
$this->load->language('catalog/product');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/product');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $product_id) {
$this->model_catalog_product->editProductStatus($product_id, 0);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/product', 'token=' . $this->session->data['token'] . $url, 'SSL'));
}
$this->getList();
}
admin/view/template/catalog/product_list.tpl
Bul;
PHP:
<div class="buttons"><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('#form').attr('action', '<?php echo $copy; ?>'); $('#form').submit();" class="button"><span><?php echo $button_copy; ?></span></a><a onclick="$('form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
Değiştir;
PHP:
<div class="buttons"><a onclick="$('#form').attr('action', '<?php echo $enabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_enable; ?></span></a><a onclick="$('#form').attr('action', '<?php echo $disabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_disable; ?></span></a><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('#form').attr('action', '<?php echo $copy; ?>'); $('#form').submit();" class="button"><span><?php echo $button_copy; ?></span></a><a onclick="$('form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
admin/controller/catalog/review.php
Bul;
PHP:
$this->data['delete'] = $this->url->link('catalog/review/delete', 'token=' . $this->session->data['token'] . $url, 'SSL');
Sonrasına;
PHP:
$this->data['enabled'] = $this->url->link('catalog/review/enable', 'token=' . $this->session->data['token'] . $url, 'SSL');
$this->data['disabled'] = $this->url->link('catalog/review/disable', 'token=' . $this->session->data['token'] . $url, 'SSL');
Bul;
PHP:
$this->data['button_delete'] = $this->language->get('button_delete');
Sonrasına;
PHP:
$this->data['button_enable'] = $this->language->get('button_enable');
$this->data['button_disable'] = $this->language->get('button_disable');
Bul;
PHP:
private function validateDelete() {
Öncesine;
PHP:
public function enable() {
$this->load->language('catalog/review');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/review');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $review_id) {
$data = array();
$result = $this->model_catalog_review->getReview($review_id);
foreach ($result as $key => $value) {
$data[$key] = $value;
}
$data['status'] = 1;
$this->model_catalog_review->editReview($review_id, $data);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/review', 'token=' . $this->session->data['token'] . $url, 'SSL'));
}
$this->getList();
}
public function disable() {
$this->load->language('catalog/review');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/review');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $review_id) {
$data = array();
$result = $this->model_catalog_review->getReview($review_id);
foreach ($result as $key => $value) {
$data[$key] = $value;
}
$data['status'] = 0;
$this->model_catalog_review->editReview($review_id, $data);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/review', 'token=' . $this->session->data['token'] . $url, 'SSL'));
}
$this->getList();
}
admin/view/template/catalog/review_list.tpl
Bul;
PHP:
<div class="buttons"><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
Değiştir;
PHP:
<div class="buttons"><a onclick="$('#form').attr('action', '<?php echo $enabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_enable; ?></span></a><a onclick="$('#form').attr('action', '<?php echo $disabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_disable; ?></span></a><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
admin/model/catalog/information.php
Bul;
PHP:
public function deleteInformation($information_id) {
Öncesine;
PHP:
public function editInformationStatus($information_id, $status) {
$this->db->query("UPDATE " . DB_PREFIX . "information SET status = '" . (int)$status . "'WHERE information_id = '" . (int)$information_id . "'");
$this->cache->delete('information');
}
admin/controller/catalog/information.php
Bul;
PHP:
$this->data['delete'] = $this->url->link('catalog/information/delete', 'token=' . $this->session->data['token'] . $url, 'SSL');
Sonrasına;
PHP:
$this->data['enabled'] = $this->url->link('catalog/information/enable', 'token=' . $this->session->data['token'] . $url, 'SSL');
$this->data['disabled'] = $this->url->link('catalog/information/disable', 'token=' . $this->session->data['token'] . $url, 'SSL');
Bul;
PHP:
$this->data['button_delete'] = $this->language->get('button_delete');
Sonrasına;
PHP:
$this->data['button_enable'] = $this->language->get('button_enable');
$this->data['button_disable'] = $this->language->get('button_disable');
Bul;
PHP:
private function validateDelete() {
Öncesine;
PHP:
public function enable() {
$this->load->language('catalog/information');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/information');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $information_id) {
$this->model_catalog_information->editInformationStatus($information_id, 1);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/information', 'token=' . $this->session->data['token'] . $url, 'SSL'));
}
$this->getList();
}
public function disable() {
$this->load->language('catalog/information');
$this->document->setTitle($this->language->get('heading_title'));
$this->load->model('catalog/information');
if (isset($this->request->post['selected'])) {
foreach ($this->request->post['selected'] as $information_id) {
$this->model_catalog_information->editInformationStatus($information_id, 0);
}
$this->session->data['success'] = $this->language->get('text_success');
$url = '';
if (isset($this->request->get['page'])) {
$url .= '&page=' . $this->request->get['page'];
}
if (isset($this->request->get['sort'])) {
$url .= '&sort=' . $this->request->get['sort'];
}
if (isset($this->request->get['order'])) {
$url .= '&order=' . $this->request->get['order'];
}
$this->redirect($this->url->link('catalog/information', 'token=' . $this->session->data['token'] . $url, 'SSL'));
}
$this->getList();
}
admin/view/template/catalog/information_list.tpl
Bul;
PHP:
<div class="buttons"><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
Değiştir;
PHP:
<div class="buttons"><a onclick="$('#form').attr('action', '<?php echo $enabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_enable; ?></span></a><a onclick="$('#form').attr('action', '<?php echo $disabled; ?>'); $('#form').submit();" class="button"><span><?php echo $button_disable; ?></span></a><a onclick="location = '<?php echo $insert; ?>'" class="button"><span><?php echo $button_insert; ?></span></a><a onclick="$('form').submit();" class="button"><span><?php echo $button_delete; ?></span></a></div>
Hepsi bu kadar...
Kolay Gelsin.