Skip to content

Instantly share code, notes, and snippets.

View msoroka's full-sized avatar

Mateusz Soroka msoroka

View GitHub Profile
framework:
messenger:
transports:
async: "%env(MESSENGER_TRANSPORT_DSN)%"
routing:
'App\Message\CompetitionApplicationMessage': async
services:
App\MessageHandler\CompetitionApplicationMessageHandler:
tags:
- { name: messenger.message_handler }
<?php
namespace App\Controller;
use App\Form\Type\CompetitionApplicationType;
use App\Message\CompetitionApplicationMessage;
use Exception;
use Pimcore\Controller\FrontendController;
use Pimcore\Model\DataObject\CompetitionApplication;
use Pimcore\Translation\Translator;
<?php
namespace App\MessageHandler;
use App\Message\CompetitionApplicationMessage;
use Carbon\Carbon;
use Pimcore\Mail;
use Pimcore\Model\DataObject\Service;
use Symfony\Component\Messenger\Handler\MessageHandlerInterface;
<?php
namespace App\Message;
use Pimcore\Model\DataObject\CompetitionApplication;
class CompetitionApplicationMessage
{
public function __construct(
private readonly CompetitionApplication $competitionApplication
<?php
namespace App\Controller;
use App\Form\Type\CompetitionApplicationType;
use Carbon\Carbon;
use Exception;
use Pimcore\Controller\FrontendController;
use Pimcore\Mail;
use Pimcore\Model\DataObject\CompetitionApplication;
<?php
$posts = get_posts([
'post_type' => 'produkte',
'numberposts' => -1
]);
foreach ($posts as $p) {
$images =& get_children( array (
'post_parent' => $p->ID,
'post_type' => 'attachment',
<?php
class CeneoXml extends inspirePlugin2 {
protected $_pluginNamespace = 'woocommerce_ceneo';
protected $ceneo;
const DEFAULT_EXPORT_LANG = 'pl';
const WPDESK_FILTER_PRODUCT_SHOULD_EXPORT = 'wpdesk_ceneo_product_should_export';
$pageId = $queried_district->term_id;
if(ICL_LANGUAGE_CODE == 'en') {
$pageId = 22;
}
if (ICL_LANGUAGE_CODE == 'de') {
$pageId = 95;
}
$districts = get_terms('district', array('parent' => $pageId, 'hide_empty' => false));
<?php
/**
* Single Product Image
*
* This template can be overridden by copying it to yourtheme/woocommerce/single-product/product-image.php.
*
* HOWEVER, on occasion WooCommerce will need to update template files and you
* (the theme developer) will need to copy the new files to your theme to
* maintain compatibility. We try to do this as little as possible, but it does
* happen. When this occurs the version of the template file will be bumped and