This commit is contained in:
root 2019-11-23 22:25:06 +08:00
parent fd2ffd8374
commit 7683ddc6e0
2 changed files with 6 additions and 3 deletions

View File

@ -41,7 +41,7 @@ class CheckExpire extends Command
{
$user = User::all();
foreach ($user as $item) {
if ($item->expired_at < time()) {
if ($item->expired_at < time() || $item->u + $item->d >= $item->transfer_enable) {
$item->enable = 0;
} else {
$item->enable = 1;

View File

@ -4,6 +4,9 @@ ALTER TABLE `v2_server`
ADD `network` varchar(11) COLLATE 'utf8_general_ci' NOT NULL AFTER `rate`;
ALTER TABLE `v2_server`
ADD `settings` text COLLATE 'utf8_general_ci' NULL AFTER `network`;
/* 2019-11-18 18:14:11 */
/* 2019-11-18 */
ALTER TABLE `v2_server`
ADD `show` tinyint(1) NOT NULL DEFAULT '0' AFTER `settings`;
ADD `show` tinyint(1) NOT NULL DEFAULT '0' AFTER `settings`;
/* 2019-11-23 */
ALTER TABLE `v2_user`
CHANGE `enable` `enable` tinyint(1) NOT NULL DEFAULT '1' AFTER `transfer_enable`;