Proj. plan, URS v1.01; UML v1; ModelBinding, DataAnnotations, Models start
This commit is contained in:
78
StudentHouseDashboard/HouseData/ClassDiagram1.cd
Normal file
78
StudentHouseDashboard/HouseData/ClassDiagram1.cd
Normal file
@@ -0,0 +1,78 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ClassDiagram MajorVersion="1" MinorVersion="1">
|
||||
<Class Name="StudentHouseDashboard.Models.Announcement" BaseTypeListCollapsed="true">
|
||||
<Position X="4.75" Y="2" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAACAAAAAEgAEAAiAAAAAAAAAAAAAAAAAAAAAAAIhA=</HashCode>
|
||||
<FileName>Models\Announcement.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
<Lollipop Position="0.2" Collapsed="true" />
|
||||
</Class>
|
||||
<Class Name="StudentHouseDashboard.Models.Comment" BaseTypeListCollapsed="true">
|
||||
<Position X="6.5" Y="2" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAAAAAAAAFgAEAAiAAAAAAAAAAAAAAAAAAAAAAAABA=</HashCode>
|
||||
<FileName>Models\Comment.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
<Lollipop Position="0.2" Collapsed="true" />
|
||||
</Class>
|
||||
<Class Name="StudentHouseDashboard.Models.Complaint" BaseTypeListCollapsed="true">
|
||||
<Position X="8.25" Y="2" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAAAAAEAAAgAEAAiAAAAAAAAAAAAAAAAAAAAAQAAAA=</HashCode>
|
||||
<FileName>Models\Complaint.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
<Lollipop Position="0.2" Collapsed="true" />
|
||||
</Class>
|
||||
<Class Name="StudentHouseDashboard.Models.Event" BaseTypeListCollapsed="true">
|
||||
<Position X="10" Y="2" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAAAAAAAAEgAEAAiAAAAAAgAAAAAAAAAAAAAEAAABA=</HashCode>
|
||||
<FileName>Models\Event.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
<Lollipop Position="0.2" Collapsed="true" />
|
||||
</Class>
|
||||
<Class Name="StudentHouseDashboard.Models.User">
|
||||
<Position X="11.75" Y="2" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAAAAAAAAAAAAAAEQAAAAAAAAAAAAAAAAAAAAAAAAA=</HashCode>
|
||||
<FileName>Models\User.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
</Class>
|
||||
<Interface Name="StudentHouseDashboard.Models.IMessage">
|
||||
<Position X="11.75" Y="5.25" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAAAAAAAAAgAEAAiAAAAAAAAAAAAAAAAAAAAAAAAAA=</HashCode>
|
||||
<FileName>Models\IMessage.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
</Interface>
|
||||
<Interface Name="StudentHouseDashboard.Models.IVotable">
|
||||
<Position X="10" Y="5.25" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABA=</HashCode>
|
||||
<FileName>Models\IVotable.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
</Interface>
|
||||
<Enum Name="StudentHouseDashboard.Models.ComplaintSeverity">
|
||||
<Position X="4.75" Y="5.25" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAEgAAAACgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=</HashCode>
|
||||
<FileName>Models\ComplaintSeverity.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
</Enum>
|
||||
<Enum Name="StudentHouseDashboard.Models.ComplaintStatus">
|
||||
<Position X="6.5" Y="5.25" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAAAAAAABAAAACAAAAAAAAAAAAAAAAAAAAAgAAAAAAA=</HashCode>
|
||||
<FileName>Models\ComplaintStatus.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
</Enum>
|
||||
<Enum Name="StudentHouseDashboard.Models.UserRole">
|
||||
<Position X="8.25" Y="5.25" Width="1.5" />
|
||||
<TypeIdentifier>
|
||||
<HashCode>AAQAAAAAAAAAAAAAAAAAAAAAQAAAAQAAAAAAAAAAAAA=</HashCode>
|
||||
<FileName>Models\UserRole.cs</FileName>
|
||||
</TypeIdentifier>
|
||||
</Enum>
|
||||
<Font Name="Segoe UI" Size="9" />
|
||||
</ClassDiagram>
|
||||
49
StudentHouseDashboard/HouseData/Models/Announcement.cs
Normal file
49
StudentHouseDashboard/HouseData/Models/Announcement.cs
Normal file
@@ -0,0 +1,49 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public class Announcement : IMessage, IVotable
|
||||
{
|
||||
public List<Comment> Comments
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public int IsImportant
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public int IsSticky
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public string Title { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public string Description { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public User Author { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public DateTime PublishDate { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
|
||||
public void DownVote()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public void UpVote()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
32
StudentHouseDashboard/HouseData/Models/Comment.cs
Normal file
32
StudentHouseDashboard/HouseData/Models/Comment.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public class Comment : IMessage, IVotable
|
||||
{
|
||||
public int Responses
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
public string Title { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public string Description { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public User Author { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public DateTime PublishDate { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
|
||||
public void DownVote()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public void UpVote()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
31
StudentHouseDashboard/HouseData/Models/Complaint.cs
Normal file
31
StudentHouseDashboard/HouseData/Models/Complaint.cs
Normal file
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public class Complaint : IMessage
|
||||
{
|
||||
public ComplaintStatus Status
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public ComplaintSeverity Severity
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public string Title { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public string Description { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public User Author { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public DateTime PublishDate { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
}
|
||||
}
|
||||
15
StudentHouseDashboard/HouseData/Models/ComplaintSeverity.cs
Normal file
15
StudentHouseDashboard/HouseData/Models/ComplaintSeverity.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public enum ComplaintSeverity
|
||||
{
|
||||
LOW,
|
||||
NORMAL,
|
||||
HIGH,
|
||||
URGENT
|
||||
}
|
||||
}
|
||||
15
StudentHouseDashboard/HouseData/Models/ComplaintStatus.cs
Normal file
15
StudentHouseDashboard/HouseData/Models/ComplaintStatus.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public enum ComplaintStatus
|
||||
{
|
||||
FILED,
|
||||
UNDER_REVIEW,
|
||||
SOLVED,
|
||||
ARCHIVED
|
||||
}
|
||||
}
|
||||
41
StudentHouseDashboard/HouseData/Models/Event.cs
Normal file
41
StudentHouseDashboard/HouseData/Models/Event.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public class Event : IMessage, IVotable
|
||||
{
|
||||
public int StartDate
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public int EndDate
|
||||
{
|
||||
get => default;
|
||||
set
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public string Title { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public string Description { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public User Author { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
public DateTime PublishDate { get => throw new NotImplementedException(); set => throw new NotImplementedException(); }
|
||||
|
||||
public void DownVote()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public void UpVote()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
15
StudentHouseDashboard/HouseData/Models/IMessage.cs
Normal file
15
StudentHouseDashboard/HouseData/Models/IMessage.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public interface IMessage
|
||||
{
|
||||
string Title { get; set; }
|
||||
string Description { get; set; }
|
||||
User Author { get; set; }
|
||||
DateTime PublishDate { get; set; }
|
||||
}
|
||||
}
|
||||
13
StudentHouseDashboard/HouseData/Models/IVotable.cs
Normal file
13
StudentHouseDashboard/HouseData/Models/IVotable.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public interface IVotable
|
||||
{
|
||||
void UpVote();
|
||||
void DownVote();
|
||||
}
|
||||
}
|
||||
26
StudentHouseDashboard/HouseData/Models/User.cs
Normal file
26
StudentHouseDashboard/HouseData/Models/User.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public class User
|
||||
{
|
||||
public User(int username, UserRole role)
|
||||
{
|
||||
Username = username;
|
||||
Role = role;
|
||||
}
|
||||
|
||||
public int Username
|
||||
{
|
||||
get;set;
|
||||
}
|
||||
|
||||
public UserRole Role
|
||||
{
|
||||
get;set;
|
||||
}
|
||||
}
|
||||
}
|
||||
14
StudentHouseDashboard/HouseData/Models/UserRole.cs
Normal file
14
StudentHouseDashboard/HouseData/Models/UserRole.cs
Normal file
@@ -0,0 +1,14 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace StudentHouseDashboard.Models
|
||||
{
|
||||
public enum UserRole
|
||||
{
|
||||
TENANT,
|
||||
MANAGER,
|
||||
ADMIN
|
||||
}
|
||||
}
|
||||
13
StudentHouseDashboard/HouseData/StudentHouseDashboard.csproj
Normal file
13
StudentHouseDashboard/HouseData/StudentHouseDashboard.csproj
Normal file
@@ -0,0 +1,13 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="Controllers\" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
Reference in New Issue
Block a user