first commit
This commit is contained in:
0
Modules/Asset/database/migrations/.gitkeep
Normal file
0
Modules/Asset/database/migrations/.gitkeep
Normal file
@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('tbl_assets', function (Blueprint $table) {
|
||||
$table->unsignedTinyInteger('asset_id')->autoIncrement();
|
||||
$table->string('name')->nullable();
|
||||
$table->date('purchased_date')->nullable();
|
||||
$table->string('purchased_from')->nullable();
|
||||
$table->string('manufacturer')->nullable();
|
||||
$table->string('model')->nullable();
|
||||
$table->string('serial_number')->nullable();
|
||||
$table->string('supplier')->nullable();
|
||||
$table->string('condition')->nullable();
|
||||
$table->string('warranty')->nullable();
|
||||
$table->string('value')->nullable();
|
||||
$table->unsignedBigInteger('asset_category_id')->nullable();
|
||||
$table->unsignedBigInteger('asset_user')->nullable();
|
||||
$table->integer('status')->default(11);
|
||||
$table->longText('description')->nullable();
|
||||
$table->longText('remarks')->nullable();
|
||||
$table->date('approved_date')->nullable();
|
||||
$table->boolean('is_available')->default(1);
|
||||
$table->unsignedBigInteger('approved_by')->nullable();
|
||||
$table->unsignedBigInteger('createdBy')->nullable();
|
||||
$table->unsignedBigInteger('updatedBy')->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('tbl_assets');
|
||||
}
|
||||
};
|
@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration {
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('tbl_asset_categories', function (Blueprint $table) {
|
||||
$table->unsignedTinyInteger('asset_category_id')->autoIncrement();
|
||||
$table->string('name')->default(11);
|
||||
$table->integer('status')->default(11);
|
||||
$table->mediumText('description')->nullable();
|
||||
$table->mediumText('remarks')->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('tbl_asset_categories');
|
||||
}
|
||||
};
|
@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration {
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('tbl_asset_demands', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->unsignedBigInteger('department_id')->nullable();
|
||||
$table->unsignedBigInteger('designation_id')->nullable();
|
||||
$table->unsignedBigInteger('employee_id')->nullable();
|
||||
$table->unsignedBigInteger('asset_id')->nullable();
|
||||
$table->date('request_date')->nullable();
|
||||
$table->integer('status')->default(11);
|
||||
$table->mediumText('reason')->nullable();
|
||||
$table->mediumText('description')->nullable();
|
||||
$table->mediumText('remarks')->nullable();
|
||||
$table->unsignedBigInteger('createdby')->nullable();
|
||||
$table->unsignedBigInteger('updatedBy')->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('tbl_asset_demands');
|
||||
}
|
||||
};
|
Reference in New Issue
Block a user