dd/app/Http/Controllers/Api/Nasa/V1/TestsFnSubfileController.php
2026-07-04 19:17:24 +08:00

89 lines
2.4 KiB
PHP
Executable File
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
declare(strict_types=1);
namespace App\Http\Controllers\Api\Nasa\V1;
use Illuminate\Http\Request;
use App\Http\Controllers\Api\Nasa\V1\Base\ListController;
final class TestsFnSubfileController extends ListController
{
protected string $sModelPath = 'App\Models\TestSubfile';
protected array $aFilterFields = [ // 允许where的字段不设视为全允许
// 's_name',
// 'i_status'
];
protected string $sPageName = "订阅文件状态";
protected array $aListFields = [ // list展示的字段和名字映射
'id' => 'id',
'site_code'=> 'site code',
'url' => [
'clash_url' => 'clash url',
'v2ray_url' => 'v2ray url',
'singbox_url' => 'singbox url'
],
'content' => [
'clash_content' => 'clash file',
'v2ray_content' => 'v2ray file',
'singbox_content' => 'singbox file'
],
'status_http_page' => '站点页面状态码',
'updated_at'=> '更新时间'
];
protected array $aFieldTypes = [
'clash_url' => 'copy',
'v2ray_url' => 'copy',
'singbox_url' => 'copy',
'clash_content' => 'copy-nick',
'v2ray_content' => 'copy-nick',
'singbox_content' => 'copy-nick'
];
protected array $aOrderBy = [
[
"sField" => "id",
"sSort" => "desc",
]
];
protected array $aValueStyle = [ // 特定文字渲染样式
'200' => "<span class='text-success'>200</span>",
];
protected array $aJsonFields = [ // json字段
];
protected array $aDateFields = [ // date字段
// 'dtUpdatedAt'
];
protected array $aLenthFields = [ // 限制长度的字段
// "xx" => 100,
];
protected array $aSelectFields = [ // 作为默认select的字段
// 'iStatus',
// 'sComponentType',
];
// protected array $aValueFields = [ // 值映射
// 'sComponentType' => [
// 'TOP_BAR' => '顶级菜单',
// 'SIDEBAR_MENU' => '次级菜单',
// 'INNER_PAGE_TAB' => '页内菜单',
// ]
// ];
protected array $aCcExtFields = [
// 'dtCreatedAt' => '创建时间'
];
// protected array $aLimit = [3, 15, 40, 100]; // list长度第一个为默认
}