mirror of
https://github.com/bvanroll/cs-oo-project.git
synced 2025-08-29 12:02:40 +00:00
voila
This commit is contained in:
52
Online Gokkantoor/ClassLibrary1/General.cs
Normal file
52
Online Gokkantoor/ClassLibrary1/General.cs
Normal file
@@ -0,0 +1,52 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Logic
|
||||
{
|
||||
public class General
|
||||
{
|
||||
/*
|
||||
bijna alle berekeningen voor het prorgamma gaan uit deze klasse komen
|
||||
|
||||
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/* hier komen de wedstrijden en zo die je inlaad*/
|
||||
public List<Wedstrijden> wedstrijden { get; set; }
|
||||
public List<Persoon> personen { get; set; }
|
||||
public List<Keuze> keuzes { get; set; }
|
||||
public enum Gokken { ThuisPloeg, Gelijk, Uitploeg }
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
door gebruik van deze klassen kan je bekijken welk team gewonnen heeft en
|
||||
door gebruik van keuze kan je zien hoeveel de persoon met id x ingezet heeft en zo de winst berekenen.
|
||||
*/
|
||||
|
||||
public double Winst(int wedstrijdID, int persoonID, int keuzeID)
|
||||
{
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
/*
|
||||
deze functie haalt een persoon uit de lijst van personen met de juiste id, best ook mss maken voor een wedstrijd en een keuze, gewoon voor gemak later.
|
||||
*/
|
||||
|
||||
public Persoon GetPersoonById(int id)
|
||||
{
|
||||
return new Persoon();
|
||||
}
|
||||
|
||||
public void OnLoad()
|
||||
{
|
||||
wedstrijden = Laad_Wedstrijden();
|
||||
}
|
||||
}
|
||||
}
|
19
Online Gokkantoor/ClassLibrary1/Keuze.cs
Normal file
19
Online Gokkantoor/ClassLibrary1/Keuze.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using static Logic.General;
|
||||
|
||||
namespace Logic
|
||||
{
|
||||
public class Keuze
|
||||
{
|
||||
|
||||
public int Match_ID { get; set; }
|
||||
public int Speler_ID { get; set; }
|
||||
public double Inzet { get; set; }
|
||||
public Gokken Gok { get; set; } // thuis uit of gelijk
|
||||
|
||||
}
|
||||
}
|
7
Online Gokkantoor/ClassLibrary1/Logic.csproj
Normal file
7
Online Gokkantoor/ClassLibrary1/Logic.csproj
Normal file
@@ -0,0 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netstandard1.4</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
</Project>
|
23
Online Gokkantoor/ClassLibrary1/Persoon.cs
Normal file
23
Online Gokkantoor/ClassLibrary1/Persoon.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using static Logic.General;
|
||||
|
||||
namespace Logic
|
||||
{
|
||||
public class Persoon
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Voornaam { get; set; }
|
||||
public string Naam { get; set; }
|
||||
public string Adres { get; set; }
|
||||
public string Gsm { get; set; }
|
||||
public double Balans { get; set; }
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
32
Online Gokkantoor/ClassLibrary1/Wedstrijden.cs
Normal file
32
Online Gokkantoor/ClassLibrary1/Wedstrijden.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using static Logic.General;
|
||||
|
||||
namespace Logic
|
||||
{
|
||||
public class Wedstrijden
|
||||
{
|
||||
public int Wedstrijd_ID { get; set; }
|
||||
public string ThuisPloeg { get; set; }
|
||||
public string UitPloeg { get; set; }
|
||||
public int Score_ThuisPloeg { get; set; }
|
||||
public int Score_UitPloeg { get; set; }
|
||||
|
||||
public Gokken Winnaar()
|
||||
{
|
||||
if(Score_ThuisPloeg > Score_UitPloeg)
|
||||
{
|
||||
return Gokken.ThuisPloeg;
|
||||
}else if(Score_UitPloeg > Score_ThuisPloeg)
|
||||
{
|
||||
return Gokken.Uitploeg;
|
||||
}
|
||||
else
|
||||
{
|
||||
return Gokken.Gelijk;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
6
Online Gokkantoor/Console/App.config
Normal file
6
Online Gokkantoor/Console/App.config
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
</configuration>
|
53
Online Gokkantoor/Console/ConsoleApp.csproj
Normal file
53
Online Gokkantoor/Console/ConsoleApp.csproj
Normal file
@@ -0,0 +1,53 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{75E1DDD1-C2F0-4C29-A95A-85A72D8C4948}</ProjectGuid>
|
||||
<OutputType>Exe</OutputType>
|
||||
<RootNamespace>Console</RootNamespace>
|
||||
<AssemblyName>Console</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||
<Deterministic>true</Deterministic>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
20
Online Gokkantoor/Console/Program.cs
Normal file
20
Online Gokkantoor/Console/Program.cs
Normal file
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace ConsoleApp
|
||||
{
|
||||
class Program
|
||||
{
|
||||
static void Main(string[] args)
|
||||
{
|
||||
Console.WriteLine("Online Gokkantoor heet u welkom");
|
||||
|
||||
// Keep the console window open in debug mode.
|
||||
Console.WriteLine("Druk op eender welke toets om af te sluiten.");
|
||||
Console.ReadKey();
|
||||
}
|
||||
}
|
||||
}
|
36
Online Gokkantoor/Console/Properties/AssemblyInfo.cs
Normal file
36
Online Gokkantoor/Console/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Console")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("Console")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2018")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("75e1ddd1-c2f0-4c29-a95a-85a72d8c4948")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
66
Online Gokkantoor/DataLaag/DataLaag.csproj
Normal file
66
Online Gokkantoor/DataLaag/DataLaag.csproj
Normal file
@@ -0,0 +1,66 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{CA62D8EA-2739-4C85-81B4-FBA040592DAE}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>DataLaag</RootNamespace>
|
||||
<AssemblyName>DataLaag</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<Deterministic>true</Deterministic>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Newtonsoft.Json.11.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Enums.cs" />
|
||||
<Compile Include="Interfaces\IFKeuze.cs" />
|
||||
<Compile Include="Interfaces\IFPersoon.cs" />
|
||||
<Compile Include="Interfaces\IFWedstrijden.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="Gegevens\Keuzes.json">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
<None Include="packages.config" />
|
||||
<Content Include="Gegevens\Personen.json">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
<Content Include="Gegevens\Wedstrijden.json">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
13
Online Gokkantoor/DataLaag/Enums.cs
Normal file
13
Online Gokkantoor/DataLaag/Enums.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DataLaag
|
||||
{
|
||||
public class Enums
|
||||
{
|
||||
public enum Gokken { Uitploeg, Gelijk, Thuisploeg}
|
||||
}
|
||||
}
|
1
Online Gokkantoor/DataLaag/Gegevens/Keuzes.json
Normal file
1
Online Gokkantoor/DataLaag/Gegevens/Keuzes.json
Normal file
@@ -0,0 +1 @@
|
||||
[{"match_ID":128,"speler_ID":1,"inzet":0.15,"gok":2},{"match_ID":128,"speler_ID":1,"inzet":0.15,"gok":2},{"match_ID":128,"speler_ID":1,"inzet":0.15,"gok":2},{"match_ID":128,"speler_ID":1,"inzet":0.15,"gok":2},{"match_ID":128,"speler_ID":2,"inzet":500.0,"gok":0},{"match_ID":128,"speler_ID":2,"inzet":400.0,"gok":1},{"match_ID":128,"speler_ID":2,"inzet":200.0,"gok":2},{"match_ID":128,"speler_ID":2,"inzet":200.0,"gok":1},{"match_ID":128,"speler_ID":2,"inzet":200.0,"gok":0},{"match_ID":128,"speler_ID":2,"inzet":500.0,"gok":0},{"match_ID":128,"speler_ID":2,"inzet":500.0,"gok":1},{"match_ID":128,"speler_ID":2,"inzet":500.0,"gok":2}]
|
1
Online Gokkantoor/DataLaag/Gegevens/Personen.json
Normal file
1
Online Gokkantoor/DataLaag/Gegevens/Personen.json
Normal file
@@ -0,0 +1 @@
|
||||
[{"persoon_ID":0,"voorNaam":"VOORBEELD","naam":"NAAM","adres":"STRAAT","gsm":"GSM","balans":0.0},{"persoon_ID":0,"voorNaam":"john","naam":"doe","adres":"street","gsm":"048765656565","balans":0.15},{"persoon_ID":0,"voorNaam":"john","naam":"doe","adres":"street","gsm":"048765656565","balans":0.15},{"persoon_ID":1,"voorNaam":"john","naam":"doe","adres":"street","gsm":"048765656565","balans":0.15},{"persoon_ID":2,"voorNaam":"fg","naam":"fg","adres":"fgfg","gsm":"fg","balans":0.0},{"persoon_ID":1,"voorNaam":"john","naam":"doe","adres":"street","gsm":"048765656565","balans":0.15},{"persoon_ID":2,"voorNaam":"Michiel","naam":"VD","adres":"JUP","gsm":"FLEX","balans":0.0},{"persoon_ID":3,"voorNaam":"jef","naam":"Basil","adres":"fdf","gsm":"dfddf","balans":0.0}]
|
1
Online Gokkantoor/DataLaag/Gegevens/Wedstrijden.json
Normal file
1
Online Gokkantoor/DataLaag/Gegevens/Wedstrijden.json
Normal file
@@ -0,0 +1 @@
|
||||
[{"wedstrijd_ID":128,"thuisPloeg":"Belgie","uitPloeg":"Polen","score_ThuisPloeg":1,"score_UitPloeg":0,"geldThuisPloeg":2.6,"geldGelijk":2.0,"geldUitPloeg":1.6},{"wedstrijd_ID":129,"thuisPloeg":"Anderlecht","uitPloeg":"Brugge","score_ThuisPloeg":1,"score_UitPloeg":0,"geldThuisPloeg":1.4,"geldGelijk":1.8,"geldUitPloeg":3.0},{"wedstrijd_ID":130,"thuisPloeg":"Dender","uitPloeg":"Aalst","score_ThuisPloeg":1,"score_UitPloeg":0,"geldThuisPloeg":2.3,"geldGelijk":1.5,"geldUitPloeg":1.9},{"wedstrijd_ID":131,"thuisPloeg":"Gent","uitPloeg":"Genk","score_ThuisPloeg":1,"score_UitPloeg":0,"geldThuisPloeg":5.0,"geldGelijk":1.0,"geldUitPloeg":2.0},{"wedstrijd_ID":132,"thuisPloeg":"Belgie","uitPloeg":"Polen","score_ThuisPloeg":1,"score_UitPloeg":0,"geldThuisPloeg":6.0,"geldGelijk":1.8,"geldUitPloeg":1.6}]
|
17
Online Gokkantoor/DataLaag/Interfaces/IFKeuze.cs
Normal file
17
Online Gokkantoor/DataLaag/Interfaces/IFKeuze.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using static DataLaag.Enums;
|
||||
|
||||
namespace DataLaag.Interfaces
|
||||
{
|
||||
public interface IFKeuze
|
||||
{
|
||||
int match_ID { get; set; }
|
||||
int speler_ID { get; set; }
|
||||
double inzet { get; set; }
|
||||
Gokken gok { get; set; }
|
||||
}
|
||||
}
|
18
Online Gokkantoor/DataLaag/Interfaces/IFPersoon.cs
Normal file
18
Online Gokkantoor/DataLaag/Interfaces/IFPersoon.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DataLaag.Interfaces
|
||||
{
|
||||
public interface IFPersoon
|
||||
{
|
||||
int persoon_ID { get; set; }
|
||||
string voorNaam { get; set; }
|
||||
string naam { get; set; }
|
||||
string adres { get; set; }
|
||||
string gsm { get; set; }
|
||||
double balans { get; set; }
|
||||
}
|
||||
}
|
19
Online Gokkantoor/DataLaag/Interfaces/IFWedstrijden.cs
Normal file
19
Online Gokkantoor/DataLaag/Interfaces/IFWedstrijden.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using static DataLaag.Enums;
|
||||
|
||||
namespace DataLaag.Interfaces
|
||||
{
|
||||
public interface IFWedstrijden
|
||||
{
|
||||
int wedstrijd_ID { get; set; }
|
||||
string thuisPloeg { get; set; }
|
||||
string uitPloeg { get; set; }
|
||||
int score_ThuisPloeg { get; set; }
|
||||
int score_UitPloeg { get; set; }
|
||||
Gokken GetWinnaar();
|
||||
}
|
||||
}
|
36
Online Gokkantoor/DataLaag/Properties/AssemblyInfo.cs
Normal file
36
Online Gokkantoor/DataLaag/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("DataLaag")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("DataLaag")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2018")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("ca62d8ea-2739-4c85-81b4-fba040592dae")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
4
Online Gokkantoor/DataLaag/packages.config
Normal file
4
Online Gokkantoor/DataLaag/packages.config
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="Newtonsoft.Json" version="11.0.2" targetFramework="net461" />
|
||||
</packages>
|
241
Online Gokkantoor/LogicLayer/General.cs
Normal file
241
Online Gokkantoor/LogicLayer/General.cs
Normal file
@@ -0,0 +1,241 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using DataLaag;
|
||||
using DataLaag.Interfaces;
|
||||
using Newtonsoft.Json;
|
||||
using static DataLaag.Enums;
|
||||
|
||||
namespace LogicLayer
|
||||
{
|
||||
public class General
|
||||
{
|
||||
public List<Wedstrijden> wedstrijden { get; set; }
|
||||
public List<Persoon> personen { get; set; }
|
||||
public List<Keuze> keuzes { get; set; }
|
||||
|
||||
public General()
|
||||
{
|
||||
wedstrijden = new List<Wedstrijden>();
|
||||
try
|
||||
{
|
||||
personen = new List<Persoon>();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
throw new Exception("" + ex);
|
||||
}
|
||||
try
|
||||
{
|
||||
keuzes = new List<Keuze>();
|
||||
}catch (Exception e)
|
||||
{
|
||||
throw new Exception("" + e);
|
||||
}
|
||||
Deserialize();
|
||||
}
|
||||
|
||||
public void Deserialize()
|
||||
{
|
||||
using (StreamReader file = File.OpenText(@"Gegevens\Keuzes.json"))
|
||||
{
|
||||
JsonSerializer serializer = new JsonSerializer();
|
||||
keuzes = (List<Keuze>)serializer.Deserialize(file, typeof(List<Keuze>));
|
||||
|
||||
}
|
||||
using (StreamReader file = File.OpenText(@"Gegevens\Personen.json"))
|
||||
{
|
||||
JsonSerializer serializer = new JsonSerializer();
|
||||
personen = (List<Persoon>)serializer.Deserialize(file, typeof(List<Persoon>));
|
||||
}
|
||||
using (StreamReader file = File.OpenText(@"Gegevens\Wedstrijden.json"))
|
||||
{
|
||||
JsonSerializer serializer = new JsonSerializer();
|
||||
wedstrijden = (List<Wedstrijden>)serializer.Deserialize(file, typeof(List<Wedstrijden>));
|
||||
}
|
||||
wedstrijden = (wedstrijden == null) ? new List<Wedstrijden>() : wedstrijden;
|
||||
personen = (personen == null) ? new List<Persoon>() : personen;
|
||||
keuzes = (keuzes == null) ? new List<Keuze>() : keuzes;
|
||||
|
||||
}
|
||||
public void Serialize()
|
||||
{
|
||||
using (StreamWriter file = File.CreateText(@"Gegevens\Keuzes.json"))
|
||||
{
|
||||
JsonSerializer serializer = new JsonSerializer();
|
||||
serializer.Serialize(file, keuzes);
|
||||
}
|
||||
using (StreamWriter file = File.CreateText(@"Gegevens\Personen.json"))
|
||||
{
|
||||
JsonSerializer serializer = new JsonSerializer();
|
||||
serializer.Serialize(file, personen);
|
||||
}
|
||||
using (StreamWriter file = File.CreateText(@"Gegevens\Wedstrijden.json"))
|
||||
{
|
||||
JsonSerializer serializer = new JsonSerializer();
|
||||
serializer.Serialize(file, wedstrijden);
|
||||
}
|
||||
}
|
||||
|
||||
public void PlaatsGok(int matchID, int persoonID, double inzet, string g)
|
||||
{
|
||||
try
|
||||
{
|
||||
Enum.TryParse(g, out Gokken gok);
|
||||
Keuze k = new Keuze(matchID, persoonID, inzet, gok);
|
||||
keuzes.Add(k);
|
||||
}catch(Exception ex)
|
||||
{
|
||||
throw ex;
|
||||
}
|
||||
}
|
||||
|
||||
public void GebruikerToevoegen(string voornaam, string naam, string adres, string gsm)
|
||||
{
|
||||
Persoon p = new Persoon(0, "Voornaam", "Naam", "Adres", "Gsm", 0.00);
|
||||
try
|
||||
{
|
||||
p = new Persoon(personen[personen.Count - 1].persoon_ID + 1, voornaam, naam, adres, gsm, 0);
|
||||
}
|
||||
catch
|
||||
{
|
||||
p = new Persoon(0, voornaam, naam, adres, gsm, 0);
|
||||
Debug.WriteLine("probleem met id settings");
|
||||
}
|
||||
personen.Add(p);
|
||||
}
|
||||
|
||||
public void MaakVoorbeelden()
|
||||
{
|
||||
personen.Add(new Persoon(1, "john", "doe", "street", "048765656565", 0.15));
|
||||
wedstrijden.Add(new Wedstrijden(128, "belgie", "polen", 1, 0, 2.3, 3, 1.8));
|
||||
keuzes.Add(new Keuze(128, 1, 0.15, Gokken.Thuisploeg));
|
||||
}
|
||||
|
||||
public List<string> GetGebruikers()
|
||||
{
|
||||
List<string> lijst = new List<string>();
|
||||
if (personen != null) {
|
||||
foreach(Persoon p in personen)
|
||||
{
|
||||
lijst.Add(p.persoon_ID+":"+p.naam + " " + p.voorNaam);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lijst.Add("None");
|
||||
}
|
||||
return lijst;
|
||||
}
|
||||
|
||||
public List<string> GetWedstrijden()
|
||||
{
|
||||
List<string> temp = new List<string>();
|
||||
if (personen != null)
|
||||
{
|
||||
foreach (Wedstrijden w in wedstrijden)
|
||||
{
|
||||
temp.Add( w.thuisPloeg + " - " + w.uitPloeg);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
temp.Add("None");
|
||||
}
|
||||
return temp;
|
||||
}
|
||||
|
||||
public List<string> GetGeldVerdubbeling(int ID)
|
||||
{
|
||||
List<string> lijst2 = new List<string>();
|
||||
if (personen != null)
|
||||
{
|
||||
foreach (Wedstrijden a in wedstrijden)
|
||||
{
|
||||
if(a.wedstrijd_ID == ID)
|
||||
{
|
||||
lijst2.Add(a.geldThuisPloeg + "");
|
||||
lijst2.Add(a.geldGelijk + "");
|
||||
lijst2.Add(a.geldUitPloeg + "");
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lijst2.Add("None");
|
||||
lijst2.Add("None");
|
||||
lijst2.Add("None");
|
||||
}
|
||||
return lijst2;
|
||||
}
|
||||
|
||||
public int[] GetP_ID()
|
||||
{
|
||||
int[] p_ID = new int[personen.Count];
|
||||
int teller = 0;
|
||||
foreach (Persoon p in personen)
|
||||
{
|
||||
p_ID[teller] = p.persoon_ID;
|
||||
teller++;
|
||||
}
|
||||
return p_ID;
|
||||
}
|
||||
|
||||
public int[] GetW_ID()
|
||||
{
|
||||
int[] w_ID = new int[wedstrijden.Count];
|
||||
int teller = 0;
|
||||
foreach (Wedstrijden w in wedstrijden)
|
||||
{
|
||||
w_ID[teller] = w.wedstrijd_ID;
|
||||
teller++;
|
||||
}
|
||||
return w_ID;
|
||||
}
|
||||
|
||||
private Wedstrijden GetWedstrijd(int ID)
|
||||
{
|
||||
foreach(Wedstrijden w in wedstrijden)
|
||||
{
|
||||
if(w.wedstrijd_ID == ID)
|
||||
{
|
||||
return w;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public double GetWinst(int ID)
|
||||
{
|
||||
double winst = 0;
|
||||
foreach (Keuze k in keuzes)
|
||||
{
|
||||
if(k.speler_ID == ID)
|
||||
{
|
||||
Gokken g = k.gok;
|
||||
double temp = k.inzet;
|
||||
Wedstrijden w = GetWedstrijd(k.match_ID);
|
||||
Gokken uitKomst = w.GetWinnaar();
|
||||
if(uitKomst == g)
|
||||
{
|
||||
switch (uitKomst)
|
||||
{
|
||||
case Gokken.Gelijk:
|
||||
winst += temp * w.geldGelijk;
|
||||
break;
|
||||
case Gokken.Thuisploeg:
|
||||
winst += temp * w.geldThuisPloeg;
|
||||
break;
|
||||
case Gokken.Uitploeg:
|
||||
winst += temp * w.geldUitPloeg;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
return winst;
|
||||
}
|
||||
}
|
||||
}
|
35
Online Gokkantoor/LogicLayer/Keuze.cs
Normal file
35
Online Gokkantoor/LogicLayer/Keuze.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using DataLaag.Interfaces;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using static DataLaag.Enums;
|
||||
|
||||
namespace LogicLayer
|
||||
{
|
||||
public class Keuze : IFKeuze
|
||||
{
|
||||
|
||||
public int match_ID { get; set; }
|
||||
public int speler_ID { get; set; }
|
||||
public double inzet { get; set; }
|
||||
public Gokken gok { get; set; } // thuis uit of gelijk
|
||||
|
||||
public Keuze(int match_ID, int speler_ID, double inzet, Gokken gok)
|
||||
{
|
||||
try
|
||||
{
|
||||
this.match_ID = match_ID;
|
||||
this.speler_ID = speler_ID;
|
||||
this.inzet = inzet;
|
||||
this.gok = gok;
|
||||
|
||||
} catch (Exception e)
|
||||
{
|
||||
throw new Exception("keuze is niet gelukt:" + e);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
63
Online Gokkantoor/LogicLayer/LogicLayer.csproj
Normal file
63
Online Gokkantoor/LogicLayer/LogicLayer.csproj
Normal file
@@ -0,0 +1,63 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{517C3448-BD87-4D62-9316-6BABBC9A9CFC}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>LogicLayer</RootNamespace>
|
||||
<AssemblyName>LogicLayer</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<Deterministic>true</Deterministic>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Newtonsoft.Json.11.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="General.cs" />
|
||||
<Compile Include="Keuze.cs" />
|
||||
<Compile Include="Persoon.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="Wedstrijden.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\DataLaag\DataLaag.csproj">
|
||||
<Project>{ca62d8ea-2739-4c85-81b4-fba040592dae}</Project>
|
||||
<Name>DataLaag</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
41
Online Gokkantoor/LogicLayer/Persoon.cs
Normal file
41
Online Gokkantoor/LogicLayer/Persoon.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using DataLaag.Interfaces;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
|
||||
namespace LogicLayer
|
||||
{
|
||||
public class Persoon : IFPersoon
|
||||
{
|
||||
public int persoon_ID { get; set; }
|
||||
public string voorNaam { get; set; }
|
||||
public string naam { get; set; }
|
||||
public string adres { get; set; }
|
||||
public string gsm { get; set; }
|
||||
public double balans { get; set; }
|
||||
|
||||
|
||||
public Persoon(int persoon_ID, string voorNaam, string naam, string adres, string gsm, double balans)
|
||||
{
|
||||
try
|
||||
{
|
||||
this.persoon_ID = persoon_ID;
|
||||
this.voorNaam = voorNaam;
|
||||
this.naam = naam;
|
||||
this.adres = adres;
|
||||
this.gsm = gsm;
|
||||
this.balans = balans;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
throw new Exception("Foutieve ingave: " + ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
36
Online Gokkantoor/LogicLayer/Properties/AssemblyInfo.cs
Normal file
36
Online Gokkantoor/LogicLayer/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("LogicLayer")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("LogicLayer")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2018")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("517c3448-bd87-4d62-9316-6babbc9a9cfc")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
48
Online Gokkantoor/LogicLayer/Wedstrijden.cs
Normal file
48
Online Gokkantoor/LogicLayer/Wedstrijden.cs
Normal file
@@ -0,0 +1,48 @@
|
||||
using DataLaag.Interfaces;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using static DataLaag.Enums;
|
||||
|
||||
namespace LogicLayer
|
||||
{
|
||||
public class Wedstrijden : IFWedstrijden
|
||||
{
|
||||
public int wedstrijd_ID { get; set; }
|
||||
public string thuisPloeg { get; set; }
|
||||
public string uitPloeg { get; set; }
|
||||
public int score_ThuisPloeg { get; set; }
|
||||
public int score_UitPloeg { get; set; }
|
||||
public double geldThuisPloeg { get; set; }
|
||||
public double geldGelijk { get; set; }
|
||||
public double geldUitPloeg { get; set; }
|
||||
|
||||
|
||||
public Wedstrijden(int wedstrijd_ID, string thuisPloeg, string uitPloeg, int score_ThuisPloeg, int score_UitPloeg, double geldThuisPloeg, double geldGelijk, double geldUitPloeg)
|
||||
{
|
||||
this.wedstrijd_ID = wedstrijd_ID;
|
||||
this.thuisPloeg = thuisPloeg;
|
||||
this.uitPloeg = uitPloeg;
|
||||
this.score_ThuisPloeg = score_ThuisPloeg;
|
||||
this.score_UitPloeg = score_UitPloeg;
|
||||
this.geldThuisPloeg = geldThuisPloeg;
|
||||
this.geldGelijk = geldGelijk;
|
||||
this.geldUitPloeg = geldUitPloeg;
|
||||
}
|
||||
|
||||
public Gokken GetWinnaar()
|
||||
{
|
||||
if(score_ThuisPloeg > score_UitPloeg)
|
||||
{
|
||||
return Gokken.Thuisploeg;
|
||||
}else if(score_UitPloeg > score_ThuisPloeg)
|
||||
{
|
||||
return Gokken.Uitploeg;
|
||||
}
|
||||
else
|
||||
{
|
||||
return Gokken.Gelijk;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
4
Online Gokkantoor/LogicLayer/packages.config
Normal file
4
Online Gokkantoor/LogicLayer/packages.config
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="Newtonsoft.Json" version="11.0.2" targetFramework="net461" />
|
||||
</packages>
|
43
Online Gokkantoor/Online Gokkantoor.sln
Normal file
43
Online Gokkantoor/Online Gokkantoor.sln
Normal file
@@ -0,0 +1,43 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.28010.2026
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Online Gokkantoor_GUI", "Online Gokkantoor\Online Gokkantoor_GUI.csproj", "{62E2ECA5-72AF-4401-9FE3-D7BD5044D7E9}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DataLaag", "DataLaag\DataLaag.csproj", "{CA62D8EA-2739-4C85-81B4-FBA040592DAE}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LogicLayer", "LogicLayer\LogicLayer.csproj", "{517C3448-BD87-4D62-9316-6BABBC9A9CFC}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleApp", "Console\ConsoleApp.csproj", "{75E1DDD1-C2F0-4C29-A95A-85A72D8C4948}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{62E2ECA5-72AF-4401-9FE3-D7BD5044D7E9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{62E2ECA5-72AF-4401-9FE3-D7BD5044D7E9}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{62E2ECA5-72AF-4401-9FE3-D7BD5044D7E9}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{62E2ECA5-72AF-4401-9FE3-D7BD5044D7E9}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{CA62D8EA-2739-4C85-81B4-FBA040592DAE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{CA62D8EA-2739-4C85-81B4-FBA040592DAE}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{CA62D8EA-2739-4C85-81B4-FBA040592DAE}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{CA62D8EA-2739-4C85-81B4-FBA040592DAE}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{517C3448-BD87-4D62-9316-6BABBC9A9CFC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{517C3448-BD87-4D62-9316-6BABBC9A9CFC}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{517C3448-BD87-4D62-9316-6BABBC9A9CFC}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{517C3448-BD87-4D62-9316-6BABBC9A9CFC}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{75E1DDD1-C2F0-4C29-A95A-85A72D8C4948}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{75E1DDD1-C2F0-4C29-A95A-85A72D8C4948}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{75E1DDD1-C2F0-4C29-A95A-85A72D8C4948}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{75E1DDD1-C2F0-4C29-A95A-85A72D8C4948}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {13B0BD72-57FE-4A9D-86CA-848D0C9EE5EB}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
380
Online Gokkantoor/Online Gokkantoor/Aanmeldscherm.Designer.cs
generated
Normal file
380
Online Gokkantoor/Online Gokkantoor/Aanmeldscherm.Designer.cs
generated
Normal file
@@ -0,0 +1,380 @@
|
||||
namespace Online_Gokkantoor
|
||||
{
|
||||
partial class Aanmeldscherm
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.titel = new System.Windows.Forms.Label();
|
||||
this.voornaam = new System.Windows.Forms.Label();
|
||||
this.naam = new System.Windows.Forms.Label();
|
||||
this.textVoornaam = new System.Windows.Forms.TextBox();
|
||||
this.textNaam = new System.Windows.Forms.TextBox();
|
||||
this.adres = new System.Windows.Forms.Label();
|
||||
this.textAdres = new System.Windows.Forms.TextBox();
|
||||
this.textGsm = new System.Windows.Forms.TextBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.labelMatch = new System.Windows.Forms.Label();
|
||||
this.comboKeuze = new System.Windows.Forms.ComboBox();
|
||||
this.labelThuisploeg = new System.Windows.Forms.Label();
|
||||
this.labelGelijk = new System.Windows.Forms.Label();
|
||||
this.labelUitploeg = new System.Windows.Forms.Label();
|
||||
this.buttonGokken = new System.Windows.Forms.Button();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.textInzet = new System.Windows.Forms.TextBox();
|
||||
this.button1 = new System.Windows.Forms.Button();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.button2 = new System.Windows.Forms.Button();
|
||||
this.GebruikersBox = new System.Windows.Forms.ListBox();
|
||||
this.matchbox = new System.Windows.Forms.ListBox();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.label5 = new System.Windows.Forms.Label();
|
||||
this.button3 = new System.Windows.Forms.Button();
|
||||
this.labelError = new System.Windows.Forms.Label();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.labelWinst = new System.Windows.Forms.Label();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// titel
|
||||
//
|
||||
this.titel.AutoSize = true;
|
||||
this.titel.Location = new System.Drawing.Point(576, 40);
|
||||
this.titel.Name = "titel";
|
||||
this.titel.Size = new System.Drawing.Size(94, 13);
|
||||
this.titel.TabIndex = 0;
|
||||
this.titel.Text = "Vul je gegevens in";
|
||||
//
|
||||
// voornaam
|
||||
//
|
||||
this.voornaam.AutoSize = true;
|
||||
this.voornaam.Location = new System.Drawing.Point(443, 59);
|
||||
this.voornaam.Name = "voornaam";
|
||||
this.voornaam.Size = new System.Drawing.Size(55, 13);
|
||||
this.voornaam.TabIndex = 1;
|
||||
this.voornaam.Text = "Voornaam";
|
||||
//
|
||||
// naam
|
||||
//
|
||||
this.naam.AutoSize = true;
|
||||
this.naam.Location = new System.Drawing.Point(463, 84);
|
||||
this.naam.Name = "naam";
|
||||
this.naam.Size = new System.Drawing.Size(35, 13);
|
||||
this.naam.TabIndex = 2;
|
||||
this.naam.Text = "Naam";
|
||||
//
|
||||
// textVoornaam
|
||||
//
|
||||
this.textVoornaam.Location = new System.Drawing.Point(519, 56);
|
||||
this.textVoornaam.Name = "textVoornaam";
|
||||
this.textVoornaam.Size = new System.Drawing.Size(225, 20);
|
||||
this.textVoornaam.TabIndex = 3;
|
||||
//
|
||||
// textNaam
|
||||
//
|
||||
this.textNaam.Location = new System.Drawing.Point(519, 81);
|
||||
this.textNaam.Name = "textNaam";
|
||||
this.textNaam.Size = new System.Drawing.Size(225, 20);
|
||||
this.textNaam.TabIndex = 4;
|
||||
//
|
||||
// adres
|
||||
//
|
||||
this.adres.AutoSize = true;
|
||||
this.adres.Location = new System.Drawing.Point(463, 109);
|
||||
this.adres.Name = "adres";
|
||||
this.adres.Size = new System.Drawing.Size(34, 13);
|
||||
this.adres.TabIndex = 5;
|
||||
this.adres.Text = "Adres";
|
||||
//
|
||||
// textAdres
|
||||
//
|
||||
this.textAdres.Location = new System.Drawing.Point(519, 106);
|
||||
this.textAdres.Name = "textAdres";
|
||||
this.textAdres.Size = new System.Drawing.Size(225, 20);
|
||||
this.textAdres.TabIndex = 6;
|
||||
//
|
||||
// textGsm
|
||||
//
|
||||
this.textGsm.Location = new System.Drawing.Point(519, 132);
|
||||
this.textGsm.Name = "textGsm";
|
||||
this.textGsm.Size = new System.Drawing.Size(225, 20);
|
||||
this.textGsm.TabIndex = 7;
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Location = new System.Drawing.Point(470, 135);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(28, 13);
|
||||
this.label1.TabIndex = 8;
|
||||
this.label1.Text = "Gsm";
|
||||
//
|
||||
// labelMatch
|
||||
//
|
||||
this.labelMatch.AutoSize = true;
|
||||
this.labelMatch.Location = new System.Drawing.Point(179, 238);
|
||||
this.labelMatch.Name = "labelMatch";
|
||||
this.labelMatch.Size = new System.Drawing.Size(108, 13);
|
||||
this.labelMatch.TabIndex = 9;
|
||||
this.labelMatch.Text = "Geselecteerde match";
|
||||
//
|
||||
// comboKeuze
|
||||
//
|
||||
this.comboKeuze.FormattingEnabled = true;
|
||||
this.comboKeuze.Location = new System.Drawing.Point(293, 233);
|
||||
this.comboKeuze.Name = "comboKeuze";
|
||||
this.comboKeuze.Size = new System.Drawing.Size(121, 21);
|
||||
this.comboKeuze.TabIndex = 10;
|
||||
//
|
||||
// labelThuisploeg
|
||||
//
|
||||
this.labelThuisploeg.AutoSize = true;
|
||||
this.labelThuisploeg.Location = new System.Drawing.Point(436, 233);
|
||||
this.labelThuisploeg.Name = "labelThuisploeg";
|
||||
this.labelThuisploeg.Size = new System.Drawing.Size(59, 13);
|
||||
this.labelThuisploeg.TabIndex = 11;
|
||||
this.labelThuisploeg.Text = "Thuisploeg";
|
||||
//
|
||||
// labelGelijk
|
||||
//
|
||||
this.labelGelijk.AutoSize = true;
|
||||
this.labelGelijk.Location = new System.Drawing.Point(533, 233);
|
||||
this.labelGelijk.Name = "labelGelijk";
|
||||
this.labelGelijk.Size = new System.Drawing.Size(33, 13);
|
||||
this.labelGelijk.TabIndex = 12;
|
||||
this.labelGelijk.Text = "Gelijk";
|
||||
//
|
||||
// labelUitploeg
|
||||
//
|
||||
this.labelUitploeg.AutoSize = true;
|
||||
this.labelUitploeg.Location = new System.Drawing.Point(613, 233);
|
||||
this.labelUitploeg.Name = "labelUitploeg";
|
||||
this.labelUitploeg.Size = new System.Drawing.Size(46, 13);
|
||||
this.labelUitploeg.TabIndex = 13;
|
||||
this.labelUitploeg.Text = "Uitploeg";
|
||||
//
|
||||
// buttonGokken
|
||||
//
|
||||
this.buttonGokken.BackColor = System.Drawing.SystemColors.InactiveCaptionText;
|
||||
this.buttonGokken.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
|
||||
this.buttonGokken.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.buttonGokken.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
|
||||
this.buttonGokken.Location = new System.Drawing.Point(512, 338);
|
||||
this.buttonGokken.Name = "buttonGokken";
|
||||
this.buttonGokken.Size = new System.Drawing.Size(75, 23);
|
||||
this.buttonGokken.TabIndex = 14;
|
||||
this.buttonGokken.Text = "GOKKEN";
|
||||
this.buttonGokken.UseVisualStyleBackColor = false;
|
||||
this.buttonGokken.Click += new System.EventHandler(this.knopGokken);
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Location = new System.Drawing.Point(257, 290);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(30, 13);
|
||||
this.label2.TabIndex = 16;
|
||||
this.label2.Text = "Inzet";
|
||||
//
|
||||
// textInzet
|
||||
//
|
||||
this.textInzet.Location = new System.Drawing.Point(293, 283);
|
||||
this.textInzet.Name = "textInzet";
|
||||
this.textInzet.Size = new System.Drawing.Size(121, 20);
|
||||
this.textInzet.TabIndex = 17;
|
||||
//
|
||||
// button1
|
||||
//
|
||||
this.button1.Location = new System.Drawing.Point(366, 392);
|
||||
this.button1.Name = "button1";
|
||||
this.button1.Size = new System.Drawing.Size(75, 23);
|
||||
this.button1.TabIndex = 18;
|
||||
this.button1.Text = "test";
|
||||
this.button1.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Location = new System.Drawing.Point(578, 9);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(92, 13);
|
||||
this.label3.TabIndex = 19;
|
||||
this.label3.Text = "Nieuwe Gebruiker";
|
||||
//
|
||||
// button2
|
||||
//
|
||||
this.button2.Location = new System.Drawing.Point(581, 158);
|
||||
this.button2.Name = "button2";
|
||||
this.button2.Size = new System.Drawing.Size(163, 28);
|
||||
this.button2.TabIndex = 20;
|
||||
this.button2.Text = "Gebruiker Toevoegen";
|
||||
this.button2.UseVisualStyleBackColor = true;
|
||||
this.button2.Click += new System.EventHandler(this.buttonGebruikerToevoegen);
|
||||
//
|
||||
// GebruikersBox
|
||||
//
|
||||
this.GebruikersBox.FormattingEnabled = true;
|
||||
this.GebruikersBox.Location = new System.Drawing.Point(13, 40);
|
||||
this.GebruikersBox.Name = "GebruikersBox";
|
||||
this.GebruikersBox.Size = new System.Drawing.Size(274, 160);
|
||||
this.GebruikersBox.TabIndex = 21;
|
||||
this.GebruikersBox.SelectedIndexChanged += new System.EventHandler(this.GebruikersBox_SelectedIndexChanged);
|
||||
//
|
||||
// matchbox
|
||||
//
|
||||
this.matchbox.FormattingEnabled = true;
|
||||
this.matchbox.Location = new System.Drawing.Point(13, 230);
|
||||
this.matchbox.Name = "matchbox";
|
||||
this.matchbox.Size = new System.Drawing.Size(160, 160);
|
||||
this.matchbox.TabIndex = 22;
|
||||
this.matchbox.SelectedIndexChanged += new System.EventHandler(this.matchbox_SelectedIndexChanged);
|
||||
//
|
||||
// label4
|
||||
//
|
||||
this.label4.AutoSize = true;
|
||||
this.label4.Location = new System.Drawing.Point(12, 24);
|
||||
this.label4.Name = "label4";
|
||||
this.label4.Size = new System.Drawing.Size(61, 13);
|
||||
this.label4.TabIndex = 23;
|
||||
this.label4.Text = "Gebruikers:";
|
||||
//
|
||||
// label5
|
||||
//
|
||||
this.label5.AutoSize = true;
|
||||
this.label5.Location = new System.Drawing.Point(10, 214);
|
||||
this.label5.Name = "label5";
|
||||
this.label5.Size = new System.Drawing.Size(49, 13);
|
||||
this.label5.TabIndex = 24;
|
||||
this.label5.Text = "Matchen";
|
||||
//
|
||||
// button3
|
||||
//
|
||||
this.button3.Location = new System.Drawing.Point(713, 415);
|
||||
this.button3.Name = "button3";
|
||||
this.button3.Size = new System.Drawing.Size(75, 23);
|
||||
this.button3.TabIndex = 25;
|
||||
this.button3.Text = "exit";
|
||||
this.button3.UseVisualStyleBackColor = true;
|
||||
this.button3.Click += new System.EventHandler(this.buttonExit);
|
||||
//
|
||||
// labelError
|
||||
//
|
||||
this.labelError.AutoSize = true;
|
||||
this.labelError.Location = new System.Drawing.Point(524, 167);
|
||||
this.labelError.Name = "labelError";
|
||||
this.labelError.Size = new System.Drawing.Size(0, 13);
|
||||
this.labelError.TabIndex = 26;
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Location = new System.Drawing.Point(309, 56);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(37, 13);
|
||||
this.label6.TabIndex = 27;
|
||||
this.label6.Text = "Winst:";
|
||||
//
|
||||
// labelWinst
|
||||
//
|
||||
this.labelWinst.AutoSize = true;
|
||||
this.labelWinst.Location = new System.Drawing.Point(309, 88);
|
||||
this.labelWinst.Name = "labelWinst";
|
||||
this.labelWinst.Size = new System.Drawing.Size(0, 13);
|
||||
this.labelWinst.TabIndex = 28;
|
||||
//
|
||||
// Aanmeldscherm
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.BackColor = System.Drawing.SystemColors.Window;
|
||||
this.ClientSize = new System.Drawing.Size(800, 450);
|
||||
this.Controls.Add(this.labelWinst);
|
||||
this.Controls.Add(this.label6);
|
||||
this.Controls.Add(this.labelError);
|
||||
this.Controls.Add(this.button3);
|
||||
this.Controls.Add(this.label5);
|
||||
this.Controls.Add(this.label4);
|
||||
this.Controls.Add(this.matchbox);
|
||||
this.Controls.Add(this.GebruikersBox);
|
||||
this.Controls.Add(this.button2);
|
||||
this.Controls.Add(this.label3);
|
||||
this.Controls.Add(this.button1);
|
||||
this.Controls.Add(this.textInzet);
|
||||
this.Controls.Add(this.label2);
|
||||
this.Controls.Add(this.buttonGokken);
|
||||
this.Controls.Add(this.labelUitploeg);
|
||||
this.Controls.Add(this.labelGelijk);
|
||||
this.Controls.Add(this.labelThuisploeg);
|
||||
this.Controls.Add(this.comboKeuze);
|
||||
this.Controls.Add(this.labelMatch);
|
||||
this.Controls.Add(this.label1);
|
||||
this.Controls.Add(this.textGsm);
|
||||
this.Controls.Add(this.textAdres);
|
||||
this.Controls.Add(this.adres);
|
||||
this.Controls.Add(this.textNaam);
|
||||
this.Controls.Add(this.textVoornaam);
|
||||
this.Controls.Add(this.naam);
|
||||
this.Controls.Add(this.voornaam);
|
||||
this.Controls.Add(this.titel);
|
||||
this.Name = "Aanmeldscherm";
|
||||
this.Text = "Aanmeldscherm";
|
||||
this.Load += new System.EventHandler(this.Aanmeldscherm_Load);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Label titel;
|
||||
private System.Windows.Forms.Label voornaam;
|
||||
private System.Windows.Forms.Label naam;
|
||||
private System.Windows.Forms.TextBox textVoornaam;
|
||||
private System.Windows.Forms.TextBox textNaam;
|
||||
private System.Windows.Forms.Label adres;
|
||||
private System.Windows.Forms.TextBox textAdres;
|
||||
private System.Windows.Forms.TextBox textGsm;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Label labelMatch;
|
||||
private System.Windows.Forms.ComboBox comboKeuze;
|
||||
private System.Windows.Forms.Label labelThuisploeg;
|
||||
private System.Windows.Forms.Label labelGelijk;
|
||||
private System.Windows.Forms.Label labelUitploeg;
|
||||
private System.Windows.Forms.Button buttonGokken;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.TextBox textInzet;
|
||||
private System.Windows.Forms.Button button1;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.Button button2;
|
||||
private System.Windows.Forms.ListBox GebruikersBox;
|
||||
private System.Windows.Forms.ListBox matchbox;
|
||||
private System.Windows.Forms.Label label4;
|
||||
private System.Windows.Forms.Label label5;
|
||||
private System.Windows.Forms.Button button3;
|
||||
private System.Windows.Forms.Label labelError;
|
||||
private System.Windows.Forms.Label label6;
|
||||
private System.Windows.Forms.Label labelWinst;
|
||||
}
|
||||
}
|
135
Online Gokkantoor/Online Gokkantoor/Aanmeldscherm.cs
Normal file
135
Online Gokkantoor/Online Gokkantoor/Aanmeldscherm.cs
Normal file
@@ -0,0 +1,135 @@
|
||||
using DataLaag;
|
||||
using LogicLayer;
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Diagnostics;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
|
||||
namespace Online_Gokkantoor
|
||||
{
|
||||
public partial class Aanmeldscherm : Form
|
||||
{
|
||||
public int[] p_ID;
|
||||
public int[] w_ID;
|
||||
public General g;
|
||||
private List<Persoon> personen = new List<Persoon>();
|
||||
private string[] uitkomsten = { "Uitploeg", "Gelijk", "Thuisploeg" };
|
||||
public Aanmeldscherm()
|
||||
{
|
||||
InitializeComponent();
|
||||
try
|
||||
{
|
||||
g = new General();
|
||||
g.Deserialize();
|
||||
UpdateUI();
|
||||
|
||||
} catch (Exception e )
|
||||
{
|
||||
labelError.Text = "error throw: " + e;
|
||||
}
|
||||
}
|
||||
|
||||
private void UpdateUI()
|
||||
{
|
||||
GebruikersBox.DataSource = g.GetGebruikers();
|
||||
matchbox.DataSource = g.GetWedstrijden();
|
||||
p_ID = g.GetP_ID();
|
||||
w_ID = g.GetW_ID();
|
||||
labelError.Text = "";
|
||||
}
|
||||
private void Save()
|
||||
{
|
||||
string nieuw = JsonConvert.SerializeObject(personen);
|
||||
Debug.WriteLine(nieuw);
|
||||
}
|
||||
|
||||
private string RandomGok()
|
||||
{
|
||||
Random randm = new Random();
|
||||
int willekeurigeGok = randm.Next(0, 2);
|
||||
return uitkomsten[willekeurigeGok];
|
||||
}
|
||||
|
||||
private void knopGokken(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
int per_ID = p_ID[GebruikersBox.SelectedIndex];
|
||||
int wed_ID = w_ID[matchbox.SelectedIndex];
|
||||
g.PlaatsGok(wed_ID, per_ID, Double.Parse(textInzet.Text), comboKeuze.Items[comboKeuze.SelectedIndex].ToString());
|
||||
}catch(Exception e2)
|
||||
{
|
||||
labelError.Text = e2 + "";
|
||||
}
|
||||
UpdateUI();
|
||||
}
|
||||
|
||||
private void matchbox_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
labelMatch.Text = (string)this.matchbox.SelectedItem;
|
||||
List<string> geld = g.GetGeldVerdubbeling(w_ID[matchbox.SelectedIndex]);
|
||||
labelThuisploeg.Text = "Thuisploeg:" + geld[0];
|
||||
labelGelijk.Text = "Gelijk:" + geld[1];
|
||||
labelUitploeg.Text = "Uitploeg:" + geld[2];
|
||||
}catch (Exception exceptie)
|
||||
{
|
||||
labelError.Text = exceptie + "";
|
||||
}
|
||||
}
|
||||
|
||||
private void Aanmeldscherm_Load(object sender, EventArgs e)
|
||||
{
|
||||
labelThuisploeg.Text = "Thuisploeg:";
|
||||
labelGelijk.Text = "Gelijk:";
|
||||
labelUitploeg.Text = "Uitploeg:";
|
||||
|
||||
foreach(string s in uitkomsten)
|
||||
{
|
||||
comboKeuze.Items.Add(s);
|
||||
}
|
||||
}
|
||||
|
||||
private void GebruikersBox_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
int ID = p_ID[GebruikersBox.SelectedIndex];
|
||||
|
||||
labelWinst.Text = g.GetWinst(ID) + "€";
|
||||
}catch(Exception e1)
|
||||
{
|
||||
labelError.Text = e1 + "";
|
||||
}
|
||||
}
|
||||
|
||||
private void buttonGebruikerToevoegen(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
g.MaakVoorbeelden();
|
||||
UpdateUI();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
labelError.Text = ex + "";
|
||||
}
|
||||
}
|
||||
|
||||
private void buttonExit(object sender, EventArgs e)
|
||||
{
|
||||
UpdateUI();
|
||||
g.Serialize();
|
||||
this.Close();
|
||||
}
|
||||
}
|
||||
}
|
120
Online Gokkantoor/Online Gokkantoor/Aanmeldscherm.resx
Normal file
120
Online Gokkantoor/Online Gokkantoor/Aanmeldscherm.resx
Normal file
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
6
Online Gokkantoor/Online Gokkantoor/App.config
Normal file
6
Online Gokkantoor/Online Gokkantoor/App.config
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1"/>
|
||||
</startup>
|
||||
</configuration>
|
103
Online Gokkantoor/Online Gokkantoor/Online Gokkantoor_GUI.csproj
Normal file
103
Online Gokkantoor/Online Gokkantoor/Online Gokkantoor_GUI.csproj
Normal file
@@ -0,0 +1,103 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{62E2ECA5-72AF-4401-9FE3-D7BD5044D7E9}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<RootNamespace>Online_Gokkantoor</RootNamespace>
|
||||
<AssemblyName>Online Gokkantoor</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||
<Deterministic>true</Deterministic>
|
||||
<TargetFrameworkProfile />
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Newtonsoft.Json.11.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Deployment" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Aanmeldscherm.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Aanmeldscherm.Designer.cs">
|
||||
<DependentUpon>Aanmeldscherm.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="Aanmeldscherm.resx">
|
||||
<DependentUpon>Aanmeldscherm.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Properties\Resources.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<Compile Include="Properties\Resources.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
<DesignTime>True</DesignTime>
|
||||
</Compile>
|
||||
<None Include="packages.config" />
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
</None>
|
||||
<Compile Include="Properties\Settings.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Settings.settings</DependentUpon>
|
||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="Voorstel_COO.txt" />
|
||||
<Content Include="ZelfEvaluatie.txt" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\DataLaag\DataLaag.csproj">
|
||||
<Project>{ca62d8ea-2739-4c85-81b4-fba040592dae}</Project>
|
||||
<Name>DataLaag</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\LogicLayer\LogicLayer.csproj">
|
||||
<Project>{517c3448-bd87-4d62-9316-6babbc9a9cfc}</Project>
|
||||
<Name>LogicLayer</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
29
Online Gokkantoor/Online Gokkantoor/Program.cs
Normal file
29
Online Gokkantoor/Online Gokkantoor/Program.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace Online_Gokkantoor
|
||||
{
|
||||
public class Program
|
||||
{
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// The main entry point for the application.
|
||||
/// </summary>
|
||||
[STAThread]
|
||||
static void Main()
|
||||
{
|
||||
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
Application.Run(new Aanmeldscherm());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Online Gokkantoor")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("Online Gokkantoor")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2018")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("62e2eca5-72af-4401-9fe3-d7bd5044d7e9")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
63
Online Gokkantoor/Online Gokkantoor/Properties/Resources.Designer.cs
generated
Normal file
63
Online Gokkantoor/Online Gokkantoor/Properties/Resources.Designer.cs
generated
Normal file
@@ -0,0 +1,63 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Online_Gokkantoor.Properties {
|
||||
using System;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// A strongly-typed resource class, for looking up localized strings, etc.
|
||||
/// </summary>
|
||||
// This class was auto-generated by the StronglyTypedResourceBuilder
|
||||
// class via a tool like ResGen or Visual Studio.
|
||||
// To add or remove a member, edit your .ResX file then rerun ResGen
|
||||
// with the /str option, or rebuild your VS project.
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
internal class Resources {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Resources() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the cached ResourceManager instance used by this class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Online_Gokkantoor.Properties.Resources", typeof(Resources).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Overrides the current thread's CurrentUICulture property for all
|
||||
/// resource lookups using this strongly typed resource class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Globalization.CultureInfo Culture {
|
||||
get {
|
||||
return resourceCulture;
|
||||
}
|
||||
set {
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
117
Online Gokkantoor/Online Gokkantoor/Properties/Resources.resx
Normal file
117
Online Gokkantoor/Online Gokkantoor/Properties/Resources.resx
Normal file
@@ -0,0 +1,117 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
26
Online Gokkantoor/Online Gokkantoor/Properties/Settings.Designer.cs
generated
Normal file
26
Online Gokkantoor/Online Gokkantoor/Properties/Settings.Designer.cs
generated
Normal file
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Online_Gokkantoor.Properties {
|
||||
|
||||
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.8.0.0")]
|
||||
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
|
||||
|
||||
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||
|
||||
public static Settings Default {
|
||||
get {
|
||||
return defaultInstance;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
<?xml version='1.0' encoding='utf-8'?>
|
||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
||||
<Profiles>
|
||||
<Profile Name="(Default)" />
|
||||
</Profiles>
|
||||
<Settings />
|
||||
</SettingsFile>
|
48
Online Gokkantoor/Online Gokkantoor/Voorstel_COO.txt
Normal file
48
Online Gokkantoor/Online Gokkantoor/Voorstel_COO.txt
Normal file
@@ -0,0 +1,48 @@
|
||||
C# OO - zelfevaluatie
|
||||
=========================================
|
||||
|
||||
Naam: Michiel Van Dorpe
|
||||
Datum: 3 oktober 2018
|
||||
Volgnummer blok: 1
|
||||
|
||||
Onderwerp: Online gokkantoor
|
||||
|
||||
Beschrijving:
|
||||
|
||||
Met behulp van deze toepassing kan er een simulatie gemaakt worden waarbij er gegokt kan worden op wedstrijden.
|
||||
|
||||
Functionele beschrijving:
|
||||
|
||||
De bezoeker zal eerst en vooral een keuzeformulier voorgeschoten krijgen met daarop de wedstrijden waar er gegokt op kan worden.
|
||||
Dit keuzeformulier zal dus bestaan uit wedstrijden, een woordje uitleg en de mogelijkheid om naar een GUI-toepassing te gaan.
|
||||
|
||||
In deze GUI-toepassing zullen personen kunnen toegevoegd worden die deelnemen aan het gokkantoor,
|
||||
hier zullen persoonlijke gegevens worden ingegeven met daarbij de wedstrijd(en) waarop er deelgenomen wordt.
|
||||
|
||||
Eens deze correct is ingevuld (18+) zullen deze gegevens worden opgeslaan in een lokaal bestand.
|
||||
|
||||
Wanneer dit lokaal bestand is aangevuld kunnen de wedstrijden gesorteerd worden
|
||||
waarbij het duidelijk zichtbaar is hoeveel personen op gelijkspel, winst of verlies hebben gegokt.
|
||||
Hier zal dus ook de winnaar(s) bekend gemaakt worden.
|
||||
|
||||
Voor de routines die gemeenschappelijk vanuit beide toepassingen gebruikt worden,
|
||||
zal een afzonderlijke klassebibliotheek opgesteld worden (die vanuit beide toepassingen gebruikt wordt).
|
||||
|
||||
Leerdoelen:
|
||||
|
||||
Blok 1:
|
||||
|
||||
- kennismaking met Visual Studio & C#
|
||||
- debugging
|
||||
- unit tests
|
||||
- programmeerstijl
|
||||
- exception handling
|
||||
- enum
|
||||
- properties
|
||||
- generic collections
|
||||
- werken met bestanden/streams
|
||||
- objecten: cloning & serialisatie
|
||||
|
||||
Bijkomend:
|
||||
|
||||
- architectuur van een toepassing: meerlagenmodel
|
49
Online Gokkantoor/Online Gokkantoor/ZelfEvaluatie.txt
Normal file
49
Online Gokkantoor/Online Gokkantoor/ZelfEvaluatie.txt
Normal file
@@ -0,0 +1,49 @@
|
||||
C# OO - zelfevaluatie
|
||||
=========================================
|
||||
|
||||
Naam: Michiel Van Dorpe
|
||||
Datum: 30/10/2018
|
||||
Volgnummer blok: 1
|
||||
|
||||
Onderwerp: Online Gokkantoor
|
||||
|
||||
Stand van zaken:
|
||||
|
||||
Grootste deel zoals in het voorstel is volbracht.
|
||||
Enkel het stukje "'Value' en 'Reference' types, cloning van objecten" is nog niet uitgevoerd.
|
||||
|
||||
|
||||
Sterke punten:
|
||||
|
||||
Duidelijke methodes, Meerlagen gebruikt (duidelijke klassen mooi geheel), eerste demo afgewerkt.
|
||||
|
||||
Aandachtspunten in je aanpak:
|
||||
|
||||
Robuste code, effici<63>nte code (soms kan het gemakkelijker en korter).
|
||||
|
||||
Technische aandachtspunten:
|
||||
|
||||
Cloning van objecten heb ik momenteel nog niet goed onder de knie.
|
||||
Meerlagenmodel is nog steeds wennen, dit was een grote omvorming van mijn code.
|
||||
Alle andere punten zijn opgenomen mits gebruik van alternatieven bronnen zoals stackoverflow.
|
||||
|
||||
Leerdoelen:
|
||||
|
||||
< opsomming van de leerdoelen voor dit blok met het niveau waarop je dat doel al verworven hebt:
|
||||
Leerdoelen:
|
||||
|
||||
Blok 1:
|
||||
|
||||
- kennismaking met Visual Studio & C#
|
||||
- debugging
|
||||
- programmeerstijl
|
||||
- exception handling
|
||||
- enum
|
||||
- properties
|
||||
- generic collections
|
||||
- werken met bestanden/streams
|
||||
- Interfaces
|
||||
- Lambda expressions
|
||||
- architectuur van een toepassing: meerlagenmodel
|
||||
|
||||
>
|
4
Online Gokkantoor/Online Gokkantoor/packages.config
Normal file
4
Online Gokkantoor/Online Gokkantoor/packages.config
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="Newtonsoft.Json" version="11.0.2" targetFramework="net461" />
|
||||
</packages>
|
6
Online Gokkantoor/Opstarten/App.config
Normal file
6
Online Gokkantoor/Opstarten/App.config
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
</startup>
|
||||
</configuration>
|
53
Online Gokkantoor/Opstarten/Opstarten.csproj
Normal file
53
Online Gokkantoor/Opstarten/Opstarten.csproj
Normal file
@@ -0,0 +1,53 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{8F83F7BE-61E6-4128-9269-4865CC8C5259}</ProjectGuid>
|
||||
<OutputType>Exe</OutputType>
|
||||
<RootNamespace>Opstarten</RootNamespace>
|
||||
<AssemblyName>Opstarten</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||
<Deterministic>true</Deterministic>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
18
Online Gokkantoor/Opstarten/Program.cs
Normal file
18
Online Gokkantoor/Opstarten/Program.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Opstarten
|
||||
{
|
||||
class Program
|
||||
{
|
||||
static void Main(string[] args)
|
||||
{
|
||||
Console.WriteLine("Welkom in het Online Gokkantoor");
|
||||
Console.WriteLine("Duw op eender welke toets om te sluiten.");
|
||||
Console.ReadKey();
|
||||
}
|
||||
}
|
||||
}
|
36
Online Gokkantoor/Opstarten/Properties/AssemblyInfo.cs
Normal file
36
Online Gokkantoor/Opstarten/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Opstarten")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("Opstarten")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2018")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("8f83f7be-61e6-4128-9269-4865cc8c5259")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
Reference in New Issue
Block a user