| 123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- <?php
- namespace addons\WechatVideoShop\console\migrations;
- use yii\db\Migration;
- /**
- * Class M240606032740CronTaskSyncWechatRegion
- */
- class M240606032740CronTaskSyncWechatRegion extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- $this->execute("INSERT INTO `qimall_crontab_task` (`name`, `command`, `type`, `rule`, `is_warning`, `status`, `created_at`, `updated_at`) VALUES ('每天同步一次微信地址', 'wechat-video-shop/sync/region', 2, '0 0 1 * * *', 0, 1, 1718070034, 1718070034);");
- }
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- echo "M240606032740CronTaskSyncWechatRegion cannot be reverted.\n";
- return false;
- }
- /*
- // Use up()/down() to run migration code without a transaction.
- public function up()
- {
- }
- public function down()
- {
- echo "M240606032740CronTaskSyncWechatRegion cannot be reverted.\n";
- return false;
- }
- */
- }
|