mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/izyim-api.git
synced 2026-08-19 04:24:01 +00:00
added create company
added update company
This commit is contained in:
@@ -15,6 +15,7 @@ class CreateCompaniesTable extends Migration
|
||||
{
|
||||
Schema::create('companies', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
//$table->string('company-profile'); //need to check about storage type
|
||||
$table->string('company-name');
|
||||
$table->string('registration-no');
|
||||
$table->string('tax-no');
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class RenameColumnInCompany extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('companies', function (Blueprint $table) {
|
||||
// $table->renameColumn('company-profile', 'company_profile');
|
||||
$table->renameColumn('"company-name"', 'company_name');
|
||||
$table->renameColumn('"registration-no"', 'registration_no');
|
||||
$table->renameColumn('"tax-no"', 'tax_no');
|
||||
$table->renameColumn('"tel-no"', 'tel_no');
|
||||
$table->renameColumn('"contact-person"', 'contact_person');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user