This commit is contained in:
aozhiwei 2023-08-09 16:59:39 +08:00
commit abdef7c7e0
3 changed files with 5 additions and 2 deletions

View File

@ -117,7 +117,7 @@ class Rankings {
recordsSort(sorted, records) { recordsSort(sorted, records) {
// 根据分数加入到排序表中 // 根据分数加入到排序表中
for (let element of records) { for (let element of records) {
if (element.score>BASE_SCORE) { if (element.score>=BASE_SCORE) {
if (sorted.length >= 10000){ if (sorted.length >= 10000){
if (element.score >= sorted[sorted.length - 1].score){ if (element.score >= sorted[sorted.length - 1].score){
this._recordsSort(sorted,element); this._recordsSort(sorted,element);

View File

@ -138,7 +138,7 @@ class Season {
// console.time("inserNewRecords"); // console.time("inserNewRecords");
for (let element of records) { for (let element of records) {
if (element.score>2800) { if (element.score>=2800) {
sorted.push(element); sorted.push(element);
sorted.sort(function(a,b) { sorted.sort(function(a,b) {
let r = b.score - a.score; let r = b.score - a.score;

View File

@ -926,6 +926,9 @@ class UserController extends BaseAuthedController {
if (SignLog::isSignRecord()){ if (SignLog::isSignRecord()){
//有签到记录 //有签到记录
$row = SignLog::find(); $row = SignLog::find();
if ($row['days'] == 7){
return;
}
$paramMeta = \mt\Parameter::getByName('sign_daily_duration'); $paramMeta = \mt\Parameter::getByName('sign_daily_duration');
$end_time = myself()->_getDaySeconds($row['createtime']) + $paramMeta['param_value']*24*60*60; $end_time = myself()->_getDaySeconds($row['createtime']) + $paramMeta['param_value']*24*60*60;
//判断当前时间是否结束 并且 上次签到是否领取 并且 签到时间是否满足第二天签到 //判断当前时间是否结束 并且 上次签到是否领取 并且 签到时间是否满足第二天签到