Skip to content

Formatting CI + csharpier#192

Draft
JohannHoepfner wants to merge 4 commits intomainfrom
formatting
Draft

Formatting CI + csharpier#192
JohannHoepfner wants to merge 4 commits intomainfrom
formatting

Conversation

@JohannHoepfner
Copy link
Copy Markdown
Member

@JohannHoepfner JohannHoepfner commented Feb 3, 2026

TODO

  • Editorconfig nach unseren Vorstellungen
  • Evtl ci format workflows jeweils mit build mergen.

blocksInFutureWithoutEnrollments,
wochentyp
);
foreach (var (_, angebote) in angeboteByBlocks)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was will der hier? angebote wird genutzt und _ ist ein Discard

Comment thread Backend/Altafraner.AfraApp/Otium/Services/RulesValidationService.cs Dismissed
Comment on lines +322 to +332
foreach (var angebot in instanzen)
{
var belegWunsch = new ProfundumBelegWunsch
{
var belegWunsch = new ProfundumBelegWunsch
{
BetroffenePerson = student,
ProfundumInstanz = angebot,
Stufe = stufe,
EinwahlZeitraum = einschreibeZeitraum,
};
belegWuensche.Add(belegWunsch);
}
BetroffenePerson = student,
ProfundumInstanz = angebot,
Stufe = stufe,
EinwahlZeitraum = einschreibeZeitraum,
};
belegWuensche.Add(belegWunsch);
}
@JohannHoepfner JohannHoepfner changed the title Formatting CI + charpier Formatting CI + csharpier Feb 3, 2026
Copy link
Copy Markdown
Member

@rschlossarek rschlossarek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ich hab mal beispielhaft ein paar Dinge markiert, die mich stören. Allgemeines kommt später

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Können wir automatisch generierte Dateien, wie Migrations, bitte von Formatierungen ausschließen?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ich sehe den Grund nicht unbedingt, aber ja.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Man könnte die auch beim Generieren direkt formattieren lassen.

UserService userService,
UserAuthorizationHelper authHelper,
Guid studentId,
bool all = false)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Diese Art Änderung ist so unnötig..

await authHelper.CurrentUserHasGlobalPermission(GlobalPermission.Otiumsverantwortlich)
|| await authHelper.CurrentUserHasGlobalPermission(GlobalPermission.Admin);

if (!isMentor && !hasBypass) return Results.Unauthorized();
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Und die Art Änderung sehe ich auch irgendwie nicht ganz ein, das liegt aber im Diskussionsspielraum

var today = DateOnly.FromDateTime(now);
var time = TimeOnly.FromDateTime(now);

if (!metadata.Verpflichtend || block.SchultagKey != today || time >= metadata.Interval.Start.AddMinutes(30))
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

können wir hier die erste Zeile direkt hinter das if schreiben und die letzte Klammer mit zur letzten Zeile?

if (await scheduler.CheckExists(jobKey))
return;

var job = JobBuilder.Create<MissingStudentNotificationJob>()
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sehr unnötig..

.Include(t => t.Block)
.Include(t => t.Otium)
.Where(t => t.Block.Id == termin.Block.Id && t.Id != terminId)
.OrderBy(t => t.OverrideBezeichnung != null ? t.OverrideBezeichnung : t.Otium.Bezeichnung)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also irgendwie gefällt mir das auch nicht, aber kann verstehen, dass er die Zeile kürzer haben will

.FirstOrDefaultAsync();

var blockId = fromBlock?.Id ?? toData?.Block.Id;
if ((fromBlock is null && fromTerminId != Guid.Empty) || (toData is null && toTerminId != Guid.Empty))
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also zwei Zeilen okay, aber vier??

blocksInFutureWithoutEnrollments,
wochentyp
);
foreach (var (_, angebote) in angeboteByBlocks)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was will der hier? angebote wird genutzt und _ ist ein Discard

Comment thread Backend/Altafraner.AfraApp/Otium/Services/RulesValidationService.cs Dismissed
: base(message)
{
}
: base(message) { }
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Das mag meine IDE gar nicht, kann ich der aber evtl. austreiben

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants