- Generate high-level overview of all the main components
- How are the total item counts for each option generated?
- How is the catalog updated to display the matching products?
- How are options rendered?
- What are the customisation points?
- What events are dispatched?
This file contains 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
#!/usr/bin/env bash | |
# What it does: | |
# - Creates a local Shopware installation using the Symfony Flex template for local development of client projects | |
# - Prerequisites: ddev installed on your machine, see https://ddev.com/get-started/ | |
# | |
# How to use: | |
# - create a project folder | |
# - copy this file into the project folder | |
# - chmod +x install.sh |
This file contains 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
#!/usr/bin/env bash | |
LANGUAGES="en_US pt_BR" | |
# production or developer | |
ENVIRONMENT="production" | |
COMPOSER=$(which composer) | |
PHP=$(which php) | |
ROOT=$(pwd) |
This file contains 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
add_filter( 'woocommerce_email_customer_details_fields', 'add_user_id_to_woocommerce_emails', 10, 3); | |
function add_user_id_to_woocommerce_emails( $fields, $sent_to_admin, $order ) { | |
$user_id = $order->get_customer_id(); | |
$user_info = get_userdata( $user_id ); | |
$fields['user_id'] = array( | |
'label' => __( 'User ID', 'woocommerce' ), | |
'value' => $user_id | |
); |
This file contains 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
# allow `mount` cmd without password | |
echo "$USER ALL=NOPASSWD: /bin/mount" | (sudo su -c 'EDITOR="tee -a" visudo') | |
# add the mount directive to `fstab` | |
sudo mkdir -p /c | |
sudo sh -c "echo '/mnt/c /c none bind' >> /etc/fstab" | |
# update to `.bashrc` to auto mount at login | |
echo "sudo mount -a" >> ~/.bashrc | |
# now reload it | |
source ~/.bashrc |
This file contains 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
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_regular_price' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_sale_price' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_price' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_regular_price_tmp' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_sale_price_tmp' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_price_tmp' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_min_variation_price' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_max_variation_price' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHERE meta_key = '_min_variation_regular_price' AND meta_value != '' | |
UPDATE wp_postmeta SET meta_value = meta_value*0.8 WHE |
This file contains 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
export default { | |
beforeRouteEnter(route, redirect, next) { | |
next(vm => { | |
vm.$http.get(`${API.BASE}/${API.PAGE}/${route.name}`).then((response) => { | |
vm.page = response.data.page; | |
vm.eventHub.$emit('update-breadcrumb', [ | |
{ | |
title: 'Home', |
This file contains 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
# Resetting your Windows Subsystem for Linux (WSL) Environment | |
lxrun.exe /uninstall /full | |
lxrun.exe /install |
This file contains 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 | |
/** | |
* Magento | |
* | |
* NOTICE OF LICENSE | |
* | |
* This source file is subject to the Open Software License (OSL 3.0) | |
* that is bundled with this package in the file LICENSE.txt. | |
* It is also available through the world-wide-web at this URL: | |
* http://opensource.org/licenses/osl-3.0.php |
This file contains 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
SUM( | |
IF(at.attr5 IS NOT NULL AND at.attr5 <> '', at.attr5 * b.quantity, | |
IF(d.weight * b.quantity < 3, 4.99, | |
IF(d.weight * b.quantity < 5, 6.90, | |
IF(d.weight * b.quantity < 10, 9.50, | |
IF(d.weight * b.quantity < 15, 10.90, | |
IF(d.weight * b.quantity < 20, 12.90, | |
IF(d.weight * b.quantity < 31, 17.90, | |
IF(d.weight * b.quantity < 40, 49.90, | |
(49.90+(0.59*(d.weight * b.quantity - 40))) |
NewerOlder