mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
Update vendor contact schema to match client contact schema
This commit is contained in:
parent
b12fe64a63
commit
1042bbec7b
@ -26,6 +26,7 @@ class Vendor extends BaseModel
|
||||
|
||||
protected $fillable = [
|
||||
'name',
|
||||
'assigned_user_id',
|
||||
'id_number',
|
||||
'vat_number',
|
||||
'work_phone',
|
||||
|
@ -85,6 +85,7 @@ class VendorTransformer extends EntityTransformer
|
||||
'state' => $vendor->state ?: '',
|
||||
'postal_code' => $vendor->postal_code ?: '',
|
||||
'country_id' => (string) $vendor->country_id ?: '',
|
||||
'currency_id' => (string) $vendor->currency_id ?: '',
|
||||
'custom_value1' => $vendor->custom_value1 ?: '',
|
||||
'custom_value2' => $vendor->custom_value2 ?: '',
|
||||
'custom_value3' => $vendor->custom_value3 ?: '',
|
||||
|
@ -1239,6 +1239,7 @@ class CreateUsersTable extends Migration
|
||||
$table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade')->onUpdate('cascade');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('expense_categories', function ($table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('user_id');
|
||||
|
@ -42,6 +42,7 @@ class UpdateGatewayTableVisibleColumn extends Migration
|
||||
$t->boolean('is_deleted')->default(0);
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class VendorSchemaUpdate extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('vendor_contacts', function ($table){
|
||||
$table->timestamp('email_verified_at')->nullable();
|
||||
$table->string('confirmation_code')->nullable();
|
||||
$table->boolean('confirmed')->default(false);
|
||||
$table->timestamp('last_login')->nullable();
|
||||
$table->smallInteger('failed_logins')->nullable();
|
||||
$table->string('oauth_user_id', 100)->nullable()->unique();
|
||||
$table->unsignedInteger('oauth_provider_id')->nullable()->unique();
|
||||
$table->string('google_2fa_secret')->nullable();
|
||||
$table->string('accepted_terms_version')->nullable();
|
||||
$table->string('avatar', 255)->nullable();
|
||||
$table->string('avatar_type', 255)->nullable();
|
||||
$table->string('avatar_size', 255)->nullable();
|
||||
$table->string('password');
|
||||
$table->string('token')->nullable();
|
||||
$table->boolean('is_locked')->default(false);
|
||||
$table->string('contact_key')->nullable();
|
||||
$table->rememberToken();
|
||||
$table->index(['company_id', 'email', 'deleted_at']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user