Spamworldpro Mini Shell
Spamworldpro


Server : Apache
System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64
User : corals ( 1002)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
Directory :  /home/corals/ts.corals.io/corals-api/Corals/core/Settings/update-batches/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/corals/ts.corals.io/corals-api/Corals/core/Settings/update-batches/1.6.php
<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Corals\Menu\Models\Menu;

if (!Schema::hasTable('countries')) {
    Schema::create('countries', function (Blueprint $table) {
        $table->increments('id');
        $table->string('code', 2)
            ->index();
        $table->string('name', 75);
    });

    $countriesTableSeeder = new \Corals\Settings\database\seeds\CountriesTableSeeder();

    $countriesTableSeeder->run();
}

if (empty(\Settings::get('address_types'))) {
    \DB::table('settings')->insert([
        'code' => 'address_types',
        'type' => 'SELECT',
        'label' => 'Address Types',
        'value' => '{"home":"Home","office":"Office","shipping":"Shipping","billing":"Billing"}',
        'editable' => 1,
        'hidden' => 0,
        'created_at' => \Carbon\Carbon::now(),
        'updated_at' => \Carbon\Carbon::now(),
    ]);
}

$administrationMenu = Menu::where('key', 'administration')->get();

$custom_fields_menu = Menu::where('url', 'custom-fields')->get();

if (!$custom_fields_menu) {
    \DB::table('menus')->create(
        [
            'parent_id' => $administrationMenu->id,// admin
            'key' => null,
            'url' => 'custom-fields',
            'active_menu_url' => 'custom-fields*',
            'name' => 'Custom Fields',
            'description' => 'Custom Fields menu Item',
            'icon' => 'fa fa-microchip',
            'target' => null, 'roles' => '["1"]',
            'order' => 985
        ]
    );
}

Spamworldpro Mini