Browse Source

刷数据v2,利好修改

master
nili 2 months ago
parent
commit
5d9a04817d
  1. 9
      game-service/src/main/java/awesome/group/game/service/matrix/SuperAdminService.java

9
game-service/src/main/java/awesome/group/game/service/matrix/SuperAdminService.java

@ -157,7 +157,7 @@ public class SuperAdminService {
mockScheduleV2Mapper.insertBatch(list);
}
@Scheduled(cron = "0 * * * * ?")
@Scheduled(cron = "0 */2 * * * ?")
public void mockSchedule() {
LambdaQueryWrapper<MatrixMockScheduleV2> queryWrapper = Wrappers.lambdaQuery();
queryWrapper.le(MatrixMockScheduleV2::getScheduleTime, new Timestamp(System.currentTimeMillis()));
@ -191,6 +191,10 @@ public class SuperAdminService {
MatrixAdvRecord record = advRecordMapper.queryByUid(uid);
long ecpm = 3000_00 + random.nextInt(2000_00);
MatrixApp app = appMapper.selectById(schedule.getAppId());
if ("lihao".equals(app.getChannel())) {
ecpm = 5000_00 + random.nextInt(3000_00);
}
MatrixUser u = userMapper.selectById(uid);
AppNormalConfig config = AppNormalConfig.getConfig(app);
long ecpmReal = config.getEcpmReal(ecpm, u);
@ -200,6 +204,9 @@ public class SuperAdminService {
newRecord.setAppId(schedule.getAppId());
newRecord.setAdvId(null);
newRecord.setPlatform(2);
if ("lihao".equals(app.getChannel())) {
newRecord.setPlatform(5);
}
newRecord.setAdvType(Constants.VIDEO);
newRecord.setEcpm(ecpm);
newRecord.setEcpmReal(ecpmReal);

Loading…
Cancel
Save