Fix code quality violations and rename select input components

Move small tasks from wishlist to todo, update npm packages
Replace #[Auth] attributes with manual auth checks and code quality rule
Remove on_jqhtml_ready lifecycle method from framework
Complete ACL system with 100-based role indexing and /dev/acl tester
WIP: ACL system implementation with debug instrumentation
Convert rsx:check JS linting to RPC socket server
Clean up docs and fix $id→$sid in man pages, remove SSR/FPC feature
Reorganize wishlists: priority order, mark sublayouts complete, add email
Update model_fetch docs: mark MVP complete, fix enum docs, reorganize
Comprehensive documentation overhaul: clarity, compression, and critical rules
Convert Contacts/Projects CRUD to Model.fetch() and add fetch_or_null()
Add JS ORM relationship lazy-loading and fetch array handling
Add JS ORM relationship fetching and CRUD documentation
Fix ORM hydration and add IDE resolution for Base_* model stubs
Rename Json_Tree_Component to JS_Tree_Debug_Component and move to framework
Enhance JS ORM infrastructure and add Json_Tree class name badges

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
root
2025-11-23 21:39:43 +00:00
parent 78553d4edf
commit 84ca3dfe42
167 changed files with 7538 additions and 49164 deletions

View File

@@ -311,6 +311,21 @@
"created_at": "2025-11-19T23:17:08+00:00",
"created_by": "root",
"command": "php artisan make:migration:safe create_test_user_record"
},
"2025_11_21_193529_create_api_keys_table.php": {
"created_at": "2025-11-21T19:35:29+00:00",
"created_by": "root",
"command": "php artisan make:migration:safe create_api_keys_table"
},
"2025_11_23_160855_create_user_permissions_table.php": {
"created_at": "2025-11-23T16:08:55+00:00",
"created_by": "root",
"command": "php artisan make:migration:safe create_user_permissions_table"
},
"2025_11_23_164439_reindex_user_roles_to_100_based.php": {
"created_at": "2025-11-23T16:44:39+00:00",
"created_by": "root",
"command": "php artisan make:migration:safe reindex_user_roles_to_100_based"
}
}
}

View File

@@ -0,0 +1,52 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\DB;
return new class extends Migration
{
/**
* Run the migrations.
*
* IMPORTANT: Use raw MySQL queries for clarity and auditability
* DB::statement() with raw SQL
* Schema::create() with Blueprint
*
* REQUIRED: ALL tables MUST have: id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY
* No exceptions - every table needs this exact ID column (SIGNED for easier migrations)
*
* Integer types: Use BIGINT for all integers, TINYINT(1) for booleans only
* Never use unsigned - all integers should be signed
*
* Migrations must be self-contained - no Model/Service references
*
* @return void
*/
public function up()
{
DB::statement("
CREATE TABLE _api_keys (
id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY,
user_id BIGINT NOT NULL,
name VARCHAR(255) NOT NULL,
key_hash VARCHAR(255) NOT NULL,
key_prefix VARCHAR(16) NOT NULL,
user_role_id BIGINT NULL DEFAULT NULL,
last_used_at TIMESTAMP NULL DEFAULT NULL,
expires_at TIMESTAMP NULL DEFAULT NULL,
is_revoked TINYINT(1) NOT NULL DEFAULT 0,
created_at TIMESTAMP NULL DEFAULT NULL,
updated_at TIMESTAMP NULL DEFAULT NULL,
INDEX idx_api_keys_user_id (user_id),
INDEX idx_api_keys_key_hash (key_hash),
INDEX idx_api_keys_key_prefix (key_prefix)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci
");
}
/**
* down() method is prohibited in RSpade framework
* Migrations should only move forward, never backward
* You may remove this comment as soon as you see it and understand.
*/
};

View File

@@ -0,0 +1,48 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\DB;
return new class extends Migration
{
/**
* Run the migrations.
*
* IMPORTANT: Use raw MySQL queries for clarity and auditability
* DB::statement() with raw SQL
* Schema::create() with Blueprint
*
* REQUIRED: ALL tables MUST have: id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY
* No exceptions - every table needs this exact ID column (SIGNED for easier migrations)
*
* Integer types: Use BIGINT for all integers, TINYINT(1) for booleans only
* Never use unsigned - all integers should be signed
*
* Migrations must be self-contained - no Model/Service references
*
* @return void
*/
public function up()
{
DB::statement("
CREATE TABLE user_permissions (
id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY,
user_id BIGINT NOT NULL,
permission_id BIGINT NOT NULL,
is_grant TINYINT(1) NOT NULL DEFAULT 1,
created_at TIMESTAMP(3) NULL DEFAULT CURRENT_TIMESTAMP(3),
updated_at TIMESTAMP(3) NULL DEFAULT CURRENT_TIMESTAMP(3) ON UPDATE CURRENT_TIMESTAMP(3),
UNIQUE KEY uk_user_permission (user_id, permission_id),
INDEX idx_user_id (user_id),
INDEX idx_permission_id (permission_id),
CONSTRAINT fk_user_permissions_user FOREIGN KEY (user_id) REFERENCES users(id) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci
");
}
/**
* down() method is prohibited in RSpade framework
* Migrations should only move forward, never backward
* You may remove this comment as soon as you see it and understand.
*/
};

View File

@@ -0,0 +1,38 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\DB;
return new class extends Migration
{
/**
* Reindex user role_id values from sequential (1-7) to 100-based spacing.
* Also set user 1 to ROLE_DEVELOPER (100).
*
* Old New mapping:
* 1 (ROOT_ADMIN) 200
* 2 (SITE_OWNER) 300
* 3 (SITE_ADMIN) 400
* 4 (MANAGER) 500
* 5 (USER) 600
* 6 (VIEWER) 700
* 7 (DISABLED) 800
*
* @return void
*/
public function up()
{
// Update existing roles from old values to new 100-based values
// Process in reverse order to avoid collision (7→800 first, then 6→700, etc.)
DB::statement("UPDATE users SET role_id = 800 WHERE role_id = 7");
DB::statement("UPDATE users SET role_id = 700 WHERE role_id = 6");
DB::statement("UPDATE users SET role_id = 600 WHERE role_id = 5");
DB::statement("UPDATE users SET role_id = 500 WHERE role_id = 4");
DB::statement("UPDATE users SET role_id = 400 WHERE role_id = 3");
DB::statement("UPDATE users SET role_id = 300 WHERE role_id = 2");
DB::statement("UPDATE users SET role_id = 200 WHERE role_id = 1");
// Set user 1 to ROLE_DEVELOPER (100)
DB::statement("UPDATE users SET role_id = 100 WHERE id = 1");
}
};