migrate classes to OXID-eSales/oxideshop_ce V6.0.0
added .gitignore
This commit is contained in:
parent
62413d02ef
commit
1187854c86
53
.gitignore
vendored
Normal file
53
.gitignore
vendored
Normal file
@ -0,0 +1,53 @@
|
||||
# Created by .ignore support plugin (hsz.mobi)
|
||||
### JetBrains template
|
||||
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm
|
||||
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
|
||||
|
||||
# User-specific stuff:
|
||||
.idea/**/workspace.xml
|
||||
.idea/**/tasks.xml
|
||||
.idea/dictionaries
|
||||
|
||||
# Sensitive or high-churn files:
|
||||
.idea/**/dataSources/
|
||||
.idea/**/dataSources.ids
|
||||
.idea/**/dataSources.xml
|
||||
.idea/**/dataSources.local.xml
|
||||
.idea/**/sqlDataSources.xml
|
||||
.idea/**/dynamic.xml
|
||||
.idea/**/uiDesigner.xml
|
||||
|
||||
# Gradle:
|
||||
.idea/**/gradle.xml
|
||||
.idea/**/libraries
|
||||
|
||||
# CMake
|
||||
cmake-build-debug/
|
||||
cmake-build-release/
|
||||
|
||||
# Mongo Explorer plugin:
|
||||
.idea/**/mongoSettings.xml
|
||||
|
||||
## File-based project format:
|
||||
*.iws
|
||||
|
||||
## Plugin-specific files:
|
||||
|
||||
# IntelliJ
|
||||
out/
|
||||
|
||||
# mpeltonen/sbt-idea plugin
|
||||
.idea_modules/
|
||||
|
||||
# JIRA plugin
|
||||
atlassian-ide-plugin.xml
|
||||
|
||||
# Cursive Clojure plugin
|
||||
.idea/replstate.xml
|
||||
|
||||
# Crashlytics plugin (for Android Studio and IntelliJ)
|
||||
com_crashlytics_export_strings.xml
|
||||
crashlytics.properties
|
||||
crashlytics-build.properties
|
||||
fabric.properties
|
||||
|
@ -71,6 +71,10 @@ class d3dev extends \OxidEsales\EshopProfessional\Application\Controller\Fronten
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
public function showOrderMailContent()
|
||||
{
|
||||
header('Content-type: text/html; charset='.Registry::getLang()->translateString('charset'));
|
||||
@ -93,6 +97,9 @@ class d3dev extends \OxidEsales\EshopProfessional\Application\Controller\Fronten
|
||||
die();
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
*/
|
||||
public function showInquiryMailContent()
|
||||
{
|
||||
if (Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?php
|
||||
|
||||
// .../?cl=thankyou[&d3orderid=23]
|
||||
use OxidEsales\Eshop\Core\Registry;
|
||||
|
||||
/**
|
||||
* This Software is the property of Data Development and is protected
|
||||
@ -19,17 +20,23 @@
|
||||
|
||||
class d3_dev_thankyou extends d3_dev_thankyou_parent
|
||||
{
|
||||
/**
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
* @throws object
|
||||
* @throws oxUserException
|
||||
*/
|
||||
public function init()
|
||||
{
|
||||
$sSessChallenge = oxRegistry::getSession()->getVariable('sess_challenge');
|
||||
$sSessChallenge = Registry::getSession()->getVariable('sess_challenge');
|
||||
|
||||
parent::init();
|
||||
|
||||
oxRegistry::getSession()->setVariable('sess_challenge', $sSessChallenge);
|
||||
Registry::getSession()->setVariable('sess_challenge', $sSessChallenge);
|
||||
|
||||
if (oxRegistry::getConfig()->getRequestParameter('d3dev')
|
||||
&& false == (bool) oxRegistry::getConfig()->getActiveShop()->oxshops__oxproductive->value
|
||||
&& oxRegistry::getConfig()->getConfigParam('blD3DevShowThankyou')
|
||||
if (oxNew(\OxidEsales\Eshop\Core\Request::class)->getRequestParameter('d3dev')
|
||||
&& false == (bool) Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value
|
||||
&& Registry::getConfig()->getConfigParam('blD3DevShowThankyou')
|
||||
) {
|
||||
$this->_d3authenticate();
|
||||
$oOrder = $this->d3GetLastOrder();
|
||||
@ -38,13 +45,17 @@ class d3_dev_thankyou extends d3_dev_thankyou_parent
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws object
|
||||
* @throws oxUserException
|
||||
*/
|
||||
protected function _d3authenticate ()
|
||||
{
|
||||
$oConfig = oxRegistry::getConfig();
|
||||
$request = oxNew(\OxidEsales\Eshop\Core\Request::class);
|
||||
|
||||
try {
|
||||
$sUser = $oConfig->getRequestParameter( 'usr' );
|
||||
$sPassword = $oConfig->getRequestParameter( 'pwd' );
|
||||
$sUser = $request->getRequestParameter( 'usr' );
|
||||
$sPassword = $request->getRequestParameter( 'pwd' );
|
||||
|
||||
if ( !$sUser || !$sPassword ) {
|
||||
$sUser = $_SERVER[ 'PHP_AUTH_USER' ];
|
||||
@ -67,16 +78,16 @@ class d3_dev_thankyou extends d3_dev_thankyou_parent
|
||||
}
|
||||
}
|
||||
}
|
||||
/** @var oxUser $oUser */
|
||||
$oUser = oxNew( 'oxuser' );
|
||||
/** @var \OxidEsales\Eshop\Application\Model\User $oUser */
|
||||
$oUser = oxNew( \OxidEsales\Eshop\Application\Model\User::class );
|
||||
if ( !$sUser || !$sPassword || !$oUser->login( $sUser, $sPassword ) ) {
|
||||
$oEx = oxNew( 'oxuserexception' );
|
||||
$oEx->setMessage( 'EXCEPTION_USER_NOVALIDLOGIN' );
|
||||
/** @var \OxidEsales\Eshop\Core\Exception\UserException $oEx */
|
||||
$oEx = oxNew( \OxidEsales\Eshop\Core\Exception\UserException::class, 'EXCEPTION_USER_NOVALIDLOGIN');
|
||||
throw $oEx;
|
||||
}
|
||||
}
|
||||
catch ( Exception $oEx ) {
|
||||
$oShop = $oConfig->getActiveShop();
|
||||
$oShop = Registry::getConfig()->getActiveShop();
|
||||
header( 'WWW-Authenticate: Basic realm="' . $oShop->oxshops__oxname->value . '"' );
|
||||
header( 'HTTP/1.0 401 Unauthorized' );
|
||||
exit( 1 );
|
||||
@ -84,27 +95,30 @@ class d3_dev_thankyou extends d3_dev_thankyou_parent
|
||||
}
|
||||
|
||||
/**
|
||||
* @return d3_dev_oxorder
|
||||
* @return bool|d3_dev_oxorder
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
public function d3GetLastOrder()
|
||||
{
|
||||
if (oxRegistry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
if (Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
return false;
|
||||
}
|
||||
|
||||
/** @var d3_dev_oxorder $oOrder */
|
||||
$oOrder = oxNew('oxorder');
|
||||
$oOrder = oxNew(\OxidEsales\Eshop\Application\Model\Order::class);
|
||||
$oOrder->d3getLastOrder();
|
||||
|
||||
return $oOrder;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return d3_dev_d3inquiry
|
||||
* @return bool|d3_dev_d3inquiry
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
*/
|
||||
public function d3GetLastInquiry()
|
||||
{
|
||||
if (oxRegistry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
if (Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,8 @@
|
||||
<?php
|
||||
|
||||
use OxidEsales\Eshop\Core\DatabaseProvider;
|
||||
use OxidEsales\Eshop\Core\Registry;
|
||||
|
||||
/**
|
||||
* This Software is the property of Data Development and is protected
|
||||
* by copyright law - it is NOT Freeware.
|
||||
@ -20,11 +24,13 @@ class d3_dev_d3inquiry extends d3_dev_d3inquiry_parent
|
||||
|
||||
/**
|
||||
* @return d3_dev_oxbasket
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
public function d3DevGetOrderBasket()
|
||||
{
|
||||
/** @var oxbasket $oBasket */
|
||||
$oBasket = $this->_getInquiryBasket();
|
||||
$this->_getInquiryBasket();
|
||||
|
||||
// unsetting bundles
|
||||
$oOrderArticles = $this->getInquiryArticles();
|
||||
@ -45,20 +51,24 @@ class d3_dev_d3inquiry extends d3_dev_d3inquiry_parent
|
||||
|
||||
/**
|
||||
* @return string
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
*/
|
||||
public function d3getLastInquiryId()
|
||||
{
|
||||
if (oxRegistry::getConfig()->getRequestParameter('d3inquirynr')) {
|
||||
$sWhere = ' oxinquirynr = ' . (int) oxRegistry::getConfig()->getRequestParameter('d3inquirynr');
|
||||
} else {
|
||||
$inquiryNr = (int) oxNew(\OxidEsales\Eshop\Core\Request::class)->getRequestParameter('d3inquirynr');
|
||||
$sWhere = 1;
|
||||
if ($inquiryNr) {
|
||||
$sWhere = ' oxinquirynr = ' . $inquiryNr;
|
||||
}
|
||||
|
||||
$sSelect = "SELECT oxid FROM ".getViewName('d3inquiry')." WHERE ".$sWhere." ORDER BY oxinquirydate DESC LIMIT 1";
|
||||
|
||||
return oxDb::getDb(oxDb::FETCH_MODE_ASSOC)->getOne($sSelect);
|
||||
return DatabaseProvider::getDb(DatabaseProvider::FETCH_MODE_ASSOC)->getOne($sSelect);
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
*/
|
||||
public function d3getLastInquiry()
|
||||
{
|
||||
$this->load($this->d3getLastInquiryId());
|
||||
@ -67,23 +77,29 @@ class d3_dev_d3inquiry extends d3_dev_d3inquiry_parent
|
||||
|
||||
/**
|
||||
* @return oxBasket
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
public function getBasket()
|
||||
{
|
||||
$oBasket = parent::getBasket();
|
||||
|
||||
if (false == $oBasket && oxRegistry::getConfig()->getActiveView()->getClassName() == 'd3dev') {
|
||||
if (false == $oBasket && Registry::getConfig()->getActiveView()->getClassKey() == 'd3dev') {
|
||||
$oBasket = $this->d3DevGetOrderBasket();
|
||||
}
|
||||
|
||||
return $oBasket;
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
protected function _d3AddVouchers()
|
||||
{
|
||||
$sSelect = "SELECT oxid FROM oxvouchers WHERE oxorderid = ".oxDb::getDb(oxDb::FETCH_MODE_ASSOC)->quote($this->getId()).";";
|
||||
$sSelect = "SELECT oxid FROM oxvouchers WHERE oxorderid = ". DatabaseProvider::getDb(DatabaseProvider::FETCH_MODE_ASSOC)->quote($this->getId()).";";
|
||||
|
||||
$aResult = oxDb::getDb(oxDb::FETCH_MODE_ASSOC)->getArray($sSelect);
|
||||
$aResult = DatabaseProvider::getDb(DatabaseProvider::FETCH_MODE_ASSOC)->getAll($sSelect);
|
||||
|
||||
foreach ($aResult as $aFields) {
|
||||
$oVoucher = oxNew('oxvoucher');
|
||||
@ -97,11 +113,14 @@ class d3_dev_d3inquiry extends d3_dev_d3inquiry_parent
|
||||
*
|
||||
* @param bool $blStockCheck perform stock check or not (default true)
|
||||
*
|
||||
* @return oxBasket
|
||||
* @return \OxidEsales\Eshop\Application\Model\Basket
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
protected function _getInquiryBasket($blStockCheck = true)
|
||||
{
|
||||
$this->_oOrderBasket = oxNew("oxBasket");
|
||||
/** @var \OxidEsales\Eshop\Application\Model\Basket _oOrderBasket */
|
||||
$this->_oOrderBasket = oxNew(\OxidEsales\Eshop\Application\Model\Basket::class);
|
||||
$this->_oOrderBasket->enableSaveToDataBase(false);
|
||||
|
||||
//setting recalculation mode
|
||||
@ -117,7 +136,7 @@ class d3_dev_d3inquiry extends d3_dev_d3inquiry_parent
|
||||
$this->_oOrderBasket->setInquiryId($this->getId());
|
||||
|
||||
// setting basket currency order uses
|
||||
$aCurrencies = $this->getConfig()->getCurrencyArray();
|
||||
$aCurrencies = Registry::getConfig()->getCurrencyArray();
|
||||
foreach ($aCurrencies as $oCur) {
|
||||
if ($oCur->name == $this->oxorder__oxcurrency->value) {
|
||||
$oBasketCur = $oCur;
|
||||
@ -133,7 +152,7 @@ class d3_dev_d3inquiry extends d3_dev_d3inquiry_parent
|
||||
$this->_oOrderBasket->setCardMessage($this->oxorder__oxcardtext->value);
|
||||
|
||||
if ($this->_blReloadDiscount) {
|
||||
$oDb = oxDb::getDb(oxDb::FETCH_MODE_ASSOC);
|
||||
$oDb = DatabaseProvider::getDb(DatabaseProvider::FETCH_MODE_ASSOC);
|
||||
// disabling availability check
|
||||
$this->_oOrderBasket->setSkipVouchersChecking(true);
|
||||
|
||||
|
@ -1,4 +1,7 @@
|
||||
<?php
|
||||
|
||||
use OxidEsales\Eshop\Core\Registry;
|
||||
|
||||
/**
|
||||
* This Software is the property of Data Development and is protected
|
||||
* by copyright law - it is NOT Freeware.
|
||||
@ -18,8 +21,8 @@ class d3_dev_oxbasket extends d3_dev_oxbasket_parent
|
||||
{
|
||||
public function deleteBasket()
|
||||
{
|
||||
if (oxRegistry::getConfig()->getActiveShop()->oxshops__oxproductive->value
|
||||
|| false == oxRegistry::getConfig()->getConfigParam('blD3DevAvoidDelBasket')
|
||||
if (Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value
|
||||
|| false == Registry::getConfig()->getConfigParam('blD3DevAvoidDelBasket')
|
||||
) {
|
||||
parent::deleteBasket();
|
||||
}
|
||||
|
@ -21,6 +21,12 @@ class d3_dev_oxbasketitem extends d3_dev_oxbasketitem_parent
|
||||
$this->_oArticle = null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
* @throws \OxidEsales\EshopCommunity\Application\Model\oxArticleException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\StandardException
|
||||
* @throws oxNoArticleException
|
||||
*/
|
||||
public function getTitle()
|
||||
{
|
||||
$oArticle = $this->getArticle();
|
||||
|
@ -1,4 +1,7 @@
|
||||
<?php
|
||||
|
||||
use OxidEsales\Eshop\Core\Registry;
|
||||
|
||||
/**
|
||||
* This Software is the property of Data Development and is protected
|
||||
* by copyright law - it is NOT Freeware.
|
||||
@ -19,11 +22,13 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
/**
|
||||
* @param d3_dev_oxorder $oOrder
|
||||
*
|
||||
* @param $sType
|
||||
*
|
||||
* @return mixed|string
|
||||
*/
|
||||
public function d3GetOrderMailContent($oOrder, $sType)
|
||||
{
|
||||
if (oxRegistry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
if (Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
return '';
|
||||
}
|
||||
|
||||
@ -59,7 +64,7 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
// send not pretending from order user, as different email domain rise spam filters
|
||||
$this->setFrom($oShop->oxshops__oxowneremail->value);
|
||||
|
||||
$oLang = oxRegistry::getLang();
|
||||
$oLang = Registry::getLang();
|
||||
$iOrderLang = $oLang->getObjectTplLanguage();
|
||||
|
||||
// if running shop language is different from admin lang. set in config
|
||||
@ -71,6 +76,7 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
$this->setSmtp($oShop);
|
||||
|
||||
// create messages
|
||||
/** @var Smarty $oSmarty */
|
||||
$oSmarty = $this->_getSmarty();
|
||||
$this->setViewData("order", $oOrder);
|
||||
|
||||
@ -83,11 +89,13 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
/**
|
||||
* @param d3_dev_d3inquiry $oInquiry
|
||||
*
|
||||
* @param $sType
|
||||
*
|
||||
* @return mixed|string
|
||||
*/
|
||||
public function d3GetInquiryMailContent($oInquiry, $sType)
|
||||
{
|
||||
if (oxRegistry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
if (Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
return '';
|
||||
}
|
||||
|
||||
@ -123,7 +131,7 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
// send not pretending from order user, as different email domain rise spam filters
|
||||
$this->setFrom($oShop->oxshops__oxowneremail->value);
|
||||
|
||||
$oLang = oxRegistry::getLang();
|
||||
$oLang = Registry::getLang();
|
||||
$iOrderLang = $oLang->getObjectTplLanguage();
|
||||
|
||||
// if running shop language is different from admin lang. set in config
|
||||
@ -135,6 +143,7 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
$this->setSmtp($oShop);
|
||||
|
||||
// create messages
|
||||
/** @var Smarty $oSmarty */
|
||||
$oSmarty = $this->_getSmarty();
|
||||
$this->setViewData("inquiry", $oInquiry);
|
||||
|
||||
@ -146,7 +155,7 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
|
||||
protected function _sendMail()
|
||||
{
|
||||
if (oxRegistry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
if (Registry::getConfig()->getActiveShop()->oxshops__oxproductive->value) {
|
||||
return parent::_sendMail();
|
||||
}
|
||||
|
||||
@ -223,10 +232,10 @@ class d3_dev_oxemail extends d3_dev_oxemail_parent
|
||||
|
||||
public function getNewRecipient($sMailAddress)
|
||||
{
|
||||
if (oxRegistry::getConfig()->getConfigParam('blD3DevBlockMails')) {
|
||||
if (Registry::getConfig()->getConfigParam('blD3DevBlockMails')) {
|
||||
return false;
|
||||
} elseif (oxRegistry::getConfig()->getConfigParam('sD3DevRedirectMail')) {
|
||||
return trim(oxRegistry::getConfig()->getConfigParam('sD3DevRedirectMail'));
|
||||
} elseif (Registry::getConfig()->getConfigParam('sD3DevRedirectMail')) {
|
||||
return trim(Registry::getConfig()->getConfigParam('sD3DevRedirectMail'));
|
||||
}
|
||||
|
||||
return $sMailAddress;
|
||||
|
@ -1,4 +1,8 @@
|
||||
<?php
|
||||
|
||||
use OxidEsales\Eshop\Core\DatabaseProvider;
|
||||
use OxidEsales\Eshop\Core\Registry;
|
||||
|
||||
/**
|
||||
* This Software is the property of Data Development and is protected
|
||||
* by copyright law - it is NOT Freeware.
|
||||
@ -25,8 +29,10 @@ class d3_dev_oxorder extends d3_dev_oxorder_parent
|
||||
$oBasket = $this->_getOrderBasket();
|
||||
|
||||
// unsetting bundles
|
||||
/** @var \OxidEsales\Eshop\Core\Model\ListModel $oOrderArticles */
|
||||
$oOrderArticles = $this->getOrderArticles();
|
||||
foreach ($oOrderArticles as $sItemId => $oItem) {
|
||||
/** @var $oItem \OxidEsales\Eshop\Application\Model\OrderArticle */
|
||||
if ($oItem->isBundle()) {
|
||||
$oOrderArticles->offsetUnset($sItemId);
|
||||
}
|
||||
@ -45,20 +51,25 @@ class d3_dev_oxorder extends d3_dev_oxorder_parent
|
||||
|
||||
/**
|
||||
* @return string
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
*/
|
||||
public function d3getLastOrderId()
|
||||
{
|
||||
if (oxRegistry::getConfig()->getRequestParameter('d3ordernr')) {
|
||||
$sWhere = ' oxordernr = ' . (int) oxRegistry::getConfig()->getRequestParameter('d3ordernr');
|
||||
} else {
|
||||
$orderNr = (int) oxNew(\OxidEsales\Eshop\Core\Request::class)->getRequestParameter('d3ordernr');
|
||||
$sWhere = 1;
|
||||
if ($orderNr) {
|
||||
$sWhere = ' oxordernr = ' . $orderNr;
|
||||
}
|
||||
|
||||
$sSelect = "SELECT oxid FROM ".getViewName('oxorder')." WHERE ".$sWhere." ORDER BY oxorderdate DESC LIMIT 1";
|
||||
|
||||
return oxDb::getDb(oxDb::FETCH_MODE_ASSOC)->getOne($sSelect);
|
||||
return DatabaseProvider::getDb(DatabaseProvider::FETCH_MODE_ASSOC)->getOne($sSelect);
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
public function d3getLastOrder()
|
||||
{
|
||||
$this->load($this->d3getLastOrderId());
|
||||
@ -66,27 +77,31 @@ class d3_dev_oxorder extends d3_dev_oxorder_parent
|
||||
}
|
||||
|
||||
/**
|
||||
* @return oxBasket
|
||||
* @return d3_dev_oxbasket|\OxidEsales\Eshop\Application\Model\Basket
|
||||
*/
|
||||
public function getBasket()
|
||||
{
|
||||
$oBasket = parent::getBasket();
|
||||
|
||||
if (false == $oBasket && oxRegistry::getConfig()->getActiveView()->getClassName() == 'd3dev') {
|
||||
if (false == $oBasket && Registry::getConfig()->getActiveView()->getClassKey() == 'd3dev') {
|
||||
$oBasket = $this->d3DevGetOrderBasket();
|
||||
}
|
||||
|
||||
return $oBasket;
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseConnectionException
|
||||
* @throws \OxidEsales\Eshop\Core\Exception\DatabaseErrorException
|
||||
*/
|
||||
protected function _d3AddVouchers()
|
||||
{
|
||||
$sSelect = "SELECT oxid FROM oxvouchers WHERE oxorderid = ".oxDb::getDb(oxDb::FETCH_MODE_ASSOC)->quote($this->getId()).";";
|
||||
$sSelect = "SELECT oxid FROM oxvouchers WHERE oxorderid = ".DatabaseProvider::getDb(DatabaseProvider::FETCH_MODE_ASSOC)->quote($this->getId()).";";
|
||||
|
||||
$aResult = oxDb::getDb(oxDb::FETCH_MODE_ASSOC)->getArray($sSelect);
|
||||
$aResult = DatabaseProvider::getDb(DatabaseProvider::FETCH_MODE_ASSOC)->getAll($sSelect);
|
||||
|
||||
foreach ($aResult as $aFields) {
|
||||
$oVoucher = oxNew('oxvoucher');
|
||||
$oVoucher = oxNew(\OxidEsales\Eshop\Application\Model\Voucher::class);
|
||||
$oVoucher->load($aFields['oxid']);
|
||||
$this->_aVoucherList[$oVoucher->getId()] = $oVoucher;
|
||||
}
|
||||
|
@ -17,7 +17,7 @@
|
||||
class d3_dev_oxorderarticle extends d3_dev_oxorderarticle_parent
|
||||
{
|
||||
/**
|
||||
* @return array
|
||||
* @return null|\OxidEsales\EshopCommunity\Application\Model\ArticleList
|
||||
*/
|
||||
public function getCustomerAlsoBoughtThisProducts()
|
||||
{
|
||||
|
@ -9,9 +9,9 @@
|
||||
* civil and criminal law.
|
||||
* http://www.shopmodule.com
|
||||
*
|
||||
* @copyright © D³ Data Development, Thomas Dartsch
|
||||
* @copyright © D³ Data Development, Thomas Dartsch
|
||||
* @package OrderManager
|
||||
* @author D³ Data Development - Daniel Seifert <support@shopmodule.com>
|
||||
* @author D³ Data Development - Daniel Seifert <support@shopmodule.com>
|
||||
* @link http://www.oxidmodule.com
|
||||
*/
|
||||
|
||||
@ -22,29 +22,29 @@ $sLangName = "Deutsch";
|
||||
// -------------------------------
|
||||
$aLang = array(
|
||||
//Navigation
|
||||
'charset' => 'ISO-8859-15',
|
||||
'charset' => 'UTF-8',
|
||||
|
||||
'SHOP_MODULE_GROUP_d3dev_order' => 'Bestellungsablauf manipulieren',
|
||||
'SHOP_MODULE_blD3DevAvoidDelBasket' => 'Warenkorb wird nach Bestellabschluss nicht geleert',
|
||||
'HELP_SHOP_MODULE_blD3DevAvoidDelBasket' => 'Damit kann auf der Bestellbestätigungsseite '.
|
||||
'(Thankyou) durch den "zurück"-Button in den Warenkorb Schritt 4 gewechselt werden und die Bestellung erneut '.
|
||||
'abgeschickt werden. Eine erneute Bestückung des Warenkorbs ist nicht nötig. Beim erneuten Absenden wird '.
|
||||
'jeweils eine weitere Bestellung angelegt werden. Eventuell verwendete Gutscheine müssen so eingestellt '.
|
||||
'werden, dass diese mehrfach verwendet werden können.',
|
||||
'HELP_SHOP_MODULE_blD3DevAvoidDelBasket' => 'Damit kann auf der Bestellbestätigungsseite '.
|
||||
'(Thankyou) durch den "zurück"-Button in den Warenkorb Schritt 4 gewechselt werden und die Bestellung erneut '.
|
||||
'abgeschickt werden. Eine erneute Bestückung des Warenkorbs ist nicht nötig. Beim erneuten Absenden wird '.
|
||||
'jeweils eine weitere Bestellung angelegt werden. Eventuell verwendete Gutscheine müssen so eingestellt '.
|
||||
'werden, dass diese mehrfach verwendet werden können.',
|
||||
'SHOP_MODULE_blD3DevShowThankyou' => 'Thankyou-Seite kann auch ohne Bestellung '.
|
||||
'aufgerufen werden',
|
||||
'HELP_SHOP_MODULE_blD3DevShowThankyou' => 'Ohne abgesendete Bestellung läßt sich die '.
|
||||
'Thankyou-Seite im Standardshop nicht aufrufen. Diese Option stellt dies für Entwicklungszwecke zur '.
|
||||
'Verfügung. <br>Den Link zum Seitenaufruf haben wir hier im Stamm-Tab hinterlegt. Die Seite öffnet sich in '.
|
||||
'einem neuen Browserfenster. <br>Für die Anzeige wird die letzte vorliegende Bestellung geladen. Über den '.
|
||||
'HELP_SHOP_MODULE_blD3DevShowThankyou' => 'Ohne abgesendete Bestellung läßt sich die '.
|
||||
'Thankyou-Seite im Standardshop nicht aufrufen. Diese Option stellt dies für Entwicklungszwecke zur '.
|
||||
'Verfügung. <br>Den Link zum Seitenaufruf haben wir hier im Stamm-Tab hinterlegt. Die Seite öffnet sich in '.
|
||||
'einem neuen Browserfenster. <br>Für die Anzeige wird die letzte vorliegende Bestellung geladen. Über den '.
|
||||
'Parameter "d3ordernr=X" kann eine bestimmten Bestellung vorgegeben werden.',
|
||||
|
||||
'SHOP_MODULE_GROUP_d3dev_mail' => 'Mailanzeige',
|
||||
'SHOP_MODULE_blD3DevShowOrderMailsInBrowser' => 'Bestellbestätigungsmails können im Browser '.
|
||||
'SHOP_MODULE_blD3DevShowOrderMailsInBrowser' => 'Bestellbestätigungsmails können im Browser '.
|
||||
'angezeigt werden',
|
||||
'HELP_SHOP_MODULE_blD3DevShowOrderMailsInBrowser' => 'Die Links zu den '.
|
||||
'jeweiligen Mails sind im Stamm-Tab aufgelistet.<br>Für die Anzeige wird ohne Angabe der Bestellnummer die '.
|
||||
'letzte vorliegende Bestellung geladen. Über den Parameter "d3ordernr=X" kann eine bestimmten Bestellung '.
|
||||
'jeweiligen Mails sind im Stamm-Tab aufgelistet.<br>Für die Anzeige wird ohne Angabe der Bestellnummer die '.
|
||||
'letzte vorliegende Bestellung geladen. Über den Parameter "d3ordernr=X" kann eine bestimmten Bestellung '.
|
||||
'vorgegeben werden.',
|
||||
|
||||
'SHOP_MODULE_GROUP_d3dev_mailblock' => 'Mailversand',
|
||||
@ -53,5 +53,5 @@ $aLang = array(
|
||||
'HELP_SHOP_MODULE_blD3DevBlockMails' => 'Der Mailversand wird komplett geblockt.',
|
||||
'SHOP_MODULE_sD3DevRedirectMail' => 'versendete Mails an diese Adresse umleiten',
|
||||
'HELP_SHOP_MODULE_sD3DevRedirectMail' => 'Wenn leer, erfolgt keine Umleitung. Ohne '.
|
||||
'zusätzliche Blockieroption werden die Mails dann an den original Empfänger gesendet.',
|
||||
'zusätzliche Blockieroption werden die Mails dann an den original Empfänger gesendet.',
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user