Fix session_id column TrackEExercise - refs BT#13873

pull/2487/head
Angel Fernando Quiroz Campos 7 years ago
parent c486020133
commit 1d3f388ad9
  1. 39
      app/Migrations/Schema/V200/Version20180115082400.php
  2. 2
      src/CoreBundle/Entity/TrackEExercises.php

@ -0,0 +1,39 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Migrations\Schema\V200;
use Application\Migrations\AbstractMigrationChamilo;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\DBAL\Types\Type;
/**
* Class Version20180115082400
*
* @package Chamilo\CoreBundle\Migrations\Schema\V200
*/
class Version20180115082400 extends AbstractMigrationChamilo
{
/**
* @param Schema $schema
*
* @throws \Doctrine\DBAL\Schema\SchemaException
*/
public function up(Schema $schema)
{
$trackExe = $schema->getTable('track_e_exercises');
$colSession = $trackExe->getColumn('session_id');
if ($colSession->getType() != Type::INTEGER) {
$colSession->setType(Type::INTEGER);
}
}
/**
* @param Schema $schema
*/
public function down(Schema $schema)
{
}
}

@ -97,7 +97,7 @@ class TrackEExercises
/**
* @var integer
*
* @ORM\Column(name="session_id", type="smallint", nullable=false)
* @ORM\Column(name="session_id", type="integer", nullable=false)
*/
private $sessionId;

Loading…
Cancel
Save