Skip to content

Commit

Permalink
Merge pull request #235 from uasoft-indonesia/develop
Browse files Browse the repository at this point in the history
Merge develop to main
  • Loading branch information
rizkiheryandi authored Jul 4, 2021
2 parents 11d48c5 + 895495e commit 86e02cc
Show file tree
Hide file tree
Showing 16 changed files with 12 additions and 276 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "2.0.0-rc.6",
"version": "2.0.0-rc.7",
"name": "uasoft-indonesia/badaso",
"description": "The First Open-Source Laravel Vue headless CMS (PWA dashboard + CRUD + API generator & more) for more productivity !",
"keywords": [
Expand Down
1 change: 1 addition & 0 deletions src/Config/badaso.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
'admin_panel_route_prefix' => env('MIX_ADMIN_PANEL_ROUTE_PREFIX', 'badaso-dashboard'),
'default_menu' => env('MIX_DEFAULT_MENU', 'admin'),
'api_route_prefix' => env('MIX_API_ROUTE_PREFIX', 'badaso-api'),
'license_key' => env('BADASO_LICENSE_KEY'),
'storage' => [
'disk' => env('FILESYSTEM_DRIVER', 'public'),
],
Expand Down
4 changes: 2 additions & 2 deletions src/Controllers/BadasoDashboardController.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ class BadasoDashboardController extends Controller
{
public function verifyLicense()
{
$license = env('BADASO_LICENSE_KEY');
$license = config('badaso.license_key');
if (is_null($license)) {
return ApiResponse::paymentRequired('BADASO_LICENSE_KEY not found');
return ApiResponse::paymentRequired('BADASO_LICENSE_KEY not found on .env');
} elseif ($license == '') {
return ApiResponse::paymentRequired('BADASO_LICENSE_KEY License Empty');
} else {
Expand Down
3 changes: 2 additions & 1 deletion src/Migrations/2020_11_13_064800_create_data_type.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,10 @@ public function up()
$table->enum('order_direction', ['ASC', 'DESC'])->nullable();
$table->boolean('generate_permissions')->default(false);
$table->tinyInteger('server_side')->default(0);
$table->boolean('is_maintenance')->default(false);
$table->text('description')->nullable();

$table->text('details')->nullable();
$table->text('notification')->nullable();
$table->boolean('is_soft_delete')->default(0)->nullable();
$table->timestamps();
});
Expand Down
1 change: 1 addition & 0 deletions src/Migrations/2020_11_18_014827_create_configurations.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ public function up()
$table->string('type');
$table->integer('order')->default('1');
$table->string('group')->nullable();
$table->boolean('can_delete')->default(false);
$table->timestamps();
});
} catch (PDOException $ex) {
Expand Down
1 change: 1 addition & 0 deletions src/Migrations/2020_11_18_014950_create_permissions.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ public function up()
$table->string('description')->nullable();
$table->string('table_name')->nullable();
$table->boolean('always_allow')->default(false);
$table->boolean('is_public')->default(false);
$table->timestamps();
});
} catch (PDOException $ex) {
Expand Down
1 change: 1 addition & 0 deletions src/Migrations/2020_11_18_015020_create_menus.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ public function up()
$table->increments('id');
$table->string('key')->unique();
$table->string('display_name');
$table->string('icon')->nullable();
$table->timestamps();
});
} catch (PDOException $ex) {
Expand Down
2 changes: 1 addition & 1 deletion src/Migrations/2020_11_18_015341_add_badaso_user_field.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public function up()
try {
Schema::table('users', function (Blueprint $table) {
if (! Schema::hasColumn('users', 'avatar')) {
$table->string('avatar')->nullable()->after('email')->default('users/default.png');
$table->string('avatar')->nullable()->after('email')->default('files/shares/default-user.png');
}
if (! Schema::hasColumn('users', 'additional_info')) {
$table->text('additional_info')->nullable()->after('email');
Expand Down
36 changes: 0 additions & 36 deletions src/Migrations/2021_02_19_033756_add_icon_to_menus.php

This file was deleted.

36 changes: 0 additions & 36 deletions src/Migrations/2021_03_02_022959_add_column_to_permissions.php

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

9 changes: 2 additions & 7 deletions src/Seeder/Configurations/SiteManagementSeeder.php
Original file line number Diff line number Diff line change
Expand Up @@ -153,16 +153,11 @@ public function run()
],
];

$new_settings = [];
foreach ($settings as $key => $value) {
$setting = \DB::table('configurations')->where('key', $value['key'])->first();
if (isset($setting)) {
continue;
}
$new_settings[] = $value;
\DB::table('configurations')->where('key', $value['key'])->delete();
}

\DB::table('configurations')->insert($new_settings);
\DB::table('configurations')->insert($settings);

\DB::commit();
} catch (Exception $e) {
Expand Down

0 comments on commit 86e02cc

Please sign in to comment.