migrations/Version20220823112754.php line 1

Open in your IDE?
  1. <?php
  2. declare(strict_types=1);
  3. namespace DoctrineMigrations;
  4. use Doctrine\DBAL\Schema\Schema;
  5. use Doctrine\Migrations\AbstractMigration;
  6. /**
  7.  * Auto-generated Migration: Please modify to your needs!
  8.  */
  9. final class Version20220823112754 extends AbstractMigration
  10. {
  11.     public function getDescription(): string
  12.     {
  13.         return 'Add new template for vipps invoice notifications';
  14.     }
  15.     public function up(Schema $schema): void
  16.     {
  17.         // this up() migration is auto-generated, please modify it to your needs
  18.         $this->addSql("INSERT INTO notification_template (identifier, notification_type, text_email, text_sms, subject, created_at, updated_at, text_system, notification_language, category, setting, profile_default, icon, color, profile_title) VALUES ('PAYMENT_DONE_AUTOMATIC_VIPPS_NOR', 45, '<p>%customer_number% %user_name% skal faktureres for kjøp av %lot_number% %object_title%</p>', null, 'Fakturere VIP-kunde', '2022-08-23 14:35:44', '2022-08-23 14:35:44', null, 'nor-NO', 'Fakturere VIP-kunde', 0, 0, null, null, 'Fakturere VIP-kunde');");
  19.         $this->addSql("INSERT INTO notification_template (identifier, notification_type, text_email, text_sms, subject, created_at, updated_at, text_system, notification_language, category, setting, profile_default, icon, color, profile_title) VALUES ('PAYMENT_DONE_AUTOMATIC_VIPPS_ENG', 45, '<p>%customer_number% %user_name% will be invoiced for the purchase of %lot_number% %object_title%</p>', null, 'Invoice VIP-customer', '2022-08-23 14:35:44', '2022-08-23 14:35:44', null, 'eng-GB', 'Invoice VIP-customer', 0, 0, null, null, 'Invoice VIP-customer');");
  20.     }
  21.     public function down(Schema $schema): void
  22.     {
  23.         // this down() migration is auto-generated, please modify it to your needs
  24.         $this->addSql('DELETE FROM notification_template WHERE notification_type = 45)');
  25.     }
  26. }