Skip to content

Commit

Permalink
release 0.12.0
Browse files Browse the repository at this point in the history
  • Loading branch information
olavhinz committed Nov 25, 2024
1 parent b901b5a commit 15add44
Show file tree
Hide file tree
Showing 40 changed files with 952 additions and 1,141 deletions.
6 changes: 3 additions & 3 deletions Sources/SolutionInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersion("0.10.2.0")]
[assembly: AssemblyFileVersion("0.10.2.0")]
[assembly: AssemblyInformationalVersion("0.10.2")]
[assembly: AssemblyVersion("0.12.0.0")]
[assembly: AssemblyFileVersion("0.12.0.0")]
[assembly: AssemblyInformationalVersion("0.12.0")]
2 changes: 1 addition & 1 deletion Sources/TimeTable/MyStik.TimeTable.Data/ExaminationUnit.cs
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public string OptionName
{
foreach (var fraction in Fractions)
{
if (Fractions != Fractions.Last())
if (fraction != Fractions.Last())
{
sb.AppendFormat("{0} {1:P0} und ", fraction.Form.ShortName, fraction.Weight);
}
Expand Down
35 changes: 35 additions & 0 deletions Sources/TimeTable/MyStik.TimeTable.Data/ModuleSubject.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text;

namespace MyStik.TimeTable.Data
{
Expand Down Expand Up @@ -62,6 +63,40 @@ public ModuleSubject()

public string FullTag => $"{Module.FullTag}#{Tag}";

public string FullName
{
get
{
var sb = new StringBuilder();

if (TeachingFormat != null)
{
if (!string.IsNullOrEmpty(Name))
{
sb.AppendFormat("{0} | {1} | {2} SWS", Name, TeachingFormat.Tag, SWS);
}
else
{
sb.AppendFormat("{0} | {1} SWS", TeachingFormat.Tag, SWS);
}
}
else
{
if (!string.IsNullOrEmpty(Name))
{
sb.AppendFormat("{0} | {1} SWS", Name, SWS);
}
else
{
sb.AppendFormat("LV | {0} SWS", SWS);
}
}

return sb.ToString();

}
}

/// <summary>
/// Das zugehörige Modul
/// </summary>
Expand Down
38 changes: 38 additions & 0 deletions Sources/TimeTable/MyStik.TimeTable.Data/Occurrence.cs
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,8 @@ public string Summary
{
foreach (var fraction in Fractions)
{
sb.Append(fraction.FullName);
/*
if (fraction.Curriculum != null)
{
sb.Append(fraction.Curriculum.ShortName);
Expand All @@ -191,6 +193,7 @@ public string Summary
{
sb.Append("offen für alle Studiengänge");
}
*/
if (fraction != Fractions.Last())
{
sb.Append(" oder ");
Expand Down Expand Up @@ -234,6 +237,41 @@ public class SeatQuotaFraction
/// Und Verknüpfung
/// </summary>
public virtual ItemLabelSet ItemLabelSet { get; set; }

public string FullName
{
get
{
var sb = new StringBuilder();

if (Curriculum != null)
{
sb.Append(Curriculum.ShortName);
}
else
{
sb.Append("Offen für alle Studiengänge");
}

if (ItemLabelSet?.ItemLabels != null && ItemLabelSet.ItemLabels.Any())
{
sb.Append(" mit Kohorte(n): ");
foreach (var label in ItemLabelSet.ItemLabels)
{
if (label != ItemLabelSet.ItemLabels.Last())
{
sb.AppendFormat("{0}, ", label.Name);
}
else
{
sb.AppendFormat("{0}", label.Name);
}
}
}

return sb.ToString();
}
}
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,6 @@ public QuotaCheckResponse IsAvailable(SeatQuota quota, Curriculum curr, ICollect
return checkLabelSet;
}
}

result.Remark = "Fehlerhaftes Kontingent";
return result;
}

private QuotaCheckResponse CheckLabelSet(ItemLabelSet labelSet, ICollection<ItemLabel> labels)
Expand Down
Loading

0 comments on commit 15add44

Please sign in to comment.