|
Apache/2.4.41 (Ubuntu) Linux vmi616275.contaboserver.net 5.4.0-84-generic #94-Ubuntu SMP Thu Aug 26 20:27:37 UTC 2021 x86_64 uid=33(www-data) gid=33(www-data) groups=33(www-data) server ip : 62.171.164.128 | your ip : 127.0.0.1 safemode OFF > / home / a / home / dev2.destoffenstraat.com / app / code / Mageplaza / Smtp / Setup / |
Filename | /home/a/home/dev2.destoffenstraat.com/app/code/Mageplaza/Smtp/Setup/InstallSchema.php |
Size | 2.17 kb |
Permission | rwxrwxrwx |
Owner | root : root |
Create time | 21-Aug-2025 12:26 |
Last modified | 02-Nov-2021 12:46 |
Last accessed | 24-Aug-2025 07:27 |
Actions | edit | rename | delete | download (gzip) |
View | text | code | image |
<?php
/**
* Mageplaza
*
* NOTICE OF LICENSE
*
* This source file is subject to the Mageplaza.com license that is
* available through the world-wide-web at this URL:
* https://www.mageplaza.com/LICENSE.txt
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade this extension to newer
* version in the future.
*
* @category Mageplaza
* @package Mageplaza_Smtp
* @copyright Copyright (c) Mageplaza (https://www.mageplaza.com/)
* @license https://www.mageplaza.com/LICENSE.txt
*/
namespace Mageplaza\Smtp\Setup;
use Magento\Framework\DB\Ddl\Table;
use Magento\Framework\Setup\InstallSchemaInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\SchemaSetupInterface;
use Zend_Db_Exception;
/**
* Class InstallSchema
* @package Mageplaza\Smtp\Setup
*/
class InstallSchema implements InstallSchemaInterface
{
/**
* @param SchemaSetupInterface $setup
* @param ModuleContextInterface $context
*
* @throws Zend_Db_Exception
*/
public function install(SchemaSetupInterface $setup, ModuleContextInterface $context)
{
$installer = $setup;
$installer->startSetup();
if (!$installer->tableExists('mageplaza_smtp_log')) {
$table = $installer->getConnection()
->newTable($installer->getTable('mageplaza_smtp_log'))
->addColumn('id', Table::TYPE_INTEGER, null, [
'identity' => true,
'nullable' => false,
'primary' => true,
'unsigned' => true,
], 'Log ID')
->addColumn('subject', Table::TYPE_TEXT, 255, ['nullable => false'], 'Email Subject')
->addColumn('email_content', Table::TYPE_TEXT, '64k', [], 'Email Content')
->addColumn('status', Table::TYPE_SMALLINT, 1, ['nullable' => false], 'Status')
->addColumn('created_at', Table::TYPE_TIMESTAMP, null, [], 'Created At')
->addIndex($installer->getIdxName('mageplaza_smtp_log', ['status']), ['status']);
$installer->getConnection()->createTable($table);
}
$installer->endSetup();
}
}
/**
* Mageplaza
*
* NOTICE OF LICENSE
*
* This source file is subject to the Mageplaza.com license that is
* available through the world-wide-web at this URL:
* https://www.mageplaza.com/LICENSE.txt
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade this extension to newer
* version in the future.
*
* @category Mageplaza
* @package Mageplaza_Smtp
* @copyright Copyright (c) Mageplaza (https://www.mageplaza.com/)
* @license https://www.mageplaza.com/LICENSE.txt
*/
namespace Mageplaza\Smtp\Setup;
use Magento\Framework\DB\Ddl\Table;
use Magento\Framework\Setup\InstallSchemaInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\SchemaSetupInterface;
use Zend_Db_Exception;
/**
* Class InstallSchema
* @package Mageplaza\Smtp\Setup
*/
class InstallSchema implements InstallSchemaInterface
{
/**
* @param SchemaSetupInterface $setup
* @param ModuleContextInterface $context
*
* @throws Zend_Db_Exception
*/
public function install(SchemaSetupInterface $setup, ModuleContextInterface $context)
{
$installer = $setup;
$installer->startSetup();
if (!$installer->tableExists('mageplaza_smtp_log')) {
$table = $installer->getConnection()
->newTable($installer->getTable('mageplaza_smtp_log'))
->addColumn('id', Table::TYPE_INTEGER, null, [
'identity' => true,
'nullable' => false,
'primary' => true,
'unsigned' => true,
], 'Log ID')
->addColumn('subject', Table::TYPE_TEXT, 255, ['nullable => false'], 'Email Subject')
->addColumn('email_content', Table::TYPE_TEXT, '64k', [], 'Email Content')
->addColumn('status', Table::TYPE_SMALLINT, 1, ['nullable' => false], 'Status')
->addColumn('created_at', Table::TYPE_TIMESTAMP, null, [], 'Created At')
->addIndex($installer->getIdxName('mageplaza_smtp_log', ['status']), ['status']);
$installer->getConnection()->createTable($table);
}
$installer->endSetup();
}
}