Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue1 class library --> All models put into class library #11

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
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
2 changes: 1 addition & 1 deletion BackEndTests/EmailConfigurationTests.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using System.Collections.Generic;
using System.Text;
using Web.Models;
using PlanYourVoteLibrary2;
using Xunit;

namespace BackEndTests
Expand Down
2 changes: 1 addition & 1 deletion BackEndTests/EmailTests.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Microsoft.Extensions.Options;
using System;
using Web.Controllers;
using Web.Models;
using PlanYourVoteLibrary2;
using Xunit;


Expand Down
6 changes: 6 additions & 0 deletions OpenVoting.sln
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Web", "Web\Web.csproj", "{A
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BackEndTests", "BackEndTests\BackEndTests.csproj", "{B89D3B6C-980D-40D8-A716-27E4B066E444}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PlanYourVoteLibrary2", "PlanYourVoteLibrary2\PlanYourVoteLibrary2.csproj", "{93C0CF7E-E504-424D-9E06-378C7EADCEF4}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -21,6 +23,10 @@ Global
{B89D3B6C-980D-40D8-A716-27E4B066E444}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B89D3B6C-980D-40D8-A716-27E4B066E444}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B89D3B6C-980D-40D8-A716-27E4B066E444}.Release|Any CPU.Build.0 = Release|Any CPU
{93C0CF7E-E504-424D-9E06-378C7EADCEF4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{93C0CF7E-E504-424D-9E06-378C7EADCEF4}.Debug|Any CPU.Build.0 = Debug|Any CPU
{93C0CF7E-E504-424D-9E06-378C7EADCEF4}.Release|Any CPU.ActiveCfg = Release|Any CPU
{93C0CF7E-E504-424D-9E06-378C7EADCEF4}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public class BallotIssue
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public class Candidate
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public enum CandidateDetailFormat
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class CandidateRace
{
Expand Down
3 changes: 2 additions & 1 deletion Web/Models/Contact.cs → PlanYourVoteLibrary2/Contact.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System.ComponentModel.DataAnnotations;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public enum ContactMethod
{
Expand Down
3 changes: 2 additions & 1 deletion Web/Models/Election.cs → PlanYourVoteLibrary2/Election.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
using System.ComponentModel.DataAnnotations;
using System.Text;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public class Election
{
Expand Down
3 changes: 2 additions & 1 deletion Web/Models/Email.cs → PlanYourVoteLibrary2/Email.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
namespace Web.Models
namespace PlanYourVoteLibrary2

{
public class Email
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
namespace Web.Models

namespace PlanYourVoteLibrary2

>>>>>>> e052836aeeba1471d7e823423ddcd29a2b74fee1
{
public class EmailConfiguration
{
Expand Down
4 changes: 3 additions & 1 deletion Web/Models/Image.cs → PlanYourVoteLibrary2/Image.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
using System.ComponentModel.DataAnnotations;
using System.Text;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class Image
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
using System.ComponentModel.DataAnnotations;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class IssueOption
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
using System.Linq;
using System.Threading.Tasks;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class JSONCandidate
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
using System.Linq;
using System.Threading.Tasks;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class JSONPollingPlace
{
Expand Down
4 changes: 3 additions & 1 deletion Web/Models/Map.cs → PlanYourVoteLibrary2/Map.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
using Newtonsoft.Json.Converters;
using System.Globalization;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public partial class Map
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
using System.Linq;
using System.Threading.Tasks;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class MapConfiguration
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class OpenGraph
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class Organization
{
Expand Down
13 changes: 13 additions & 0 deletions PlanYourVoteLibrary2/PlanYourVoteLibrary2.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<Project Sdk="Microsoft.NET.Sdk">

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


<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
<PackageReference Include="System.ComponentModel.Annotations" Version="5.0.0" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
using System.ComponentModel.DataAnnotations;
using System.Text;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public class PollingPlace
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class PollingPlaceDate
{
Expand Down
4 changes: 3 additions & 1 deletion Web/Models/Race.cs → PlanYourVoteLibrary2/Race.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class Race
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
using System.Threading.Tasks;
using System.ComponentModel.DataAnnotations;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class SocialMedia
{
Expand Down
4 changes: 3 additions & 1 deletion Web/Models/State.cs → PlanYourVoteLibrary2/State.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
using System.ComponentModel.DataAnnotations;
using System.Text;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class State
{
Expand Down
3 changes: 2 additions & 1 deletion Web/Models/Step.cs → PlanYourVoteLibrary2/Step.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public class Step
{
Expand Down
4 changes: 3 additions & 1 deletion Web/Models/Theme.cs → PlanYourVoteLibrary2/Theme.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
using System.ComponentModel.DataAnnotations;

namespace Web.Models

namespace PlanYourVoteLibrary2

{
public class Theme
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
using System.ComponentModel.DataAnnotations;
using System.Text;

namespace Web.Models
namespace PlanYourVoteLibrary2

{
public class VoteEvent
{
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/BallotIssuesApiController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Web.Models;
using PlanYourVoteLibrary2;
using Web.Data;
using Web.ApiDTO;

Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/CandidateApiController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Web.Models;
using PlanYourVoteLibrary2;
using Web.Data;

namespace Web.Controllers
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/ElectionsController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Web.Models;
using PlanYourVoteLibrary2;
using Web.Data;

namespace Web.ApiControllers
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/EmailController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Options;
using Web.Models;
using PlanYourVoteLibrary2;

namespace Web.Controllers
{
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/MapController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
using System.Windows.Input;
using Web.ApiDTO;
using Web.Data;
using Web.Models;
using PlanYourVoteLibrary2;

namespace Web.ApiControllers
{
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/PollingPlacesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Web.Models;
using PlanYourVoteLibrary2;
using Web.Data;
using Web.ApiDTO;

Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/RacesApiController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using System.Threading.Tasks;
using Web.ApiDTO;
using Web.Data;
using Web.Models;
using PlanYourVoteLibrary2;

namespace Web.Controllers
{
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/SocialMediasAPIController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Web.Data;
using Web.Models;
using PlanYourVoteLibrary2;

namespace Web.ApiControllers
{
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/StepsApiController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Web.Data;
using Web.Models;
using PlanYourVoteLibrary2;

namespace Web.ApiControllers
{
Expand Down
2 changes: 1 addition & 1 deletion Web/ApiControllers/ThemesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Web.Models;
using PlanYourVoteLibrary2;
using Web.Data;

namespace Web.ApiControllers
Expand Down
2 changes: 1 addition & 1 deletion Web/CmsControllers/BallotIssuesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using System.Linq;
using System.Threading.Tasks;
using Web.Data;
using Web.Models;
using PlanYourVoteLibrary2;
using Web.ViewModels;

namespace Web
Expand Down
Loading