1.0.6
Funktioniert nicht mehr unter Windows ...
This commit is contained in:
@@ -109,8 +109,8 @@ internal static class BaseFunc {
|
||||
internal static async Task SaveItemAsync(string url, string token, DayTime item, bool isNewItem = false) {
|
||||
|
||||
|
||||
//Uhrzeiten sollten sinnvolle Werte haben
|
||||
if (item.TimeSpanVon == item.TimeSpanBis) {
|
||||
//Uhrzeiten sollten sinnvolle Werte haben - außer bei Freistellungen, da wäre eigentlich null
|
||||
if (item.TimeSpanVon == item.TimeSpanBis && item.FreistellungAktiv == null) {
|
||||
throw new Exception("Beginn und Ende sind gleich");
|
||||
}
|
||||
|
||||
@@ -134,9 +134,13 @@ internal static class BaseFunc {
|
||||
throw new Exception("Projekt nicht gewählt");
|
||||
}
|
||||
//Keine Beschreibung
|
||||
if (string.IsNullOrEmpty(item.Description)) {
|
||||
if (string.IsNullOrEmpty(item.Description) && item.FreistellungAktiv == null) {
|
||||
throw new Exception("Keine Beschreibung");
|
||||
}
|
||||
//Keine Beschreibung
|
||||
if (string.IsNullOrEmpty(item.Description)) {
|
||||
item.Description = item.FreistellungAktiv.Name;
|
||||
}
|
||||
using (HttpClient client = new HttpClient() { Timeout = TimeSpan.FromSeconds(15) }) {
|
||||
//HttpClient client = new HttpClient();
|
||||
client.DefaultRequestHeaders.Add("Accept", "application/json");
|
||||
|
||||
Reference in New Issue
Block a user