-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/KorzhCom/EasyData
- Loading branch information
Showing
41 changed files
with
528 additions
and
65 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
easydata.net/src/EasyData.AspNetCore/EasyData.AspNetCore.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"assemblyVersion": "1.4.18.1", | ||
"packageVersion": "1.4.18", | ||
"assetVersion": "01_04_18" | ||
"assemblyVersion": "1.4.19.1", | ||
"packageVersion": "1.4.19", | ||
"assetVersion": "01_04_19" | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
playground/EasyDataAspNetCoreTest02/Models/NWind/Category.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.ComponentModel; | ||
using System.ComponentModel.DataAnnotations; | ||
using System.ComponentModel.DataAnnotations.Schema; | ||
using System.Linq; | ||
using System.Threading.Tasks; | ||
|
||
using EasyData.EntityFrameworkCore; | ||
|
||
namespace EasyDataBasicDemo.Models | ||
{ | ||
[MetaEntity(Description = "Categories of Product")] | ||
public class Category | ||
{ | ||
//[DatabaseGenerated(DatabaseGeneratedOption.None)] | ||
[Column("CategoryID")] | ||
public int Id { get; set; } | ||
|
||
public int? LanguageId { get; set; } | ||
public Language Language { get; set; } | ||
|
||
// [MetaEntityAttr(ShowOnCreate = false, ShowOnEdit = false, ShowOnView = false)] | ||
public string CategoryName { get; set; } = "Category name"; | ||
|
||
public string Description { get; set; } | ||
|
||
[ScaffoldColumn(false)] | ||
public byte[] Picture { get; set; } | ||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
playground/EasyDataAspNetCoreTest02/Models/NWind/CityEntity.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
using System; | ||
using EasyData.EntityFrameworkCore; | ||
using Microsoft.EntityFrameworkCore; | ||
|
||
|
||
namespace EasyDataBasicDemo.Models | ||
{ | ||
[Keyless] | ||
[MetaEntity(DisplayName = "City", DisplayNamePlural = "Cities")] | ||
public class CityEntity | ||
{ | ||
public string Country { get; set; } | ||
|
||
public string City { get; set; } | ||
} | ||
} |
35 changes: 35 additions & 0 deletions
35
playground/EasyDataAspNetCoreTest02/Models/NWind/Customer.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
using EasyData.EntityFrameworkCore; | ||
using System.ComponentModel.DataAnnotations; | ||
using System.ComponentModel.DataAnnotations.Schema; | ||
|
||
namespace EasyDataBasicDemo.Models | ||
{ | ||
|
||
[DisplayColumn("Name")] | ||
public class Customer | ||
{ | ||
[Column("CustomerID")] | ||
public string Id { get; set; } | ||
|
||
[Display(Name = "Company Name")] | ||
public string CompanyName { get; set; } | ||
|
||
public string Address { get; set; } | ||
|
||
public string City { get; set; } | ||
|
||
public string Region { get; set; } | ||
|
||
public string PostalCode { get; set; } | ||
|
||
public string Country { get; set; } | ||
|
||
public string ContactName { get; set; } | ||
|
||
public string ContactTitle { get; set; } | ||
|
||
public string Phone { get; set; } | ||
|
||
public string Fax { get; set; } | ||
} | ||
} |
84 changes: 84 additions & 0 deletions
84
playground/EasyDataAspNetCoreTest02/Models/NWind/Employee.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.ComponentModel.DataAnnotations; | ||
using System.ComponentModel.DataAnnotations.Schema; | ||
|
||
using EasyData.EntityFrameworkCore; | ||
|
||
namespace EasyDataBasicDemo.Models | ||
{ | ||
[DisplayColumn("FirstName")] | ||
public class Employee | ||
{ | ||
[DatabaseGenerated(DatabaseGeneratedOption.None)] | ||
[Column("EmployeeID")] | ||
public int Id { get; set; } | ||
|
||
[Required] | ||
[Display(Name = "Last name")] | ||
public string LastName { get; set; } | ||
|
||
[Required] | ||
[Display(Name = "First name")] | ||
public string FirstName { get; set; } | ||
|
||
[NotMapped] | ||
public string FullName { | ||
get { | ||
string res = this.FirstName; | ||
|
||
if (!string.IsNullOrEmpty(res)) | ||
res += " "; | ||
|
||
if (!string.IsNullOrEmpty(this.LastName)) | ||
res += this.LastName; | ||
return res; | ||
} | ||
} | ||
|
||
|
||
[MaxLength(30)] | ||
public string Title { get; set; } | ||
|
||
public string TitleOfCourtesy { get; set; } | ||
|
||
[Display(Name = "Birth date")] | ||
public DateTime? BirthDate { get; set; } | ||
|
||
public DateTime? HireDate { get; set; } | ||
|
||
public string Address { get; set; } | ||
|
||
public string City { get; set; } | ||
|
||
public string Region { get; set; } | ||
|
||
public string PostalCode { get; set; } | ||
|
||
public string Country { get; set; } | ||
|
||
[MaxLength(24)] | ||
public string HomePhone { get; set; } | ||
|
||
[MaxLength(4)] | ||
public string Extension { get; set; } | ||
|
||
[ScaffoldColumn(false)] | ||
public byte[] Photo { get; set; } | ||
|
||
public string PhotoPath { get; set; } | ||
|
||
public string Notes { get; set; } | ||
|
||
[ScaffoldColumn(false)] | ||
public int? ReportsTo { get; set; } | ||
|
||
[ForeignKey("ReportsTo")] | ||
public virtual Employee Manager { get; set; } | ||
|
||
public virtual ICollection<Order> Orders { get; set; } | ||
|
||
} | ||
|
||
|
||
} |
20 changes: 20 additions & 0 deletions
20
playground/EasyDataAspNetCoreTest02/Models/NWind/Language.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
using EasyData; | ||
using EasyData.EntityFrameworkCore; | ||
|
||
namespace EasyDataBasicDemo.Models | ||
{ | ||
public class Language | ||
{ | ||
public int Id { get; set; } | ||
public string Name { get; set; } | ||
public string ShortName { get; set; } | ||
|
||
public Guid GuidTest { get; set; } | ||
} | ||
} |
Oops, something went wrong.