aboutsummaryrefslogtreecommitdiffhomepage
path: root/app/DoctrineMigrations
diff options
context:
space:
mode:
Diffstat (limited to 'app/DoctrineMigrations')
-rw-r--r--app/DoctrineMigrations/Version20160410190541.php12
1 files changed, 0 insertions, 12 deletions
diff --git a/app/DoctrineMigrations/Version20160410190541.php b/app/DoctrineMigrations/Version20160410190541.php
index f35f54ce..77c78c54 100644
--- a/app/DoctrineMigrations/Version20160410190541.php
+++ b/app/DoctrineMigrations/Version20160410190541.php
@@ -28,18 +28,6 @@ class Version20160410190541 extends AbstractMigration implements ContainerAwareI
28 $this->addSql('ALTER TABLE `wallabag_entry` ADD `uuid` LONGTEXT DEFAULT NULL'); 28 $this->addSql('ALTER TABLE `wallabag_entry` ADD `uuid` LONGTEXT DEFAULT NULL');
29 } 29 }
30 30
31 public function postUp(Schema $schema)
32 {
33 $em = $this->container->get('doctrine.orm.entity_manager');
34 $repository = $em->getRepository('WallabagCoreBundle:Entry');
35 $entries = $repository->findAll();
36
37 /** @var Entry $entry */
38 foreach ($entries as $entry) {
39 $this->addSql('UPDATE `wallabag_entry` SET `uuid` = "'.uniqid('', true).'" WHERE id = '.$entry->getId());
40 }
41 }
42
43 /** 31 /**
44 * @param Schema $schema 32 * @param Schema $schema
45 */ 33 */