diff --git a/Application/Model/AbstractClasses/pdfdocumentsGeneric.php b/Application/Model/AbstractClasses/pdfdocumentsGeneric.php index 3e66377..23bb70b 100644 --- a/Application/Model/AbstractClasses/pdfdocumentsGeneric.php +++ b/Application/Model/AbstractClasses/pdfdocumentsGeneric.php @@ -139,8 +139,8 @@ abstract class pdfdocumentsGeneric extends Base implements genericInterface public function setSmartyVars($iSelLang) { unset($iSelLang); - $this->oSmarty->assign('oConfig', Registry::getSession()->getConfig()); - $this->oSmarty->assign('oViewConf', Registry::getSession()->getConfig()->getActiveView()->getViewConfig()); + $this->oSmarty->assign('config', Registry::getSession()->getConfig()); + $this->oSmarty->assign('viewConfig', Registry::getSession()->getConfig()->getActiveView()->getViewConfig()); $this->oSmarty->assign('shop', Registry::getSession()->getConfig()->getActiveShop()); $this->oSmarty->assign('lang', Registry::getLang()); $this->oSmarty->assign('document', $this); diff --git a/Application/views/tpl/admin/orderoverview_pdfform.tpl b/Application/views/tpl/admin/orderoverview_pdfform.tpl index 27e8ff0..0effc13 100644 --- a/Application/views/tpl/admin/orderoverview_pdfform.tpl +++ b/Application/views/tpl/admin/orderoverview_pdfform.tpl @@ -1,14 +1,14 @@ [{if $edit && $oView->canExport()}]
-
- [{$oViewConf->getHiddenSid()}] + + [{$viewConfig->getHiddenSid()}] @@ -103,7 +103,7 @@ @@ -141,7 +141,7 @@ @@ -202,7 +202,7 @@ [{block name="giftcard"}] [{if $order->getFieldData('oxgiftcardcost')}] - [{if $oConfig->getConfigParam('blShowVATForWrapping')}] + [{if $config->getConfigParam('blShowVATForWrapping')}] [{assign var="giftCardPrice" value=$order->getOrderGiftCardPrice()}] diff --git a/Application/views/tpl/documents/inc/elements/articlelist.tpl b/Application/views/tpl/documents/inc/elements/articlelist.tpl index 7deead4..dbb9161 100644 --- a/Application/views/tpl/documents/inc/elements/articlelist.tpl +++ b/Application/views/tpl/documents/inc/elements/articlelist.tpl @@ -22,102 +22,27 @@ [{/if}] - [{foreach from=$order->getOrderArticles(true) item=oOrderArticle}] + [{foreach from=$order->getOrderArticles(true) item=orderArticle}] [{if $showPrices}] - [{/if}] - - [{/foreach}] - [{foreach from=$order->getOrderArticles(true) item=oOrderArticle}] - - - - [{if $showPrices}] - - - - [{/if}] - - [{/foreach}] - [{foreach from=$order->getOrderArticles(true) item=oOrderArticle}] - - - - [{if $showPrices}] - - - - [{/if}] - - [{/foreach}] - [{foreach from=$order->getOrderArticles(true) item=oOrderArticle}] - - - - [{if $showPrices}] - - - [{/if}] diff --git a/Application/views/tpl/documents/inc/page/footer.tpl b/Application/views/tpl/documents/inc/page/footer.tpl index c4f12b5..0e9a8a9 100644 --- a/Application/views/tpl/documents/inc/page/footer.tpl +++ b/Application/views/tpl/documents/inc/page/footer.tpl @@ -7,12 +7,12 @@ [{block name="pdfFooterLeft"}] [{/block}] [{block name="pdfFooterCenter"}] diff --git a/Application/views/tpl/documents/inc/page/header.tpl b/Application/views/tpl/documents/inc/page/header.tpl index e6f15b1..8e864ac 100644 --- a/Application/views/tpl/documents/inc/page/header.tpl +++ b/Application/views/tpl/documents/inc/page/header.tpl @@ -4,10 +4,10 @@
[{if $showLogo}] [{* pdf logo is available only in non admin theme *}] - [{assign var="isAdmin" value=$oViewConf->isAdmin()}] - [{$oViewConf->setAdminMode(false)}] - - [{$oViewConf->setAdminMode($isAdmin)}] + [{assign var="isAdmin" value=$viewConfig->isAdmin()}] + [{$viewConfig->setAdminMode(false)}] + + [{$viewConfig->setAdminMode($isAdmin)}] [{/if}]
[{/block}] \ No newline at end of file diff --git a/metadata.php b/metadata.php index 5952b46..cb49195 100644 --- a/metadata.php +++ b/metadata.php @@ -42,8 +42,8 @@ $aModule = [ 'email' => 'support@shopmodule.com', 'url' => 'http://www.oxidmodule.com/', 'extend' => [ - OxidModel\Order::class => d3_pdfdocs_OrderModel::class, - OrderOverview::class => d3_overview_controller_pdfdocuments::class + OxidModel\Order::class => d3_pdfdocs_OrderModel::class, + OrderOverview::class => d3_overview_controller_pdfdocuments::class ], 'controllers' => [], 'templates' => [
- + [{oxmultilang ident="ORDER_OVERVIEW_PDF_TYPE"}]:  diff --git a/Application/views/tpl/documents/inc/elements/articlecostssummary.tpl b/Application/views/tpl/documents/inc/elements/articlecostssummary.tpl index 320842f..62f384d 100644 --- a/Application/views/tpl/documents/inc/elements/articlecostssummary.tpl +++ b/Application/views/tpl/documents/inc/elements/articlecostssummary.tpl @@ -89,7 +89,7 @@ [{/if}] [{block name="delivery"}] - [{if $oConfig->getConfigParam('blShowVATForDelivery')}] + [{if $config->getConfigParam('blShowVATForDelivery')}] [{assign var="deliveryPrice" value=$order->getOrderDeliveryPrice()}]
- [{if $oConfig->getConfigParam('sAdditionalServVATCalcMethod') != 'proportional'}] + [{if $config->getConfigParam('sAdditionalServVATCalcMethod') != 'proportional'}] [{oxmultilang ident="D3_PDFDOCUMENTS_TAX" args=$order->getFieldData('oxdelvat') suffix="COLON"}] [{else}] [{oxmultilang ident="D3_PDFDOCUMENTS_PROPORTIONAL_TAX" suffix="COLON"}] @@ -127,7 +127,7 @@ [{/block}] [{block name="payment"}] - [{if $oConfig->getConfigParam('blShowVATForPayCharge')}] + [{if $config->getConfigParam('blShowVATForPayCharge')}] [{assign var="paymentPrice" value=$order->getOrderPaymentPrice()}]
- [{if $oConfig->getConfigParam('sAdditionalServVATCalcMethod') != 'proportional'}] + [{if $config->getConfigParam('sAdditionalServVATCalcMethod') != 'proportional'}] [{oxmultilang ident="D3_PDFDOCUMENTS_TAX" args=$order->getFieldData('oxpayvat') suffix="COLON"}] [{else}] [{oxmultilang ident="D3_PDFDOCUMENTS_PROPORTIONAL_TAX" suffix="COLON"}] @@ -166,7 +166,7 @@ [{block name="wrapping"}] [{if $order->getFieldData('oxwrapcost')}] - [{if $oConfig->getConfigParam('blShowVATForWrapping')}] + [{if $config->getConfigParam('blShowVATForWrapping')}] [{assign var="wrappingPrice" value=$order->getOrderWrappingPrice()}]
- [{$oOrderArticle->oxorderarticles__oxamount->value }] + [{$orderArticle->getFieldData('oxamount')}] - [{$oOrderArticle->oxorderarticles__oxtitle->getRawValue() }] [{ $oOrderArticle->oxorderarticles__oxselvariant->getRawValue() }] + [{$orderArticle->getFieldData('oxtitle')}] [{ $orderArticle->getFieldData('oxselvariant')}]
- [{oxmultilang ident="D3_PDFDOCUMENTS_ARTNR"}] [{$oOrderArticle->oxorderarticles__oxartnum->value }] + [{oxmultilang ident="D3_PDFDOCUMENTS_ARTNR"}] [{$orderArticle->getFieldData('oxartnum')}]
- [{$oOrderArticle->oxorderarticles__oxvat->value }] + [{$orderArticle->getFieldData('oxvat')}] - [{$oOrderArticle->getBrutPriceFormated()}] [{$currency->name}] + [{$orderArticle->getBrutPriceFormated()}] [{$currency->name}] - [{$oOrderArticle->getTotalBrutPriceFormated()}] [{$currency->name}] -
- [{$oOrderArticle->oxorderarticles__oxamount->value }] - - [{$oOrderArticle->oxorderarticles__oxtitle->getRawValue() }] [{ $oOrderArticle->oxorderarticles__oxselvariant->getRawValue() }] -
- - [{oxmultilang ident="D3_PDFDOCUMENTS_ARTNR"}] [{$oOrderArticle->oxorderarticles__oxartnum->value }] - -
- [{$oOrderArticle->oxorderarticles__oxvat->value }] - - [{$oOrderArticle->getBrutPriceFormated()}] [{$currency->name}] - - [{$oOrderArticle->getTotalBrutPriceFormated()}] [{$currency->name}] -
- [{$oOrderArticle->oxorderarticles__oxamount->value }] - - [{$oOrderArticle->oxorderarticles__oxtitle->getRawValue() }] [{ $oOrderArticle->oxorderarticles__oxselvariant->getRawValue() }] -
- - [{oxmultilang ident="D3_PDFDOCUMENTS_ARTNR"}] [{$oOrderArticle->oxorderarticles__oxartnum->value }] - -
- [{$oOrderArticle->oxorderarticles__oxvat->value }] - - [{$oOrderArticle->getBrutPriceFormated()}] [{$currency->name}] - - [{$oOrderArticle->getTotalBrutPriceFormated()}] [{$currency->name}] -
- [{$oOrderArticle->oxorderarticles__oxamount->value }] - - [{$oOrderArticle->oxorderarticles__oxtitle->getRawValue() }] [{ $oOrderArticle->oxorderarticles__oxselvariant->getRawValue() }] -
- - [{oxmultilang ident="D3_PDFDOCUMENTS_ARTNR"}] [{$oOrderArticle->oxorderarticles__oxartnum->value }] - -
- [{$oOrderArticle->oxorderarticles__oxvat->value }] - - [{$oOrderArticle->getBrutPriceFormated()}] [{$currency->name}] - - [{$oOrderArticle->getTotalBrutPriceFormated()}] [{$currency->name}] + [{$orderArticle->getTotalBrutPriceFormated()}] [{$currency->name}]
-
[{$shop->oxshops__oxname->value}]
-
[{$shop->oxshops__oxstreet->value}]
-
[{$shop->oxshops__oxzip->value}] [{$shop->oxshops__oxcity->value}]
-
[{$shop->oxshops__oxcountry->value}]
-
[{$shop->oxshops__oxurl->value}]
-
[{$shop->oxshops__oxinfoemail->value}]
+
[{$shop->getFieldData('oxname')}]
+
[{$shop->getFieldData('oxstreet')}]
+
[{$shop->getFieldData('oxzip')}] [{$shop->getFieldData('oxcity')}]
+
[{$shop->getFieldData('oxcountry')}]
+
[{$shop->getFieldData('oxurl')}]
+
[{$shop->getFieldData('oxinfoemail')}]