|
@@ -0,0 +1,42 @@
|
|
|
+<?php
|
|
|
+
|
|
|
+use yii\db\Migration;
|
|
|
+
|
|
|
+/**
|
|
|
+ * Class m240814_005724_Actualizar_columna_descripcion_varias_tablas
|
|
|
+ */
|
|
|
+class m240814_005724_Actualizar_columna_descripcion_varias_tablas extends Migration
|
|
|
+{
|
|
|
+ /**
|
|
|
+ * {@inheritdoc}
|
|
|
+ */
|
|
|
+ public function safeUp()
|
|
|
+ {
|
|
|
+ $this->alterColumn('Marca', 'descripcion', $this->string()->null());
|
|
|
+ $this->alterColumn('Obra', 'descripcion', $this->string()->null());
|
|
|
+ $this->alterColumn('TipoAuto', 'descripcion', $this->string()->null());
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ public function safeDown()
|
|
|
+ {
|
|
|
+ $this->alterColumn('Marca', 'descripcion', $this->string()->notNull());
|
|
|
+ $this->alterColumn('Obra', 'descripcion', $this->string()->notNull());
|
|
|
+ $this->alterColumn('TipoAuto', 'descripcion', $this->string()->notNull());
|
|
|
+ }
|
|
|
+
|
|
|
+ /*
|
|
|
+ // Use up()/down() to run migration code without a transaction.
|
|
|
+ public function up()
|
|
|
+ {
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ public function down()
|
|
|
+ {
|
|
|
+ echo "m240814_005724_Actualizar_columna_descripcion_varias_tablas cannot be reverted.\n";
|
|
|
+
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ */
|
|
|
+}
|