Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 8 additions & 27 deletions DataInputt/DataInputt.Tests/DataInputt.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.props" Condition="Exists('..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
Expand All @@ -9,7 +8,7 @@
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>DataInputt.Tests</RootNamespace>
<AssemblyName>DataInputt.Tests</AssemblyName>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">15.0</VisualStudioVersion>
Expand All @@ -19,6 +18,7 @@
<TestProjectType>UnitTest</TestProjectType>
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
Expand All @@ -38,40 +38,21 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.VisualStudio.TestPlatform.TestFramework, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\MSTest.TestFramework.1.2.0\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.dll</HintPath>
</Reference>
<Reference Include="Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\MSTest.TestFramework.1.2.0\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll</HintPath>
</Reference>
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xaml" />
<Reference Include="WindowsBase" />
</ItemGroup>
<ItemGroup>
<Compile Include="UnitTest1.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\DataInputt\DataInputt.csproj">
<Project>{5E84912A-4948-49FE-BFFF-465A7FDC2C1C}</Project>
<Name>DataInputt</Name>
</ProjectReference>
<PackageReference Include="MSTest.TestAdapter">
<Version>1.2.0</Version>
</PackageReference>
<PackageReference Include="MSTest.TestFramework">
<Version>1.2.0</Version>
</PackageReference>
</ItemGroup>
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.props'))" />
<Error Condition="!Exists('..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.targets'))" />
</Target>
<Import Project="..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.targets" Condition="Exists('..\packages\MSTest.TestAdapter.1.2.0\build\net45\MSTest.TestAdapter.targets')" />
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="10.0.3" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
{
"runtime": "NetCore31",
"defaultVariables": null,
"documentGenerator": {
"fromDocument": {
"json": "{\r\n \"x-generator\": \"NSwag v13.7.1.0 (NJsonSchema v10.1.26.0 (Newtonsoft.Json v10.0.0.0))\",\r\n \"swagger\": \"2.0\",\r\n \"info\": {\r\n \"title\": \"My Title\",\r\n \"version\": \"1.0.0\"\r\n },\r\n \"host\": \"localhost:52841\",\r\n \"schemes\": [\r\n \"http\"\r\n ],\r\n \"paths\": {\r\n \"/api/zeitservice/CreateUser\": {\r\n \"post\": {\r\n \"tags\": [\r\n \"ZeitService\"\r\n ],\r\n \"operationId\": \"ZeitService_CreateUser\",\r\n \"consumes\": [\r\n \"application/json\",\r\n \"text/json\",\r\n \"application/*+json\"\r\n ],\r\n \"produces\": [\r\n \"text/plain\",\r\n \"application/json\",\r\n \"text/json\"\r\n ],\r\n \"parameters\": [\r\n {\r\n \"name\": \"user\",\r\n \"in\": \"body\",\r\n \"required\": true,\r\n \"schema\": {\r\n \"$ref\": \"#/definitions/User\"\r\n },\r\n \"x-nullable\": false\r\n }\r\n ],\r\n \"responses\": {\r\n \"200\": {\r\n \"x-nullable\": false,\r\n \"description\": \"\",\r\n \"schema\": {\r\n \"type\": \"integer\",\r\n \"format\": \"int32\"\r\n }\r\n }\r\n }\r\n }\r\n },\r\n \"/api/zeitservice/Login\": {\r\n \"post\": {\r\n \"tags\": [\r\n \"ZeitService\"\r\n ],\r\n \"operationId\": \"ZeitService_Login\",\r\n \"consumes\": [\r\n \"application/json\",\r\n \"text/json\",\r\n \"application/*+json\"\r\n ],\r\n \"produces\": [\r\n \"text/plain\",\r\n \"application/json\",\r\n \"text/json\"\r\n ],\r\n \"parameters\": [\r\n {\r\n \"name\": \"user\",\r\n \"in\": \"body\",\r\n \"required\": true,\r\n \"schema\": {\r\n \"$ref\": \"#/definitions/User\"\r\n },\r\n \"x-nullable\": false\r\n }\r\n ],\r\n \"responses\": {\r\n \"200\": {\r\n \"x-nullable\": false,\r\n \"description\": \"\",\r\n \"schema\": {\r\n \"type\": \"integer\",\r\n \"format\": \"int32\"\r\n }\r\n }\r\n }\r\n }\r\n },\r\n \"/api/zeitservice/Times\": {\r\n \"get\": {\r\n \"tags\": [\r\n \"ZeitService\"\r\n ],\r\n \"operationId\": \"ZeitService_GetTimes\",\r\n \"produces\": [\r\n \"text/plain\",\r\n \"application/json\",\r\n \"text/json\"\r\n ],\r\n \"parameters\": [\r\n {\r\n \"type\": \"integer\",\r\n \"name\": \"userId\",\r\n \"in\": \"query\",\r\n \"format\": \"int32\",\r\n \"x-nullable\": false\r\n }\r\n ],\r\n \"responses\": {\r\n \"200\": {\r\n \"x-nullable\": false,\r\n \"description\": \"\",\r\n \"schema\": {\r\n \"type\": \"array\",\r\n \"items\": {\r\n \"$ref\": \"#/definitions/Time\"\r\n }\r\n }\r\n }\r\n }\r\n }\r\n },\r\n \"/api/zeitservice/AddTime\": {\r\n \"post\": {\r\n \"tags\": [\r\n \"ZeitService\"\r\n ],\r\n \"operationId\": \"ZeitService_AddTime\",\r\n \"consumes\": [\r\n \"application/json\",\r\n \"text/json\",\r\n \"application/*+json\"\r\n ],\r\n \"parameters\": [\r\n {\r\n \"name\": \"time\",\r\n \"in\": \"body\",\r\n \"required\": true,\r\n \"schema\": {\r\n \"$ref\": \"#/definitions/Time\"\r\n },\r\n \"x-nullable\": false\r\n },\r\n {\r\n \"type\": \"integer\",\r\n \"name\": \"userId\",\r\n \"in\": \"query\",\r\n \"format\": \"int32\",\r\n \"x-nullable\": false\r\n }\r\n ],\r\n \"responses\": {\r\n \"200\": {\r\n \"description\": \"\"\r\n }\r\n }\r\n }\r\n },\r\n \"/api/zeitservice/Projects\": {\r\n \"get\": {\r\n \"tags\": [\r\n \"ZeitService\"\r\n ],\r\n \"operationId\": \"ZeitService_Projects\",\r\n \"produces\": [\r\n \"text/plain\",\r\n \"application/json\",\r\n \"text/json\"\r\n ],\r\n \"responses\": {\r\n \"200\": {\r\n \"x-nullable\": false,\r\n \"description\": \"\",\r\n \"schema\": {\r\n \"type\": \"array\",\r\n \"items\": {\r\n \"type\": \"string\"\r\n }\r\n }\r\n }\r\n }\r\n }\r\n },\r\n \"/api/zeitservice/CalculateEarnings\": {\r\n \"get\": {\r\n \"tags\": [\r\n \"ZeitService\"\r\n ],\r\n \"operationId\": \"ZeitService_CalculateEarnings\",\r\n \"produces\": [\r\n \"text/plain\",\r\n \"application/json\",\r\n \"text/json\"\r\n ],\r\n \"parameters\": [\r\n {\r\n \"type\": \"integer\",\r\n \"name\": \"id\",\r\n \"in\": \"query\",\r\n \"format\": \"int32\",\r\n \"x-nullable\": false\r\n }\r\n ],\r\n \"responses\": {\r\n \"200\": {\r\n \"x-nullable\": false,\r\n \"description\": \"\",\r\n \"schema\": {\r\n \"type\": \"number\",\r\n \"format\": \"decimal\"\r\n }\r\n }\r\n }\r\n }\r\n }\r\n },\r\n \"definitions\": {\r\n \"User\": {\r\n \"type\": \"object\",\r\n \"properties\": {\r\n \"name\": {\r\n \"type\": \"string\"\r\n },\r\n \"passwort\": {\r\n \"type\": \"string\"\r\n }\r\n }\r\n },\r\n \"Time\": {\r\n \"type\": \"object\",\r\n \"required\": [\r\n \"start\",\r\n \"end\",\r\n \"uId\",\r\n \"id\"\r\n ],\r\n \"properties\": {\r\n \"start\": {\r\n \"type\": \"string\",\r\n \"format\": \"date-time\"\r\n },\r\n \"end\": {\r\n \"type\": \"string\",\r\n \"format\": \"date-time\"\r\n },\r\n \"project\": {\r\n \"type\": \"string\"\r\n },\r\n \"uId\": {\r\n \"type\": \"integer\",\r\n \"format\": \"int32\"\r\n },\r\n \"id\": {\r\n \"type\": \"integer\",\r\n \"format\": \"int32\"\r\n }\r\n }\r\n }\r\n }\r\n}",
"url": "http://localhost:52841/swagger/v1/swagger.json",
"output": null,
"newLineBehavior": "Auto"
}
},
"codeGenerators": {
"openApiToCSharpClient": {
"clientBaseClass": null,
"configurationClass": null,
"generateClientClasses": true,
"generateClientInterfaces": true,
"clientBaseInterface": null,
"injectHttpClient": false,
"disposeHttpClient": false,
"protectedMethods": [],
"generateExceptionClasses": true,
"exceptionClass": "ZeitServiceApiException",
"wrapDtoExceptions": true,
"useHttpClientCreationMethod": false,
"httpClientType": "System.Net.Http.HttpClient",
"useHttpRequestMessageCreationMethod": false,
"useBaseUrl": true,
"generateBaseUrlProperty": true,
"generateSyncMethods": true,
"exposeJsonSerializerSettings": false,
"clientClassAccessModifier": "public",
"typeAccessModifier": "public",
"generateContractsOutput": false,
"contractsNamespace": "DataInputt.ZeitService.Api",
"contractsOutputFilePath": null,
"parameterDateTimeFormat": "s",
"parameterDateFormat": "yyyy-MM-dd",
"generateUpdateJsonSerializerSettingsMethod": true,
"useRequestAndResponseSerializationSettings": false,
"serializeTypeInformation": false,
"queryNullValue": "",
"className": "{controller}Client",
"operationGenerationMode": "MultipleClientsFromOperationId",
"additionalNamespaceUsages": [],
"additionalContractNamespaceUsages": [],
"generateOptionalParameters": false,
"generateJsonMethods": false,
"enforceFlagEnums": false,
"parameterArrayType": "System.Collections.Generic.IEnumerable",
"parameterDictionaryType": "System.Collections.Generic.IDictionary",
"responseArrayType": "System.Collections.Generic.List",
"responseDictionaryType": "System.Collections.Generic.IDictionary",
"wrapResponses": false,
"wrapResponseMethods": [],
"generateResponseClasses": true,
"responseClass": "SwaggerResponse",
"namespace": "DataInputt.ZeitService.Api",
"requiredPropertiesMustBeDefined": true,
"dateType": "System.DateTimeOffset",
"jsonConverters": null,
"anyType": "object",
"dateTimeType": "System.DateTimeOffset",
"timeType": "System.TimeSpan",
"timeSpanType": "System.TimeSpan",
"arrayType": "System.Collections.Generic.ICollection",
"arrayInstanceType": "System.Collections.ObjectModel.Collection",
"dictionaryType": "System.Collections.Generic.IDictionary",
"dictionaryInstanceType": "System.Collections.Generic.Dictionary",
"arrayBaseType": "System.Collections.ObjectModel.Collection",
"dictionaryBaseType": "System.Collections.Generic.Dictionary",
"classStyle": "Poco",
"generateDefaultValues": true,
"generateDataAnnotations": true,
"excludedTypeNames": [],
"excludedParameterNames": [],
"handleReferences": false,
"generateImmutableArrayProperties": false,
"generateImmutableDictionaryProperties": false,
"jsonSerializerSettingsTransformationMethod": null,
"inlineNamedArrays": false,
"inlineNamedDictionaries": false,
"inlineNamedTuples": true,
"inlineNamedAny": false,
"generateDtoTypes": false,
"generateOptionalPropertiesAsNullable": false,
"generateNullableReferenceTypes": false,
"templateDirectory": null,
"typeNameGeneratorType": null,
"propertyNameGeneratorType": null,
"enumNameGeneratorType": null,
"serviceHost": null,
"serviceSchemes": null,
"output": "ZeitServiceClient.cs",
"newLineBehavior": "Auto"
}
}
}
13 changes: 13 additions & 0 deletions DataInputt/DataInputt.ZeitService.Api/Time.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
using System;

namespace DataInputt.ZeitService.Api
{
public class Time
{
public DateTime Start { get; set; }
public DateTime End { get; set; }
public string Project { get; set; }
public int uId { get; set; }
public int Id { get; set; }
}
}
8 changes: 8 additions & 0 deletions DataInputt/DataInputt.ZeitService.Api/User.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
namespace DataInputt.ZeitService.Api
{
public class User
{
public string Name { get; set; }
public string Passwort { get; set; }
}
}
Loading