Merge remote-tracking branch 'origin/tmp_cls' into dev
This commit is contained in:
commit
4b021a5bdf
4 changed files with 34 additions and 21 deletions
|
|
@ -21,6 +21,7 @@ import ru.spcex.clearing.platform.messaging.service.sender.KafkaSender;
|
|||
import ru.spcex.clearing.service.executors.AbstractExecutor;
|
||||
import ru.spcex.clearing.service.executors.Reviser;
|
||||
import ru.spcex.clearing.service.model.Result;
|
||||
import ru.spcex.clearing.statement.StatementServiceV2;
|
||||
import ru.spcex.platform.classes.base.SpcexObjectBase;
|
||||
import ru.spcex.platform.enumeration.ObjectType;
|
||||
import ru.spcex.platform.enumeration.Priority;
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ public enum TaskType implements IEnumKey {
|
|||
*/
|
||||
StartRevise("CLR0"),
|
||||
ContinueRevise("CLR 0_0"),
|
||||
StartRevisePart1("CLR 0_9"),
|
||||
StartRevisePart1("С0_1"),
|
||||
|
||||
/**
|
||||
* step 1
|
||||
|
|
|
|||
|
|
@ -0,0 +1,30 @@
|
|||
package ru.spcex.clearing.statement;
|
||||
|
||||
import ru.spcex.platform.enumeration.SdfTable;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
public enum SdfGroup {
|
||||
Sdf01And57(SdfTable.SDF_01, SdfTable.SDF_57),
|
||||
// Triple(SdfTable.SDF_04, SdfTable.SDF_01, SdfTable.SDF_57),
|
||||
// Quad(SdfTable.SDF_04, SdfTable.SDF_13, SdfTable.SDF_01, SdfTable.SDF_57),
|
||||
Sdf08And21(SdfTable.SDF_08, SdfTable.SDF_21);
|
||||
private final Collection<SdfTable> group;
|
||||
|
||||
SdfGroup(SdfTable... group) {
|
||||
this.group = List.of(group);
|
||||
}
|
||||
|
||||
public Collection<SdfTable> getGroup() {
|
||||
return group;
|
||||
}
|
||||
|
||||
public static Optional<SdfGroup> groupByTable(SdfTable t) {
|
||||
return Arrays.stream(SdfGroup.values())
|
||||
.filter(g -> g.getGroup().contains(t))
|
||||
.findFirst();
|
||||
}
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package ru.spcex.clearing.service;
|
||||
package ru.spcex.clearing.statement;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
|
@ -11,6 +11,7 @@ import ru.spcex.clearing.platform.messaging.domain.Consts;
|
|||
import ru.spcex.clearing.platform.messaging.domain.cud.account.sdf01.AccountSdf01Request;
|
||||
import ru.spcex.clearing.platform.messaging.domain.cud.balance.StatementRequest;
|
||||
import ru.spcex.clearing.platform.messaging.service.sender.KafkaSender;
|
||||
import ru.spcex.clearing.service.StatementService;
|
||||
import ru.spcex.clearing.service.executors.*;
|
||||
import ru.spcex.clearing.service.model.Result;
|
||||
import ru.spcex.platform.enumeration.SdfTable;
|
||||
|
|
@ -177,23 +178,4 @@ public class StatementServiceV2 {
|
|||
}
|
||||
}
|
||||
|
||||
private enum SdfGroup {
|
||||
Sdf01And57(SdfTable.SDF_01, SdfTable.SDF_57),
|
||||
Sdf08And21(SdfTable.SDF_08, SdfTable.SDF_21);
|
||||
private final Collection<SdfTable> group;
|
||||
|
||||
SdfGroup(SdfTable... group) {
|
||||
this.group = List.of(group);
|
||||
}
|
||||
|
||||
public Collection<SdfTable> getGroup() {
|
||||
return group;
|
||||
}
|
||||
|
||||
public static Optional<SdfGroup> groupByTable(SdfTable t) {
|
||||
return Arrays.stream(SdfGroup.values())
|
||||
.filter(g -> g.getGroup().contains(t))
|
||||
.findFirst();
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Reference in a new issue