<?php

namespace App\Database\Migrations;

use CodeIgniter\Database\Migration;

class AddContractorContactNoToContractorsTable extends Migration
{
    public function up()
    {
        $this->forge->addColumn('contractors', [
            'contractor_contact_no' => [
                'type'       => 'VARCHAR',
                'constraint' => '20',
                'null'       => true,
                'after'      => 'contractor_name'
            ]
        ]);
    }

    public function down()
    {
        $this->forge->dropColumn('contractors', 'contractor_contact_no');
    }
}