<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
clickandmortar / akeneo-migrations-manager-bundle example snippets
// app/AppKernel.php
// ...
class AppKernel extends Kernel
{
public function registerProjectBundles()
{
return [
// ...
new ClickAndMortar\AkeneoMigrationsManagerBundle\ClickAndMortarAkeneoMigrationsManagerBundle(),
];
// ...
}
// ...
}
namespace Pim\Upgrade\Schema;
use ClickAndMortar\AkeneoMigrationsManagerBundle\Migration\AbstractStepMigration;
use Doctrine\DBAL\Schema\Schema;
/**
* Class Version20190121174114
*
* @author Simon CARRE <[email protected]>
* @package Pim\Upgrade\Schema
*/
class Version20190121174114 extends AbstractStepMigration
{
/**
* Migration label
*
* @var string
*/
const MIGRATION_LABEL = 'Update to 1.0.1';
/**
* @param Schema $schema
*/
public function up(Schema $schema)
{
$this->createNewStep('Start a new step');
// Process here
$this->addWarning('Error: Bad process');
$this->createNewStep('Start the last step');
// Process here
}
/**
* Get migration label used in dashboard widget
*
* @return string
*/
public static function getLabel()
{
return self::MIGRATION_LABEL;
}
}
php bin/console doctrine:migrations:generate
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.