This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #category_products_sales_report | |
| SET @categoryEntityTypeId := (SELECT entity_type_id FROM eav_entity_type WHERE entity_type_code = 'catalog_category'); | |
| SET @nameAttributeId := (select attribute_id FROM eav_attribute where attribute_code = 'name' and entity_type_id = @categoryEntityTypeId); | |
| SET @categoryId = 1; | |
| select w.name as website_name, oi.name, SUM(oi.base_row_invoiced) as total,SUM(qty_invoiced) FROM catalog_category_product cp | |
| INNER JOIN sales_flat_order_item oi ON oi.product_id = cp.product_id | |
| INNER JOIN core_store s ON s.store_id = oi.store_id | |
| INNER JOIN core_website w ON w.website_id = s.website_id | |
| WHERE cp.category_id = @categoryId |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| SET @categoryEntityTypeId := (SELECT entity_type_id FROM eav_entity_type WHERE entity_type_code = 'catalog_category'); | |
| SET @nameAttributeId := (select attribute_id FROM eav_attribute where attribute_code = 'name' and entity_type_id = @categoryEntityTypeId); | |
| SET @storeId = 1; | |
| select w.name as website_name, name.value as category_name, SUM(oi.base_row_invoiced) as total,SUM(qty_invoiced) FROM catalog_category_product cp | |
| INNER JOIN sales_flat_order_item oi ON oi.product_id = cp.product_id | |
| INNER JOIN catalog_category_entity_varchar name ON name.entity_id = cp.category_id AND name.store_id = 0 | |
| INNER JOIN core_store s ON s.store_id = oi.store_id | |
| INNER JOIN core_website w ON w.website_id = s.website_id | |
| WHERE name.attribute_id = @nameAttributeId | |
| AND cp.category_id IN ({commaseperatedcategoryids}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function gdResize($uploadDir, $filename,$ext, $newWidth, $newHeight) | |
| { | |
| list($orginalWidth, $orginalHeight) = getimagesize($uploadDir. $filename . '.' . $ext); | |
| $ratio = $orginalWidth/$orginalHeight; | |
| if ($orginalWidth < $newWidth || $orginalHeight < $newHeight) | |
| { | |
| return ''; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function imagickResize($uploadDir, $fileFrom, $fileTo, $newWidth, $newHeight) | |
| { | |
| $thumb = new Imagick(); | |
| $thumb->readImage($uploadDir. $fileFrom); | |
| $dimensions = $thumb->getImageGeometry(); | |
| $orginalWidth = $dimensions['width']; | |
| $orginalHeight = $dimensions['height']; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #Retrieve Entity Type Ids | |
| SET @categoryEntityTypeId := (SELECT entity_type_id FROM eav_entity_type WHERE entity_type_code = 'catalog_category'); | |
| SET @nameAttributeId := (select attribute_id FROM eav_attribute where attribute_code = 'name' and entity_type_id = @categoryEntityTypeId); | |
| SET @descriptionAttributeId := (select attribute_id FROM eav_attribute where attribute_code = 'description' and entity_type_id = @categoryEntityTypeId); | |
| SET @metaTitleAttributeId := (select attribute_id FROM eav_attribute where attribute_code = 'meta_title' and entity_type_id = @categoryEntityTypeId); | |
| SET @metaDescriptionAttributeId := (select attribute_id FROM eav_attribute where attribute_code = 'meta_description' and entity_type_id = @categoryEntityTypeId); | |
| SET @isActiveAttributeId := (select attribute_id FROM eav_attribute where attribute_code = 'is_active' and entity_type_id = @categoryEntityTypeId); | |
| SELECT DISTINCT c.entity_id as `Category_Id`, | |
| name.value as `Name`, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * Author : Anil Paul | |
| * Date: 25/08/16 | |
| * Time: 5:19 PM | |
| */ | |
| $sourcePath = 'Module Path'; | |
| $csvFile = 'Namespace_Module.csv'; | |
| $searchExtensions = array('php', 'phtml'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| jQuery(document).ready( | |
| function($) | |
| { | |
| var isRandomize = 0; | |
| var randomize; | |
| var retrievedData = localStorage.getItem("sr_extraitems"); | |
| var extraItems = JSON.parse(retrievedData); | |
| if (extraItems == undefined) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @import url(https://fonts.googleapis.com/css?family=Raleway); | |
| .webdawe-tabs { | |
| position: relative; | |
| margin: 0 auto; | |
| width: 100%; | |
| font-weight: 300; | |
| font-size: 1.25em; | |
| margin-top:20px; | |
| font-family: 'Raleway', sans-serif; | |
| /*box-shadow: 0px 0px 5px #f5f5f5;*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| jQuery(document).ready( | |
| function($) | |
| { | |
| $('.webdawe-tabs-link').click( | |
| function() | |
| { | |
| //console.log($(this).attr('data-link')); | |
| $('.webdawe-content-wrap').find('section' + '#' + $(this).attr('data-link')).addClass('content-current'); | |
| $('.webdawe-content-wrap').find('section' + '#' + $(this).attr('data-link')).siblings().removeClass('content-current'); | |
| $(this).parent().addClass('tab-current'); |
NewerOlder