public function getBuyTabHtml() { $helpBlock = $this->getLayout()->createBlock('M2ePro/adminhtml_common_buy_order_help'); $javascript = $this->getHelpBlockJavascript($helpBlock->getContainerId()); return $javascript . $helpBlock->toHtml() . $this->getBuyTabBlockFilterHtml() . parent::getBuyTabHtml(); }
public function getBuyTabHtml() { /** @var $helper Ess_M2ePro_Helper_Data */ $helper = Mage::helper('M2ePro'); $componentMode = Ess_M2ePro_Helper_Component_Buy::NICK; $logViewUrl = $this->getUrl('*/adminhtml_common_log/listingOther', array('filter' => base64_encode('component_mode=' . Ess_M2ePro_Helper_Component_Buy::NICK), 'back' => $helper->makeBackUrlParam('*/adminhtml_common_listing_other/index/tab/' . $componentMode))); $prepareData = $this->getUrl('*/adminhtml_listing_other_moving/prepareMoveToListing'); $createDefaultListingUrl = $this->getUrl('*/adminhtml_listing_other_moving/createDefaultListing'); $getMoveToListingGridHtml = $this->getUrl('*/adminhtml_listing_other_moving/moveToListingGrid'); $getFailedProductsGridHtml = $this->getUrl('*/adminhtml_listing_other_moving/getFailedProductsGrid'); $tryToMoveToListing = $this->getUrl('*/adminhtml_listing_other_moving/tryToMoveToListing'); $moveToListing = $this->getUrl('*/adminhtml_listing_other_moving/moveToListing'); $mapAutoToProductUrl = $this->getUrl('*/adminhtml_listing_other_mapping/autoMap'); $removingProductsUrl = $this->getUrl('*/adminhtml_common_listing_other/removing'); $unmappingProductsUrl = $this->getUrl('*/adminhtml_listing_other_mapping/unmapping'); $someProductsWereNotMappedMessage = 'No matches were found. Please change the mapping attributes in <strong>'; $someProductsWereNotMappedMessage .= 'Configuration > Account > 3rd Party Listings</strong> '; $someProductsWereNotMappedMessage .= 'or try to map manually.'; $someProductsWereNotMappedMessage = $helper->escapeJs($helper->__($someProductsWereNotMappedMessage)); $successfullyMappedMessage = $helper->escapeJs($helper->__('Product was successfully mapped.')); $createListing = $helper->escapeJs($helper->__('Listings, which have the same Marketplace and Account were not found.')); $createListing .= $helper->escapeJs($helper->__('Would you like to create one with default settings ?')); $popupTitle = $helper->escapeJs($helper->__('Moving Rakuten.com Items.')); $failedProductsPopupTitle = $helper->escapeJs($helper->__('Products failed to move')); $confirmMessage = $helper->escapeJs($helper->__('Are you sure?')); $successfullyMovedMessage = $helper->escapeJs($helper->__('Product(s) was successfully moved.')); $productsWereNotMovedMessage = $helper->escapeJs($helper->__('Products were not moved. <a target="_blank" href="%url%">View log</a> for details.')); $someProductsWereNotMovedMessage = $helper->escapeJs($helper->__('Some of the products were not moved. <a target="_blank" href="%url%">View log</a> for details.')); $notEnoughDataMessage = $helper->escapeJs($helper->__('Not enough data.')); $successfullyUnmappedMessage = $helper->escapeJs($helper->__('Product(s) was successfully unmapped.')); $successfullyRemovedMessage = $helper->escapeJs($helper->__('Product(s) was successfully removed.')); $viewAllProductLogMessage = $helper->escapeJs($helper->__('View All Product Log.')); $selectItemsMessage = $helper->escapeJs($helper->__('Please select the products you want to perform the action on.')); $selectActionMessage = $helper->escapeJs($helper->__('Please select action.')); $processingDataMessage = $helper->escapeJs($helper->__('Processing %product_title% product(s).')); $successWord = $helper->escapeJs($helper->__('Success')); $noticeWord = $helper->escapeJs($helper->__('Notice')); $warningWord = $helper->escapeJs($helper->__('Warning')); $errorWord = $helper->escapeJs($helper->__('Error')); $closeWord = $helper->escapeJs($helper->__('Close')); $autoMapProgressTitle = $helper->escapeJs($helper->__('Map Item(s) to Products')); $selectOnlyMapped = $helper->escapeJs($helper->__('Only mapped products must be selected.')); $selectTheSameTypeProducts = $helper->escapeJs($helper->__('Selected items must belong to the same Account and Marketplace.')); $javascriptsMain = <<<JAVASCRIPT <script type="text/javascript"> M2eProBuy = {}; M2eProBuy.url = {}; M2eProBuy.formData = {}; M2eProBuy.customData = {}; M2eProBuy.text = {}; M2eProBuy.url.logViewUrl = '{$logViewUrl}'; M2eProBuy.url.prepareData = '{$prepareData}'; M2eProBuy.url.createDefaultListing = '{$createDefaultListingUrl}'; M2eProBuy.url.getGridHtml = '{$getMoveToListingGridHtml}'; M2eProBuy.url.getFailedProductsGridHtml = '{$getFailedProductsGridHtml}'; M2eProBuy.url.tryToMoveToListing = '{$tryToMoveToListing}'; M2eProBuy.url.moveToListing = '{$moveToListing}'; M2eProBuy.url.mapAutoToProduct = '{$mapAutoToProductUrl}'; M2eProBuy.url.removingProducts = '{$removingProductsUrl}'; M2eProBuy.url.unmappingProducts = '{$unmappingProductsUrl}'; M2eProBuy.text.create_listing = '{$createListing}'; M2eProBuy.text.popup_title = '{$popupTitle}'; M2eProBuy.text.failed_products_popup_title = '{$failedProductsPopupTitle}'; M2eProBuy.text.confirm = '{$confirmMessage}'; M2eProBuy.text.successfully_moved = '{$successfullyMovedMessage}'; M2eProBuy.text.products_were_not_moved = '{$productsWereNotMovedMessage}'; M2eProBuy.text.some_products_were_not_moved = '{$someProductsWereNotMovedMessage}'; M2eProBuy.text.not_enough_data = '{$notEnoughDataMessage}'; M2eProBuy.text.successfully_unmapped = '{$successfullyUnmappedMessage}'; M2eProBuy.text.successfully_removed = '{$successfullyRemovedMessage}'; M2eProBuy.text.select_items_message = '{$selectItemsMessage}'; M2eProBuy.text.select_action_message = '{$selectActionMessage}'; M2eProBuy.text.automap_progress_title = '{$autoMapProgressTitle}'; M2eProBuy.text.processing_data_message = '{$processingDataMessage}'; M2eProBuy.text.successfully_mapped = '{$successfullyMappedMessage}'; M2eProBuy.text.failed_mapped = '{$someProductsWereNotMappedMessage}'; M2eProBuy.text.select_only_mapped_products = '{$selectOnlyMapped}'; M2eProBuy.text.select_the_same_type_products = '{$selectTheSameTypeProducts}'; M2eProBuy.text.view_all_product_log_message = '{$viewAllProductLogMessage}'; M2eProBuy.text.success_word = '{$successWord}'; M2eProBuy.text.notice_word = '{$noticeWord}'; M2eProBuy.text.warning_word = '{$warningWord}'; M2eProBuy.text.error_word = '{$errorWord}'; M2eProBuy.text.close_word = '{$closeWord}'; M2eProBuy.customData.componentMode = '{$componentMode}'; M2eProBuy.customData.gridId = 'buyListingOtherGrid'; var init = function () { BuyListingOtherGridHandlerObj = new BuyListingOtherGridHandler('buyListingOtherGrid'); BuyListingOtherMappingHandlerObj = new ListingOtherMappingHandler( BuyListingOtherGridHandlerObj, 'buy' ); BuyListingOtherGridHandlerObj.movingHandler.setOptions(M2eProBuy); BuyListingOtherGridHandlerObj.autoMappingHandler.setOptions(M2eProBuy); BuyListingOtherGridHandlerObj.removingHandler.setOptions(M2eProBuy); BuyListingOtherGridHandlerObj.unmappingHandler.setOptions(M2eProBuy); } if (\$\$('.tabs-horiz').first()) { var buyTabId = \$\$('.tabs-horiz').first().id + '_buy'; \$(buyTabId).observe('click', init); } {$this->isAjax} ? init() : Event.observe(window, 'load', init); </script> JAVASCRIPT; $helpBlock = $this->getLayout()->createBlock('M2ePro/adminhtml_common_buy_listing_other_help'); return $javascriptsMain . $helpBlock->toHtml() . $this->getBuyTabBlockFilterHtml() . parent::getBuyTabHtml(); }
public function getBuyTabHtml() { return $this->getBuyTabBlockFilterHtml() . parent::getBuyTabHtml(); }
public function getBuyTabHtml() { $helpBlock = $this->getLayout()->createBlock('M2ePro/adminhtml_common_buy_synchronization_help'); return $helpBlock->toHtml() . parent::getBuyTabHtml(); }
public function getBuyTabHtml() { $tutorialShown = Mage::helper('M2ePro/Module')->getConfig()->getGroupValue('/view/common/buy/listing/', 'tutorial_shown'); if (!$tutorialShown) { return parent::getBuyTabHtml(); } $javascript = ''; if ($this->getRequest()->isXmlHttpRequest()) { $javascript = $this->getBuyTabBlock()->getTemplatesButtonJavascript(); } return $javascript . $this->getLayout()->createBlock('M2ePro/adminhtml_common_buy_listing_filter')->toHtml() . parent::getBuyTabHtml(); }
public function getBuyTabHtml() { return $this->getLayout()->createBlock('M2ePro/adminhtml_common_buy_listing_filter')->toHtml() . parent::getBuyTabHtml(); }