Signed-off-by: Chaoscaot <chaoscaot444@gmail.com>
Dieser Commit ist enthalten in:
Ursprung
37f11e4723
Commit
1865342a00
@ -81,7 +81,9 @@ public class Schematic {
|
||||
public static List<Schematic> getSchemsAccessibleByUser(int schemOwner){
|
||||
List<Schematic> schematics = new ArrayList<>();
|
||||
SchematicNode.getSchematicsAccessibleByUser(schemOwner, null)
|
||||
.forEach(node1 -> schematics.add(new Schematic(node1)));
|
||||
.forEach(node1 -> {
|
||||
if (!node1.isDir()) schematics.add(new Schematic(node1));
|
||||
});
|
||||
return schematics;
|
||||
}
|
||||
|
||||
@ -92,7 +94,9 @@ public class Schematic {
|
||||
public static List<Schematic> getSchemsOfType(int schemOwner, SchematicType schemType){
|
||||
List<Schematic> schematics = new ArrayList<>();
|
||||
SchematicNode.getSchematicsOfType(schemOwner, schemType.toDB(), null)
|
||||
.forEach(node1 -> schematics.add(new Schematic(node1)));
|
||||
.forEach(node1 -> {
|
||||
if (!node1.isDir()) schematics.add(new Schematic(node1));
|
||||
});
|
||||
return schematics;
|
||||
}
|
||||
|
||||
|
@ -186,7 +186,7 @@ public class SchematicNode {
|
||||
|
||||
public static List<SchematicNode> getSchematicsOfType(int owner, String schemType, Integer parent) {
|
||||
List<SchematicNode> schems = getAllSchematicsAccessibleByUser(owner);
|
||||
schems.removeIf(node -> !node.getType().equals(schemType));
|
||||
schems.removeIf(node -> node.isDir() || !node.getType().equals(schemType));
|
||||
Map<Integer, SchematicNode> nodesInParent = new LinkedHashMap<>();
|
||||
for (SchematicNode schematicNode : schems) {
|
||||
SchematicNode currentNode = schematicNode;
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren