Skip to content

Commit

Permalink
Initial update to 2.8
Browse files Browse the repository at this point in the history
  • Loading branch information
dongilbert committed May 12, 2016
1 parent 9d03872 commit db63cee
Show file tree
Hide file tree
Showing 11 changed files with 1,251 additions and 599 deletions.
2 changes: 2 additions & 0 deletions app/autoload.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?php

require_once __DIR__ . '/bootstrap.php.cache';

use Doctrine\Common\Annotations\AnnotationRegistry;
use Composer\Autoload\ClassLoader;

Expand Down
15 changes: 10 additions & 5 deletions app/bundles/CoreBundle/Config/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -469,28 +469,33 @@
'tag' => 'twig.extension'
),
// Schema
'mautic.scheme.helper.factory' => array(

'mautic.schema.helper.factory' => array(
'class' => 'Maujtic\CoreBundle\Doctrine\Helper\SchemaHelperFactory',
'arguments' => array(
'mautic.schema.helper.table',
'mautic.schema.helper.index',
'mautic.schema.helper.column'
)
),
'mautic.schema.helper.column' => array(
'class' => 'Mautic\CoreBundle\Doctrine\Helper\ColumnSchemaHelper',
'arguments' => array(
'database_connection',
'mautic.db_table_prefix'
'%mautic.db_table_prefix%'
)
),
'mautic.schema.helper.index' => array(
'class' => 'Mautic\CoreBundle\Doctrine\Helper\IndexSchemaHelper',
'arguments' => array(
'database_connection',
'mautic.db_table_prefix'
'%mautic.db_table_prefix%'
)
),
'mautic.schema.helper.table' => array(
'class' => 'Mautic\CoreBundle\Doctrine\Helper\TableSchemaHelper',
'arguments' => array(
'database_connection',
'mautic.db_table_prefix',
'%mautic.db_table_prefix%',
'mautic.schema.helper.column'
)
),
Expand Down
7 changes: 4 additions & 3 deletions app/bundles/CoreBundle/Model/AbstractCommonModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
use Symfony\Component\Security\Core\SecurityContext;
use Symfony\Bundle\FrameworkBundle\Routing\Router;
use Symfony\Component\Intl\Intl;
use Symfony\Component\Translation\TranslatorInterface;

/**
* Class AbstractCommonModel
Expand Down Expand Up @@ -62,7 +63,7 @@ public function setFactory(MauticFactory $factory)
protected $router;

/**
* @var Translator
* @var TranslatorInterface
*/
protected $translator;

Expand Down Expand Up @@ -104,9 +105,9 @@ public function setRouter(Router $router)
}

/**
* @param Translator $translator
* @param TranslatorInterface $translator
*/
public function setTranslator(Translator $translator)
public function setTranslator(TranslatorInterface $translator)
{
$this->translator = $translator;
}
Expand Down
17 changes: 15 additions & 2 deletions app/bundles/CoreBundle/Templating/Helper/AssetsHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@

use Mautic\CoreBundle\Factory\MauticFactory;
use Mautic\CoreBundle\Helper\AssetGenerationHelper;
use Symfony\Component\Templating\Helper\CoreAssetsHelper;
use Symfony\Component\Asset\Package;
use Symfony\Component\Asset\Packages;

/**
* Class AssetsHelper
*/
class AssetsHelper extends CoreAssetsHelper
class AssetsHelper extends Package
{

/**
Expand All @@ -39,6 +40,13 @@ class AssetsHelper extends CoreAssetsHelper
*/
protected $version;

public function __construct(Packages $packages)
{
$defaultPackage = $packages->getPackage();

parent::__construct($defaultPackage->getVersionStrategy(), $defaultPackage->getContext());
}

/**
* Gets asset prefix
*
Expand Down Expand Up @@ -603,4 +611,9 @@ public function getName()
{
return 'assets';
}

public function setCharset($charset)
{

}
}
8 changes: 4 additions & 4 deletions app/bundles/FormBundle/Model/SubmissionModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
use Mautic\LeadBundle\Entity\Lead;
use Mautic\CoreBundle\Helper\Chart\LineChart;
use Mautic\CoreBundle\Helper\Chart\ChartQuery;
use Mautic\LeadBundle\Model\FieldModel;
use Mautic\LeadBundle\Model\FieldModel as LeadFieldModel;
use Mautic\LeadBundle\Model\LeadModel;
use Mautic\PageBundle\Model\PageModel;
use Monolog\Logger;
Expand Down Expand Up @@ -74,7 +74,7 @@ class SubmissionModel extends CommonFormModel
protected $campaignModel;

/**
* @var FieldModel
* @var LeadFieldModel
*/
protected $leadFieldModel;

Expand All @@ -92,7 +92,7 @@ class SubmissionModel extends CommonFormModel
* @param PageModel $pageModel
* @param LeadModel $leadModel
* @param CampaignModel $campaignModel
* @param FieldModel $leadFieldModel
* @param LeadFieldModel $leadFieldModel
*/
public function __construct(
IpLookupHelper $ipLookupHelper,
Expand All @@ -101,7 +101,7 @@ public function __construct(
PageModel $pageModel,
LeadModel $leadModel,
CampaignModel $campaignModel,
FieldModel $leadFieldModel
LeadFieldModel $leadFieldModel
)
{
$this->ipLookupHelper = $ipLookupHelper;
Expand Down
5 changes: 4 additions & 1 deletion app/bundles/UserBundle/Config/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,10 @@
'class' => 'Mautic\UserBundle\Model\RoleModel'
),
'mautic.user.model.user' => array(
'class' => 'Mautic\UserBundle\Model\UserModel'
'class' => 'Mautic\UserBundle\Model\UserModel',
'arguments' => array(
'mautic.helper.mailer'
)
)
)
)
Expand Down
2 changes: 1 addition & 1 deletion app/console
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ set_time_limit(0);

defined('IN_MAUTIC_CONSOLE') or define('IN_MAUTIC_CONSOLE', 1);

require_once __DIR__.'/bootstrap.php.cache';
require_once __DIR__.'/autoload.php';
require_once __DIR__.'/AppKernel.php';

use Symfony\Bundle\FrameworkBundle\Console\Application;
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
"symfony/doctrine-bridge": "2.8.*",
"symfony/monolog-bridge": "2.8.*",

"sensio/distribution-bundle": "2.3.*",
"sensio/distribution-bundle": "~5.0",

"twig/twig": "1.*",
"symfony/twig-bundle": "2.5.*",
Expand Down
Loading

0 comments on commit db63cee

Please # to comment.