mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2024-11-03 01:10:17 +01:00
Fixed an ActivityIndex query
This commit is contained in:
parent
ad7f8c5631
commit
4ff86347b0
@ -202,10 +202,10 @@ public class ActivityIndexQueries {
|
||||
public void prepare(PreparedStatement statement) throws SQLException {
|
||||
setSelectActivityIndexSQLParameters(statement, 1, threshold, serverUUID, end);
|
||||
setSelectActivityIndexSQLParameters(statement, 12, threshold, serverUUID, start);
|
||||
statement.setDouble(22, ActivityIndex.REGULAR);
|
||||
statement.setDouble(23, 5.1);
|
||||
statement.setDouble(24, -0.1);
|
||||
statement.setDouble(25, ActivityIndex.IRREGULAR);
|
||||
statement.setDouble(23, ActivityIndex.REGULAR);
|
||||
statement.setDouble(24, 5.1);
|
||||
statement.setDouble(25, -0.1);
|
||||
statement.setDouble(26, ActivityIndex.IRREGULAR);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -33,6 +33,7 @@ import com.djrapitops.plan.data.time.WorldTimes;
|
||||
import com.djrapitops.plan.db.access.Executable;
|
||||
import com.djrapitops.plan.db.access.Query;
|
||||
import com.djrapitops.plan.db.access.queries.*;
|
||||
import com.djrapitops.plan.db.access.queries.analysis.ActivityIndexQueries;
|
||||
import com.djrapitops.plan.db.access.queries.containers.AllPlayerContainersQuery;
|
||||
import com.djrapitops.plan.db.access.queries.containers.ContainerFetchQueries;
|
||||
import com.djrapitops.plan.db.access.queries.containers.ServerPlayerContainersQuery;
|
||||
@ -1392,6 +1393,15 @@ public interface DatabaseTest {
|
||||
assertEquals(expected.parseHtml(), table.getHtmlTable().parseHtml());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void activeTunredInactiveQueryHasAllParametersSet() {
|
||||
Integer result = db.query(ActivityIndexQueries.countRegularPlayersTurnedInactive(
|
||||
0, System.currentTimeMillis(), serverUUID,
|
||||
TimeUnit.HOURS.toMillis(2L)
|
||||
));
|
||||
assertNotNull(result);
|
||||
}
|
||||
|
||||
@PluginInfo(name = "ConditionalExtension")
|
||||
class ConditionalExtension implements DataExtension {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user