Skip to content

Commit

Permalink
[FEATURE] - Added db_schema changes after removal of installscripts t…
Browse files Browse the repository at this point in the history
…o installscripts
  • Loading branch information
rensieeee committed Nov 25, 2020
1 parent 2228e93 commit 7cda5bd
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
14 changes: 14 additions & 0 deletions Setup/UpgradeSchema.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,19 @@ public function upgrade(
);
}
}
if (version_compare($context->getVersion(), "1.0.2", "<")) {
$connection = $setup->getConnection();
if (!$connection->tableColumnExists($setup->getTable('experius_emailcatcher'), 'template_identifier')) {
$connection->addColumn(
$setup->getTable('experius_emailcatcher'),
'template_identifier',
[
'type' => \Magento\Framework\DB\Ddl\Table::TYPE_TEXT,
'nullable' => true,
'comment' => 'Email Template Identifier'
]
);
}
}
}
}
2 changes: 1 addition & 1 deletion etc/module.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" ?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Experius_EmailCatcher" setup_version="1.0.1" schema_version="1.0.1">
<module name="Experius_EmailCatcher" setup_version="1.0.2" schema_version="1.0.2">
<sequence>
<module name="Magento_Email"/>
</sequence>
Expand Down

0 comments on commit 7cda5bd

Please sign in to comment.