mirror of
https://github.com/v2board/v2board.git
synced 2024-11-10 09:39:10 +08:00
update: remove v2ray alterid
This commit is contained in:
parent
54ea079d4d
commit
ab5fce51a1
@ -97,7 +97,7 @@ class Clash
|
|||||||
$array['server'] = $server['host'];
|
$array['server'] = $server['host'];
|
||||||
$array['port'] = $server['port'];
|
$array['port'] = $server['port'];
|
||||||
$array['uuid'] = $uuid;
|
$array['uuid'] = $uuid;
|
||||||
$array['alterId'] = $server['alter_id'];
|
$array['alterId'] = 0;
|
||||||
$array['cipher'] = 'auto';
|
$array['cipher'] = 'auto';
|
||||||
$array['udp'] = true;
|
$array['udp'] = true;
|
||||||
|
|
||||||
|
@ -54,7 +54,7 @@ class Passwall
|
|||||||
"add" => $server['host'],
|
"add" => $server['host'],
|
||||||
"port" => (string)$server['port'],
|
"port" => (string)$server['port'],
|
||||||
"id" => $uuid,
|
"id" => $uuid,
|
||||||
"aid" => (string)$server['alter_id'],
|
"aid" => '0',
|
||||||
"net" => $server['network'],
|
"net" => $server['network'],
|
||||||
"type" => "none",
|
"type" => "none",
|
||||||
"host" => "",
|
"host" => "",
|
||||||
|
@ -54,7 +54,7 @@ class SSRPlus
|
|||||||
"add" => $server['host'],
|
"add" => $server['host'],
|
||||||
"port" => (string)$server['port'],
|
"port" => (string)$server['port'],
|
||||||
"id" => $uuid,
|
"id" => $uuid,
|
||||||
"aid" => (string)$server['alter_id'],
|
"aid" => '0',
|
||||||
"net" => $server['network'],
|
"net" => $server['network'],
|
||||||
"type" => "none",
|
"type" => "none",
|
||||||
"host" => "",
|
"host" => "",
|
||||||
|
@ -58,7 +58,7 @@ class Shadowrocket
|
|||||||
$config = [
|
$config = [
|
||||||
'tfo' => 1,
|
'tfo' => 1,
|
||||||
'remark' => $server['name'],
|
'remark' => $server['name'],
|
||||||
'alterId' => $server['alter_id']
|
'alterId' => 0
|
||||||
];
|
];
|
||||||
if ($server['tls']) {
|
if ($server['tls']) {
|
||||||
$config['tls'] = 1;
|
$config['tls'] = 1;
|
||||||
|
@ -98,7 +98,7 @@ class Stash
|
|||||||
$array['server'] = $server['host'];
|
$array['server'] = $server['host'];
|
||||||
$array['port'] = $server['port'];
|
$array['port'] = $server['port'];
|
||||||
$array['uuid'] = $uuid;
|
$array['uuid'] = $uuid;
|
||||||
$array['alterId'] = $server['alter_id'];
|
$array['alterId'] = 0;
|
||||||
$array['cipher'] = 'auto';
|
$array['cipher'] = 'auto';
|
||||||
$array['udp'] = true;
|
$array['udp'] = true;
|
||||||
|
|
||||||
|
@ -54,7 +54,7 @@ class V2rayN
|
|||||||
"add" => $server['host'],
|
"add" => $server['host'],
|
||||||
"port" => (string)$server['port'],
|
"port" => (string)$server['port'],
|
||||||
"id" => $uuid,
|
"id" => $uuid,
|
||||||
"aid" => (string)$server['alter_id'],
|
"aid" => '0',
|
||||||
"net" => $server['network'],
|
"net" => $server['network'],
|
||||||
"type" => "none",
|
"type" => "none",
|
||||||
"host" => "",
|
"host" => "",
|
||||||
|
@ -54,7 +54,7 @@ class V2rayNG
|
|||||||
"add" => $server['host'],
|
"add" => $server['host'],
|
||||||
"port" => (string)$server['port'],
|
"port" => (string)$server['port'],
|
||||||
"id" => $uuid,
|
"id" => $uuid,
|
||||||
"aid" => (string)$server['alter_id'],
|
"aid" => '0',
|
||||||
"net" => $server['network'],
|
"net" => $server['network'],
|
||||||
"type" => "none",
|
"type" => "none",
|
||||||
"host" => "",
|
"host" => "",
|
||||||
|
@ -47,7 +47,7 @@ class DeepbworkController extends Controller
|
|||||||
$user->v2ray_user = [
|
$user->v2ray_user = [
|
||||||
"uuid" => $user->uuid,
|
"uuid" => $user->uuid,
|
||||||
"email" => sprintf("%s@v2board.user", $user->uuid),
|
"email" => sprintf("%s@v2board.user", $user->uuid),
|
||||||
"alter_id" => $server->alter_id,
|
"alter_id" => 0,
|
||||||
"level" => 0,
|
"level" => 0,
|
||||||
];
|
];
|
||||||
unset($user['uuid']);
|
unset($user['uuid']);
|
||||||
|
@ -13,6 +13,7 @@ use App\Models\ServerLog;
|
|||||||
use App\Models\User;
|
use App\Models\User;
|
||||||
|
|
||||||
use App\Utils\Helper;
|
use App\Utils\Helper;
|
||||||
|
use Illuminate\Support\Facades\DB;
|
||||||
|
|
||||||
class ServerController extends Controller
|
class ServerController extends Controller
|
||||||
{
|
{
|
||||||
@ -35,7 +36,15 @@ class ServerController extends Controller
|
|||||||
$type = $request->input('type') ? $request->input('type') : 0;
|
$type = $request->input('type') ? $request->input('type') : 0;
|
||||||
$current = $request->input('current') ? $request->input('current') : 1;
|
$current = $request->input('current') ? $request->input('current') : 1;
|
||||||
$pageSize = $request->input('pageSize') >= 10 ? $request->input('pageSize') : 10;
|
$pageSize = $request->input('pageSize') >= 10 ? $request->input('pageSize') : 10;
|
||||||
$serverLogModel = ServerLog::where('user_id', $request->session()->get('id'))
|
$serverLogModel = ServerLog::select([
|
||||||
|
DB::raw('sum(u) as u'),
|
||||||
|
DB::raw('sum(d) as d'),
|
||||||
|
'log_at',
|
||||||
|
'user_id',
|
||||||
|
'updated_at'
|
||||||
|
])
|
||||||
|
->where('user_id', $request->session()->get('id'))
|
||||||
|
->groupBy('log_at', 'user_id')
|
||||||
->orderBy('log_at', 'DESC');
|
->orderBy('log_at', 'DESC');
|
||||||
switch ($type) {
|
switch ($type) {
|
||||||
case 0:
|
case 0:
|
||||||
|
@ -24,7 +24,6 @@ class ServerV2raySave extends FormRequest
|
|||||||
'tls' => 'required',
|
'tls' => 'required',
|
||||||
'tags' => 'nullable|array',
|
'tags' => 'nullable|array',
|
||||||
'rate' => 'required|numeric',
|
'rate' => 'required|numeric',
|
||||||
'alter_id' => 'required|integer',
|
|
||||||
'network' => 'required|in:tcp,kcp,ws,http,domainsocket,quic,grpc',
|
'network' => 'required|in:tcp,kcp,ws,http,domainsocket,quic,grpc',
|
||||||
'networkSettings' => 'nullable|array',
|
'networkSettings' => 'nullable|array',
|
||||||
'ruleSettings' => 'nullable|array',
|
'ruleSettings' => 'nullable|array',
|
||||||
|
@ -237,5 +237,5 @@ return [
|
|||||||
| The only modification by laravel config
|
| The only modification by laravel config
|
||||||
|
|
|
|
||||||
*/
|
*/
|
||||||
'version' => '1.5.4.1640966110216'
|
'version' => '1.5.5.1641274817595'
|
||||||
];
|
];
|
||||||
|
@ -257,7 +257,6 @@ CREATE TABLE `v2_server_v2ray` (
|
|||||||
`tags` varchar(255) DEFAULT NULL,
|
`tags` varchar(255) DEFAULT NULL,
|
||||||
`rate` varchar(11) NOT NULL,
|
`rate` varchar(11) NOT NULL,
|
||||||
`network` text NOT NULL,
|
`network` text NOT NULL,
|
||||||
`alter_id` int(11) NOT NULL DEFAULT '1',
|
|
||||||
`settings` text,
|
`settings` text,
|
||||||
`rules` text,
|
`rules` text,
|
||||||
`networkSettings` text,
|
`networkSettings` text,
|
||||||
@ -370,4 +369,4 @@ CREATE TABLE `v2_user` (
|
|||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
|
||||||
-- 2021-12-27 17:37:09
|
-- 2022-01-04 05:39:52
|
||||||
|
@ -471,3 +471,6 @@ ALTER TABLE `v2_coupon`
|
|||||||
|
|
||||||
ALTER TABLE `v2_order`
|
ALTER TABLE `v2_order`
|
||||||
CHANGE `cycle` `period` varchar(255) COLLATE 'utf8_general_ci' NOT NULL AFTER `type`;
|
CHANGE `cycle` `period` varchar(255) COLLATE 'utf8_general_ci' NOT NULL AFTER `type`;
|
||||||
|
|
||||||
|
ALTER TABLE `v2_server_v2ray`
|
||||||
|
DROP `alter_id`;
|
||||||
|
2
public/assets/admin/components.async.js
vendored
2
public/assets/admin/components.async.js
vendored
File diff suppressed because one or more lines are too long
2
public/assets/admin/components.chunk.css
vendored
2
public/assets/admin/components.chunk.css
vendored
File diff suppressed because one or more lines are too long
2
public/assets/admin/umi.js
vendored
2
public/assets/admin/umi.js
vendored
File diff suppressed because one or more lines are too long
2
public/assets/admin/vendors.async.js
vendored
2
public/assets/admin/vendors.async.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user