Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
W
Webinar_51
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alexey Goikolov
Webinar_51
Commits
2abd503b
Commit
2abd503b
authored
Mar 31, 2021
by
Alexey Goikolov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Добавил модель User и прописал в MobileContext
parent
ff9f7f3d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
0 deletions
+15
-0
MobileContext.cs
Lesson49/Models/Data/MobileContext.cs
+1
-0
User.cs
Lesson49/Models/User.cs
+14
-0
No files found.
Lesson49/Models/Data/MobileContext.cs
View file @
2abd503b
...
...
@@ -7,6 +7,7 @@ namespace Lesson49.Models.Data
public
DbSet
<
Phone
>
Phones
{
get
;
set
;
}
public
DbSet
<
Order
>
Orders
{
get
;
set
;
}
public
DbSet
<
Brand
>
Brands
{
get
;
set
;
}
public
DbSet
<
User
>
Users
{
get
;
set
;
}
public
MobileContext
(
DbContextOptions
<
MobileContext
>
options
)
:
base
(
options
){}
}
...
...
Lesson49/Models/User.cs
0 → 100644
View file @
2abd503b
namespace
Lesson49.Models
{
public
class
User
{
public
string
Name
{
get
;
set
;
}
public
string
Surname
{
get
;
set
;
}
public
int
Age
{
get
;
set
;
}
public
override
string
ToString
()
{
return
$"Name -
{
Name
}
\nSurname -
{
Surname
}
\nAge -
{
Age
}
"
;
}
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment