0 Пользователей и 1 Гость просматривают эту тему.
  • 13 Ответов
  • 1736 Просмотров
*

Артур13

  • Осваиваюсь на форуме
  • 13
  • 0 / 0
Добрый день, форумчане!
Нужен модуль на страницу товара JoomShopping, чтобы в нем отображались кнопки "распечатать", "скачать Pdf" - для соответственно печати и формирования pdf из контентной части документа.
Встречал ли кто-нибудь подобный модуль где-либо? Может быть кто реализовывал скриптом или еще как-то?
Не нашел ничего в магазинах и сети на этот счет.
*

dmitry_stas

  • Легенда
  • 13151
  • 1234 / 8
даже тут на форуме выкладывали такой плагин, но что-то сходу не нашел. но был 100%, хотите поищите.
Тут дарят бакс просто за регистрацию! Успей получить!
Все советы на форуме раздаю бесплатно, то есть даром. Индивидуально бесплатно консультирую только по вопросам стоимости индивидуальных консультаций
*

kit2m2

  • Живу я здесь
  • 3269
  • 268 / 0
  • Беру сайты на полное сопровождение
Для JoomShopping нет такого плагина. Нужно копать здесь - https://extensions.joomla.org/extensions/?filter[tags][0]=354&filter[core_catid]=&filter[includes]=plugin&filter[versions]=&filter[type]=&filter[hasdemo]=&filter[newupdated]=&filter[score]=&filter[favourites]=&dir=DESC&controller=filter&view=extension&layout=list&clearorders=0&clearfilters=1&limitstart=0]

Есть такой плагин - Phoca PDF Content, но работает только для контента

Есть еще такой -  Phoca PDF VirtueMart, но работает только для VirtueMart
Расширения для JoomShopping | Расширения на заказ | Сайты и магазины под ключ: Дизайн, Верстка, Программирование, СЕО-оптимизация, Сопровождение, Перенос на Joomla 4+ и JoomShopping 5+
*

dmitry_stas

  • Легенда
  • 13151
  • 1234 / 8
Для JoomShopping нет такого плагина.
есть есть, на форуме делали 100%. я еще помню подсказывал что-то по нему

P.S. нашел Plugin Generate PDF Product
« Последнее редактирование: 07.10.2018, 14:18:15 от dmitry_stas »
Тут дарят бакс просто за регистрацию! Успей получить!
Все советы на форуме раздаю бесплатно, то есть даром. Индивидуально бесплатно консультирую только по вопросам стоимости индивидуальных консультаций
*

kit2m2

  • Живу я здесь
  • 3269
  • 268 / 0
  • Беру сайты на полное сопровождение
Не для страницы товара... Насколько я помню...

Есть еще это - Generate PDF product list
Расширения для JoomShopping | Расширения на заказ | Сайты и магазины под ключ: Дизайн, Верстка, Программирование, СЕО-оптимизация, Сопровождение, Перенос на Joomla 4+ и JoomShopping 5+
*

Артур13

  • Осваиваюсь на форуме
  • 13
  • 0 / 0
есть есть, на форуме делали 100%. я еще помню подсказывал что-то по нему

P.S. нашел Plugin Generate PDF Product

ДА! Это то что нужно! Огромное спасибо!
Необходимо отредактировать шаблон вывода PDF файла что я и сделал. Получилось так:
PDF: https://eurospeckam.ru/spetsavtotekhnika/neftepromyslovaya-tekhnika/sin-32-na-shassi-kamaz-43118?PDF

Но! Как видите в pdf-файле описание товара выходит за область 1ой страницы... Что нужно сделать чтобы описание дописывалось на второй страницы а не выходило за области 1ой страницы. Именно тогда когда необходимо (на данной страницы товара описание очень длинное, такое будет на каждом товаре).
Код
<?php
/**
* @version      1.0.1 03.02.2017
* @author       Maximis <maximis@list.ru>
* @package      generate_pdf_product
* [member=126442]copyright[/member]    Copyright (C) Maximis. All rights reserved.
* @license      GNU/GPL
*/
include(JPATH_SITE."/components/com_jshopping/lib/pdf_config.php");
include(JPATH_SITE."/components/com_jshopping/lib/tcpdf/tcpdf.php");

class JproductPDF extends TCPDF{
   
private $params;
private $product;
private $product_images;

function __construct($params, $product, $product_images, $orientation, $unit, $format) {
parent::__construct($orientation, $unit, $format, true, 'UTF-8');

$this->jshopConfig = JSFactory::getConfig();
$this->params = $params;
$this->product = $product;
$this->product_images = $product_images;

$this->SetFont('freesans','',10);
$this->setPrintHeader(false);
$this->setPrintFooter(false);
$this->SetMargins(0,0,0);
$this->SetAutoPageBreak(false);

$this->SetCreator(PDF_CREATOR);
$this->SetTitle($this->product->name);
$this->SetSubject($this->product->name);
$this->SetKeywords('product, PDF, '.$this->product->name);

$this->addPage();
}

function addHeader() {
if ($this->params->get('logo')) {
$this->Image($this->params->get('logo'),20,1,170);

}
$this->Line(14,34,195,34);
$this->Ln(36);
}

function addTitle() {
$this->SetX(14);
$this->SetFont('freesans','',16);
$this->SetTextColor(0,0,0);
$this->Cell(182,7,$this->product->name,0,0,'L',false);
}

function addImage() {
if (!empty($this->product_images)) {
$this->Image($this->jshopConfig->image_product_live_path.'/'.$this->product_images[0]->image_name,14,43,75);
$this->Ln(0);
}
}

function addExtraFields() {
$this->SetFont('freesans','', 8);
$this->SetY(45);
$this->SetX(95);

if ($this->jshopConfig->product_show_manufacturer && $this->product->manufacturer_info->name != '') {
$this->MultiCell(40,3,_JSHOP_MANUFACTURER.':',0,'L','L',false);
$this->MultiCell(42,3,$this->product->manufacturer_info->name,0,'L','R',false);
$this->Ln();
$this->SetX(95);
}

foreach($this->product->extra_field as $extra_field) {
$this->SetFont('freesans','', 8);
$this->MultiCell(40,3,$extra_field['name'].':',0,'L','L',false);
$this->MultiCell(42,3,$extra_field['value'],0,'L','R',false);
$this->Ln();
$this->SetX(95);
}
if ($this->product->_display_price) {
$this->SetFont('freesans','', 15);
$this->MultiCell(40,3,_JSHOP_PRICE.':',0,'L','L',false);
$this->SetTextColor(255,0,0);
$this->MultiCell(42,3,formatprice($this->product->getPriceCalculate()),0,'L','R',false);
$this->Ln();
$this->SetX(95);
}
}

function addDescription() {
$this->SetFont('freesans','', 8);
$this->SetY(100);
$this->SetX(95);
$this->SetFillColor(255,255,255);
$this->MultiCell(100,1,strip_tags($this->product->description),0,1,'L',false);
$this->Line(14, 100, 195, 100);
$this->Ln(0);
}

function addThumbImages() {
$x = 14;
$y = 101;
$w = 37;
$column = 2;
$interval_x = 38;
$interval_y = 29;
$show = 12;

$count = 1;
foreach($this->product_images as $k=>$image) {
if ($k == $show) {
break;
}
$this->image($this->jshopConfig->image_product_live_path.'/'.$image->image_thumb,$x,$y,$w);
if ($count == $column) {
$count = 1;
$x = $x-$interval_x*($column-1);
$y = $y+$interval_y;
}else{
$count++;
$x = $x+$interval_x;
}
}
}

function addFooter() {
$this->Line(14,290,195,290);
$this->SetXY(14,-5);
$this->SetFont('freesansb','',8);
$text_color = $this->convertColorHexToDec($this->params->get('text_color'));
$this->SetTextColor($text_color['red'],$text_color['green'],$text_color['blue']);
$this->Cell(91,4,$this->params->get('company'),0,0,'L');
$this->Cell(91,4,$this->params->get('url'),0,0,'R');
}

}
?>
*

Артур13

  • Осваиваюсь на форуме
  • 13
  • 0 / 0
есть есть, на форуме делали 100%. я еще помню подсказывал что-то по нему

P.S. нашел Plugin Generate PDF Product

dmitry_stas, сможете посмотреть и помочь решить проблему?
*

Артур13

  • Осваиваюсь на форуме
  • 13
  • 0 / 0
[Решено]
1 Установил плагин который подсказал dmitry_stas
2 Вставил плагин на страницу
3 Отредактировал внешний вид кнопки
4 plugins/jshoppingproducts/generate_pdf_product/assets/pdf/generate_pdf_product.php  - здесь редактируется вывод pdf файла.
я сделал так:
Код
<?php
/**
* @version      1.0.1 03.02.2017
* @author       Maximis <maximis@list.ru>
* @package      generate_pdf_product
* [member=126442]copyright[/member]    Copyright (C) Maximis. All rights reserved.
* @license      GNU/GPL
*/
include(JPATH_SITE."/components/com_jshopping/lib/pdf_config.php");
include(JPATH_SITE."/components/com_jshopping/lib/tcpdf/tcpdf.php");

class JproductPDF extends TCPDF{
   
private $params;
private $product;
private $product_images;

function __construct($params, $product, $product_images, $orientation, $unit, $format) {
parent::__construct($orientation, $unit, $format, true, 'UTF-8');

$this->jshopConfig = JSFactory::getConfig();
$this->params = $params;
$this->product = $product;
$this->product_images = $product_images;

$this->SetFont('freesans','',10);
$this->setPrintHeader(false);
$this->setPrintFooter(false);
$this->SetMargins(0,10,0);

$this->SetCreator(PDF_CREATOR);
$this->SetTitle($this->product->name);
$this->SetSubject($this->product->name);
$this->SetAutoPageBreak(true,10);
$this->SetKeywords('product, PDF, '.$this->product->name);
$this->addPage();


}

function addHeader() {
if ($this->params->get('logo')) {
$this->Image($this->params->get('logo'),15,5,30);

}
$this->Line(15,38,195,38);
$this->Ln(40);
}

function addTitle() {
$this->SetXY(15,40);
$this->SetFont('freesans','',18);
$this->SetTextColor(0,0,0);
$this->Cell(180,7,$this->product->name,0,0,'L',false);
}

function addImage() {
if (!empty($this->product_images)) {
$this->Image($this->jshopConfig->image_product_live_path.'/'.$this->product_images[0]->image_name,15,50,85);
}
}

function addExtraFields() {
$this->SetFont('freesans','', 10);
$this->SetY(50);
$this->SetX(110);

if ($this->jshopConfig->product_show_manufacturer && $this->product->manufacturer_info->name != '') {
$this->MultiCell(40,3,_JSHOP_MANUFACTURER.':',0,'L','L',false);
$this->MultiCell(42,3,$this->product->manufacturer_info->name,0,'L','R',false);
$this->Ln();
$this->SetX(110);
}

foreach($this->product->extra_field as $extra_field) {
$this->SetFont('freesans','', 10);
$this->MultiCell(40,3,$extra_field['name'].':',0,'L','L',false);
$this->MultiCell(42,3,$extra_field['value'],0,'L','R',false);
$this->Ln();
$this->SetX(110);
}
if ($this->product->_display_price) {
$this->SetFont('freesans','', 16);
$this->MultiCell(40,3,_JSHOP_PRICE.':',0,'L','L',false);
$this->SetTextColor(255,0,0);
$this->MultiCell(42,3,formatprice($this->product->getPriceCalculate()),0,'L','R',false);
$this->SetX(110);
$this->Line(15, 118, 195, 118);
}
}

function addDescription() {
$this->SetFont('freesans','', 8);
$this->SetY(225);
$this->SetX(15);
$this->SetFillColor(255,255,255);
$this->MultiCell(180,0,strip_tags($this->product->description),0,1,'L',false);
$this->Line(15, 222, 195, 222);
}

function addThumbImages() {
$x = 15;
$y = 122;
$w = 40;
$column = 4;
$interval_x = 43;
$interval_y = 33;
$show = 12;

$count = 1;
foreach($this->product_images as $k=>$image) {
if ($k == $show) {
break;
}
$this->image($this->jshopConfig->image_product_live_path.'/'.$image->image_thumb,$x,$y,$w);
if ($count == $column) {
$count = 1;
$x = $x-$interval_x*($column-1);
$y = $y+$interval_y;
}else{
$count++;
$x = $x+$interval_x;
}
}
$this->addPage();
}
function addFooter() {
$this->Line(15,283,195,283);
$this->SetXY(15,-11);
$this->SetFont('freesansb','',9);
$text_color = $this->convertColorHexToDec($this->params->get('text_color'));
$this->SetTextColor($text_color['red'],$text_color['green'],$text_color['blue']);
$this->Cell(90,0,$this->params->get('company'),0,0,'L');
$this->Cell(90,0,$this->params->get('url'),0,0,'R');
}
}
?>
*

dmitry_stas

  • Легенда
  • 13151
  • 1234 / 8
я в вас верил :)
Тут дарят бакс просто за регистрацию! Успей получить!
Все советы на форуме раздаю бесплатно, то есть даром. Индивидуально бесплатно консультирую только по вопросам стоимости индивидуальных консультаций
*

galkin_lancer

  • Новичок
  • 6
  • 0 / 0
Всем доброго дня. Поделитесь ссылочкой на плагин.
*

Артур13

  • Осваиваюсь на форуме
  • 13
  • 0 / 0
Всем доброго дня. Поделитесь ссылочкой на плагин.
Пожалуйста
*

Артур13

  • Осваиваюсь на форуме
  • 13
  • 0 / 0
Файл во вложении
*

kit2m2

  • Живу я здесь
  • 3269
  • 268 / 0
  • Беру сайты на полное сопровождение
Файл во вложении
Вы не можете прикреплять файлы, можете только дать ссылку на скачивание, например с Я.Диска
Расширения для JoomShopping | Расширения на заказ | Сайты и магазины под ключ: Дизайн, Верстка, Программирование, СЕО-оптимизация, Сопровождение, Перенос на Joomla 4+ и JoomShopping 5+
*

galkin_lancer

  • Новичок
  • 6
  • 0 / 0
Файл во вложении

Залейте пожалуйста куда нибудь, Google или Яндекс. >:( :'(
Чтобы оставить сообщение,
Вам необходимо Войти или Зарегистрироваться
 

Фильтр товаров для JoomShopping 5

Автор Lemonez

Ответов: 13
Просмотров: 756
Последний ответ 12.04.2024, 21:20:02
от nevigen
WT JoomShopping Favorite - кнопки избранного в категории товаров и карточке тов

Автор sergeytolkachyov

Ответов: 13
Просмотров: 2052
Последний ответ 03.04.2024, 14:24:38
от sergeytolkachyov
JoomShopping плагин подмены статического текста JoomShopping на материалы Joomla

Автор sergeytolkachyov

Ответов: 6
Просмотров: 829
Последний ответ 01.03.2024, 13:41:05
от sergeytolkachyov
WT JShopping cart save плагин брошенных корзин пользователей. JoomShopping 5.3+

Автор sergeytolkachyov

Ответов: 4
Просмотров: 357
Последний ответ 01.03.2024, 12:29:46
от kit2m2
Условие для кол-ва товара больше нуля

Автор kik84

Ответов: 3
Просмотров: 313
Последний ответ 16.02.2024, 13:33:24
от kit2m2