idx
int64
0
60.3k
question
stringlengths
101
6.21k
target
stringlengths
7
803
36,200
public function getFPrice ( ) { $ myConfig = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) ; if ( ! $ myConfig -> getConfigParam ( 'bl_perfLoadPrice' ) ) { return ; } if ( $ this -> _sFPrice ) { return $ this -> _sFPrice ; } $ sFromPrefix = '' ; if ( ! $ this -> _isFixedPrice ( ) ) { $ sFromPrefix = \ OxidEsa...
Returns MD variant price as a text .
36,201
public function deleteEntry ( ) { if ( $ this -> _allowAdminEdit ( $ this -> getEditObjectId ( ) ) ) { $ this -> _oList = null ; return parent :: deleteEntry ( ) ; } }
Admin user is allowed to be deleted only by mall admin
36,202
public function getPayment ( ) { if ( $ this -> _oPayment === null ) { $ this -> _oPayment = false ; $ oBasket = $ this -> getBasket ( ) ; $ oUser = $ this -> getUser ( ) ; $ sPaymentid = $ oBasket -> getPaymentId ( ) ; $ oPayment = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Payment :: class ) ; if ( $ sPayme...
Template variable getter . Returns payment object
36,203
public function getBasket ( ) { if ( $ this -> _oBasket === null ) { $ this -> _oBasket = false ; if ( $ oBasket = $ this -> getSession ( ) -> getBasket ( ) ) { $ this -> _oBasket = $ oBasket ; } } return $ this -> _oBasket ; }
Template variable getter . Returns active basket
36,204
public function getOrderRemark ( ) { if ( $ this -> _sOrderRemark === null ) { $ this -> _sOrderRemark = false ; if ( $ sRemark = \ OxidEsales \ Eshop \ Core \ Registry :: getSession ( ) -> getVariable ( 'ordrem' ) ) { $ this -> _sOrderRemark = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> checkParamSpecia...
Template variable getter . Returns user remark
36,205
public function getBasketArticles ( ) { if ( $ this -> _oBasketArtList === null ) { $ this -> _oBasketArtList = false ; if ( $ oBasket = $ this -> getBasket ( ) ) { $ this -> _oBasketArtList = $ oBasket -> getBasketArticles ( ) ; } } return $ this -> _oBasketArtList ; }
Template variable getter . Returns basket article list
36,206
public function getDelAddress ( ) { if ( $ this -> _oDelAddress === null ) { $ this -> _oDelAddress = false ; $ oOrder = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Order :: class ) ; $ this -> _oDelAddress = $ oOrder -> getDelAddressInfo ( ) ; } return $ this -> _oDelAddress ; }
Template variable getter . Returns delivery address
36,207
public function getShipSet ( ) { if ( $ this -> _oShipSet === null ) { $ this -> _oShipSet = false ; if ( $ oBasket = $ this -> getBasket ( ) ) { $ oShipSet = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ DeliverySet :: class ) ; if ( $ oShipSet -> load ( $ oBasket -> getShippingId ( ) ) ) { $ this -> _oShipSet ...
Template variable getter . Returns shipping set
36,208
public function isConfirmAGBActive ( ) { if ( $ this -> _blConfirmAGB === null ) { $ this -> _blConfirmAGB = false ; $ this -> _blConfirmAGB = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getConfigParam ( 'blConfirmAGB' ) ; } return $ this -> _blConfirmAGB ; }
Template variable getter . Returns if option blConfirmAGB is on
36,209
public function showOrderButtonOnTop ( ) { if ( $ this -> _blShowOrderButtonOnTop === null ) { $ this -> _blShowOrderButtonOnTop = false ; $ this -> _blShowOrderButtonOnTop = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getConfigParam ( 'blShowOrderButtonOnTop' ) ; } return $ this -> _blShowOrderButtonOnT...
Template variable getter . Returns if option blShowOrderButtonOnTop is on
36,210
public function getDeliveryAddressMD5 ( ) { $ oUser = $ this -> getUser ( ) ; $ sDelAddress = $ oUser -> getEncodedDeliveryAddress ( ) ; if ( \ OxidEsales \ Eshop \ Core \ Registry :: getSession ( ) -> getVariable ( 'deladrid' ) ) { $ oDelAdress = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Address :: class ) ...
Return users setted delivery address md5
36,211
protected function _validateTermsAndConditions ( ) { $ blValid = true ; $ oConfig = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) ; if ( $ oConfig -> getConfigParam ( 'blConfirmAGB' ) && ! $ oConfig -> getRequestParameter ( 'ord_agb' ) ) { $ blValid = false ; } if ( $ oConfig -> getConfigParam ( 'blEnableInta...
Validates whether necessary terms and conditions checkboxes were checked .
36,212
public function getArticle ( $ sItemKey ) { if ( ! $ this -> oxuserbasketitems__oxartid -> value ) { $ oEx = oxNew ( \ OxidEsales \ Eshop \ Core \ Exception \ ArticleException :: class ) ; $ oEx -> setMessage ( 'EXCEPTION_ARTICLE_NOPRODUCTID' ) ; throw $ oEx ; } if ( $ this -> _oArticle === null ) { $ this -> _oArticle...
Loads and returns the article for that basket item
36,213
public function getSelList ( ) { if ( $ this -> _aSelList == null && $ this -> oxuserbasketitems__oxsellist -> value ) { $ this -> _aSelList = unserialize ( $ this -> oxuserbasketitems__oxsellist -> value ) ; } return $ this -> _aSelList ; }
Basket item selection list getter
36,214
public function setSelList ( $ aSelList ) { $ this -> oxuserbasketitems__oxsellist = new \ OxidEsales \ Eshop \ Core \ Field ( serialize ( $ aSelList ) , \ OxidEsales \ Eshop \ Core \ Field :: T_RAW ) ; }
Basket item selection list setter
36,215
public function getPersParams ( ) { if ( $ this -> _aPersParam == null && $ this -> oxuserbasketitems__oxpersparam -> value ) { $ this -> _aPersParam = unserialize ( $ this -> oxuserbasketitems__oxpersparam -> value ) ; } return $ this -> _aPersParam ; }
Basket item persistent parameters getter
36,216
public function setPersParams ( $ sPersParams ) { $ this -> oxuserbasketitems__oxpersparam = new \ OxidEsales \ Eshop \ Core \ Field ( serialize ( $ sPersParams ) , \ OxidEsales \ Eshop \ Core \ Field :: T_RAW ) ; }
Basket item persistent parameters setter
36,217
public function prepareCSVField ( $ sInField ) { $ oStr = getStr ( ) ; if ( $ oStr -> strstr ( $ sInField , '"' ) ) { return '"' . str_replace ( '"' , '""' , $ sInField ) . '"' ; } elseif ( $ oStr -> strstr ( $ sInField , ';' ) ) { return '"' . $ sInField . '"' ; } return $ sInField ; }
Prepares passed string for CSV format
36,218
public function prepareStrForSearch ( $ sSearchStr ) { $ oStr = getStr ( ) ; if ( $ oStr -> hasSpecialChars ( $ sSearchStr ) ) { return $ oStr -> recodeEntities ( $ sSearchStr , true , [ '&' ] , [ '&' ] ) ; } return '' ; }
Prepares and returns string for search engines .
36,219
public function addArticle ( ) { $ myConfig = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) ; $ aArticles = $ this -> _getActionIds ( 'oxarticles.oxid' ) ; $ sCategoryID = $ myConfig -> getRequestParameter ( 'synchoxid' ) ; $ sShopID = $ myConfig -> getShopId ( ) ; \ OxidEsales \ Eshop \ Core \ DatabaseProvid...
Adds article to category Creates new list
36,220
protected function _updateOxTime ( $ sProdIds ) { if ( $ sProdIds ) { $ sO2CView = $ this -> _getViewName ( 'oxobject2category' ) ; $ sSqlShopFilter = $ this -> getUpdateOxTimeQueryShopFilter ( ) ; $ sSqlWhereShopFilter = $ this -> getUpdateOxTimeSqlWhereFilter ( ) ; $ sQ = "update oxobject2category set oxtime = 0 wher...
Updates oxtime value for products
36,221
public function removeArticle ( ) { $ aArticles = $ this -> _getActionIds ( 'oxarticles.oxid' ) ; $ sCategoryID = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'oxid' ) ; if ( \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'all' ) ) { $ sArticleTable ...
Removes article from category
36,222
protected function getRemoveCategoryArticlesQueryFilter ( $ categoryID , $ prodIds ) { $ db = \ OxidEsales \ Eshop \ Core \ DatabaseProvider :: getDb ( ) ; $ where = "where oxcatnid=" . $ db -> quote ( $ categoryID ) ; $ whereProductIdIn = " oxobjectid in ( {$prodIds} )" ; if ( ! \ OxidEsales \ Eshop \ Core \ Registry ...
Form query filter to remove articles from category .
36,223
protected function _unsetPaymentErrors ( ) { $ iPayError = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'payerror' ) ; $ sPayErrorText = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'payerrortext' ) ; if ( ! ( $ iPayError || $ sPayErrorText ) ) { $...
Unsets payment errors from session
36,224
public function changeshipping ( ) { $ oSession = $ this -> getSession ( ) ; $ oBasket = $ oSession -> getBasket ( ) ; $ oBasket -> setShipping ( null ) ; $ oBasket -> onUpdate ( ) ; $ oSession -> setVariable ( 'sShipSet' , \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'sShipSet' ) ) ...
Changes shipping set to chosen one . Sets basket status to not up - to - date which later forces to recalculate it
36,225
public function validatePayment ( ) { $ myConfig = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) ; $ oSession = $ this -> getSession ( ) ; $ oUser = $ this -> getUser ( ) ; if ( ! $ oUser ) { $ oSession -> setVariable ( 'payerror' , 2 ) ; return ; } if ( ! ( $ sShipSetId = \ OxidEsales \ Eshop \ Core \ Regist...
Validates oxidcreditcard and oxiddebitnote user payment data . Returns null if problems on validating occured . If everything is OK - returns order and redirects to payment confirmation page .
36,226
public function getPaymentList ( ) { if ( $ this -> _oPaymentList === null ) { $ this -> _oPaymentList = false ; $ sActShipSet = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'sShipSet' ) ; if ( ! $ sActShipSet ) { $ sActShipSet = \ OxidEsales \ Eshop \ Core \ Registry :: getSession (...
Template variable getter . Returns paymentlist
36,227
public function getAllSets ( ) { if ( $ this -> _aAllSets === null ) { $ this -> _aAllSets = false ; if ( $ this -> getPaymentList ( ) ) { return $ this -> _aAllSets ; } } return $ this -> _aAllSets ; }
Template variable getter . Returns all delivery sets
36,228
public function getAllSetsCnt ( ) { if ( $ this -> _iAllSetsCnt === null ) { $ this -> _iAllSetsCnt = 0 ; if ( $ this -> getPaymentList ( ) ) { $ this -> _iAllSetsCnt = count ( $ this -> _aAllSets ) ; } } return $ this -> _iAllSetsCnt ; }
Template variable getter . Returns number of delivery sets
36,229
protected function _setValues ( & $ aPaymentList , $ oBasket = null ) { if ( is_array ( $ aPaymentList ) ) { foreach ( $ aPaymentList as $ oPayment ) { $ oPayment -> calculate ( $ oBasket ) ; $ oPayment -> aDynValues = $ oPayment -> getDynValues ( ) ; if ( $ oPayment -> oxpayments__oxchecked -> value ) { $ this -> _sCh...
Calculate payment cost for each payment . Sould be removed later
36,230
public function getDynValue ( ) { if ( $ this -> _aDynValue === null ) { $ this -> _aDynValue = false ; if ( ( $ aDynValue = \ OxidEsales \ Eshop \ Core \ Registry :: getSession ( ) -> getVariable ( 'dynvalue' ) ) ) { $ this -> _aDynValue = $ aDynValue ; } else { $ this -> _aDynValue = \ OxidEsales \ Eshop \ Core \ Reg...
Template variable getter . Returns dyn values
36,231
public function getCheckedPaymentId ( ) { if ( $ this -> _sCheckedPaymentId === null ) { if ( ! ( $ sPaymentID = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'paymentid' ) ) ) { $ sPaymentID = \ OxidEsales \ Eshop \ Core \ Registry :: getSession ( ) -> getVariable ( 'paymentid' ) ; }...
Get checked payment ID . Tries to get checked payment ID from session if fails then tries to get payment ID from last order .
36,232
public function getPaymentCnt ( ) { if ( $ this -> _iPaymentCnt === null ) { $ this -> _iPaymentCnt = false ; if ( $ oPaymentList = $ this -> getPaymentList ( ) ) { $ this -> _iPaymentCnt = count ( $ oPaymentList ) ; } } return $ this -> _iPaymentCnt ; }
Template variable getter . Returns payment list count
36,233
public function getCreditYears ( ) { if ( $ this -> _aCreditYears === null ) { $ this -> _aCreditYears = false ; $ this -> _aCreditYears = range ( date ( 'Y' ) , date ( 'Y' ) + 10 ) ; } return $ this -> _aCreditYears ; }
Template variable getter . Returns array of years for credit cards
36,234
protected function _checkArrValuesEmpty ( $ aData , $ aKeys ) { if ( ! is_array ( $ aKeys ) || count ( $ aKeys ) < 1 ) { return false ; } foreach ( $ aKeys as $ sKey ) { if ( isset ( $ aData [ $ sKey ] ) && ! empty ( $ aData [ $ sKey ] ) ) { return false ; } } return true ; }
Function to check if array values are empty againts given array keys
36,235
protected function _filterDynData ( ) { if ( \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getConfigParam ( "blStoreCreditCardInfo" ) ) { $ this -> _blDynDataFiltered = false ; return ; } $ aDynData = $ this -> getSession ( ) -> getVariable ( "dynvalue" ) ; $ aFields = [ "kktype" , "kknumber" , "kkname" , ...
Due to legal reasons probably you are not allowed to store or even handle credit card data . In this case we just delete and forget all submited credit card data from this point . Override this method if you actually want to process credit card data .
36,236
public function combinePaths ( ) { $ pathElements = func_get_args ( ) ; foreach ( $ pathElements as $ key => $ pathElement ) { $ pathElements [ $ key ] = rtrim ( $ pathElement , DIRECTORY_SEPARATOR ) ; } return implode ( DIRECTORY_SEPARATOR , $ pathElements ) ; }
Connect all parameters with backslash to single path . Ensure that no double backslash appears if parameter already ends with backslash .
36,237
public function removeAttrArticle ( ) { $ aChosenCat = $ this -> _getActionIds ( 'oxobject2attribute.oxid' ) ; if ( \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'all' ) ) { $ sO2AttributeView = $ this -> _getViewName ( 'oxobject2attribute' ) ; $ sQ = parent :: _addFilter ( "delete $s...
Removes article from Attribute list
36,238
public function addAttrArticle ( ) { $ aAddArticle = $ this -> _getActionIds ( 'oxarticles.oxid' ) ; $ soxId = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'synchoxid' ) ; if ( \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'all' ) ) { $ sArticleTabl...
Adds article to Attribute list
36,239
public function displayExceptionError ( ) { $ aViewData = $ this -> getViewData ( ) ; $ aErrors = $ this -> _getErrors ( ) ; if ( is_array ( $ aErrors ) && count ( $ aErrors ) ) { \ OxidEsales \ Eshop \ Core \ Registry :: getUtilsView ( ) -> passAllErrorsToView ( $ aViewData , $ aErrors ) ; } $ oSmarty = \ OxidEsales \...
Sets exception errros to template
36,240
protected function _getErrors ( ) { $ aErrors = \ OxidEsales \ Eshop \ Core \ Registry :: getSession ( ) -> getVariable ( 'Errors' ) ; if ( null === $ aErrors ) { $ aErrors = [ ] ; } return $ aErrors ; }
return page errors array
36,241
public function render ( ) { $ myConfig = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) ; $ sPwrSearchFld = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( "pwrsearchfld" ) ; $ sPwrSearchFld = $ sPwrSearchFld ? strtolower ( $ sPwrSearchFld ) : "oxtitle" ; $ oArticle = null ; $...
Collects articles base data and passes them according to filtering rules returns name of template file article_list . tpl .
36,242
public function getSearchFields ( ) { $ aSkipFields = [ "oxblfixedprice" , "oxvarselect" , "oxamitemid" , "oxamtaskid" , "oxpixiexport" , "oxpixiexported" ] ; $ oArticle = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Article :: class ) ; return array_diff ( $ oArticle -> getFieldNames ( ) , $ aSkipFields ) ; }
Returns array of fields which may be used for product data search
36,243
public function getCategoryList ( $ sType , $ sValue ) { $ oCatTree = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ CategoryList :: class ) ; $ oCatTree -> loadList ( ) ; if ( $ sType === 'cat' ) { foreach ( $ oCatTree as $ oCategory ) { if ( $ oCategory -> oxcategories__oxid -> value == $ sValue ) { $ oCategory...
Load category list mark active category ;
36,244
public function getManufacturerList ( $ sType , $ sValue ) { $ oMnfTree = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ ManufacturerList :: class ) ; $ oMnfTree -> loadManufacturerList ( ) ; if ( $ sType === 'mnf' ) { foreach ( $ oMnfTree as $ oManufacturer ) { if ( $ oManufacturer -> oxmanufacturers__oxid -> va...
Load manufacturer list mark active category ;
36,245
public function getVendorList ( $ sType , $ sValue ) { $ oVndTree = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ VendorList :: class ) ; $ oVndTree -> loadVendorList ( ) ; if ( $ sType === 'vnd' ) { foreach ( $ oVndTree as $ oVendor ) { if ( $ oVendor -> oxvendor__oxid -> value == $ sValue ) { $ oVendor -> sele...
Load vendor list mark active category ;
36,246
public function deleteEntry ( ) { $ sOxId = $ this -> getEditObjectId ( ) ; $ oArticle = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Article :: class ) ; if ( $ sOxId && $ oArticle -> load ( $ sOxId ) ) { parent :: deleteEntry ( ) ; } }
Deletes entry from the database
36,247
protected function _loadActiveUrl ( $ iShopId ) { $ sActObject = null ; if ( $ this -> _sActSeoObject ) { $ sActObject = $ this -> _sActSeoObject ; } elseif ( is_array ( $ aStatUrl = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'aStaticUrl' ) ) ) { $ sActObject = $ aStatUrl [ 'oxseo_...
Loads and sets active url info to view
36,248
protected function _processUrls ( $ aUrls ) { if ( isset ( $ aUrls [ 'oxseo__oxstdurl' ] ) && $ aUrls [ 'oxseo__oxstdurl' ] ) { $ aUrls [ 'oxseo__oxstdurl' ] = $ this -> _cleanupUrl ( $ aUrls [ 'oxseo__oxstdurl' ] ) ; } if ( isset ( $ aUrls [ 'oxseo__oxseourl' ] ) && is_array ( $ aUrls [ 'oxseo__oxseourl' ] ) ) { forea...
Goes through urls array and prepares them for saving to db
36,249
protected function _cleanupUrl ( $ sUrl ) { while ( ( stripos ( $ sUrl , '&amp;' ) !== false ) || ( stripos ( $ sUrl , '&&' ) !== false ) ) { $ sUrl = str_replace ( '&amp;' , '&' , $ sUrl ) ; $ sUrl = str_replace ( '&&' , '&' , $ sUrl ) ; } return str_replace ( '&' , '&amp;' , $ sUrl ) ; }
processes urls by fixing &amp ; &
36,250
public function deleteStaticUrl ( ) { $ aStaticUrl = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'aStaticUrl' ) ; if ( is_array ( $ aStaticUrl ) ) { $ sObjectid = $ aStaticUrl [ 'oxseo__oxobjectid' ] ; if ( $ sObjectid && $ sObjectid != '-1' ) { $ this -> deleteStaticUrlFromDb ( $ s...
Deletes static url .
36,251
protected function deleteStaticUrlFromDb ( $ staticUrlId ) { $ shopId = $ this -> getEditObjectId ( ) ; $ db = \ OxidEsales \ Eshop \ Core \ DatabaseProvider :: getDb ( ) ; $ db -> execute ( "delete from oxseo where oxtype='static' and oxobjectid = " . $ db -> quote ( $ staticUrlId ) . " and oxshopid = " . $ db -> quot...
Deletes static url from DB .
36,252
public function getReviewList ( ) { $ currentPage = $ this -> getActPage ( ) ; $ itemsPerPage = $ this -> getItemsPerPage ( ) ; $ offset = $ currentPage * $ itemsPerPage ; $ userId = $ this -> getUser ( ) -> getId ( ) ; $ reviewModel = oxNew ( Review :: class ) ; $ reviewAndRatingList = $ reviewModel -> getReviewAndRat...
Returns Review List
36,253
public function deleteReviewAndRating ( ) { if ( $ this -> getSession ( ) -> checkSessionChallenge ( ) ) { try { $ this -> deleteReview ( ) ; $ this -> deleteRating ( ) ; } catch ( EntryDoesNotExistDaoException $ exception ) { } } }
Delete review and rating which belongs to the active user .
36,254
public function getPageNavigation ( ) { $ this -> _iCntPages = $ this -> getPagesCount ( ) ; $ this -> _oPageNavigation = $ this -> generatePageNavigation ( ) ; return $ this -> _oPageNavigation ; }
Generates the pagination .
36,255
private function deleteReview ( ) { $ userId = $ this -> getUser ( ) -> getId ( ) ; $ reviewId = $ this -> getReviewIdFromRequest ( ) ; if ( $ reviewId ) { $ userReviewBridge = $ this -> getContainer ( ) -> get ( UserReviewBridgeInterface :: class ) ; $ userReviewBridge -> deleteReview ( $ userId , $ reviewId ) ; } }
Deletes Review .
36,256
private function deleteRating ( ) { $ userId = $ this -> getUser ( ) -> getId ( ) ; $ ratingId = $ this -> getRatingIdFromRequest ( ) ; if ( $ ratingId ) { $ userRatingBridge = $ this -> getContainer ( ) -> get ( UserRatingBridgeInterface :: class ) ; $ userRatingBridge -> deleteRating ( $ userId , $ ratingId ) ; } }
Deletes Rating .
36,257
private function getTranslatedString ( $ string ) { $ languageId = Registry :: getLang ( ) -> getBaseLanguage ( ) ; return Registry :: getLang ( ) -> translateString ( $ string , $ languageId , false ) ; }
Returns translated string .
36,258
public function save ( ) { parent :: save ( ) ; $ soxId = $ this -> getEditObjectId ( ) ; $ aParams = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( "editval" ) ; if ( ! isset ( $ aParams [ 'oxgroups__oxactive' ] ) ) { $ aParams [ 'oxgroups__oxactive' ] = 0 ; } $ oGroup = oxNew ( \ Oxi...
Saves changed usergroup parameters .
36,259
public function themeInConfigFile ( ) { $ blThemeSet = isset ( \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> sTheme ) ; $ blCustomThemeSet = isset ( \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> sCustomTheme ) ; return ( $ blThemeSet || $ blCustomThemeSet ) ; }
Check if theme config is in config file .
36,260
protected function _getLanguageInfo ( $ sOxId ) { $ sDefaultLang = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getConfigParam ( 'sDefaultLang' ) ; $ aLangData = $ this -> _aLangData [ 'params' ] [ $ sOxId ] ; $ aLangData [ 'abbr' ] = $ sOxId ; $ aLangData [ 'desc' ] = $ this -> _aLangData [ 'lang' ] [ $ ...
Get selected language info
36,261
protected function _getLanguages ( ) { $ aLangData [ 'params' ] = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getConfigParam ( 'aLanguageParams' ) ; $ aLangData [ 'lang' ] = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getConfigParam ( 'aLanguages' ) ; $ aLangData [ 'urls' ] = \ OxidEsales ...
Loads from config all data related with languages . If no languages parameters array exists sets default parameters values . Returns collected languages parameters array .
36,262
protected function _updateAbbervation ( $ sOldId , $ sNewId ) { foreach ( array_keys ( $ this -> _aLangData ) as $ sTypeKey ) { if ( is_array ( $ this -> _aLangData [ $ sTypeKey ] ) && count ( $ this -> _aLangData [ $ sTypeKey ] ) > 0 ) { if ( $ sTypeKey == 'urls' || $ sTypeKey == 'sslUrls' ) { continue ; } $ aKeys = a...
Replaces languages arrays keys by new value .
36,263
protected function _sortLangArraysByBaseId ( ) { $ aUrls = [ ] ; $ aSslUrls = [ ] ; $ aLanguages = [ ] ; uasort ( $ this -> _aLangData [ 'params' ] , [ $ this , '_sortLangParamsByBaseIdCallback' ] ) ; foreach ( $ this -> _aLangData [ 'params' ] as $ sAbbr => $ aParams ) { $ iId = ( int ) $ aParams [ 'baseId' ] ; $ aUrl...
Sort languages languages parameters urls ssl urls arrays according base land ID
36,264
protected function _assignDefaultLangParams ( $ aLanguages ) { $ aParams = [ ] ; $ iBaseId = 0 ; foreach ( array_keys ( $ aLanguages ) as $ sOxId ) { $ aParams [ $ sOxId ] [ 'baseId' ] = $ iBaseId ; $ aParams [ $ sOxId ] [ 'active' ] = 1 ; $ aParams [ $ sOxId ] [ 'sort' ] = $ iBaseId + 1 ; $ iBaseId ++ ; } return $ aPa...
Assign default values for eache language
36,265
protected function _setDefaultLang ( $ sOxId ) { $ sDefaultId = $ this -> _aLangData [ 'params' ] [ $ sOxId ] [ 'baseId' ] ; \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> saveShopConfVar ( 'str' , 'sDefaultLang' , $ sDefaultId ) ; }
Sets default language base ID to config var sDefaultLang
36,266
protected function _getAvailableLangBaseId ( ) { $ aBaseId = [ ] ; foreach ( $ this -> _aLangData [ 'params' ] as $ aLang ) { $ aBaseId [ ] = $ aLang [ 'baseId' ] ; } $ iNewId = 0 ; sort ( $ aBaseId ) ; $ iTotal = count ( $ aBaseId ) ; while ( $ iNewId <= $ iTotal ) { if ( $ iNewId !== $ aBaseId [ $ iNewId ] ) { break ...
Get availabale language base ID
36,267
protected function _checkLangTranslations ( $ sOxId ) { $ myConfig = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) ; $ sDir = dirname ( $ myConfig -> getTranslationsDir ( 'lang.php' , $ sOxId ) ) ; if ( empty ( $ sDir ) ) { $ oEx = oxNew ( \ OxidEsales \ Eshop \ Core \ Exception \ ExceptionToDisplay :: class ...
Check selected language has translation file lang . php If not - displays warning
36,268
protected function _checkMultilangFieldsExistsInDb ( $ sOxId ) { $ iBaseId = $ this -> _aLangData [ 'params' ] [ $ sOxId ] [ 'baseId' ] ; $ sTable = getLangTableName ( 'oxarticles' , $ iBaseId ) ; $ sColumn = 'oxtitle' . \ OxidEsales \ Eshop \ Core \ Registry :: getLang ( ) -> getLanguageTag ( $ iBaseId ) ; $ oDbMetada...
Check if selected language already has multilanguage fields in DB
36,269
protected function _validateInput ( ) { $ result = true ; $ oxid = $ this -> getEditObjectId ( ) ; $ parameters = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( "editval" ) ; if ( ( $ oxid == - 1 ) && $ this -> _checkLangExists ( $ parameters [ 'abbr' ] ) ) { $ this -> addDisplayExcept...
Check language input errors
36,270
protected function addDisplayException ( $ message ) { $ exception = oxNew ( \ OxidEsales \ Eshop \ Core \ Exception \ ExceptionToDisplay :: class ) ; $ exception -> setMessage ( $ message ) ; \ OxidEsales \ Eshop \ Core \ Registry :: getUtilsView ( ) -> addErrorToDisplay ( $ exception ) ; }
Add exception to be displayed in frontend .
36,271
protected function isValidLanguageData ( $ aLanguageData ) { $ blValid = true ; $ configValidator = $ this -> getNoJsValidator ( ) ; foreach ( $ aLanguageData as $ mLanguageDataParameters ) { if ( is_array ( $ mLanguageDataParameters ) ) { $ blDeepResult = $ this -> isValidLanguageData ( $ mLanguageDataParameters ) ; $...
Validates provided language data and sets error to view in case it is not valid .
36,272
public function getHomeLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'homeLink' ) ) === null ) { $ sValue = null ; $ blAddStartCl = $ this -> isStartClassRequired ( ) ; if ( $ blAddStartCl ) { $ baseLanguage = \ OxidEsales \ Eshop \ Core \ Registry :: getLang ( ) -> getBaseLanguage ( ) ; $ sValue = \ Oxid...
Returns shops home link
36,273
protected function isStartClassRequired ( ) { $ baseLanguage = \ OxidEsales \ Eshop \ Core \ Registry :: getLang ( ) -> getBaseLanguage ( ) ; $ shopConfig = $ this -> getConfig ( ) ; $ isSeoActive = \ OxidEsales \ Eshop \ Core \ Registry :: getUtils ( ) -> seoIsActive ( ) ; return $ isSeoActive && ( $ baseLanguage != $...
Check if some shop selection page must be shown
36,274
public function getLogoutLink ( ) { $ sClass = $ this -> getTopActionClassName ( ) ; $ sCatnid = $ this -> getActCatId ( ) ; $ sMnfid = $ this -> getActManufacturerId ( ) ; $ sArtnid = $ this -> getActArticleId ( ) ; $ sTplName = $ this -> getActTplName ( ) ; $ sContentLoadId = $ this -> getActContentLoadId ( ) ; $ sSe...
Returns shop logout link
36,275
public function getHelpPageLink ( ) { if ( $ this -> _sHelpPageLink === null ) { $ this -> _sHelpPageLink = "" ; $ aContentIdents = $ this -> _getHelpContentIdents ( ) ; $ oContent = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Content :: class ) ; foreach ( $ aContentIdents as $ sIdent ) { if ( $ oContent -> l...
Returns shop help link
36,276
public function getViewConfigParam ( $ sName ) { startProfile ( '\OxidEsales\Eshop\Core\ViewConfig::getViewConfigParam' ) ; if ( $ this -> _oShop && isset ( $ this -> _oShop -> $ sName ) ) { $ sValue = $ this -> _oShop -> $ sName ; } elseif ( $ this -> _aViewData && isset ( $ this -> _aViewData [ $ sName ] ) ) { $ sVal...
Returns current view config parameter
36,277
public function getHiddenSid ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'hiddensid' ) ) === null ) { $ sValue = $ this -> getSession ( ) -> hiddenSid ( ) ; if ( ( $ sLang = \ OxidEsales \ Eshop \ Core \ Registry :: getLang ( ) -> getFormLang ( ) ) ) { $ sValue .= "\n{$sLang}" ; } $ sValue .= $ this -> getAd...
Returns forms hidden session parameters
36,278
public function getSelfLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'selflink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopHomeUrl ( ) ; $ this -> setViewConfigParam ( 'selflink' , $ sValue ) ; } return $ sValue ; }
Returns shops self link
36,279
public function getSslSelfLink ( ) { if ( $ this -> isAdmin ( ) ) { return $ this -> getSelfLink ( ) ; } if ( ( $ sValue = $ this -> getViewConfigParam ( 'sslselflink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopSecureHomeURL ( ) ; $ this -> setViewConfigParam ( 'sslselflink' , $ sValue ) ; } return $...
Returns shops self ssl link
36,280
public function getBaseDir ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'basedir' ) ) === null ) { if ( $ this -> getConfig ( ) -> isSsl ( ) ) { $ sValue = $ this -> getConfig ( ) -> getSSLShopURL ( ) ; } else { $ sValue = $ this -> getConfig ( ) -> getShopURL ( ) ; } $ this -> setViewConfigParam ( 'basedir' ...
Returns shops base directory path
36,281
public function getCoreUtilsDir ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'coreutilsdir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getCoreUtilsURL ( ) ; $ this -> setViewConfigParam ( 'coreutilsdir' , $ sValue ) ; } return $ sValue ; }
Returns shops utility directory path
36,282
public function getSelfActionLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'selfactionlink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopCurrentUrl ( ) ; $ this -> setViewConfigParam ( 'selfactionlink' , $ sValue ) ; } return $ sValue ; }
Returns shops action link
36,283
public function getCurrentHomeDir ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'currenthomedir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getCurrentShopUrl ( ) ; $ this -> setViewConfigParam ( 'currenthomedir' , $ sValue ) ; } return $ sValue ; }
Returns shops home path
36,284
public function getBasketLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'basketlink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopHomeUrl ( ) . 'cl=basket' ; $ this -> setViewConfigParam ( 'basketlink' , $ sValue ) ; } return $ sValue ; }
Returns shops basket link
36,285
public function getOrderLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'orderlink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopSecureHomeUrl ( ) . 'cl=user' ; $ this -> setViewConfigParam ( 'orderlink' , $ sValue ) ; } return $ sValue ; }
Returns shops order link
36,286
public function getPaymentLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'paymentlink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopSecureHomeUrl ( ) . 'cl=payment' ; $ this -> setViewConfigParam ( 'paymentlink' , $ sValue ) ; } return $ sValue ; }
Returns shops payment link
36,287
public function getExeOrderLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'exeorderlink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopSecureHomeUrl ( ) . 'cl=order&amp;fnc=execute' ; $ this -> setViewConfigParam ( 'exeorderlink' , $ sValue ) ; } return $ sValue ; }
Returns shops order execution link
36,288
public function getOrderConfirmLink ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'orderconfirmlink' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopSecureHomeUrl ( ) . 'cl=order' ; $ this -> setViewConfigParam ( 'orderconfirmlink' , $ sValue ) ; } return $ sValue ; }
Returns shops order confirmation link
36,289
public function getResourceUrl ( $ sFile = null ) { if ( $ sFile ) { $ sValue = $ this -> getConfig ( ) -> getResourceUrl ( $ sFile , $ this -> isAdmin ( ) ) ; } elseif ( ( $ sValue = $ this -> getViewConfigParam ( 'basetpldir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getResourceUrl ( '' , $ this -> isAdm...
Returns shops resource url
36,290
public function getUrlTemplateDir ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'urltemplatedir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getTemplateUrl ( $ this -> isAdmin ( ) ) ; $ this -> setViewConfigParam ( 'urltemplatedir' , $ sValue ) ; } return $ sValue ; }
Returns shops current templates url
36,291
public function getImageUrl ( $ sFile = null , $ bSsl = null ) { if ( $ sFile ) { $ sValue = $ this -> getConfig ( ) -> getImageUrl ( $ this -> isAdmin ( ) , $ bSsl , null , $ sFile ) ; } elseif ( ( $ sValue = $ this -> getViewConfigParam ( 'imagedir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getImageUrl (...
Returns image url
36,292
public function getNoSslImageDir ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'nossl_imagedir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getImageUrl ( $ this -> isAdmin ( ) , false ) ; $ this -> setViewConfigParam ( 'nossl_imagedir' , $ sValue ) ; } return $ sValue ; }
Returns non ssl image url
36,293
public function getPictureDir ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'picturedir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getPictureUrl ( null , $ this -> isAdmin ( ) ) ; $ this -> setViewConfigParam ( 'picturedir' , $ sValue ) ; } return $ sValue ; }
Returns url to pictures directory .
36,294
public function getAdminDir ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'sAdminDir' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getConfigParam ( 'sAdminDir' ) ; $ this -> setViewConfigParam ( 'sAdminDir' , $ sValue ) ; } return $ sValue ; }
Returns admin path
36,295
public function getActiveShopId ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'shopid' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopId ( ) ; $ this -> setViewConfigParam ( 'shopid' , $ sValue ) ; } return $ sValue ; }
Returns currently open shop id
36,296
public function getRemoteAddress ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'ip' ) ) === null ) { $ sValue = \ OxidEsales \ Eshop \ Core \ Registry :: getUtilsServer ( ) -> getRemoteAddress ( ) ; $ this -> setViewConfigParam ( 'ip' , $ sValue ) ; } return $ sValue ; }
Returns visitor ip address
36,297
public function getPopupIdent ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'popupident' ) ) === null ) { $ sValue = md5 ( $ this -> getConfig ( ) -> getShopUrl ( ) ) ; $ this -> setViewConfigParam ( 'popupident' , $ sValue ) ; } return $ sValue ; }
Returns basket popup identifier
36,298
public function getPopupIdentRand ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'popupidentrand' ) ) === null ) { $ sValue = md5 ( time ( ) ) ; $ this -> setViewConfigParam ( 'popupidentrand' , $ sValue ) ; } return $ sValue ; }
Returns random basket popup identifier
36,299
public function getArtPerPageForm ( ) { if ( ( $ sValue = $ this -> getViewConfigParam ( 'artperpageform' ) ) === null ) { $ sValue = $ this -> getConfig ( ) -> getShopCurrentUrl ( ) ; $ this -> setViewConfigParam ( 'artperpageform' , $ sValue ) ; } return $ sValue ; }
Returns list view paging url