Files
BeWoPlaner/BeWo/DebugConfig.cs

91 lines
2.4 KiB
C#
Raw Normal View History

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BeWo
{
public enum DebugConfigMode
{
SimpleAutoLogin,
2024-09-16 15:08:27 +02:00
FeatureCustomerWohnhilfe,
FeatureWohnheimWohneinheit,
FeatureAuswertungenQuittierungsbelege,
FeatureDakota
}
public class DebugConfig
{
private static DebugConfig _CurrentConfig;
public static DebugConfig CurrentConfig
{
get
{
#if DEBUG
2024-10-23 17:05:20 +02:00
return _CurrentConfig ?? (_CurrentConfig = null);
#endif
return null;
}
}
public DebugConfigMode DebugConfigMode { get; set; }
public bool AutoLogin { get; set; }
public UIContext? SelectView { get; set; }
2024-09-23 18:14:35 +02:00
/// <summary>
2024-09-25 13:35:24 +02:00
/// Beschreibt den Index der jeweils gewählten View (UIContext)
///
/// Z.b.:
2024-09-23 18:14:35 +02:00
/// Customer:
/// - Details: 0
/// - ...: 1
/// - ...: 2
/// - ...: 3
/// - VermittlungArbeit: 4
/// - Wohnhilfe: 5
/// </summary>
public int? SelectIndex { get; set; }
public static DebugConfig SimpleAutoLogin => new DebugConfig()
{
DebugConfigMode = DebugConfigMode.SimpleAutoLogin,
AutoLogin = true
};
2024-09-19 15:34:32 +02:00
public static DebugConfig Feature_Customer_Wohnhilfe => new DebugConfig()
{
2024-09-16 15:08:27 +02:00
DebugConfigMode = DebugConfigMode.FeatureCustomerWohnhilfe,
AutoLogin = true,
2024-09-23 18:14:35 +02:00
SelectView = UIContext.Customer,
SelectIndex = 5
};
2024-09-19 15:34:32 +02:00
public static DebugConfig Feature_Wohnheim_Wohneinheit => new DebugConfig()
2024-09-16 15:08:27 +02:00
{
DebugConfigMode = DebugConfigMode.FeatureWohnheimWohneinheit,
AutoLogin = true,
SelectView = UIContext.Wohnheim
};
public static DebugConfig FeatureAuswertungenQuittierungsbelege => new DebugConfig()
{
DebugConfigMode = DebugConfigMode.FeatureAuswertungenQuittierungsbelege,
AutoLogin = true,
SelectView = UIContext.Report
};
public static DebugConfig Feature_Dakota => new DebugConfig()
{
DebugConfigMode = DebugConfigMode.FeatureDakota,
AutoLogin = true,
SelectView = UIContext.Finance,
SelectIndex = 8
};
}
}