Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,6 @@ HE4RT_DISCORD_BOT_KEY=
HE4RT_DISCORD_LEVELUP_CHANNEL=
HE4RT_DISCORD_GUILD=

DB_TEST_DATABASE="dev_he4rtbot"
DB_TEST_USERNAME="root"
DB_TEST_PASSWORD="root"

DISCORD_OAUTH_CLIENT_ID=
DISCORD_OAUTH_CLIENT_SECRET=
DISCORD_OAUTH_SCOPES=
Expand Down
69 changes: 0 additions & 69 deletions .env.pipeline

This file was deleted.

10 changes: 10 additions & 0 deletions .env.testing.example
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,13 @@ HE4RT_DISCORD_LEVELUP_CHANNEL=
HE4RT_DISCORD_GUILD=

REDIS_URL=127.0.0.1

DISCORD_OAUTH_CLIENT_ID=
DISCORD_OAUTH_CLIENT_SECRET=
DISCORD_OAUTH_SCOPES=
DISCORD_OAUTH_REDIRECT_URI=

TWITCH_OAUTH_SCOPES=
TWITCH_OAUTH_CLIENT_ID=
TWITCH_OAUTH_CLIENT_SECRET=
TWITCH_OAUTH_REDIRECT_URI=
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ help: ## Show available commands

.PHONY: route-list
route-list: ## List all registered routes
@php artisan route:list --ansi
@php artisan route:list --except-vendor --ansi

.PHONY: pint
pint: ## Run Pint code style fixer
Expand Down
2 changes: 1 addition & 1 deletion Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ tasks:
route-list:
desc: List all registered routes
aliases: [rl]
cmd: 'php artisan route:list --ansi'
cmd: 'php artisan route:list --except-vendor --ansi'

pint:
desc: Run Pint code style fixer
Expand Down
3 changes: 1 addition & 2 deletions app-modules/character/database/factories/WalletFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@
use He4rt\Character\Models\Character;
use He4rt\Character\Models\Wallet;
use Illuminate\Database\Eloquent\Factories\Factory;
use Illuminate\Database\Eloquent\Model;

/**
* @extends Factory<Model>
* @extends Factory<Wallet>
*/
final class WalletFactory extends Factory
{
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?php

declare(strict_types=1);

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
public function up(): void
{
Schema::create('characters_wallet', function (Blueprint $table): void {
$table->id();
$table->integer('balance')->default(0);
$table->foreignUuid('character_id')->constrained('characters')->cascadeOnDelete();
$table->timestampsTz();
});
}
};
7 changes: 6 additions & 1 deletion app-modules/character/src/Models/Wallet.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

namespace He4rt\Character\Models;

use He4rt\Character\Database\Factories\WalletFactory;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;

Expand All @@ -13,7 +15,10 @@
*/
final class Wallet extends Model
{
protected $table = 'character_wallet';
/** @use HasFactory<WalletFactory> */
use HasFactory;

protected $table = 'characters_wallet';

protected $fillable = [
'character_id',
Expand Down
2 changes: 1 addition & 1 deletion app-modules/events/src/Models/Pivot/EventAttend.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

class EventAttend extends Pivot
{
protected $table = 'event_attend';
protected $table = 'events_attendees';

protected $fillable = [
'status',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public function up(): void
{
Schema::create('sessions', function (Blueprint $table): void {
$table->string('id')->primary();
$table->foreignId('user_id')->nullable()->index();
$table->foreignUuid('user_id')->nullable()->index();
$table->string('ip_address', 45)->nullable();
$table->text('user_agent')->nullable();
$table->longText('payload');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@ public function up(): void
*/
public function down(): void
{
Schema::dropIfExists('event_sponsors');
Schema::dropIfExists('events_sponsors');
}
};
2 changes: 1 addition & 1 deletion app-modules/sponsors/src/Models/Pivot/SponsorAttend.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

class SponsorAttend extends Pivot
{
protected $table = 'sponsor_attend';
protected $table = 'events_sponsors';
Comment thread
coderabbitai[bot] marked this conversation as resolved.

protected $fillable = [
'level',
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@
"ide-helper": [
"@php artisan ide-helper:generate -q",
"@php artisan ide-helper:meta -q",
"@php artisan ide-helper:models -q -N"
"@php artisan ide-helper:models -q -N --dir='app-modules/*/src/Models' --dir='app/Models'"
],
"setup": [
"composer install",
Expand Down