<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use App\Notification\AuctionAlertAuctionEndingSoon2HOnlineFavoriteFollowingNotification;
use App\Notification\AuctionAlertNotification;
use App\Notification\SellerObjectNotSoldThirdNotification;
use App\Notification\SellerObjectNotSoldSecondNotification;
use App\Notification\AuctionResultsToSellerNotification;
use App\Notification\AutomaticPaymentSuccessfullReceiptAttachedAsPDFNotification;
use App\Notification\BankCardExpiredNotification;
use App\Notification\BankCardExpiresSoonNotification;
use App\Notification\BidConfirmationOnlineAuctionNotification;
use App\Notification\BidConfirmationOnlineAuctionNotInTheLeadNotification;
use App\Notification\CardPaymentUnsuccessfulLateFeeNotification;
use App\Notification\AdvanceBidNotification;
use App\Notification\PhoneBidNotification;
use App\Notification\InactiveUserFirstNoticeNotification;
use App\Notification\InactiveUserProfileClosedNotification;
use App\Notification\PasswordResetEmailNotification;
use App\Notification\PaymentReceiptReceiptAttachedAsPDFNotification;
use App\Notification\UserPasswordUpdatedNotification;
use App\Notification\UserPaymentCardUpdatedNotification;
use App\Notification\UserProfileIsUpdatedNotification;
use App\Notification\YourLotsAreLiveOnlineNotification;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20220614155914 extends AbstractMigration
{
public function getDescription(): string
{
return 'Update default notification_template setting';
}
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('UPDATE notification_template SET setting = 12 WHERE notification_type = ' . UserProfileIsUpdatedNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . UserPasswordUpdatedNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . UserPaymentCardUpdatedNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 12 WHERE notification_type = ' . PasswordResetEmailNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 61 WHERE notification_type = ' . BidConfirmationOnlineAuctionNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 61 WHERE notification_type = ' . BidConfirmationOnlineAuctionNotInTheLeadNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 21 WHERE notification_type = ' . AuctionAlertNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 21 WHERE notification_type = ' . AuctionAlertAuctionEndingSoon2HOnlineFavoriteFollowingNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . AdvanceBidNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . PhoneBidNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 21 WHERE notification_type = ' . YourLotsAreLiveOnlineNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 53 WHERE notification_type = ' . AuctionResultsToSellerNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 53 WHERE notification_type = ' . SellerObjectNotSoldSecondNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 61 WHERE notification_type = ' . SellerObjectNotSoldThirdNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 61 WHERE notification_type = ' . AutomaticPaymentSuccessfullReceiptAttachedAsPDFNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 61 WHERE notification_type = ' . PaymentReceiptReceiptAttachedAsPDFNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 61 WHERE notification_type = ' . CardPaymentUnsuccessfulLateFeeNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . BankCardExpiresSoonNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . BankCardExpiredNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . InactiveUserFirstNoticeNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 60 WHERE notification_type = ' . InactiveUserProfileClosedNotification::TYPE);
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . UserProfileIsUpdatedNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . UserPasswordUpdatedNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . UserPaymentCardUpdatedNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . PasswordResetEmailNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 21 WHERE notification_type = ' . BidConfirmationOnlineAuctionNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . BidConfirmationOnlineAuctionNotInTheLeadNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . AuctionAlertNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . AuctionAlertAuctionEndingSoon2HOnlineFavoriteFollowingNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 20 WHERE notification_type = ' . AdvanceBidNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 20 WHERE notification_type = ' . PhoneBidNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . YourLotsAreLiveOnlineNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 21 WHERE notification_type = ' . AuctionResultsToSellerNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 28 WHERE notification_type = ' . SellerObjectNotSoldSecondNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 28 WHERE notification_type = ' . SellerObjectNotSoldThirdNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 29 WHERE notification_type = ' . AutomaticPaymentSuccessfullReceiptAttachedAsPDFNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 29 WHERE notification_type = ' . PaymentReceiptReceiptAttachedAsPDFNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 29 WHERE notification_type = ' . CardPaymentUnsuccessfulLateFeeNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 20 WHERE notification_type = ' . BankCardExpiresSoonNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = 21 WHERE notification_type = ' . BankCardExpiredNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . InactiveUserFirstNoticeNotification::TYPE);
$this->addSql('UPDATE notification_template SET setting = NULL WHERE notification_type = ' . InactiveUserProfileClosedNotification::TYPE);
}
}