├── .gitignore ├── README.md ├── demos-core └── KendoCRUDService │ ├── KendoCRUDService.sln │ └── KendoCRUDService │ ├── Content │ ├── editor │ │ ├── SubFolder │ │ │ ├── a100.png │ │ │ ├── aeroviewr.png │ │ │ ├── chart-wrapper-small.png │ │ │ ├── demos-dataviz.png │ │ │ └── demos-mobile.png │ │ ├── a100.png │ │ ├── aeroviewr.png │ │ ├── chart-wrapper-small.png │ │ ├── demos-dataviz.png │ │ ├── demos-mobile.png │ │ ├── demos-web.png │ │ ├── dojo-banner.jpg │ │ ├── hand-ipad.png │ │ ├── sushi.png │ │ └── themebuilder.png │ └── filemanager │ │ ├── Documents │ │ ├── ExcelDocument.xlsx │ │ ├── SamplePDF.pdf │ │ ├── Text.txt │ │ └── WordDocument.docx │ │ └── Images │ │ ├── a100.png │ │ ├── aeroviewr.png │ │ ├── chart-wrapper-small.png │ │ ├── demos-dataviz.png │ │ ├── demos-mobile.png │ │ ├── demos-web.png │ │ ├── dojo-banner.jpg │ │ ├── hand-ipad.png │ │ ├── sushi.png │ │ └── themebuilder.png │ ├── Controllers │ ├── CategoriesController.cs │ ├── CountriesController.cs │ ├── CustomersController.cs │ ├── DetailProductsController.cs │ ├── DiagramConnectionsController.cs │ ├── DiagramShapesController.cs │ ├── EmployeeDirectoryController.cs │ ├── EmployeesController.cs │ ├── EmployeesOrgChartController.cs │ ├── ExportController.cs │ ├── FileBrowserController.cs │ ├── FileManagerController.cs │ ├── FormUploadController.cs │ ├── GanttDependenciesController.cs │ ├── GanttResourceAssignmentsController.cs │ ├── GanttResourcesController.cs │ ├── GanttTasksController.cs │ ├── HierarchicalMeetingsController.cs │ ├── ImageBrowserController.cs │ ├── LLMController.cs │ ├── MeetingsController.cs │ ├── OrdersController.cs │ ├── ProductsController.cs │ ├── RedditImagesController.cs │ ├── StockDataController.cs │ ├── TaskBoardController.cs │ ├── TasksController.cs │ ├── TwitterController.cs │ └── WeatherController.cs │ ├── Data │ ├── DemoDbContext.cs │ ├── Models │ │ ├── CardModel.cs │ │ ├── Category.cs │ │ ├── ColumnModel.cs │ │ ├── Country.cs │ │ ├── Customer.cs │ │ ├── CustomerCustomerDemo.cs │ │ ├── CustomerDemographic.cs │ │ ├── DataFilter.cs │ │ ├── DetailProduct.cs │ │ ├── Employee.cs │ │ ├── EmployeeDirectory.cs │ │ ├── EmployeeDirectoryModel.cs │ │ ├── EmployeeTerritory.cs │ │ ├── FileManagerEntry.cs │ │ ├── GanttDependency.cs │ │ ├── GanttResource.cs │ │ ├── GanttResourceAssignment.cs │ │ ├── GanttTask.cs │ │ ├── Intraday.cs │ │ ├── Meeting.cs │ │ ├── MeetingAttendee.cs │ │ ├── MeetingSignalR.cs │ │ ├── Order.cs │ │ ├── OrderDetail.cs │ │ ├── OrgChartConnection.cs │ │ ├── OrgChartShape.cs │ │ ├── Product.cs │ │ ├── ProductSignalR.cs │ │ ├── Region.cs │ │ ├── SchedulerEvent.cs │ │ ├── Shipper.cs │ │ ├── Stock.cs │ │ ├── StockDataPoint.cs │ │ ├── Supplier.cs │ │ ├── Task.cs │ │ ├── Territory.cs │ │ ├── UrbanArea.cs │ │ ├── Weather.cs │ │ └── WeatherModel.cs │ └── Repositories │ │ ├── CategoriesRepository.cs │ │ ├── CountryRepository.cs │ │ ├── CustomerRepository.cs │ │ ├── DetailProductRepository.cs │ │ ├── DiagramConnectionsRepository.cs │ │ ├── DiagramShapesRepository.cs │ │ ├── DirectoryRepository.cs │ │ ├── EmployeeDrirectoryRepository.cs │ │ ├── EmployeeOrgChartRepository.cs │ │ ├── EmployeeRepository.cs │ │ ├── FileBrowserRepository.cs │ │ ├── GanttDependencyRepository.cs │ │ ├── GanttResourceAssignmentsRepository.cs │ │ ├── GanttResourcesRepository.cs │ │ ├── GanttTaskRepository.cs │ │ ├── MeetingsRepository.cs │ │ ├── OrderRepository.cs │ │ ├── ProductRepository.cs │ │ ├── TaskBoardRepository.cs │ │ ├── TasksRepository.cs │ │ └── WeatherRepository.cs │ ├── Enums │ └── BaseUnit.cs │ ├── Extensions │ ├── AggregateExtension.cs │ ├── CommonExtension.cs │ ├── ExpressionExtension.cs │ ├── FilteringExtension.cs │ ├── GroupingExtension.cs │ ├── PagingExtension.cs │ ├── SessionExtensions.cs │ ├── SortingExtension.cs │ └── Utils.cs │ ├── FileBrowser │ ├── DirectoryBrowser.cs │ ├── EntryType.cs │ ├── FileBrowserEntry.cs │ ├── FitImageResizer.cs │ ├── ImageSize.cs │ └── ThumbnailCreator.cs │ ├── Filters │ ├── ApiKeyAuthFilter .cs │ ├── RateLimitAttribute.cs │ ├── RequestRateLimiter.cs │ └── RestrictDomainAttribute.cs │ ├── Hubs │ ├── BaseHub.cs │ ├── MeetingHub.cs │ └── ProductHub.cs │ ├── KendoCRUDService.csproj │ ├── Models │ ├── CustomerViewModel.cs │ ├── DetailProductSubmitViewModel.cs │ ├── EmployeeCompleteViewModel.cs │ ├── EmployeeNodeViewModel.cs │ ├── EmployeeViewModel.cs │ ├── ErrorViewModel.cs │ ├── FormUploadItemsViewModel.cs │ ├── FormUploadViewModel.cs │ ├── MeetingViewModel.cs │ ├── Request │ │ ├── AggregateRequest.cs │ │ ├── Filter.cs │ │ ├── GroupRequest.cs │ │ ├── Request.cs │ │ └── Sort.cs │ ├── Response │ │ ├── Group.cs │ │ └── Response.cs │ ├── SpreadsheetSubmitViewModel.cs │ └── TaskViewModel.cs │ ├── Program.cs │ ├── Properties │ └── launchSettings.json │ ├── Settings │ └── ApiKeySettings.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ └── wwwroot │ ├── Content │ ├── editor │ │ ├── SubFolder │ │ │ ├── a100.png │ │ │ ├── aeroviewr.png │ │ │ ├── chart-wrapper-small.png │ │ │ ├── demos-dataviz.png │ │ │ └── demos-mobile.png │ │ ├── a100.png │ │ ├── aeroviewr.png │ │ ├── chart-wrapper-small.png │ │ ├── demos-dataviz.png │ │ ├── demos-mobile.png │ │ ├── demos-web.png │ │ ├── dojo-banner.jpg │ │ ├── hand-ipad.png │ │ ├── sushi.png │ │ └── themebuilder.png │ └── filemanager │ │ ├── Documents │ │ ├── ExcelDocument.xlsx │ │ ├── SamplePDF.pdf │ │ ├── Text.txt │ │ └── WordDocument.docx │ │ └── Images │ │ ├── a100.png │ │ ├── aeroviewr.png │ │ ├── chart-wrapper-small.png │ │ ├── demos-dataviz.png │ │ ├── demos-mobile.png │ │ ├── demos-web.png │ │ ├── dojo-banner.jpg │ │ ├── hand-ipad.png │ │ ├── sushi.png │ │ └── themebuilder.png │ └── data │ ├── sample.db │ ├── sample.db-shm │ └── sample.db-wal ├── graphql └── graphql-aspnet-core │ ├── graphql-aspnet-core.sln │ └── graphql-aspnet-core │ ├── Controllers │ ├── CustomersController.cs │ ├── GraphQLController.cs │ └── ServerOperationsController.cs │ ├── Data │ ├── Contracts │ │ └── IProductRepository.cs │ ├── CustomersEntities.cs │ ├── Entities │ │ └── Customer.cs │ ├── Repositories │ │ └── ProductRepository.cs │ ├── SampleEntities.cs │ ├── SamplesEntities │ │ ├── Category.cs │ │ ├── Customer.cs │ │ ├── CustomerCustomerDemo.cs │ │ ├── CustomerDemographic.cs │ │ ├── Employee.cs │ │ ├── EmployeeDirectory.cs │ │ ├── EmployeeTerritory.cs │ │ ├── GanttDependency.cs │ │ ├── GanttResource.cs │ │ ├── GanttResourceAssignment.cs │ │ ├── GanttTask.cs │ │ ├── Intraday.cs │ │ ├── Meeting.cs │ │ ├── MeetingAttendee.cs │ │ ├── Order.cs │ │ ├── OrderDetail.cs │ │ ├── OrgChartConnection.cs │ │ ├── OrgChartShape.cs │ │ ├── Product.cs │ │ ├── Region.cs │ │ ├── Shipper.cs │ │ ├── Stock.cs │ │ ├── Supplier.cs │ │ ├── Task.cs │ │ ├── Territory.cs │ │ ├── UrbanArea.cs │ │ └── Weather.cs │ └── Seeder.cs │ ├── Models │ └── GraphQL │ │ ├── GraphQLQuery.cs │ │ └── Product │ │ ├── GraphQLActionResult.cs │ │ ├── ProductInputType.cs │ │ ├── ProductMutation.cs │ │ ├── ProductQuery.cs │ │ ├── ProductType.cs │ │ └── ProductsSchema.cs │ ├── Program.cs │ ├── Properties │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── graphql-aspnet-core.csproj │ └── wwwroot │ ├── App_Data │ ├── customers.db │ └── sample.db │ ├── cities.txt │ └── favicon.ico ├── odata-v4-core └── kendo-northwind-pg │ ├── kendo-northwind-pg.sln │ └── kendo-northwind-pg │ ├── Controllers │ ├── CategoriesController.cs │ ├── CustomersController.cs │ ├── EmployeesController.cs │ ├── GanttDependenciesController.cs │ ├── GanttTasksController.cs │ ├── Order_DetailController.cs │ ├── OrdersController.cs │ ├── ProductsController.cs │ ├── RegionsController.cs │ ├── ShippersController.cs │ ├── SuppliersController.cs │ ├── TerritoriesController.cs │ └── UploadController.cs │ ├── Data │ ├── DemoDbContext.cs │ ├── Models │ │ ├── Category.cs │ │ ├── Customer.cs │ │ ├── CustomerCustomerDemo.cs │ │ ├── CustomerDemographic.cs │ │ ├── DetailProduct.cs │ │ ├── Employee.cs │ │ ├── EmployeeDirectory.cs │ │ ├── EmployeeTerritory.cs │ │ ├── GanttDependency.cs │ │ ├── GanttResource.cs │ │ ├── GanttResourceAssignment.cs │ │ ├── GanttTask.cs │ │ ├── Intraday.cs │ │ ├── Meeting.cs │ │ ├── MeetingAttendee.cs │ │ ├── OdataModels.cs │ │ ├── Order.cs │ │ ├── OrderDetail.cs │ │ ├── OrgChartConnection.cs │ │ ├── OrgChartShape.cs │ │ ├── Product.cs │ │ ├── Region.cs │ │ ├── Shipper.cs │ │ ├── Stock.cs │ │ ├── Supplier.cs │ │ ├── Task.cs │ │ ├── Territory.cs │ │ └── UrbanArea.cs │ └── Repositories │ │ ├── CustomersRepository.cs │ │ ├── EmployeeRepository.cs │ │ ├── GanttDependencyRepository.cs │ │ ├── GanttTaskRepository.cs │ │ ├── OrdersRepository.cs │ │ ├── ProductRepository.cs │ │ ├── RegionsRepository.cs │ │ ├── ShippersRepository.cs │ │ ├── SuppliersRepository.cs │ │ └── TerritoriesRepository.cs │ ├── Extensions │ ├── SessionExtensions.cs │ └── SessionUtils.cs │ ├── ODataBatchBodyPreProcessMiddleware.cs │ ├── ODataBatchHttpContextMiddleware.cs │ ├── Program.cs │ ├── Properties │ └── launchSettings.json │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── kendo-northwind-pg.csproj │ └── wwwroot │ └── data │ ├── sample.db │ ├── sample.db-shm │ └── sample.db-wal └── signalr-hubs ├── README.md ├── signalr-for-aspnet-core.sln └── signalr-for-aspnet-core ├── Hubs ├── MeetingHub.cs └── ProductHub.cs ├── Models ├── CategorySignalR.cs ├── MeetingSignalR.cs ├── ProductSignalR.cs ├── SampleEntities.cs ├── SamplesEntities │ ├── Category.cs │ ├── Customer.cs │ ├── CustomerCustomerDemo.cs │ ├── CustomerDemographic.cs │ ├── Employee.cs │ ├── EmployeeDirectory.cs │ ├── EmployeeTerritory.cs │ ├── GanttDependency.cs │ ├── GanttResource.cs │ ├── GanttResourceAssignment.cs │ ├── GanttTask.cs │ ├── Intraday.cs │ ├── Meeting.cs │ ├── MeetingAttendee.cs │ ├── Order.cs │ ├── OrderDetail.cs │ ├── OrgChartConnection.cs │ ├── OrgChartShape.cs │ ├── Product.cs │ ├── Region.cs │ ├── Shipper.cs │ ├── Stock.cs │ ├── Supplier.cs │ ├── Task.cs │ ├── Territory.cs │ ├── UrbanArea.cs │ └── Weather.cs └── SchedulerEvent.cs ├── Program.cs ├── Properties └── launchSettings.json ├── appsettings.Development.json ├── appsettings.json ├── signalr-for-aspnet-core.csproj └── wwwroot └── App_Data └── sample.db /README.md: -------------------------------------------------------------------------------- 1 | # kendo-ui-demos-service 2 | Back-end service used for the [Kendo UI Online Demos](http://demos.telerik.com/kendo-ui/) 3 | 4 | This is an ASP.NET MVC application, but it doesn't need to be. Any other server framework will work just as well. 5 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 17 4 | VisualStudioVersion = 17.6.33723.286 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KendoCRUDService", "KendoCRUDService\KendoCRUDService.csproj", "{0341E3B7-6577-40BF-B4F7-3EECED1985BB}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {0341E3B7-6577-40BF-B4F7-3EECED1985BB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {0341E3B7-6577-40BF-B4F7-3EECED1985BB}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {0341E3B7-6577-40BF-B4F7-3EECED1985BB}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {0341E3B7-6577-40BF-B4F7-3EECED1985BB}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {3C7BD298-5870-48F5-8215-7EE00C7DED32} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/a100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/a100.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/aeroviewr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/aeroviewr.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/chart-wrapper-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/chart-wrapper-small.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/demos-dataviz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/demos-dataviz.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/demos-mobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/SubFolder/demos-mobile.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/a100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/a100.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/aeroviewr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/aeroviewr.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/chart-wrapper-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/chart-wrapper-small.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/demos-dataviz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/demos-dataviz.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/demos-mobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/demos-mobile.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/demos-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/demos-web.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/dojo-banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/dojo-banner.jpg -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/hand-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/hand-ipad.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/sushi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/sushi.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/editor/themebuilder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/editor/themebuilder.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/ExcelDocument.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/ExcelDocument.xlsx -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/SamplePDF.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/SamplePDF.pdf -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/Text.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/Text.txt -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/WordDocument.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Documents/WordDocument.docx -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/a100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/a100.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/aeroviewr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/aeroviewr.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/chart-wrapper-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/chart-wrapper-small.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/demos-dataviz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/demos-dataviz.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/demos-mobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/demos-mobile.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/demos-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/demos-web.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/dojo-banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/dojo-banner.jpg -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/hand-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/hand-ipad.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/sushi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/sushi.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/themebuilder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/Content/filemanager/Images/themebuilder.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/CategoriesController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Repositories; 2 | using Microsoft.AspNetCore.Mvc; 3 | 4 | namespace KendoCRUDService.Controllers 5 | { 6 | public class Categories : Controller 7 | { 8 | private readonly CategoriesRepository _categoriesRepository; 9 | 10 | public Categories(CategoriesRepository orderRepository) 11 | { 12 | _categoriesRepository = orderRepository; 13 | } 14 | 15 | public ActionResult Index() 16 | { 17 | return Json(_categoriesRepository.All()); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/CountriesController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Repositories; 2 | using Microsoft.AspNetCore.Mvc; 3 | 4 | namespace KendoCRUDService.Controllers 5 | { 6 | public class CountriesController : Controller 7 | { 8 | private readonly CountryRepository _countryRepository; 9 | 10 | public CountriesController(CountryRepository countryRepository) 11 | { 12 | _countryRepository = countryRepository; 13 | } 14 | 15 | public ActionResult Index() 16 | { 17 | return Json(_countryRepository.All()); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/CustomersController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Repositories; 2 | using Microsoft.AspNetCore.Mvc; 3 | 4 | namespace KendoCRUDService.Controllers 5 | { 6 | public class CustomersController : Controller 7 | { 8 | private readonly CustomerRepository _customerRepository; 9 | 10 | public CustomersController(CustomerRepository customerRepository) 11 | { 12 | _customerRepository = customerRepository; 13 | } 14 | 15 | public ActionResult Index() 16 | { 17 | return Json(_customerRepository.All()); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/DiagramConnectionsController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Data.Repositories; 3 | using Microsoft.AspNetCore.Mvc; 4 | 5 | namespace KendoCRUDService.Controllers 6 | { 7 | public class DiagramConnectionsController : Controller 8 | { 9 | private readonly DiagramConnectionsRepository _diagramConnectionsRepository; 10 | public DiagramConnectionsController(DiagramConnectionsRepository diagramConnectionsRepository) 11 | { 12 | _diagramConnectionsRepository = diagramConnectionsRepository; 13 | } 14 | 15 | public ActionResult Index() 16 | { 17 | return Json(_diagramConnectionsRepository.All()); 18 | } 19 | 20 | public JsonResult Update(IEnumerable models) 21 | { 22 | if (models != null) 23 | { 24 | _diagramConnectionsRepository.Update(models); 25 | } 26 | return Json(models); 27 | } 28 | 29 | public ActionResult Destroy(IEnumerable models) 30 | { 31 | if (models != null) 32 | { 33 | _diagramConnectionsRepository.Delete(models); 34 | } 35 | return Json(models); 36 | } 37 | 38 | public ActionResult Create(IEnumerable models) 39 | { 40 | if (models != null) 41 | { 42 | _diagramConnectionsRepository.Insert(models); 43 | } 44 | return Json(models); 45 | } 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/DiagramShapesController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Data.Repositories; 3 | using Microsoft.AspNetCore.Mvc; 4 | 5 | namespace KendoCRUDService.Controllers 6 | { 7 | public class DiagramShapesController : Controller 8 | { 9 | private readonly DiagramShapesRepository _diagramShapesRepository; 10 | 11 | public DiagramShapesController(DiagramShapesRepository diagramShapesRepository) 12 | { 13 | _diagramShapesRepository = diagramShapesRepository; 14 | } 15 | 16 | public ActionResult Index() 17 | { 18 | return Json(_diagramShapesRepository.All()); 19 | } 20 | 21 | public JsonResult Update([FromBody] IEnumerable models) 22 | { 23 | if (models != null) 24 | { 25 | _diagramShapesRepository.Update(models); 26 | } 27 | return Json(models); 28 | } 29 | 30 | public ActionResult Destroy([FromBody] IEnumerable models) 31 | { 32 | if (models != null) 33 | { 34 | _diagramShapesRepository.Delete(models); 35 | } 36 | return Json(models); 37 | } 38 | 39 | public ActionResult Create([FromBody] IEnumerable models) 40 | { 41 | if (models != null) 42 | { 43 | _diagramShapesRepository.Insert(models); 44 | } 45 | return Json(models); 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/ExportController.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore.Mvc; 2 | 3 | namespace KendoCRUDService.Controllers 4 | { 5 | public class ExportController : Controller 6 | { 7 | [HttpPost] 8 | public ActionResult Index(string contentType, string base64, string fileName) 9 | { 10 | if (Request.Host.Host.EndsWith("telerik.com")) 11 | { 12 | var fileContents = Convert.FromBase64String(base64); 13 | 14 | return File(fileContents, contentType, fileName); 15 | } 16 | 17 | return new ObjectResult("Available only for demos.telerik.com") { StatusCode = 403}; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/GanttDependenciesController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Data.Repositories; 3 | using Microsoft.AspNetCore.Mvc; 4 | 5 | namespace KendoCRUDService.Controllers 6 | { 7 | public class GanttDependenciesController : Controller 8 | { 9 | private readonly GanttDependencyRepository _ganttDependencyRepository; 10 | 11 | public GanttDependenciesController(GanttDependencyRepository ganttDependencyRepository) 12 | { 13 | _ganttDependencyRepository = ganttDependencyRepository; 14 | } 15 | 16 | public ActionResult Index() 17 | { 18 | return Json(_ganttDependencyRepository.All()); 19 | } 20 | 21 | public JsonResult Update([FromBody] IEnumerable models) 22 | { 23 | if (models != null) 24 | { 25 | _ganttDependencyRepository.Update(models); 26 | } 27 | return Json(models); 28 | } 29 | 30 | public ActionResult Destroy([FromBody] IEnumerable models) 31 | { 32 | if (models != null) 33 | { 34 | _ganttDependencyRepository.Delete(models); 35 | } 36 | return Json(models); 37 | } 38 | 39 | public ActionResult Create([FromBody] IEnumerable models) 40 | { 41 | if (models != null) 42 | { 43 | _ganttDependencyRepository.Insert(models); 44 | } 45 | return Json(models); 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/GanttResourceAssignmentsController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Data.Repositories; 3 | using Microsoft.AspNetCore.Mvc; 4 | 5 | namespace KendoCRUDService.Controllers 6 | { 7 | public class GanttResourceAssignmentsController : Controller 8 | { 9 | private readonly GanttResourceAssignmentsRepository _ganttResourceAssignmentsRepository; 10 | 11 | public GanttResourceAssignmentsController(GanttResourceAssignmentsRepository ganttResourceAssignmentsRepository) 12 | { 13 | _ganttResourceAssignmentsRepository = ganttResourceAssignmentsRepository; 14 | } 15 | 16 | public ActionResult Index() 17 | { 18 | return Json(_ganttResourceAssignmentsRepository.All()); 19 | } 20 | 21 | public JsonResult Update([FromBody] IEnumerable models) 22 | { 23 | if (models != null) 24 | { 25 | _ganttResourceAssignmentsRepository.Update(models); 26 | } 27 | return Json(models); 28 | } 29 | 30 | public ActionResult Destroy([FromBody] IEnumerable models) 31 | { 32 | if (models != null) 33 | { 34 | _ganttResourceAssignmentsRepository.Delete(models); 35 | } 36 | return Json(models); 37 | } 38 | 39 | public ActionResult Create([FromBody] IEnumerable models) 40 | { 41 | if (models != null) 42 | { 43 | _ganttResourceAssignmentsRepository.Insert(models); 44 | } 45 | return Json(models); 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/GanttResourcesController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Repositories; 2 | using Microsoft.AspNetCore.Mvc; 3 | 4 | namespace KendoCRUDService.Controllers 5 | { 6 | public class GanttResourcesController : Controller 7 | { 8 | private readonly GanttResourcesRepository _ganttResourcesRepository; 9 | 10 | public GanttResourcesController(GanttResourcesRepository ganttResourcesRepository) 11 | { 12 | _ganttResourcesRepository = ganttResourcesRepository; 13 | } 14 | 15 | public ActionResult Index() 16 | { 17 | return Json(_ganttResourcesRepository.All()); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/GanttTasksController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Data.Repositories; 3 | using Microsoft.AspNetCore.Mvc; 4 | using Microsoft.EntityFrameworkCore.Metadata.Internal; 5 | 6 | namespace KendoCRUDService.Controllers 7 | { 8 | public class GanttTasksController : Controller 9 | { 10 | private readonly GanttTaskRepository _ganttTaskRepository; 11 | 12 | public GanttTasksController(GanttTaskRepository ganttTaskRepository) 13 | { 14 | _ganttTaskRepository = ganttTaskRepository; 15 | } 16 | 17 | public ActionResult Index() 18 | { 19 | return Json(_ganttTaskRepository.All()); 20 | } 21 | 22 | public ActionResult Update([FromBody]IEnumerable models) 23 | { 24 | if (models != null) 25 | { 26 | _ganttTaskRepository.Update(models); 27 | } 28 | return Json(models); 29 | } 30 | 31 | public ActionResult Destroy([FromBody]IEnumerable models) 32 | { 33 | if (models != null) 34 | { 35 | _ganttTaskRepository.Delete(models); 36 | } 37 | return Json(models); 38 | } 39 | 40 | public ActionResult Create([FromBody] IEnumerable models) 41 | { 42 | if (models != null) 43 | { 44 | _ganttTaskRepository.Insert(models); 45 | } 46 | return Json(models); 47 | } 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/OrdersController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Repositories; 2 | using Microsoft.AspNetCore.Mvc; 3 | 4 | namespace KendoCRUDService.Controllers 5 | { 6 | public class OrdersController : Controller 7 | { 8 | private readonly OrderRepository _orderRepository; 9 | 10 | public OrdersController(OrderRepository orderRepository) 11 | { 12 | _orderRepository = orderRepository; 13 | } 14 | 15 | public ActionResult Index() 16 | { 17 | return Json(_orderRepository.All()); 18 | } 19 | 20 | public ActionResult ValueMapper(int?[] values) 21 | { 22 | var indices = new List(); 23 | 24 | if (values != null && values.Any()) 25 | { 26 | var index = 0; 27 | foreach (var order in _orderRepository.All()) 28 | { 29 | if (values.Contains(order.OrderID)) 30 | { 31 | indices.Add(index); 32 | } 33 | 34 | index += 1; 35 | } 36 | } 37 | 38 | return Json(indices); 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Controllers/WeatherController.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Repositories; 2 | using Microsoft.AspNetCore.Mvc; 3 | 4 | namespace KendoCRUDService.Controllers 5 | { 6 | public class WeatherController : Controller 7 | { 8 | private readonly WeatherRepository _weatherRepository; 9 | 10 | public WeatherController(WeatherRepository weatherRepository) 11 | { 12 | _weatherRepository = weatherRepository; 13 | } 14 | 15 | // 16 | // GET: /Weather/SOFIA 17 | 18 | [Route("/[controller]/{station}")] 19 | public ActionResult Index(string station) 20 | { 21 | return Json(_weatherRepository.ByStation(station)); 22 | } 23 | 24 | // 25 | // GET: /Weather/SOFIA/2012/1 26 | // (January) 27 | [Route("/[controller]/{station}/{year}/{month}")] 28 | public ActionResult ByMonth(string station, int year, int month) 29 | { 30 | return Json(_weatherRepository.ByMonth(station, year, month)); 31 | } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/CardModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public class CardModel 4 | { 5 | public int ID { get; set; } 6 | public string Category { get; set; } 7 | public string Title { get; set; } 8 | public int Order { get; set; } 9 | public string Description { get; set; } 10 | public string Status { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Category.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Category 4 | { 5 | public Category() 6 | { 7 | DetailProducts = new HashSet(); 8 | Products = new HashSet(); 9 | } 10 | 11 | public int CategoryID { get; set; } 12 | public string CategoryName { get; set; } 13 | public string Description { get; set; } 14 | public byte[] Picture { get; set; } 15 | 16 | public virtual ICollection DetailProducts { get; set; } 17 | public virtual ICollection Products { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/ColumnModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public class ColumnModel 4 | { 5 | public int ID { get; set; } 6 | public string Text { get; set; } 7 | public int Order { get; set; } 8 | public string Status { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Country.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Country 4 | { 5 | public Country() 6 | { 7 | DetailProducts = new HashSet(); 8 | } 9 | 10 | public int CountryID { get; set; } 11 | public string CountryNameShort { get; set; } 12 | public string CountryNameLong { get; set; } 13 | 14 | public virtual ICollection DetailProducts { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Customer.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Customer 4 | { 5 | public Customer() 6 | { 7 | CustomerCustomerDemo = new HashSet(); 8 | Orders = new HashSet(); 9 | } 10 | 11 | public string CustomerID { get; set; } 12 | public string Address { get; set; } 13 | public bool Bool { get; set; } 14 | public string City { get; set; } 15 | public string CompanyName { get; set; } 16 | public string ContactName { get; set; } 17 | public string ContactTitle { get; set; } 18 | public string Country { get; set; } 19 | public string Fax { get; set; } 20 | public string Phone { get; set; } 21 | public string PostalCode { get; set; } 22 | public string Region { get; set; } 23 | 24 | public virtual ICollection CustomerCustomerDemo { get; set; } 25 | public virtual ICollection Orders { get; set; } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/CustomerCustomerDemo.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class CustomerCustomerDemo 4 | { 5 | public string CustomerID { get; set; } 6 | public string CustomerTypeID { get; set; } 7 | 8 | public virtual Customer Customer { get; set; } 9 | public virtual CustomerDemographic CustomerType { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/CustomerDemographic.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class CustomerDemographic 4 | { 5 | public CustomerDemographic() 6 | { 7 | CustomerCustomerDemo = new HashSet(); 8 | } 9 | 10 | public string CustomerTypeID { get; set; } 11 | 12 | public string CustomerDesc { get; set; } 13 | 14 | public virtual ICollection CustomerCustomerDemo { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/DataFilter.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | /// 4 | /// Represents a filter expression of Kendo DataSource. 5 | /// 6 | public class DataFilter 7 | { 8 | /// 9 | /// Gets or sets the name of the sorted field (property). Set to null if the Filters property is set. 10 | /// 11 | public string Field { get; set; } 12 | 13 | /// 14 | /// Gets or sets the filtering operator. Set to null if the Filters property is set. 15 | /// 16 | public string Operator { get; set; } 17 | 18 | /// 19 | /// Gets or sets the filtering value. Set to null if the Filters property is set. 20 | /// 21 | public object Value { get; set; } 22 | 23 | /// 24 | /// Gets or sets the filtering logic. Can be set to "or" or "and". Set to null unless Filters is set. 25 | /// 26 | public string Logic { get; set; } 27 | 28 | /// 29 | /// Gets or sets the child filter expressions. Set to null if there are no child expressions. 30 | /// 31 | public IList Filters { get; set; } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/DetailProduct.cs: -------------------------------------------------------------------------------- 1 | using System.ComponentModel.DataAnnotations.Schema; 2 | 3 | namespace KendoCRUDService.Data.Models 4 | { 5 | public partial class DetailProduct 6 | { 7 | public int ProductID { get; set; } 8 | public string ProductName { get; set; } 9 | public decimal? UnitPrice { get; set; } 10 | public int? UnitsInStock { get; set; } 11 | public string QuantityPerUnit { get; set; } 12 | public bool Discontinued { get; set; } 13 | public int? UnitsOnOrder { get; set; } 14 | public int? CategoryID { get; set; } 15 | public int? CountryID { get; set; } 16 | public int CustomerRating { get; set; } 17 | public int TargetSales { get; set; } 18 | public DateTime LastSupply { get; set; } 19 | 20 | [ForeignKey(nameof(CategoryID))] 21 | [InverseProperty("DetailProducts")] 22 | public virtual Category Category { get; set; } 23 | 24 | [ForeignKey(nameof(CountryID))] 25 | [InverseProperty("DetailProducts")] 26 | public virtual Country Country { get; set; } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Employee.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Employee 4 | { 5 | public Employee() 6 | { 7 | EmployeeTerritories = new HashSet(); 8 | Orders = new HashSet(); 9 | } 10 | 11 | public int EmployeeID { get; set; } 12 | public string? Address { get; set; } 13 | public string? BirthDate { get; set; } 14 | public string? City { get; set; } 15 | public string? Country { get; set; } 16 | public string? Extension { get; set; } 17 | public string? FirstName { get; set; } 18 | public string? HireDate { get; set; } 19 | public string? HomePhone { get; set; } 20 | public string? LastName { get; set; } 21 | public string? Notes { get; set; } 22 | public byte[] Photo { get; set; } 23 | public string? PhotoPath { get; set; } 24 | public string? PostalCode { get; set; } 25 | public string? Region { get; set; } 26 | public int? ReportsTo { get; set; } 27 | public string? Title { get; set; } 28 | public string? TitleOfCourtesy { get; set; } 29 | 30 | public virtual ICollection EmployeeTerritories { get; set; } 31 | public virtual ICollection Orders { get; set; } 32 | public virtual Employee ReportsToNavigation { get; set; } 33 | public virtual ICollection InverseReportsToNavigation { get; set; } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/EmployeeDirectory.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class EmployeeDirectory 4 | { 5 | public int EmployeeID { get; set; } 6 | public string Address { get; set; } 7 | public DateTime? BirthDate { get; set; } 8 | public string City { get; set; } 9 | public string Country { get; set; } 10 | public int? Extension { get; set; } 11 | public string FirstName { get; set; } 12 | public DateTime? HireDate { get; set; } 13 | public string LastName { get; set; } 14 | public string Phone { get; set; } 15 | public string Position { get; set; } 16 | public int? ReportsTo { get; set; } 17 | 18 | public virtual EmployeeDirectory ReportsToNavigation { get; set; } 19 | public virtual ICollection InverseReportsToNavigation { get; set; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/EmployeeTerritory.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class EmployeeTerritory 4 | { 5 | public int EmployeeID { get; set; } 6 | public string TerritoryID { get; set; } 7 | 8 | public virtual Employee Employee { get; set; } 9 | public virtual Territory Territory { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/FileManagerEntry.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public class FileManagerEntry 4 | { 5 | public string Name { get; set; } 6 | public long Size { get; set; } 7 | public string Path { get; set; } 8 | public string Extension { get; set; } 9 | public bool IsDirectory { get; set; } 10 | public bool HasDirectories { get; set; } 11 | 12 | public DateTime Created { get; set; } 13 | public DateTime CreatedUtc { get; set; } 14 | public DateTime Modified { get; set; } 15 | public DateTime ModifiedUtc { get; set; } 16 | 17 | public IEnumerable Directories { get; set; } 18 | 19 | public FileManagerEntry Clone() 20 | { 21 | return new FileManagerEntry 22 | { 23 | Name = this.Name, 24 | Size = this.Size, 25 | Path = this.Path, 26 | Extension = this.Extension, 27 | IsDirectory = this.IsDirectory, 28 | HasDirectories = this.HasDirectories, 29 | Created = this.Created, 30 | CreatedUtc = this.CreatedUtc, 31 | Modified = this.Modified, 32 | ModifiedUtc = this.ModifiedUtc, 33 | Directories = this.Directories?.Select(d => d.Clone()).ToList() 34 | }; 35 | } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/GanttDependency.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class GanttDependency 4 | { 5 | public int ID { get; set; } 6 | public int PredecessorID { get; set; } 7 | public int SuccessorID { get; set; } 8 | public int Type { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/GanttResource.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class GanttResource 4 | { 5 | public int ID { get; set; } 6 | public string Color { get; set; } 7 | public string Name { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/GanttResourceAssignment.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class GanttResourceAssignment 4 | { 5 | public int ID { get; set; } 6 | public int ResourceID { get; set; } 7 | public int TaskID { get; set; } 8 | public decimal Units { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/GanttTask.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class GanttTask 4 | { 5 | public int ID { get; set; } 6 | public DateTime End { get; set; } 7 | public bool Expanded { get; set; } 8 | public int OrderID { get; set; } 9 | public int? ParentID { get; set; } 10 | public decimal PercentComplete { get; set; } 11 | public DateTime Start { get; set; } 12 | public bool Summary { get; set; } 13 | public string Title { get; set; } 14 | 15 | public virtual GanttTask Parent { get; set; } 16 | public virtual ICollection InverseParent { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Intraday.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Intraday 4 | { 5 | public int ID { get; set; } 6 | public decimal Close { get; set; } 7 | public DateTime Date { get; set; } 8 | public decimal High { get; set; } 9 | public decimal Low { get; set; } 10 | public decimal Open { get; set; } 11 | public string Symbol { get; set; } 12 | public long Volume { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Meeting.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Meeting 4 | { 5 | public Meeting() 6 | { 7 | MeetingAttendees = new HashSet(); 8 | } 9 | 10 | public int MeetingID { get; set; } 11 | public string Description { get; set; } 12 | public DateTime End { get; set; } 13 | public string EndTimezone { get; set; } 14 | public bool IsAllDay { get; set; } 15 | public string RecurrenceException { get; set; } 16 | public int? RecurrenceID { get; set; } 17 | public string RecurrenceRule { get; set; } 18 | public int? RoomID { get; set; } 19 | public DateTime Start { get; set; } 20 | public string StartTimezone { get; set; } 21 | public string Title { get; set; } 22 | 23 | public virtual ICollection MeetingAttendees { get; set; } 24 | public virtual Meeting Recurrence { get; set; } 25 | public virtual ICollection InverseRecurrence { get; set; } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/MeetingAttendee.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class MeetingAttendee 4 | { 5 | public int MeetingID { get; set; } 6 | public int AttendeeID { get; set; } 7 | 8 | public virtual Meeting Meeting { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/MeetingSignalR.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public class MeetingSignalR : SchedulerEvent 4 | { 5 | public Guid? ID { get; set; } 6 | public int? RoomID { get; set; } 7 | public IEnumerable Attendees { get; set; } 8 | public DateTime? CreatedAt { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Order.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Order 4 | { 5 | public Order() 6 | { 7 | OrderDetails = new HashSet(); 8 | } 9 | 10 | public int OrderID { get; set; } 11 | public string CustomerID { get; set; } 12 | public int? EmployeeID { get; set; } 13 | public decimal? Freight { get; set; } 14 | public DateTime? OrderDate { get; set; } 15 | public string RequiredDate { get; set; } 16 | public string ShipAddress { get; set; } 17 | public string ShipCity { get; set; } 18 | public string ShipCountry { get; set; } 19 | public string ShipName { get; set; } 20 | public DateTime? ShippedDate { get; set; } 21 | public string ShipPostalCode { get; set; } 22 | public string ShipRegion { get; set; } 23 | public int? ShipVia { get; set; } 24 | 25 | public virtual ICollection OrderDetails { get; set; } 26 | public virtual Customer Customer { get; set; } 27 | public virtual Employee Employee { get; set; } 28 | public virtual Shipper ShipViaNavigation { get; set; } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/OrderDetail.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class OrderDetail 4 | { 5 | public int OrderID { get; set; } 6 | public int ProductID { get; set; } 7 | public double Discount { get; set; } 8 | public int Quantity { get; set; } 9 | public double UnitPrice { get; set; } 10 | 11 | public virtual Order Order { get; set; } 12 | public virtual Product Product { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/OrgChartConnection.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class OrgChartConnection 4 | { 5 | public long Id { get; set; } 6 | public long? FromPointX { get; set; } 7 | public long? FromPointY { get; set; } 8 | public long? FromShapeId { get; set; } 9 | public string Text { get; set; } 10 | public long? ToPointX { get; set; } 11 | public long? ToPointY { get; set; } 12 | public long? ToShapeId { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/OrgChartShape.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class OrgChartShape 4 | { 5 | public int Id { get; set; } 6 | public string Color { get; set; } 7 | public string JobTitle { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Product.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Product 4 | { 5 | public Product() 6 | { 7 | OrderDetails = new HashSet(); 8 | } 9 | 10 | public int ProductID { get; set; } 11 | public int? CategoryID { get; set; } 12 | public bool Discontinued { get; set; } 13 | public string ProductName { get; set; } 14 | public string QuantityPerUnit { get; set; } 15 | public int? ReorderLevel { get; set; } 16 | public int? SupplierID { get; set; } 17 | public decimal? UnitPrice { get; set; } 18 | public int? UnitsInStock { get; set; } 19 | public int? UnitsOnOrder { get; set; } 20 | 21 | public virtual ICollection OrderDetails { get; set; } 22 | public virtual Category Category { get; set; } 23 | public virtual Supplier Supplier { get; set; } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/ProductSignalR.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public class ProductSignalR 4 | { 5 | public Guid? ID { get; set; } 6 | public string ProductName { get; set; } 7 | public double UnitPrice { get; set; } 8 | public int UnitsInStock { get; set; } 9 | public DateTime? CreatedAt { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Region.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Region 4 | { 5 | public Region() 6 | { 7 | Territories = new HashSet(); 8 | } 9 | 10 | public int RegionID { get; set; } 11 | public string RegionDescription { get; set; } 12 | 13 | public virtual ICollection Territories { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/SchedulerEvent.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public abstract class SchedulerEvent 4 | { 5 | public string Title { get; set; } 6 | public string Description { get; set; } 7 | 8 | public string StartTimezone { get; set; } 9 | 10 | private DateTime start; 11 | public DateTime Start 12 | { 13 | get 14 | { 15 | return start; 16 | } 17 | set 18 | { 19 | start = value.ToUniversalTime(); 20 | } 21 | } 22 | 23 | 24 | private DateTime end; 25 | public DateTime End 26 | { 27 | get 28 | { 29 | return end; 30 | } 31 | set 32 | { 33 | end = value.ToUniversalTime(); 34 | } 35 | } 36 | 37 | 38 | public string EndTimezone { get; set; } 39 | public string RecurrenceRule { get; set; } 40 | public int? RecurrenceID { get; set; } 41 | public string RecurrenceException { get; set; } 42 | public bool IsAllDay { get; set; } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Shipper.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Shipper 4 | { 5 | public Shipper() 6 | { 7 | Orders = new HashSet(); 8 | } 9 | 10 | public int ShipperID { get; set; } 11 | public string CompanyName { get; set; } 12 | public string Phone { get; set; } 13 | 14 | public virtual ICollection Orders { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Stock.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Stock 4 | { 5 | public int ID { get; set; } 6 | public decimal Close { get; set; } 7 | public DateTime Date { get; set; } 8 | public decimal High { get; set; } 9 | public decimal Low { get; set; } 10 | public decimal Open { get; set; } 11 | public string Symbol { get; set; } 12 | public long Volume { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/StockDataPoint.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public class StockDataPoint 4 | { 5 | public DateTime Date { get; set; } 6 | 7 | public decimal Close { get; set; } 8 | 9 | public long Volume { get; set; } 10 | 11 | public decimal Open { get; set; } 12 | 13 | public decimal High { get; set; } 14 | 15 | public decimal Low { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Supplier.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Supplier 4 | { 5 | public Supplier() 6 | { 7 | Products = new HashSet(); 8 | } 9 | 10 | public int SupplierID { get; set; } 11 | public string Address { get; set; } 12 | public string City { get; set; } 13 | public string CompanyName { get; set; } 14 | public string ContactName { get; set; } 15 | public string ContactTitle { get; set; } 16 | public string Country { get; set; } 17 | public string Fax { get; set; } 18 | public string HomePage { get; set; } 19 | public string Phone { get; set; } 20 | public string PostalCode { get; set; } 21 | public string Region { get; set; } 22 | 23 | public virtual ICollection Products { get; set; } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Task.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Task 4 | { 5 | public int TaskID { get; set; } 6 | public string Description { get; set; } 7 | public DateTime End { get; set; } 8 | public string EndTimezone { get; set; } 9 | public bool IsAllDay { get; set; } 10 | public int? OwnerID { get; set; } 11 | public string RecurrenceException { get; set; } 12 | public int? RecurrenceID { get; set; } 13 | public string RecurrenceRule { get; set; } 14 | public DateTime Start { get; set; } 15 | public string StartTimezone { get; set; } 16 | public string Title { get; set; } 17 | 18 | public virtual Task Recurrence { get; set; } 19 | public virtual ICollection InverseRecurrence { get; set; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Territory.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Territory 4 | { 5 | public Territory() 6 | { 7 | EmployeeTerritories = new HashSet(); 8 | } 9 | 10 | public string TerritoryID { get; set; } 11 | public int RegionID { get; set; } 12 | public string TerritoryDescription { get; set; } 13 | 14 | public virtual ICollection EmployeeTerritories { get; set; } 15 | public virtual Region Region { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/UrbanArea.cs: -------------------------------------------------------------------------------- 1 | using System.ComponentModel.DataAnnotations.Schema; 2 | 3 | namespace KendoCRUDService.Data.Models 4 | { 5 | public partial class UrbanArea 6 | { 7 | public int ID { get; set; } 8 | public string City { get; set; } 9 | public string Country { get; set; } 10 | public string Country_ISO3 { get; set; } 11 | public double Latitude { get; set; } 12 | public double Longitude { get; set; } 13 | public long Pop1950 { get; set; } 14 | public long Pop1955 { get; set; } 15 | public long Pop1960 { get; set; } 16 | public long Pop1965 { get; set; } 17 | public long Pop1970 { get; set; } 18 | public long Pop1975 { get; set; } 19 | public long Pop1980 { get; set; } 20 | public long Pop1985 { get; set; } 21 | public long Pop1990 { get; set; } 22 | public long Pop1995 { get; set; } 23 | public long Pop2000 { get; set; } 24 | public long Pop2005 { get; set; } 25 | public long Pop2010 { get; set; } 26 | public long Pop2015 { get; set; } 27 | public long Pop2020 { get; set; } 28 | public long Pop2025 { get; set; } 29 | public long Pop2050 { get; set; } 30 | 31 | [NotMapped] 32 | public double[] Location 33 | { 34 | get 35 | { 36 | return new double[] { Latitude, Longitude }; 37 | } 38 | 39 | private set { } 40 | } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/Weather.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public partial class Weather 4 | { 5 | public int ID { get; set; } 6 | public string Station { get; set; } 7 | public DateTime Date { get; set; } 8 | public decimal TMax { get; set; } 9 | public decimal TMin { get; set; } 10 | public decimal Wind { get; set; } 11 | public decimal? Gust { get; set; } 12 | public decimal Rain { get; set; } 13 | public decimal? Snow { get; set; } 14 | public string Events { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Models/WeatherModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Data.Models 2 | { 3 | public class WeatherModel 4 | { 5 | public DateTime Date { get; set; } 6 | 7 | public decimal TMax { get; set; } 8 | 9 | public decimal TMin { get; set; } 10 | 11 | public decimal Wind { get; set; } 12 | 13 | public decimal Rain { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Repositories/CategoriesRepository.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Extensions; 3 | using Microsoft.EntityFrameworkCore; 4 | 5 | namespace KendoCRUDService.Data.Repositories 6 | { 7 | public class CategoriesRepository 8 | { 9 | private readonly ISession _session; 10 | private readonly IDbContextFactory _contextFactory; 11 | 12 | public CategoriesRepository(IHttpContextAccessor httpContextAccessor, IDbContextFactory contextFactory) 13 | { 14 | _session = httpContextAccessor.HttpContext.Session; 15 | _contextFactory = contextFactory; 16 | } 17 | 18 | public IList All() 19 | { 20 | IList result = _session.GetObjectFromJson>("Categories"); 21 | 22 | if (result == null) 23 | { 24 | result = _contextFactory.CreateDbContext().Categories.Select(c => new Category 25 | { 26 | CategoryID = c.CategoryID, 27 | CategoryName = c.CategoryName, 28 | Description = c.Description, 29 | Picture = c.Picture 30 | }).ToList(); 31 | 32 | _session.SetObjectAsJson("Categories", result); 33 | } 34 | 35 | return result; 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Repositories/CountryRepository.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Extensions; 3 | using Microsoft.EntityFrameworkCore; 4 | 5 | namespace KendoCRUDService.Data.Repositories 6 | { 7 | public class CountryRepository 8 | { 9 | private readonly ISession _session; 10 | private readonly IDbContextFactory _contextFactory; 11 | 12 | public CountryRepository(IHttpContextAccessor httpContextAccessor, IDbContextFactory contextFactory) 13 | { 14 | _session = httpContextAccessor.HttpContext.Session; 15 | _contextFactory = contextFactory; 16 | } 17 | 18 | public IList All() 19 | { 20 | IList result = _session.GetObjectFromJson>("Countries"); 21 | 22 | if (result == null) 23 | { 24 | result = _contextFactory.CreateDbContext().Countries.Select(c => new Country 25 | { 26 | CountryID = c.CountryID, 27 | CountryNameLong = c.CountryNameLong, 28 | CountryNameShort = c.CountryNameShort, 29 | }).ToList(); 30 | } 31 | 32 | return result; 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Repositories/CustomerRepository.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Models; 2 | using KendoCRUDService.Extensions; 3 | using Microsoft.EntityFrameworkCore; 4 | 5 | namespace KendoCRUDService.Data.Repositories 6 | { 7 | public class CustomerRepository 8 | { 9 | private readonly ISession _session; 10 | private readonly IDbContextFactory _contextFactory; 11 | 12 | public CustomerRepository(IHttpContextAccessor httpContextAccessor, IDbContextFactory contextFactory) 13 | { 14 | _session = httpContextAccessor.HttpContext.Session; 15 | _contextFactory = contextFactory; 16 | } 17 | 18 | public IList All() 19 | { 20 | IList result = _session.GetObjectFromJson>("Customers"); 21 | 22 | if (result == null) 23 | { 24 | result = _contextFactory.CreateDbContext().Customers.Select(c => new CustomerViewModel 25 | { 26 | CustomerID = c.CustomerID, 27 | ContactName = c.ContactName, 28 | CompanyName = c.CompanyName, 29 | Address = c.Address, 30 | City = c.City, 31 | Country = c.Country, 32 | ContactTitle = c.ContactTitle, 33 | PostalCode = c.PostalCode, 34 | Bool = c.Bool, 35 | Fax = c.Fax, 36 | Phone = c.Phone, 37 | Region = c.Region 38 | }).ToList(); 39 | } 40 | 41 | return result; 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Repositories/GanttResourcesRepository.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Extensions; 3 | using Microsoft.EntityFrameworkCore; 4 | using System.Threading.Tasks; 5 | 6 | namespace KendoCRUDService.Data.Repositories 7 | { 8 | public class GanttResourcesRepository 9 | { 10 | private readonly ISession _session; 11 | private readonly IServiceScopeFactory _scopeFactory; 12 | private IList _resources; 13 | 14 | public GanttResourcesRepository(IHttpContextAccessor httpContextAccessor, IServiceScopeFactory scopeFactory) 15 | { 16 | _session = httpContextAccessor.HttpContext.Session; 17 | _scopeFactory = scopeFactory; 18 | } 19 | 20 | public IList All() 21 | { 22 | var result = _session.GetObjectFromJson>("GanttResources"); 23 | 24 | if (_resources == null) 25 | { 26 | using (var scope = _scopeFactory.CreateScope()) 27 | { 28 | var context = scope.ServiceProvider.GetRequiredService(); 29 | _resources = context.GanttResources.ToList(); 30 | } 31 | } 32 | 33 | return _resources; 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Data/Repositories/WeatherRepository.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | using KendoCRUDService.Extensions; 3 | using Microsoft.EntityFrameworkCore; 4 | 5 | namespace KendoCRUDService.Data.Repositories 6 | { 7 | public class WeatherRepository 8 | { 9 | private readonly ISession _session; 10 | private readonly IDbContextFactory _contextFactory; 11 | 12 | public WeatherRepository(IHttpContextAccessor httpContextAccessor, IDbContextFactory contextFactory) 13 | { 14 | _session = httpContextAccessor.HttpContext.Session; 15 | _contextFactory = contextFactory; 16 | } 17 | 18 | public IList ByStation(string station) 19 | { 20 | using (var db = _contextFactory.CreateDbContext()) 21 | { 22 | return _contextFactory.CreateDbContext().Weather.Select(w => new WeatherModel 23 | { 24 | Date = w.Date, 25 | TMax = w.TMax, 26 | TMin = w.TMin, 27 | Rain = w.Rain, 28 | Wind = w.Wind 29 | }).ToList(); 30 | } 31 | } 32 | 33 | public IList ByMonth(string station, int year, int month) 34 | { 35 | using (var db = _contextFactory.CreateDbContext()) 36 | { 37 | return 38 | ByStation(station) 39 | .Where(w => w.Date.Year == year && w.Date.Month == month) 40 | .ToList(); 41 | } 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Enums/BaseUnit.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Enums 2 | { 3 | public enum BaseUnit 4 | { 5 | Years = 0, 6 | Months = 1, 7 | Weeks = 2, 8 | Days = 3, 9 | Hours = 4, 10 | Minutes = 5 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Extensions/CommonExtension.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Linq; 3 | using System.Reflection; 4 | 5 | namespace KendoCRUDService.Extensions 6 | { 7 | public static class CommonExtension 8 | { 9 | public static object GetValueByPropertyName(object obj, string propertyName) 10 | { 11 | return obj.GetType().GetProperty(propertyName).GetValue(obj, null) ?? "null"; 12 | } 13 | 14 | public static PropertyInfo GetPropertyInfo(Type objType, string propertyName) 15 | { 16 | return objType.GetProperties().FirstOrDefault(p => p.Name == propertyName); 17 | } 18 | 19 | public static double ParseObjectToDouble(object data, string field) 20 | { 21 | return double.Parse(GetValueByPropertyName(data, field).ToString()); 22 | } 23 | 24 | public static bool IsNumber(this object value) 25 | { 26 | return double.TryParse(value.ToString(), out double r); 27 | } 28 | 29 | public static bool IsNull(this string str) 30 | { 31 | return str == "null"; 32 | } 33 | 34 | public static bool IsNotNull(this string str) 35 | { 36 | return str != "null"; 37 | } 38 | 39 | public static bool IsEmpty(this string str) 40 | { 41 | return str.Length == 0; 42 | } 43 | 44 | public static bool IsNotEmpty(this string str) 45 | { 46 | return str.Length != 0; 47 | } 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Extensions/FilteringExtension.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Models.Request; 2 | 3 | namespace KendoCRUDService.Extensions 4 | { 5 | public static class FilteringExtension 6 | { 7 | 8 | public static IQueryable Filter(this IQueryable data, Filter filter) 9 | { 10 | var filterExpression = ExpressionExtension.GenerateFilterExpression(filter); 11 | 12 | if(filterExpression != null) 13 | { 14 | return data.Where(filterExpression); 15 | } 16 | 17 | return data; 18 | } 19 | 20 | public static string GetOperator(string key) 21 | { 22 | Dictionary operators = new Dictionary() 23 | { 24 | { "eq", "Equals" }, 25 | { "neq", "DoesNotEqual" }, 26 | { "doesnotcontain", "DoesNotContain" }, 27 | { "contains", "Contains" }, 28 | { "startswith", "StartsWith" }, 29 | { "endswith", "EndsWith" }, 30 | { "isnull", "IsNull" }, 31 | { "isnotnull", "IsNotNull" }, 32 | { "isempty", "IsEmpty" }, 33 | { "isnotempty", "IsNotEmpty" }, 34 | { "gt", "GreaterThan" }, 35 | { "gte", "GreaterThanOrEqual" }, 36 | { "lt", "LessThan" }, 37 | { "lte", "LessThanOrEqual" } 38 | }; 39 | 40 | return operators[key]; 41 | } 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Extensions/PagingExtension.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | 3 | namespace KendoCRUDService.Extensions 4 | { 5 | public static class PagingExtension 6 | { 7 | public static IQueryable Page(this IQueryable data, int skip, int take) 8 | { 9 | return data 10 | .Skip(skip) 11 | .Take(take); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Extensions/SessionExtensions.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | 3 | namespace KendoCRUDService.Extensions 4 | { 5 | public static class SessionExtension 6 | { 7 | public static void SetObjectAsJson(this ISession session, string key, object value) 8 | { 9 | session.SetString(key, JsonConvert.SerializeObject(value)); 10 | } 11 | 12 | public static T GetObjectFromJson(this ISession session, string key) 13 | { 14 | var value = session.GetString(key); 15 | 16 | return value == null ? default(T) : JsonConvert.DeserializeObject(value); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Extensions/Utils.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | using System.Security.Cryptography; 3 | using System.Text; 4 | 5 | namespace KendoCRUDService.Extensions 6 | { 7 | public static class SessionUtils 8 | { 9 | public static string GetUserKey(IHttpContextAccessor _contextAccessor) 10 | { 11 | var identifierBuilder = new StringBuilder(); 12 | var connectionID = _contextAccessor.HttpContext.Connection.Id.Substring(0, 11); 13 | 14 | identifierBuilder.Append(connectionID); 15 | 16 | var ipAddress = _contextAccessor.HttpContext.Connection.RemoteIpAddress?.ToString() ?? "unknown"; 17 | identifierBuilder.Append(ipAddress); 18 | 19 | var userAgent = _contextAccessor.HttpContext.Response.Headers["User-Agent"].ToString(); 20 | identifierBuilder.Append(userAgent); 21 | 22 | var identifier = Convert.ToBase64String(SHA256.HashData(Encoding.UTF8.GetBytes(identifierBuilder.ToString()))).Substring(0, 32); 23 | 24 | return identifier; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/FileBrowser/DirectoryBrowser.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore.Metadata.Internal; 2 | 3 | namespace KendoCRUDService.FileBrowser 4 | { 5 | public class DirectoryBrowser 6 | { 7 | public IEnumerable GetContent(string contentRootPath, string path, string filter) 8 | { 9 | path = Path.Combine(contentRootPath, path); 10 | return GetFiles(path, filter).Concat(GetDirectories(path)); 11 | } 12 | 13 | private IEnumerable GetFiles(string path, string filter) 14 | { 15 | var directory = new DirectoryInfo(path); 16 | 17 | var extensions = (filter ?? "*").Split(",|;".ToCharArray(), System.StringSplitOptions.RemoveEmptyEntries); 18 | 19 | return extensions.SelectMany(directory.GetFiles) 20 | .Select(file => new FileBrowserEntry 21 | { 22 | Name = file.Name, 23 | Size = file.Length, 24 | Type = EntryType.File 25 | }); 26 | } 27 | 28 | private IEnumerable GetDirectories(string path) 29 | { 30 | var directory = new DirectoryInfo(path); 31 | 32 | return directory.GetDirectories() 33 | .Select(subDirectory => new FileBrowserEntry 34 | { 35 | Name = subDirectory.Name, 36 | Type = EntryType.Directory 37 | }); 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/FileBrowser/EntryType.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.FileBrowser 2 | { 3 | public enum EntryType 4 | { 5 | File = 0, 6 | Directory 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/FileBrowser/FileBrowserEntry.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore.Metadata.Internal; 2 | 3 | namespace KendoCRUDService.FileBrowser 4 | { 5 | public class FileBrowserEntry 6 | { 7 | public string Name { get; set; } 8 | public EntryType Type { get; set; } 9 | public long Size { get; set; } 10 | public string Path { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/FileBrowser/FitImageResizer.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.FileBrowser 2 | { 3 | public class ImageResizer 4 | { 5 | public ImageSize Resize(ImageSize originalSize, ImageSize targetSize) 6 | { 7 | var aspectRatio = (float)originalSize.Width / (float)originalSize.Height; 8 | var width = targetSize.Width; 9 | var height = targetSize.Height; 10 | 11 | if (originalSize.Width > targetSize.Width || originalSize.Height > targetSize.Height) 12 | { 13 | if (aspectRatio > 1) 14 | { 15 | height = (int)(targetSize.Height / aspectRatio); 16 | } 17 | else 18 | { 19 | width = (int)(targetSize.Width * aspectRatio); 20 | } 21 | } 22 | else 23 | { 24 | width = originalSize.Width; 25 | height = originalSize.Height; 26 | } 27 | 28 | return new ImageSize 29 | { 30 | Width = Math.Max(width, 1), 31 | Height = Math.Max(height, 1) 32 | }; 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/FileBrowser/ImageSize.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.FileBrowser 2 | { 3 | public class ImageSize 4 | { 5 | public int Height 6 | { 7 | get; 8 | set; 9 | } 10 | 11 | public int Width 12 | { 13 | get; 14 | set; 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Filters/ApiKeyAuthFilter .cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Settings; 2 | using Microsoft.AspNetCore.Mvc.Filters; 3 | using Microsoft.AspNetCore.Mvc; 4 | using Microsoft.Extensions.Options; 5 | 6 | namespace KendoCRUDService.Filters 7 | { 8 | public class ApiKeyAuthFilter : IAuthorizationFilter 9 | { 10 | private readonly ApiKeySettings _apiKeySettings; 11 | 12 | public ApiKeyAuthFilter(IOptions apiKeySettings) 13 | { 14 | _apiKeySettings = apiKeySettings.Value; 15 | } 16 | 17 | public void OnAuthorization(AuthorizationFilterContext context) 18 | { 19 | var request = context.HttpContext.Request; 20 | 21 | if (!request.Headers.TryGetValue("X-Api-Key", out var extractedApiKey)) 22 | { 23 | context.Result = new UnauthorizedResult(); 24 | return; 25 | } 26 | 27 | if (!_apiKeySettings.Keys.Values.Any(x => x == extractedApiKey)) 28 | { 29 | context.Result = new UnauthorizedResult(); 30 | return; 31 | } 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Filters/RateLimitAttribute.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore.Mvc; 2 | using Microsoft.AspNetCore.Mvc.Filters; 3 | using System.Collections.Concurrent; 4 | 5 | namespace KendoCRUDService.Filters 6 | { 7 | public class RateLimitAttribute : ActionFilterAttribute 8 | { 9 | private static readonly ConcurrentDictionary _requestLimits = new(); 10 | private readonly int _maxRequests; 11 | private readonly int _timeWindowInSeconds; 12 | 13 | public RateLimitAttribute(int maxRequests, int timeWindowInSeconds) 14 | { 15 | _maxRequests = maxRequests; 16 | _timeWindowInSeconds = timeWindowInSeconds; 17 | } 18 | 19 | public override void OnActionExecuting(ActionExecutingContext context) 20 | { 21 | string ipAddress = context.HttpContext.Connection.RemoteIpAddress?.ToString() ?? "unknown"; 22 | 23 | var limiter = _requestLimits.GetOrAdd(ipAddress, new RequestRateLimiter(_maxRequests, _timeWindowInSeconds)); 24 | if (!limiter.IsRequestAllowed()) 25 | { 26 | context.Result = new ContentResult 27 | { 28 | StatusCode = StatusCodes.Status429TooManyRequests, 29 | Content = "Too many requests. Please try again later." 30 | }; 31 | } 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Filters/RequestRateLimiter.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Filters 2 | { 3 | public class RequestRateLimiter 4 | { 5 | private readonly int _maxRequests; 6 | private readonly int _timeWindowInSeconds; 7 | private readonly Queue _requestTimestamps = new(); 8 | 9 | public RequestRateLimiter(int maxRequests, int timeWindowInSeconds) 10 | { 11 | _maxRequests = maxRequests; 12 | _timeWindowInSeconds = timeWindowInSeconds; 13 | } 14 | 15 | public bool IsRequestAllowed() 16 | { 17 | lock (_requestTimestamps) 18 | { 19 | DateTime currentTime = DateTime.UtcNow; 20 | 21 | while (_requestTimestamps.Count > 0 && (currentTime - _requestTimestamps.Peek()).TotalSeconds > _timeWindowInSeconds) 22 | { 23 | _requestTimestamps.Dequeue(); 24 | } 25 | 26 | if (_requestTimestamps.Count >= _maxRequests) 27 | { 28 | return false; 29 | } 30 | 31 | _requestTimestamps.Enqueue(currentTime); 32 | return true; 33 | } 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Filters/RestrictDomainAttribute.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore.Mvc.Filters; 2 | using Microsoft.AspNetCore.Mvc; 3 | 4 | namespace KendoCRUDService.Filters 5 | { 6 | public class RestrictDomainAttribute : ActionFilterAttribute 7 | { 8 | private readonly string[] _allowedDomains; 9 | 10 | public RestrictDomainAttribute(params string[] allowedDomains) 11 | { 12 | _allowedDomains = allowedDomains; 13 | } 14 | 15 | public override void OnActionExecuting(ActionExecutingContext context) 16 | { 17 | var origin = context.HttpContext.Request.Headers["Origin"].ToString(); 18 | var referer = context.HttpContext.Request.Headers["Referer"].ToString(); 19 | 20 | bool isAllowed = !string.IsNullOrEmpty(origin) && _allowedDomains.Any(d => origin.Contains(d)) || 21 | !string.IsNullOrEmpty(referer) && _allowedDomains.Any(d => referer.Contains(d)); 22 | 23 | if (!isAllowed) 24 | { 25 | context.Result = new ContentResult 26 | { 27 | StatusCode = StatusCodes.Status403Forbidden, 28 | Content = "Access denied. Your domain is not allowed." 29 | }; 30 | } 31 | 32 | base.OnActionExecuting(context); 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Hubs/BaseHub.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore.SignalR; 2 | 3 | namespace KendoCRUDService.Hubs 4 | { 5 | public class BaseHub : Hub 6 | { 7 | protected string GetGroupName() 8 | { 9 | return GetRemoteIpAddress(); 10 | } 11 | 12 | protected string GetRemoteIpAddress() 13 | { 14 | return Context.GetHttpContext()?.Connection.RemoteIpAddress.ToString(); 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/KendoCRUDService.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | net8.0 5 | disable 6 | enable 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | all 19 | runtime; build; native; contentfiles; analyzers; buildtransitive 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/CustomerViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Models 2 | { 3 | public class CustomerViewModel 4 | { 5 | public string CustomerID { get; set; } 6 | public string ContactName { get; set; } 7 | public string CompanyName { get; set; } 8 | public string Address { get; set; } 9 | public bool Bool { get; set; } 10 | public string City { get; set; } 11 | public string ContactTitle { get; set; } 12 | public string Country { get; set; } 13 | public string Fax { get; set; } 14 | public string Phone { get; set; } 15 | public string PostalCode { get; set; } 16 | public string Region { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/DetailProductSubmitViewModel.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | 3 | namespace KendoCRUDService.Models 4 | { 5 | public class DetailProductSubmitViewModel 6 | { 7 | public IList Created { get; set; } 8 | 9 | public IList Destroyed { get; set; } 10 | 11 | public IList Updated { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/EmployeeCompleteViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Models 2 | { 3 | public class EmployeeCompleteViewModel 4 | { 5 | public string FirstName { get; set; } 6 | public string LastName { get; set; } 7 | public string Country { get; set; } 8 | public string City { get; set; } 9 | public string Title { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/EmployeeNodeViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Models 2 | { 3 | public class EmployeeNodeViewModel 4 | { 5 | public int Id { get; set; } 6 | 7 | public int? ParentId { get; set; } 8 | 9 | public string Avatar { get; set; } 10 | 11 | public bool HasChildren { get; set; } 12 | 13 | public bool Expanded { get; set; } 14 | 15 | public string FullName { get; set; } 16 | 17 | public string Position { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/EmployeeViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Models 2 | { 3 | public class EmployeeViewModel 4 | { 5 | public int? EmployeeId { get; set; } 6 | public string FullName { get; set; } 7 | public bool HasEmployees { get; set; } 8 | public int? ReportsTo { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Models 2 | { 3 | public class ErrorViewModel 4 | { 5 | public string? RequestId { get; set; } 6 | 7 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 8 | } 9 | } -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/FormUploadItemsViewModel.cs: -------------------------------------------------------------------------------- 1 | using static System.Runtime.InteropServices.JavaScript.JSType; 2 | 3 | namespace KendoCRUDService.Models 4 | { 5 | public class FormUploadItemsViewModel 6 | { 7 | public string TextBox { get; set; } 8 | public string TextArea { get; set; } 9 | public int NumericTextBox { get; set; } 10 | public string MaskedTextBox { get; set; } 11 | public DateTime DatePicker { get; set; } 12 | public DateTime DateTimePicker { get; set; } 13 | public string RadioGroup { get; set; } 14 | public List CheckBoxGroup { get; set; } 15 | public bool Switch { get; set; } 16 | public int ComboBox { get; set; } 17 | public int DropDownList { get; set; } 18 | public IFormFile FileName { get; set; } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/FormUploadViewModel.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Models 2 | { 3 | public class FormUploadViewModel 4 | { 5 | public string Username { get; set; } 6 | public string Password { get; set; } 7 | public string Email { get; set; } 8 | public IFormFile File { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/MeetingViewModel.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | 3 | namespace KendoCRUDService.Models 4 | { 5 | public class MeetingViewModel : SchedulerEvent 6 | { 7 | public int MeetingID { get; set; } 8 | public int? RoomID { get; set; } 9 | public IEnumerable Attendees { get; set; } 10 | 11 | public Meeting ToEntity() 12 | { 13 | return new Meeting 14 | { 15 | MeetingID = MeetingID, 16 | Title = Title, 17 | Start = Start, 18 | StartTimezone = StartTimezone, 19 | End = End, 20 | EndTimezone = EndTimezone, 21 | Description = Description, 22 | IsAllDay = IsAllDay, 23 | RecurrenceRule = RecurrenceRule, 24 | RecurrenceException = RecurrenceException, 25 | RecurrenceID = RecurrenceID, 26 | RoomID = RoomID 27 | }; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/Request/AggregateRequest.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | 3 | namespace KendoCRUDService.Models.Request 4 | { 5 | public class AggregateRequest 6 | { 7 | [JsonProperty("field")] 8 | public string? Field { get; set; } 9 | 10 | [JsonProperty("aggregate")] 11 | public string? Aggregate { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/Request/Filter.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | 3 | namespace KendoCRUDService.Models.Request 4 | { 5 | public class Filter 6 | { 7 | [JsonProperty("logic")] 8 | public string? Logic { get; set; } 9 | 10 | [JsonProperty("field")] 11 | public string? Field { get; set; } 12 | 13 | [JsonProperty("operator")] 14 | public string? Operator { get; set; } 15 | 16 | [JsonProperty("value")] 17 | public object? Value { get; set; } 18 | 19 | [JsonProperty("filters")] 20 | public List? Filters { get; set; } 21 | 22 | public bool IsDescriptor 23 | { 24 | get 25 | { 26 | return Field != null && Operator != null; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/Request/GroupRequest.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using Newtonsoft.Json; 3 | 4 | namespace KendoCRUDService.Models.Request 5 | { 6 | public class GroupRequest 7 | { 8 | [JsonProperty("field")] 9 | public string? Field { get; set; } 10 | 11 | [JsonProperty("dir")] 12 | public string? Dir { get; set; } 13 | 14 | [JsonProperty("aggregates")] 15 | public List? Aggregates { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/Request/Request.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore.Mvc; 2 | using System.Collections.Generic; 3 | using Newtonsoft.Json; 4 | 5 | namespace KendoCRUDService.Models.Request 6 | { 7 | public class Request 8 | { 9 | [JsonProperty("skip")] 10 | public int Skip { get; set; } 11 | 12 | [JsonProperty("take")] 13 | public int Take { get; set; } 14 | 15 | [JsonProperty("groupPaging")] 16 | public bool GroupPaging { get; set; } 17 | 18 | [JsonProperty("sort")] 19 | public List? Sorts { get; set; } 20 | 21 | [JsonProperty("filter")] 22 | public Filter? Filter { get; set; } 23 | 24 | [JsonProperty("group")] 25 | public List? Groups { get; set; } 26 | 27 | [JsonProperty("aggregate")] 28 | public List? Aggregates { get; set; } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/Request/Sort.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | 3 | namespace KendoCRUDService.Models.Request 4 | { 5 | public class Sort 6 | { 7 | [JsonProperty("field")] 8 | public string? Field { get; set; } 9 | 10 | [JsonProperty("dir")] 11 | public string? Dir { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/Response/Group.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using System.Collections.Generic; 3 | using Newtonsoft.Json; 4 | 5 | namespace KendoCRUDService.Models.Response 6 | { 7 | public class Group 8 | { 9 | [JsonProperty("field")] 10 | public string? Field { get; set; } 11 | 12 | [JsonProperty("value")] 13 | public object? Value { get; set; } 14 | 15 | [JsonProperty("hasSubgroups")] 16 | public bool HasSubgroups { get; set; } 17 | 18 | [JsonProperty("items")] 19 | public IList? Items { get; set; } 20 | 21 | [JsonProperty("itemCount")] 22 | public int ItemCount { get; set; } 23 | 24 | [JsonProperty("subgroupCount")] 25 | public int SubgroupCount { get; set; } 26 | 27 | [JsonProperty("aggregates")] 28 | public Dictionary>? Aggregates { get; set; } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/Response/Response.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | 3 | namespace KendoCRUDService.Models.Response 4 | { 5 | public class Response 6 | { 7 | public Response(IList data, Dictionary> aggregates, int total, bool isGrouped) 8 | { 9 | if(isGrouped) 10 | { 11 | Groups = data; 12 | } 13 | else 14 | { 15 | Data = data; 16 | } 17 | 18 | Total = total; 19 | Aggregates = aggregates; 20 | } 21 | 22 | private IList Data { get; set; } 23 | 24 | private IList Groups { get; set; } 25 | 26 | private Dictionary> Aggregates { get; set; } 27 | 28 | private int Total { get; set; } 29 | 30 | public object ToResult() 31 | { 32 | return new 33 | { 34 | Data, 35 | Groups, 36 | Total, 37 | Aggregates 38 | }; 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/SpreadsheetSubmitViewModel.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | 3 | namespace KendoCRUDService.Models 4 | { 5 | public class SpreadsheetSubmitViewModel 6 | { 7 | public IList Created { get; set; } 8 | 9 | public IList Destroyed { get; set; } 10 | 11 | public IList Updated { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Models/TaskViewModel.cs: -------------------------------------------------------------------------------- 1 | using KendoCRUDService.Data.Models; 2 | 3 | namespace KendoCRUDService.Models 4 | { 5 | public class TaskViewModel : SchedulerEvent 6 | { 7 | public int TaskID { get; set; } 8 | public int? OwnerID { get; set; } 9 | 10 | public Data.Models.Task ToEntity() 11 | { 12 | return new Data.Models.Task 13 | { 14 | TaskID = TaskID, 15 | Title = Title, 16 | Start = Start, 17 | StartTimezone = StartTimezone, 18 | End = End, 19 | EndTimezone = EndTimezone, 20 | Description = Description, 21 | RecurrenceRule = RecurrenceRule, 22 | RecurrenceException = RecurrenceException, 23 | RecurrenceID = RecurrenceID, 24 | IsAllDay = IsAllDay, 25 | OwnerID = OwnerID 26 | }; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "profiles": { 3 | "http": { 4 | "commandName": "Project", 5 | "launchBrowser": true, 6 | "environmentVariables": { 7 | "ASPNETCORE_ENVIRONMENT": "Development" 8 | }, 9 | "dotnetRunMessages": true, 10 | "applicationUrl": "http://localhost:5099" 11 | }, 12 | "https": { 13 | "commandName": "Project", 14 | "launchBrowser": true, 15 | "environmentVariables": { 16 | "ASPNETCORE_ENVIRONMENT": "Development" 17 | }, 18 | "dotnetRunMessages": true, 19 | "applicationUrl": "https://localhost:7171;http://localhost:5099", 20 | "hotReloadEnabled": false 21 | }, 22 | "IIS Express": { 23 | "commandName": "IISExpress", 24 | "launchBrowser": true, 25 | "environmentVariables": { 26 | "ASPNETCORE_ENVIRONMENT": "Development" 27 | } 28 | } 29 | }, 30 | "iisSettings": { 31 | "windowsAuthentication": false, 32 | "anonymousAuthentication": true, 33 | "iisExpress": { 34 | "applicationUrl": "http://localhost:51337", 35 | "sslPort": 44302 36 | } 37 | } 38 | } -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/Settings/ApiKeySettings.cs: -------------------------------------------------------------------------------- 1 | namespace KendoCRUDService.Settings 2 | { 3 | public class ApiKeySettings 4 | { 5 | public Dictionary Keys { get; set; } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Information", 5 | "Microsoft.AspNetCore": "Warning" 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Information", 5 | "Microsoft.AspNetCore": "Warning" 6 | } 7 | }, 8 | "AllowedHosts": "*", 9 | "ApiKeys": { 10 | "Keys": { 11 | "Core": "${CORE_API_KEY}", 12 | "Mvc": "${MVC_API_KEY}", 13 | "Blazor": "${BLAZOR_API_KEY}", 14 | "React": "${REACT_API_KEY}", 15 | "Angular": "${ANGULAR_API_KEY}", 16 | "Reporting": "${REPORTING_API_KEY}", 17 | "Generic": "${GENERIC_API_KEY}" 18 | } 19 | }, 20 | "AI": { 21 | "AzureOpenAI": { 22 | "Endpoint": "${AZURE_OPENAI_ENDPOINT}", 23 | "Key": "${AZURE_OPENAI_KEY}", 24 | "Chat": { 25 | "ModelId": "${AZURE_OPENAI_CHAT_MODEL_ID}" 26 | } 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/a100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/a100.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/aeroviewr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/aeroviewr.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/chart-wrapper-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/chart-wrapper-small.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/demos-dataviz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/demos-dataviz.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/demos-mobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/SubFolder/demos-mobile.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/a100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/a100.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/aeroviewr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/aeroviewr.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/chart-wrapper-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/chart-wrapper-small.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/demos-dataviz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/demos-dataviz.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/demos-mobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/demos-mobile.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/demos-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/demos-web.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/dojo-banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/dojo-banner.jpg -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/hand-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/hand-ipad.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/sushi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/sushi.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/themebuilder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/editor/themebuilder.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/ExcelDocument.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/ExcelDocument.xlsx -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/SamplePDF.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/SamplePDF.pdf -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/Text.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/Text.txt -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/WordDocument.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Documents/WordDocument.docx -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/a100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/a100.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/aeroviewr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/aeroviewr.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/chart-wrapper-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/chart-wrapper-small.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/demos-dataviz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/demos-dataviz.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/demos-mobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/demos-mobile.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/demos-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/demos-web.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/dojo-banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/dojo-banner.jpg -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/hand-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/hand-ipad.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/sushi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/sushi.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/themebuilder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/Content/filemanager/Images/themebuilder.png -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/data/sample.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/data/sample.db -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/data/sample.db-shm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/data/sample.db-shm -------------------------------------------------------------------------------- /demos-core/KendoCRUDService/KendoCRUDService/wwwroot/data/sample.db-wal: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/demos-core/KendoCRUDService/KendoCRUDService/wwwroot/data/sample.db-wal -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 15 4 | VisualStudioVersion = 15.0.27703.2035 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "graphql-aspnet-core", "graphql-aspnet-core\graphql-aspnet-core.csproj", "{F78EF199-7383-46A6-8074-7CF876D60E60}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {F78EF199-7383-46A6-8074-7CF876D60E60}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {F78EF199-7383-46A6-8074-7CF876D60E60}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {F78EF199-7383-46A6-8074-7CF876D60E60}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {F78EF199-7383-46A6-8074-7CF876D60E60}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {ABA4C532-2CAF-4B9A-B0E2-EE4F21C83D64} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Controllers/CustomersController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using graphql_aspnet_core.Data; 6 | using Kendo.Mvc.Extensions; 7 | using Kendo.Mvc.UI; 8 | using Microsoft.AspNetCore.Mvc; 9 | 10 | namespace graphql_aspnet_core.Controllers 11 | { 12 | [ApiController] 13 | [Route("[controller]")] 14 | public class CustomersController : Controller 15 | { 16 | private CustomersEntitiesDataContext context; 17 | 18 | public CustomersController(CustomersEntitiesDataContext context) 19 | { 20 | this.context = context; 21 | } 22 | 23 | [AcceptVerbs("Get", "Post")] 24 | public IActionResult Get([DataSourceRequest]DataSourceRequest request) 25 | { 26 | return Json(this.context.Customers.ToDataSourceResult(request)); 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Controllers/GraphQLController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Threading.Tasks; 3 | using GraphQL; 4 | using GraphQL.NewtonsoftJson; 5 | using GraphQL.Types; 6 | using graphql_aspnet_core.Models.GraphQL; 7 | using Microsoft.AspNetCore.Mvc; 8 | 9 | namespace graphql_aspnet_core.Controllers 10 | { 11 | [Route("")] 12 | public class GraphQLController : Controller 13 | { 14 | private readonly IDocumentExecuter _documentExecuter; 15 | 16 | private readonly ISchema _schema; 17 | 18 | private readonly IGraphQLSerializer _serializer; 19 | 20 | public GraphQLController(ISchema schema, IDocumentExecuter documentExecuter, IGraphQLSerializer serializer) 21 | { 22 | _schema = schema; 23 | _documentExecuter = documentExecuter; 24 | _serializer = serializer; 25 | } 26 | 27 | [HttpPost] 28 | public async Task Post([FromBody] GraphQLQuery query) 29 | { 30 | if (query == null) { 31 | throw new ArgumentNullException(nameof(query)); 32 | 33 | } 34 | var executionOptions = new ExecutionOptions 35 | { 36 | Schema = _schema, 37 | Query = query.Query, 38 | Variables = query.Variables != null ? ((GraphQLSerializer)_serializer).Deserialize(query.Variables.ToString()) : null 39 | }; 40 | 41 | var result = await _documentExecuter.ExecuteAsync(executionOptions).ConfigureAwait(false); 42 | 43 | return new GraphQLActionResult(result); 44 | } 45 | } 46 | } -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Controllers/ServerOperationsController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using graphql_aspnet_core.Data; 6 | using Kendo.Mvc.Extensions; 7 | using Kendo.Mvc.UI; 8 | using Microsoft.AspNetCore.Mvc; 9 | 10 | namespace graphql_aspnet_core.Controllers 11 | { 12 | [ApiController] 13 | [Route("[controller]")] 14 | public class ServerOperationsController : Controller 15 | { 16 | private CustomersEntitiesDataContext context; 17 | 18 | public ServerOperationsController(CustomersEntitiesDataContext context) 19 | { 20 | this.context = context; 21 | } 22 | 23 | [AcceptVerbs("Get", "Post")] 24 | public IActionResult Get([DataSourceRequest]DataSourceRequest request) 25 | { 26 | return Json(this.context.Customers.ToList().ToDataSourceResult(request)); 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/Contracts/IProductRepository.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace graphql_aspnet_core.Data.Contracts 5 | { 6 | public interface IProductRepository 7 | { 8 | Task GetAsync(int ProductID); 9 | 10 | Task> AllAsync(); 11 | 12 | Task AddAsync(Product product); 13 | 14 | Task UpdateAsync(Product product); 15 | 16 | Task Delete(Product product); 17 | 18 | Task GetTotalRecords(); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/CustomersEntities.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.IO; 5 | using System.Linq; 6 | using System.Threading.Tasks; 7 | 8 | namespace graphql_aspnet_core.Data 9 | { 10 | public class CustomersEntitiesDataContext : DbContext 11 | { 12 | public CustomersEntitiesDataContext() : base(new DbContextOptions()) 13 | { 14 | } 15 | 16 | protected override void OnConfiguring(DbContextOptionsBuilder options) 17 | { 18 | var dataDirectory = Path.Combine(Startup.WebRootPath, "App_Data"); 19 | 20 | options.UseSqlite(@"Data Source=" + dataDirectory + System.IO.Path.DirectorySeparatorChar + @"customers.db; Foreign Keys=False"); 21 | } 22 | public virtual DbSet Customers { get; set; } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/Entities/Customer.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace graphql_aspnet_core.Data.Entities 7 | { 8 | public class Customer 9 | { 10 | public string CustomerID { get; set; } 11 | public string Address { get; set; } 12 | public string City { get; set; } 13 | public string CompanyName { get; set; } 14 | public string ContactName { get; set; } 15 | public string ContactTitle { get; set; } 16 | public string Country { get; set; } 17 | public string Fax { get; set; } 18 | public string Phone { get; set; } 19 | public string PostalCode { get; set; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/Repositories/ProductRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Threading.Tasks; 4 | using Microsoft.EntityFrameworkCore; 5 | using graphql_aspnet_core.Data.Contracts; 6 | 7 | namespace graphql_aspnet_core.Data.Repositories 8 | { 9 | public class ProductRepository : IProductRepository 10 | { 11 | private SampleEntitiesDataContext _db; 12 | 13 | public ProductRepository(SampleEntitiesDataContext db) 14 | { 15 | _db = db; 16 | } 17 | public async Task> AllAsync() 18 | { 19 | return await _db.Products.AsNoTracking().ToListAsync(); 20 | } 21 | 22 | public async Task GetAsync(int ProductID) 23 | { 24 | return await _db.Products.FirstOrDefaultAsync(p => p.ProductID == ProductID); 25 | } 26 | 27 | public async Task AddAsync(Product product) 28 | { 29 | return product; 30 | } 31 | 32 | public async Task UpdateAsync(Product product) 33 | { 34 | return product; 35 | } 36 | 37 | public async Task Delete(Product product) 38 | { 39 | return product; 40 | } 41 | 42 | public async Task GetTotalRecords() 43 | { 44 | var total = await _db.Products.CountAsync(); 45 | 46 | return total; 47 | } 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Category.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Category 6 | { 7 | public Category() 8 | { 9 | Products = new HashSet(); 10 | } 11 | 12 | public int CategoryID { get; set; } 13 | public string CategoryName { get; set; } 14 | public string Description { get; set; } 15 | public byte[] Picture { get; set; } 16 | 17 | public virtual ICollection Products { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Customer.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Customer 6 | { 7 | public Customer() 8 | { 9 | CustomerCustomerDemo = new HashSet(); 10 | Orders = new HashSet(); 11 | } 12 | 13 | public string CustomerID { get; set; } 14 | public string Address { get; set; } 15 | public bool Bool { get; set; } 16 | public string City { get; set; } 17 | public string CompanyName { get; set; } 18 | public string ContactName { get; set; } 19 | public string ContactTitle { get; set; } 20 | public string Country { get; set; } 21 | public string Fax { get; set; } 22 | public string Phone { get; set; } 23 | public string PostalCode { get; set; } 24 | public string Region { get; set; } 25 | 26 | public virtual ICollection CustomerCustomerDemo { get; set; } 27 | public virtual ICollection Orders { get; set; } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/CustomerCustomerDemo.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class CustomerCustomerDemo 4 | { 5 | public string CustomerID { get; set; } 6 | public string CustomerTypeID { get; set; } 7 | 8 | public virtual Customer Customer { get; set; } 9 | public virtual CustomerDemographic CustomerType { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/CustomerDemographic.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class CustomerDemographic 6 | { 7 | public CustomerDemographic() 8 | { 9 | CustomerCustomerDemo = new HashSet(); 10 | } 11 | 12 | public string CustomerTypeID { get; set; } 13 | public string CustomerDesc { get; set; } 14 | 15 | public virtual ICollection CustomerCustomerDemo { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Employee.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Employee 6 | { 7 | public Employee() 8 | { 9 | EmployeeTerritories = new HashSet(); 10 | Orders = new HashSet(); 11 | } 12 | 13 | public int EmployeeID { get; set; } 14 | public string Address { get; set; } 15 | public string BirthDate { get; set; } 16 | public string City { get; set; } 17 | public string Country { get; set; } 18 | public string Extension { get; set; } 19 | public string FirstName { get; set; } 20 | public string HireDate { get; set; } 21 | public string HomePhone { get; set; } 22 | public string LastName { get; set; } 23 | public string Notes { get; set; } 24 | public byte[] Photo { get; set; } 25 | public string PhotoPath { get; set; } 26 | public string PostalCode { get; set; } 27 | public string Region { get; set; } 28 | public int? ReportsTo { get; set; } 29 | public string Title { get; set; } 30 | public string TitleOfCourtesy { get; set; } 31 | 32 | public virtual ICollection EmployeeTerritories { get; set; } 33 | public virtual ICollection Orders { get; set; } 34 | public virtual Employee ReportsToNavigation { get; set; } 35 | public virtual ICollection InverseReportsToNavigation { get; set; } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/EmployeeDirectory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace graphql_aspnet_core.Data 5 | { 6 | public partial class EmployeeDirectory 7 | { 8 | public int EmployeeID { get; set; } 9 | public string Address { get; set; } 10 | public DateTime? BirthDate { get; set; } 11 | public string City { get; set; } 12 | public string Country { get; set; } 13 | public int? Extension { get; set; } 14 | public string FirstName { get; set; } 15 | public DateTime? HireDate { get; set; } 16 | public string LastName { get; set; } 17 | public string Phone { get; set; } 18 | public string Position { get; set; } 19 | public int? ReportsTo { get; set; } 20 | 21 | public virtual EmployeeDirectory ReportsToNavigation { get; set; } 22 | public virtual ICollection InverseReportsToNavigation { get; set; } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/EmployeeTerritory.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class EmployeeTerritory 4 | { 5 | public int EmployeeID { get; set; } 6 | public string TerritoryID { get; set; } 7 | 8 | public virtual Employee Employee { get; set; } 9 | public virtual Territory Territory { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/GanttDependency.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class GanttDependency 4 | { 5 | public int ID { get; set; } 6 | public int PredecessorID { get; set; } 7 | public int SuccessorID { get; set; } 8 | public int Type { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/GanttResource.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class GanttResource 4 | { 5 | public int ID { get; set; } 6 | public string Color { get; set; } 7 | public string Name { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/GanttResourceAssignment.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class GanttResourceAssignment 4 | { 5 | public int ID { get; set; } 6 | public int ResourceID { get; set; } 7 | public int TaskID { get; set; } 8 | public decimal Units { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/GanttTask.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace graphql_aspnet_core.Data 5 | { 6 | public partial class GanttTask 7 | { 8 | public int ID { get; set; } 9 | public DateTime End { get; set; } 10 | public bool Expanded { get; set; } 11 | public int OrderID { get; set; } 12 | public int? ParentID { get; set; } 13 | public decimal PercentComplete { get; set; } 14 | public DateTime Start { get; set; } 15 | public bool Summary { get; set; } 16 | public string Title { get; set; } 17 | 18 | public virtual GanttTask Parent { get; set; } 19 | public virtual ICollection InverseParent { get; set; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Intraday.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Intraday 6 | { 7 | public int ID { get; set; } 8 | public decimal Close { get; set; } 9 | public DateTime Date { get; set; } 10 | public decimal High { get; set; } 11 | public decimal Low { get; set; } 12 | public decimal Open { get; set; } 13 | public string Symbol { get; set; } 14 | public long Volume { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Meeting.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace graphql_aspnet_core.Data 5 | { 6 | public partial class Meeting 7 | { 8 | public Meeting() 9 | { 10 | MeetingAttendees = new HashSet(); 11 | } 12 | 13 | public int MeetingID { get; set; } 14 | public string Description { get; set; } 15 | public DateTime End { get; set; } 16 | public string EndTimezone { get; set; } 17 | public bool IsAllDay { get; set; } 18 | public string RecurrenceException { get; set; } 19 | public int? RecurrenceID { get; set; } 20 | public string RecurrenceRule { get; set; } 21 | public int? RoomID { get; set; } 22 | public DateTime Start { get; set; } 23 | public string StartTimezone { get; set; } 24 | public string Title { get; set; } 25 | 26 | public virtual ICollection MeetingAttendees { get; set; } 27 | public virtual Meeting Recurrence { get; set; } 28 | public virtual ICollection InverseRecurrence { get; set; } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/MeetingAttendee.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class MeetingAttendee 4 | { 5 | public int MeetingID { get; set; } 6 | public int AttendeeID { get; set; } 7 | 8 | public virtual Meeting Meeting { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Order.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace graphql_aspnet_core.Data 5 | { 6 | public partial class Order 7 | { 8 | public Order() 9 | { 10 | OrderDetails = new HashSet(); 11 | } 12 | 13 | public int OrderID { get; set; } 14 | public string CustomerID { get; set; } 15 | public int? EmployeeID { get; set; } 16 | public decimal? Freight { get; set; } 17 | public DateTime? OrderDate { get; set; } 18 | public string RequiredDate { get; set; } 19 | public string ShipAddress { get; set; } 20 | public string ShipCity { get; set; } 21 | public string ShipCountry { get; set; } 22 | public string ShipName { get; set; } 23 | public DateTime? ShippedDate { get; set; } 24 | public string ShipPostalCode { get; set; } 25 | public string ShipRegion { get; set; } 26 | public int? ShipVia { get; set; } 27 | 28 | public virtual ICollection OrderDetails { get; set; } 29 | public virtual Customer Customer { get; set; } 30 | public virtual Employee Employee { get; set; } 31 | public virtual Shipper ShipViaNavigation { get; set; } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/OrderDetail.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class OrderDetail 4 | { 5 | public int OrderID { get; set; } 6 | public int ProductID { get; set; } 7 | public double Discount { get; set; } 8 | public int Quantity { get; set; } 9 | public double UnitPrice { get; set; } 10 | 11 | public virtual Order Order { get; set; } 12 | public virtual Product Product { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/OrgChartConnection.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class OrgChartConnection 4 | { 5 | public long Id { get; set; } 6 | public long? FromPointX { get; set; } 7 | public long? FromPointY { get; set; } 8 | public long? FromShapeId { get; set; } 9 | public string Text { get; set; } 10 | public long? ToPointX { get; set; } 11 | public long? ToPointY { get; set; } 12 | public long? ToShapeId { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/OrgChartShape.cs: -------------------------------------------------------------------------------- 1 | namespace graphql_aspnet_core.Data 2 | { 3 | public partial class OrgChartShape 4 | { 5 | public int Id { get; set; } 6 | public string Color { get; set; } 7 | public string JobTitle { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Product.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Product 6 | { 7 | public Product() 8 | { 9 | OrderDetails = new HashSet(); 10 | } 11 | 12 | public int ProductID { get; set; } 13 | public int? CategoryID { get; set; } 14 | public bool Discontinued { get; set; } 15 | public string ProductName { get; set; } 16 | public string QuantityPerUnit { get; set; } 17 | public int? ReorderLevel { get; set; } 18 | public int? SupplierID { get; set; } 19 | public decimal? UnitPrice { get; set; } 20 | public int? UnitsInStock { get; set; } 21 | public int? UnitsOnOrder { get; set; } 22 | 23 | public virtual ICollection OrderDetails { get; set; } 24 | public virtual Category Category { get; set; } 25 | public virtual Supplier Supplier { get; set; } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Region.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Region 6 | { 7 | public Region() 8 | { 9 | Territories = new HashSet(); 10 | } 11 | 12 | public int RegionID { get; set; } 13 | public string RegionDescription { get; set; } 14 | 15 | public virtual ICollection Territories { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Shipper.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Shipper 6 | { 7 | public Shipper() 8 | { 9 | Orders = new HashSet(); 10 | } 11 | 12 | public int ShipperID { get; set; } 13 | public string CompanyName { get; set; } 14 | public string Phone { get; set; } 15 | 16 | public virtual ICollection Orders { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Stock.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Stock 6 | { 7 | public int ID { get; set; } 8 | public decimal Close { get; set; } 9 | public DateTime Date { get; set; } 10 | public decimal High { get; set; } 11 | public decimal Low { get; set; } 12 | public decimal Open { get; set; } 13 | public string Symbol { get; set; } 14 | public long Volume { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Supplier.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Supplier 6 | { 7 | public Supplier() 8 | { 9 | Products = new HashSet(); 10 | } 11 | 12 | public int SupplierID { get; set; } 13 | public string Address { get; set; } 14 | public string City { get; set; } 15 | public string CompanyName { get; set; } 16 | public string ContactName { get; set; } 17 | public string ContactTitle { get; set; } 18 | public string Country { get; set; } 19 | public string Fax { get; set; } 20 | public string HomePage { get; set; } 21 | public string Phone { get; set; } 22 | public string PostalCode { get; set; } 23 | public string Region { get; set; } 24 | 25 | public virtual ICollection Products { get; set; } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Task.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace graphql_aspnet_core.Data 5 | { 6 | public partial class Task 7 | { 8 | public int TaskID { get; set; } 9 | public string Description { get; set; } 10 | public DateTime End { get; set; } 11 | public string EndTimezone { get; set; } 12 | public bool IsAllDay { get; set; } 13 | public int? OwnerID { get; set; } 14 | public string RecurrenceException { get; set; } 15 | public int? RecurrenceID { get; set; } 16 | public string RecurrenceRule { get; set; } 17 | public DateTime Start { get; set; } 18 | public string StartTimezone { get; set; } 19 | public string Title { get; set; } 20 | 21 | public virtual Task Recurrence { get; set; } 22 | public virtual ICollection InverseRecurrence { get; set; } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Territory.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Territory 6 | { 7 | public Territory() 8 | { 9 | EmployeeTerritories = new HashSet(); 10 | } 11 | 12 | public string TerritoryID { get; set; } 13 | public int RegionID { get; set; } 14 | public string TerritoryDescription { get; set; } 15 | 16 | public virtual ICollection EmployeeTerritories { get; set; } 17 | public virtual Region Region { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/UrbanArea.cs: -------------------------------------------------------------------------------- 1 | using System.ComponentModel.DataAnnotations.Schema; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class UrbanArea 6 | { 7 | public int ID { get; set; } 8 | public string City { get; set; } 9 | public string Country { get; set; } 10 | public string Country_ISO3 { get; set; } 11 | public double Latitude { get; set; } 12 | public double Longitude { get; set; } 13 | public long Pop1950 { get; set; } 14 | public long Pop1955 { get; set; } 15 | public long Pop1960 { get; set; } 16 | public long Pop1965 { get; set; } 17 | public long Pop1970 { get; set; } 18 | public long Pop1975 { get; set; } 19 | public long Pop1980 { get; set; } 20 | public long Pop1985 { get; set; } 21 | public long Pop1990 { get; set; } 22 | public long Pop1995 { get; set; } 23 | public long Pop2000 { get; set; } 24 | public long Pop2005 { get; set; } 25 | public long Pop2010 { get; set; } 26 | public long Pop2015 { get; set; } 27 | public long Pop2020 { get; set; } 28 | public long Pop2025 { get; set; } 29 | public long Pop2050 { get; set; } 30 | 31 | [NotMapped] 32 | public double[] Location 33 | { 34 | get 35 | { 36 | return new double[] { Latitude, Longitude }; 37 | } 38 | 39 | private set { } 40 | } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Data/SamplesEntities/Weather.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace graphql_aspnet_core.Data 4 | { 5 | public partial class Weather 6 | { 7 | public int ID { get; set; } 8 | public string Station { get; set; } 9 | public DateTime Date { get; set; } 10 | public decimal TMax { get; set; } 11 | public decimal TMin { get; set; } 12 | public decimal Wind { get; set; } 13 | public decimal? Gust { get; set; } 14 | public decimal Rain { get; set; } 15 | public decimal? Snow { get; set; } 16 | public string Events { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Models/GraphQL/GraphQLQuery.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json.Linq; 2 | 3 | namespace graphql_aspnet_core.Models.GraphQL 4 | { 5 | public class GraphQLQuery 6 | { 7 | public string OperationName { get; set; } 8 | public string NamedQuery { get; set; } 9 | public string Query { get; set; } 10 | public JObject Variables { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Models/GraphQL/Product/GraphQLActionResult.cs: -------------------------------------------------------------------------------- 1 | using GraphQL; 2 | using Microsoft.AspNetCore.Mvc; 3 | using Microsoft.Extensions.DependencyInjection; 4 | using System.Net; 5 | using System.Threading.Tasks; 6 | 7 | namespace graphql_aspnet_core.Models.GraphQL 8 | { 9 | public class GraphQLActionResult : IActionResult 10 | { 11 | private readonly ExecutionResult _executionResult; 12 | 13 | public GraphQLActionResult(ExecutionResult executionResult) 14 | { 15 | _executionResult = executionResult; 16 | } 17 | 18 | public async Task ExecuteResultAsync(ActionContext context) 19 | { 20 | var serializer = context.HttpContext.RequestServices.GetRequiredService(); 21 | var response = context.HttpContext.Response; 22 | response.ContentType = "application/json"; 23 | response.StatusCode = _executionResult.Executed ? (int)HttpStatusCode.OK : (int)HttpStatusCode.BadRequest; 24 | await serializer.WriteAsync(response.Body, _executionResult, context.HttpContext.RequestAborted); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Models/GraphQL/Product/ProductInputType.cs: -------------------------------------------------------------------------------- 1 | using GraphQL.Types; 2 | 3 | namespace graphql_aspnet_core.Models.GraphQL 4 | { 5 | public class ProductInputType : InputObjectGraphType 6 | { 7 | public ProductInputType() 8 | { 9 | Name = "ProductInput"; 10 | Field>("ProductID"); 11 | Field>("ProductName"); 12 | Field("UnitPrice"); 13 | Field("UnitsInStock"); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Models/GraphQL/Product/ProductQuery.cs: -------------------------------------------------------------------------------- 1 | using GraphQL; 2 | using GraphQL.Types; 3 | using graphql_aspnet_core.Data.Contracts; 4 | 5 | namespace graphql_aspnet_core.Models.GraphQL 6 | { 7 | public class ProductQuery : ObjectGraphType 8 | { 9 | public ProductQuery(IProductRepository productRepository) 10 | { 11 | Field("product") 12 | .Argument>("ProductID", "") 13 | .ResolveAsync(async ctx => await productRepository.GetAsync(ctx.GetArgument("productID"))); 14 | 15 | Field>("products") 16 | .ResolveAsync(async context => await productRepository.AllAsync()); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Models/GraphQL/Product/ProductType.cs: -------------------------------------------------------------------------------- 1 | using GraphQL.Types; 2 | 3 | namespace graphql_aspnet_core.Models.GraphQL 4 | { 5 | public class ProductType : ObjectGraphType 6 | { 7 | public ProductType() 8 | { 9 | Field(x => x.ProductID); 10 | Field(x => x.ProductName); 11 | Field(x => x.UnitPrice, true); 12 | Field(x => x.UnitsInStock, true); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Models/GraphQL/Product/ProductsSchema.cs: -------------------------------------------------------------------------------- 1 | using GraphQL.Types; 2 | using Microsoft.Extensions.DependencyInjection; 3 | using System; 4 | 5 | namespace graphql_aspnet_core.Models.GraphQL.Product 6 | { 7 | public class ProductsSchema : Schema 8 | { 9 | public ProductsSchema(IServiceProvider serviceProvider) : base(serviceProvider) 10 | { 11 | Query = serviceProvider.GetRequiredService(); 12 | Mutation = serviceProvider.GetRequiredService(); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Program.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore; 2 | using Microsoft.AspNetCore.Hosting; 3 | 4 | namespace graphql_aspnet_core 5 | { 6 | public class Program 7 | { 8 | public static void Main(string[] args) 9 | { 10 | CreateWebHostBuilder(args).Build().Run(); 11 | } 12 | 13 | public static IWebHostBuilder CreateWebHostBuilder(string[] args) => 14 | WebHost.CreateDefaultBuilder(args) 15 | .UseStartup(); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "iisSettings": { 3 | "windowsAuthentication": false, 4 | "anonymousAuthentication": true, 5 | "iisExpress": { 6 | "applicationUrl": "http://localhost:5000", 7 | "sslPort": 0 8 | } 9 | }, 10 | "profiles": { 11 | "IIS Express": { 12 | "commandName": "IISExpress", 13 | "launchBrowser": true, 14 | "environmentVariables": { 15 | "ASPNETCORE_ENVIRONMENT": "Development" 16 | } 17 | }, 18 | "graphql_aspnet_core": { 19 | "commandName": "Project", 20 | "launchBrowser": true, 21 | "applicationUrl": "http://localhost:5000", 22 | "environmentVariables": { 23 | "ASPNETCORE_ENVIRONMENT": "Development" 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "Debug", 6 | "System": "Information", 7 | "Microsoft": "Information" 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "Warning" 6 | } 7 | }, 8 | "AllowedHosts": "*" 9 | } 10 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/graphql-aspnet-core.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | net8.0 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/wwwroot/App_Data/customers.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/graphql/graphql-aspnet-core/graphql-aspnet-core/wwwroot/App_Data/customers.db -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/wwwroot/App_Data/sample.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/graphql/graphql-aspnet-core/graphql-aspnet-core/wwwroot/App_Data/sample.db -------------------------------------------------------------------------------- /graphql/graphql-aspnet-core/graphql-aspnet-core/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/graphql/graphql-aspnet-core/graphql-aspnet-core/wwwroot/favicon.ico -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 17 4 | VisualStudioVersion = 17.6.33723.286 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "kendo-northwind-pg", "kendo-northwind-pg\kendo-northwind-pg.csproj", "{CFF05E32-B0F5-454F-84AA-515988FBF245}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {CFF05E32-B0F5-454F-84AA-515988FBF245}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {CFF05E32-B0F5-454F-84AA-515988FBF245}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {CFF05E32-B0F5-454F-84AA-515988FBF245}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {CFF05E32-B0F5-454F-84AA-515988FBF245}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {AEEF3223-71A6-4BEB-8918-8617BFA3CC70} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Category.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class Category 4 | { 5 | public int CategoryID { get; set; } 6 | public string CategoryName { get; set; } 7 | public string Description { get; set; } 8 | public byte[] Picture { get; set; } 9 | 10 | public virtual ICollection Products { get; set; } = new List(); 11 | public virtual ICollection DetailProducts { get; set; } = new List(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Customer.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class Customer 4 | { 5 | public Customer() 6 | { 7 | CustomerCustomerDemo = new HashSet(); 8 | Orders = new HashSet(); 9 | } 10 | 11 | public string CustomerID { get; set; } 12 | public string Address { get; set; } 13 | public bool Bool { get; set; } 14 | public string City { get; set; } 15 | public string CompanyName { get; set; } 16 | public string ContactName { get; set; } 17 | public string ContactTitle { get; set; } 18 | public string Country { get; set; } 19 | public string Fax { get; set; } 20 | public string Phone { get; set; } 21 | public string PostalCode { get; set; } 22 | public string Region { get; set; } 23 | 24 | public virtual ICollection CustomerCustomerDemo { get; set; } 25 | public virtual ICollection Orders { get; set; } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/CustomerCustomerDemo.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class CustomerCustomerDemo 4 | { 5 | public string CustomerID { get; set; } 6 | public string CustomerTypeID { get; set; } 7 | 8 | public virtual Customer Customer { get; set; } 9 | public virtual CustomerDemographic CustomerType { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/CustomerDemographic.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class CustomerDemographic 4 | { 5 | public CustomerDemographic() 6 | { 7 | CustomerCustomerDemo = new HashSet(); 8 | } 9 | 10 | public string CustomerTypeID { get; set; } 11 | 12 | public string CustomerDesc { get; set; } 13 | 14 | public virtual ICollection CustomerCustomerDemo { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/DetailProduct.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class DetailProduct 9 | { 10 | public int ProductId { get; set; } 11 | 12 | public string ProductName { get; set; } 13 | 14 | public decimal? UnitPrice { get; set; } 15 | 16 | public short? UnitsInStock { get; set; } 17 | 18 | public string QuantityPerUnit { get; set; } 19 | 20 | public bool Discontinued { get; set; } 21 | 22 | public int? UnitsOnOrder { get; set; } 23 | 24 | public int? CategoryId { get; set; } 25 | 26 | public byte? CountryId { get; set; } 27 | 28 | public byte? CustomerRating { get; set; } 29 | 30 | public int? TargetSales { get; set; } 31 | 32 | public DateTime? LastSupply { get; set; } 33 | 34 | public virtual Category Category { get; set; } 35 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Employee.cs: -------------------------------------------------------------------------------- 1 | using System.ComponentModel.DataAnnotations.Schema; 2 | 3 | namespace kendo_northwind_pg.Data.Models 4 | { 5 | public partial class Employee 6 | { 7 | public Employee() 8 | { 9 | EmployeeTerritories = new HashSet(); 10 | Orders = new HashSet(); 11 | } 12 | 13 | public int EmployeeID { get; set; } 14 | public string? Address { get; set; } 15 | public string? BirthDate { get; set; } 16 | public string? City { get; set; } 17 | public string? Country { get; set; } 18 | public string? Extension { get; set; } 19 | public string? FirstName { get; set; } 20 | public string? HireDate { get; set; } 21 | public string? HomePhone { get; set; } 22 | public string? LastName { get; set; } 23 | public string? Notes { get; set; } 24 | public byte[] Photo { get; set; } 25 | public string? PhotoPath { get; set; } 26 | public string? PostalCode { get; set; } 27 | public string? Region { get; set; } 28 | public int? ReportsTo { get; set; } 29 | public string? Title { get; set; } 30 | public string? TitleOfCourtesy { get; set; } 31 | 32 | [NotMapped] 33 | public bool hasChildren { get; set; } = true; 34 | 35 | public virtual ICollection EmployeeTerritories { get; set; } 36 | public virtual ICollection Orders { get; set; } 37 | public virtual Employee ReportsToNavigation { get; set; } 38 | public virtual ICollection InverseReportsToNavigation { get; set; } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/EmployeeDirectory.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class EmployeeDirectory 9 | { 10 | public int EmployeeId { get; set; } 11 | 12 | public string FirstName { get; set; } 13 | 14 | public string LastName { get; set; } 15 | 16 | public int? ReportsTo { get; set; } 17 | 18 | public string Address { get; set; } 19 | 20 | public string City { get; set; } 21 | 22 | public string Country { get; set; } 23 | 24 | public string Phone { get; set; } 25 | 26 | public int? Extension { get; set; } 27 | 28 | public DateTime? BirthDate { get; set; } 29 | 30 | public DateTime? HireDate { get; set; } 31 | 32 | public string Position { get; set; } 33 | 34 | public virtual ICollection InverseReportsToNavigation { get; set; } = new List(); 35 | 36 | public virtual EmployeeDirectory ReportsToNavigation { get; set; } 37 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/EmployeeTerritory.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class EmployeeTerritory 4 | { 5 | public int EmployeeID { get; set; } 6 | public string TerritoryID { get; set; } 7 | 8 | public virtual Employee Employee { get; set; } 9 | public virtual Territory Territory { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/GanttDependency.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class GanttDependency 9 | { 10 | public int Id { get; set; } 11 | 12 | public int PredecessorId { get; set; } 13 | 14 | public int SuccessorId { get; set; } 15 | 16 | public int Type { get; set; } 17 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/GanttResource.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class GanttResource 9 | { 10 | public int Id { get; set; } 11 | 12 | public string Name { get; set; } 13 | 14 | public string Color { get; set; } 15 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/GanttResourceAssignment.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class GanttResourceAssignment 9 | { 10 | public int Id { get; set; } 11 | 12 | public int TaskId { get; set; } 13 | 14 | public int ResourceId { get; set; } 15 | 16 | public double Units { get; set; } 17 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/GanttTask.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace kendo_northwind_pg.Data.Models; 5 | 6 | public partial class GanttTask 7 | { 8 | public int Id { get; set; } 9 | 10 | public int? ParentId { get; set; } 11 | 12 | public int OrderId { get; set; } 13 | 14 | public string Title { get; set; } 15 | 16 | public DateTime Start { get; set; } 17 | 18 | public DateTime End { get; set; } 19 | 20 | public double PercentComplete { get; set; } 21 | 22 | public bool Expanded { get; set; } 23 | 24 | public bool Summary { get; set; } 25 | 26 | public virtual ICollection InverseParent { get; set; } = new List(); 27 | 28 | public virtual GanttTask Parent { get; set; } 29 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Intraday.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class Intraday 9 | { 10 | public int Id { get; set; } 11 | 12 | public string Symbol { get; set; } 13 | 14 | public DateTime Date { get; set; } 15 | 16 | public double Open { get; set; } 17 | 18 | public double High { get; set; } 19 | 20 | public double Low { get; set; } 21 | 22 | public double Close { get; set; } 23 | 24 | public int Volume { get; set; } 25 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Meeting.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class Meeting 9 | { 10 | public int MeetingId { get; set; } 11 | 12 | public DateTime Start { get; set; } 13 | 14 | public DateTime End { get; set; } 15 | 16 | public string Title { get; set; } 17 | 18 | public string Description { get; set; } 19 | 20 | public int? RoomId { get; set; } 21 | 22 | public bool IsAllDay { get; set; } 23 | 24 | public string RecurrenceRule { get; set; } 25 | 26 | public int? RecurrenceId { get; set; } 27 | 28 | public string RecurrenceException { get; set; } 29 | 30 | public string StartTimezone { get; set; } 31 | 32 | public string EndTimezone { get; set; } 33 | 34 | public virtual ICollection InverseRecurrence { get; set; } = new List(); 35 | 36 | public virtual ICollection MeetingAttendees { get; set; } = new List(); 37 | 38 | public virtual Meeting Recurrence { get; set; } 39 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/MeetingAttendee.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class MeetingAttendee 9 | { 10 | public int MeetingId { get; set; } 11 | 12 | public int AttendeeId { get; set; } 13 | 14 | public virtual Meeting Meeting { get; set; } 15 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/OdataModels.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.OData.Edm; 2 | using Microsoft.OData.ModelBuilder; 3 | 4 | namespace kendo_northwind_pg.Data.Models 5 | { 6 | public static class OdataModels 7 | { 8 | public static IEdmModel GetEdmModel() 9 | { 10 | ODataConventionModelBuilder builder = new ODataConventionModelBuilder(); 11 | builder.Action("odata/EmployeeDedoviq"); 12 | builder.EntitySet("TopEmployees"); 13 | builder.EntitySet("EmployeeTerritories"); 14 | builder.EntitySet("EmployeeOrders"); 15 | builder.EntitySet("EmployeeSubordinates"); 16 | builder.EntitySet("Categories"); 17 | builder.EntitySet("Customers"); 18 | builder.EntitySet("Employees"); 19 | builder.EntitySet("Orders"); 20 | builder.EntitySet("Products"); 21 | builder.EntitySet("Regions"); 22 | builder.EntitySet("Shippers"); 23 | builder.EntitySet("Suppliers"); 24 | builder.EntitySet("Territories"); 25 | builder.StructuralTypes.First(t => t.ClrType == typeof(Employee)).AddProperty(typeof(Employee).GetProperty("hasChildren")); 26 | 27 | return builder.GetEdmModel(); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Order.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace kendo_northwind_pg.Data.Models 4 | { 5 | public partial class Order 6 | { 7 | public Order() 8 | { 9 | OrderDetails = new HashSet(); 10 | } 11 | 12 | public int OrderID { get; set; } 13 | public string CustomerID { get; set; } 14 | public int? EmployeeID { get; set; } 15 | public decimal? Freight { get; set; } 16 | public DateTime? OrderDate { get; set; } 17 | public string RequiredDate { get; set; } 18 | public string ShipAddress { get; set; } 19 | public string ShipCity { get; set; } 20 | public string ShipCountry { get; set; } 21 | public string ShipName { get; set; } 22 | public DateTime? ShippedDate { get; set; } 23 | public string ShipPostalCode { get; set; } 24 | public string ShipRegion { get; set; } 25 | public int? ShipVia { get; set; } 26 | 27 | [JsonIgnore] 28 | public virtual ICollection OrderDetails { get; set; } 29 | public virtual Customer Customer { get; set; } 30 | public virtual Employee Employee { get; set; } 31 | public virtual Shipper ShipViaNavigation { get; set; } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/OrderDetail.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace kendo_northwind_pg.Data.Models 4 | { 5 | public partial class OrderDetail 6 | { 7 | public int OrderID { get; set; } 8 | public int ProductID { get; set; } 9 | public double Discount { get; set; } 10 | public int Quantity { get; set; } 11 | public double UnitPrice { get; set; } 12 | 13 | public virtual Order Order { get; set; } 14 | [JsonIgnore] 15 | public virtual Product Product { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/OrgChartConnection.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class OrgChartConnection 9 | { 10 | public int Id { get; set; } 11 | 12 | public int? FromShapeId { get; set; } 13 | 14 | public int? ToShapeId { get; set; } 15 | 16 | public string Text { get; set; } 17 | 18 | public int? FromPointX { get; set; } 19 | 20 | public int? FromPointY { get; set; } 21 | 22 | public int? ToPointX { get; set; } 23 | 24 | public int? ToPointY { get; set; } 25 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/OrgChartShape.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class OrgChartShape 9 | { 10 | public int Id { get; set; } 11 | 12 | public string JobTitle { get; set; } 13 | 14 | public string Color { get; set; } 15 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Product.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class Product 4 | { 5 | public Product() 6 | { 7 | OrderDetails = new HashSet(); 8 | } 9 | 10 | public int ProductID { get; set; } 11 | public int? CategoryID { get; set; } 12 | public bool Discontinued { get; set; } 13 | public string ProductName { get; set; } 14 | public string QuantityPerUnit { get; set; } 15 | public int? ReorderLevel { get; set; } 16 | public int? SupplierID { get; set; } 17 | public decimal? UnitPrice { get; set; } 18 | public int? UnitsInStock { get; set; } 19 | public int? UnitsOnOrder { get; set; } 20 | 21 | public virtual ICollection OrderDetails { get; set; } 22 | public virtual Category Category { get; set; } 23 | public virtual Supplier Supplier { get; set; } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Region.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class Region 4 | { 5 | public Region() 6 | { 7 | Territories = new HashSet(); 8 | } 9 | 10 | public int RegionID { get; set; } 11 | public string RegionDescription { get; set; } 12 | 13 | public virtual ICollection Territories { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Shipper.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class Shipper 4 | { 5 | public Shipper() 6 | { 7 | Orders = new HashSet(); 8 | } 9 | 10 | public int ShipperID { get; set; } 11 | public string CompanyName { get; set; } 12 | public string Phone { get; set; } 13 | 14 | public virtual ICollection Orders { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Stock.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class Stock 9 | { 10 | public int Id { get; set; } 11 | 12 | public string Symbol { get; set; } 13 | 14 | public DateTime Date { get; set; } 15 | 16 | public double Open { get; set; } 17 | 18 | public double High { get; set; } 19 | 20 | public double Low { get; set; } 21 | 22 | public double Close { get; set; } 23 | 24 | public int Volume { get; set; } 25 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Supplier.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class Supplier 4 | { 5 | public Supplier() 6 | { 7 | Products = new HashSet(); 8 | } 9 | 10 | public int SupplierID { get; set; } 11 | public string Address { get; set; } 12 | public string City { get; set; } 13 | public string CompanyName { get; set; } 14 | public string ContactName { get; set; } 15 | public string ContactTitle { get; set; } 16 | public string Country { get; set; } 17 | public string Fax { get; set; } 18 | public string HomePage { get; set; } 19 | public string Phone { get; set; } 20 | public string PostalCode { get; set; } 21 | public string Region { get; set; } 22 | 23 | public virtual ICollection Products { get; set; } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Task.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class Task 9 | { 10 | public int TaskId { get; set; } 11 | 12 | public DateTime Start { get; set; } 13 | 14 | public DateTime End { get; set; } 15 | 16 | public string Title { get; set; } 17 | 18 | public string Description { get; set; } 19 | 20 | public int? OwnerId { get; set; } 21 | 22 | public bool IsAllDay { get; set; } 23 | 24 | public string RecurrenceRule { get; set; } 25 | 26 | public int? RecurrenceId { get; set; } 27 | 28 | public string RecurrenceException { get; set; } 29 | 30 | public string StartTimezone { get; set; } 31 | 32 | public string EndTimezone { get; set; } 33 | 34 | public virtual ICollection InverseRecurrence { get; set; } = new List(); 35 | 36 | public virtual Task Recurrence { get; set; } 37 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/Territory.cs: -------------------------------------------------------------------------------- 1 | namespace kendo_northwind_pg.Data.Models 2 | { 3 | public partial class Territory 4 | { 5 | public Territory() 6 | { 7 | EmployeeTerritories = new HashSet(); 8 | } 9 | 10 | public string TerritoryID { get; set; } 11 | public int RegionID { get; set; } 12 | public string TerritoryDescription { get; set; } 13 | 14 | public virtual ICollection EmployeeTerritories { get; set; } 15 | public virtual Region Region { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Data/Models/UrbanArea.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated by EF Core Power Tools. 2 | #nullable disable 3 | using System; 4 | using System.Collections.Generic; 5 | 6 | namespace kendo_northwind_pg.Data.Models; 7 | 8 | public partial class UrbanArea 9 | { 10 | public int Id { get; set; } 11 | 12 | public string City { get; set; } 13 | 14 | public string Country { get; set; } 15 | 16 | public double Latitude { get; set; } 17 | 18 | public double Longitude { get; set; } 19 | 20 | public string CountryIso3 { get; set; } 21 | 22 | public int Pop1950 { get; set; } 23 | 24 | public int Pop1955 { get; set; } 25 | 26 | public int Pop1960 { get; set; } 27 | 28 | public int Pop1965 { get; set; } 29 | 30 | public int Pop1970 { get; set; } 31 | 32 | public int Pop1975 { get; set; } 33 | 34 | public int Pop1980 { get; set; } 35 | 36 | public int Pop1985 { get; set; } 37 | 38 | public int Pop1990 { get; set; } 39 | 40 | public int Pop1995 { get; set; } 41 | 42 | public int Pop2000 { get; set; } 43 | 44 | public int Pop2005 { get; set; } 45 | 46 | public int Pop2010 { get; set; } 47 | 48 | public int Pop2015 { get; set; } 49 | 50 | public int Pop2020 { get; set; } 51 | 52 | public int Pop2025 { get; set; } 53 | 54 | public int Pop2050 { get; set; } 55 | } -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Extensions/SessionExtensions.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | using System.Text.Json; 3 | using System.Text.Json.Serialization; 4 | 5 | namespace kendo_northwind_pg.Extensions 6 | { 7 | public static class SessionExtensions 8 | { 9 | public static void SetObjectAsJson(this ISession session, string key, object value) 10 | { 11 | var options = new JsonSerializerOptions 12 | { 13 | ReferenceHandler = ReferenceHandler.Preserve, 14 | WriteIndented = true 15 | }; 16 | session.SetString(key, System.Text.Json.JsonSerializer.Serialize(value, options)); 17 | } 18 | 19 | public static T GetObjectFromJson(this ISession session, string key) 20 | { 21 | var value = session.GetString(key); 22 | var options = new JsonSerializerOptions 23 | { 24 | ReferenceHandler = ReferenceHandler.Preserve, 25 | WriteIndented = true 26 | }; 27 | 28 | return value == null ? default(T) : System.Text.Json.JsonSerializer.Deserialize(value, options); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Extensions/SessionUtils.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | using System.Security.Cryptography; 3 | using System.Text; 4 | using System.Text.Json; 5 | using System.Text.Json.Serialization; 6 | 7 | namespace kendo_northwind_pg 8 | { 9 | public static class SessionUtils 10 | { 11 | public static string GetUserKey(IHttpContextAccessor _contextAccessor) 12 | { 13 | var identifierBuilder = new StringBuilder(); 14 | var connectionID = _contextAccessor.HttpContext.Connection.Id.Substring(0, 11); 15 | 16 | identifierBuilder.Append(connectionID); 17 | 18 | var ipAddress = _contextAccessor.HttpContext.Connection.RemoteIpAddress?.ToString() ?? "unknown"; 19 | identifierBuilder.Append(ipAddress); 20 | 21 | var userAgent = _contextAccessor.HttpContext.Response.Headers["User-Agent"].ToString(); 22 | identifierBuilder.Append(userAgent); 23 | 24 | var identifier = Convert.ToBase64String(SHA256.HashData(Encoding.UTF8.GetBytes(identifierBuilder.ToString()))).Substring(0, 32); 25 | 26 | return identifier; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "iisSettings": { 3 | "windowsAuthentication": false, 4 | "anonymousAuthentication": true, 5 | "iisExpress": { 6 | "applicationUrl": "http://localhost:57604", 7 | "sslPort": 44307 8 | } 9 | }, 10 | "profiles": { 11 | "http": { 12 | "commandName": "Project", 13 | "dotnetRunMessages": true, 14 | "launchBrowser": true, 15 | "applicationUrl": "http://localhost:5259", 16 | "environmentVariables": { 17 | "ASPNETCORE_ENVIRONMENT": "Development" 18 | } 19 | }, 20 | "https": { 21 | "commandName": "Project", 22 | "dotnetRunMessages": true, 23 | "launchBrowser": true, 24 | "applicationUrl": "https://localhost:7240;http://localhost:5259", 25 | "environmentVariables": { 26 | "ASPNETCORE_ENVIRONMENT": "Development" 27 | } 28 | }, 29 | "IIS Express": { 30 | "commandName": "IISExpress", 31 | "launchBrowser": true, 32 | "environmentVariables": { 33 | "ASPNETCORE_ENVIRONMENT": "Development" 34 | } 35 | } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Information", 5 | "Microsoft.AspNetCore": "Warning" 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Information", 5 | "Microsoft.AspNetCore": "Warning" 6 | } 7 | }, 8 | "AllowedHosts": "*" 9 | } 10 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/kendo-northwind-pg.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | net8.0 5 | disable 6 | enable 7 | kendo_northwind_pg 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | all 17 | runtime; build; native; contentfiles; analyzers; buildtransitive 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/wwwroot/data/sample.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/wwwroot/data/sample.db -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/wwwroot/data/sample.db-shm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/wwwroot/data/sample.db-shm -------------------------------------------------------------------------------- /odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/wwwroot/data/sample.db-wal: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/odata-v4-core/kendo-northwind-pg/kendo-northwind-pg/wwwroot/data/sample.db-wal -------------------------------------------------------------------------------- /signalr-hubs/README.md: -------------------------------------------------------------------------------- 1 | # ASP.NET Core SignalR hub 2 | 3 | ## Steps do deploy the application: 4 | 1. Navigate to the `signalr-for-aspnet-core` folder 5 | ``` 6 | cd signalr-for-aspnet-core 7 | ``` 8 | 2. Execute: 9 | ``` 10 | dotnet restore 11 | dotnet publish --framework netcoreapp2.1 --configuration Release 12 | ``` 13 | **Note:** The specific version depends on the version of ASP.NET Core that the project is targeting. A compatible version should also be installed on the staging machine. 14 | 15 | 3. The files that need to be deployed are located in the following folder: 16 | ``` 17 | signalr-for-aspnet-core\bin\Release\netcoreapp2.1\publish 18 | ``` 19 | -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core.sln: -------------------------------------------------------------------------------- 1 | 2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 15 4 | VisualStudioVersion = 15.0.27428.2037 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "signalr-for-aspnet-core", "signalr-for-aspnet-core\signalr-for-aspnet-core.csproj", "{C10DB25F-9FF8-4136-A05D-1869947045AF}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {C10DB25F-9FF8-4136-A05D-1869947045AF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {C10DB25F-9FF8-4136-A05D-1869947045AF}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {C10DB25F-9FF8-4136-A05D-1869947045AF}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {C10DB25F-9FF8-4136-A05D-1869947045AF}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {DF301F58-E83C-4229-A456-08A454A9AD2F} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/CategorySignalR.cs: -------------------------------------------------------------------------------- 1 | namespace signalr_for_aspnet_core.Models; 2 | 3 | public class CategorySignalR 4 | { 5 | public int CategoryID { get; set; } 6 | public string CategoryName { get; set; } 7 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/MeetingSignalR.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public class MeetingSignalR : SchedulerEvent 7 | { 8 | public Guid? ID { get; set; } 9 | public int? RoomID { get; set; } 10 | public IEnumerable Attendees { get; set; } 11 | public DateTime? CreatedAt { get; set; } 12 | } 13 | -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/ProductSignalR.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace signalr_for_aspnet_core.Models; 4 | 5 | public class ProductSignalR 6 | { 7 | public long? ID { get; set; } 8 | public string ProductName { get; set; } 9 | public double UnitPrice { get; set; } 10 | public int UnitsInStock { get; set; } 11 | public DateTime? CreatedAt { get; set; } 12 | public CategorySignalR Category { get; set; } 13 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Category.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Category 7 | { 8 | public Category() 9 | { 10 | Products = new HashSet(); 11 | } 12 | 13 | public int CategoryID { get; set; } 14 | public string CategoryName { get; set; } 15 | public string Description { get; set; } 16 | public byte[] Picture { get; set; } 17 | 18 | public virtual ICollection Products { get; set; } 19 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Customer.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Customer 7 | { 8 | public Customer() 9 | { 10 | CustomerCustomerDemo = new HashSet(); 11 | Orders = new HashSet(); 12 | } 13 | 14 | public string CustomerID { get; set; } 15 | public string Address { get; set; } 16 | public bool Bool { get; set; } 17 | public string City { get; set; } 18 | public string CompanyName { get; set; } 19 | public string ContactName { get; set; } 20 | public string ContactTitle { get; set; } 21 | public string Country { get; set; } 22 | public string Fax { get; set; } 23 | public string Phone { get; set; } 24 | public string PostalCode { get; set; } 25 | public string Region { get; set; } 26 | 27 | public virtual ICollection CustomerCustomerDemo { get; set; } 28 | public virtual ICollection Orders { get; set; } 29 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/CustomerCustomerDemo.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class CustomerCustomerDemo 7 | { 8 | public string CustomerID { get; set; } 9 | public string CustomerTypeID { get; set; } 10 | 11 | public virtual Customer Customer { get; set; } 12 | public virtual CustomerDemographic CustomerType { get; set; } 13 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/CustomerDemographic.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class CustomerDemographic 7 | { 8 | public CustomerDemographic() 9 | { 10 | CustomerCustomerDemo = new HashSet(); 11 | } 12 | 13 | public string CustomerTypeID { get; set; } 14 | public string CustomerDesc { get; set; } 15 | 16 | public virtual ICollection CustomerCustomerDemo { get; set; } 17 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Employee.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Employee 7 | { 8 | public Employee() 9 | { 10 | EmployeeTerritories = new HashSet(); 11 | Orders = new HashSet(); 12 | } 13 | 14 | public int EmployeeID { get; set; } 15 | public string Address { get; set; } 16 | public string BirthDate { get; set; } 17 | public string City { get; set; } 18 | public string Country { get; set; } 19 | public string Extension { get; set; } 20 | public string FirstName { get; set; } 21 | public string HireDate { get; set; } 22 | public string HomePhone { get; set; } 23 | public string LastName { get; set; } 24 | public string Notes { get; set; } 25 | public byte[] Photo { get; set; } 26 | public string PhotoPath { get; set; } 27 | public string PostalCode { get; set; } 28 | public string Region { get; set; } 29 | public int? ReportsTo { get; set; } 30 | public string Title { get; set; } 31 | public string TitleOfCourtesy { get; set; } 32 | 33 | public virtual ICollection EmployeeTerritories { get; set; } 34 | public virtual ICollection Orders { get; set; } 35 | public virtual Employee ReportsToNavigation { get; set; } 36 | public virtual ICollection InverseReportsToNavigation { get; set; } 37 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/EmployeeDirectory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class EmployeeDirectory 7 | { 8 | public int EmployeeID { get; set; } 9 | public string Address { get; set; } 10 | public DateTime? BirthDate { get; set; } 11 | public string City { get; set; } 12 | public string Country { get; set; } 13 | public int? Extension { get; set; } 14 | public string FirstName { get; set; } 15 | public DateTime? HireDate { get; set; } 16 | public string LastName { get; set; } 17 | public string Phone { get; set; } 18 | public string Position { get; set; } 19 | public int? ReportsTo { get; set; } 20 | 21 | public virtual EmployeeDirectory ReportsToNavigation { get; set; } 22 | public virtual ICollection InverseReportsToNavigation { get; set; } 23 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/EmployeeTerritory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class EmployeeTerritory 7 | { 8 | public int EmployeeID { get; set; } 9 | public string TerritoryID { get; set; } 10 | 11 | public virtual Employee Employee { get; set; } 12 | public virtual Territory Territory { get; set; } 13 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/GanttDependency.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class GanttDependency 7 | { 8 | public int ID { get; set; } 9 | public int PredecessorID { get; set; } 10 | public int SuccessorID { get; set; } 11 | public int Type { get; set; } 12 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/GanttResource.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class GanttResource 7 | { 8 | public int ID { get; set; } 9 | public string Color { get; set; } 10 | public string Name { get; set; } 11 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/GanttResourceAssignment.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class GanttResourceAssignment 7 | { 8 | public int ID { get; set; } 9 | public int ResourceID { get; set; } 10 | public int TaskID { get; set; } 11 | public decimal Units { get; set; } 12 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/GanttTask.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class GanttTask 7 | { 8 | public int ID { get; set; } 9 | public DateTime End { get; set; } 10 | public bool Expanded { get; set; } 11 | public int OrderID { get; set; } 12 | public int? ParentID { get; set; } 13 | public decimal PercentComplete { get; set; } 14 | public DateTime Start { get; set; } 15 | public bool Summary { get; set; } 16 | public string Title { get; set; } 17 | 18 | public virtual GanttTask Parent { get; set; } 19 | public virtual ICollection InverseParent { get; set; } 20 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Intraday.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Intraday 7 | { 8 | public int ID { get; set; } 9 | public decimal Close { get; set; } 10 | public DateTime Date { get; set; } 11 | public decimal High { get; set; } 12 | public decimal Low { get; set; } 13 | public decimal Open { get; set; } 14 | public string Symbol { get; set; } 15 | public long Volume { get; set; } 16 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Meeting.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Meeting 7 | { 8 | public Meeting() 9 | { 10 | MeetingAttendees = new HashSet(); 11 | } 12 | 13 | public int MeetingID { get; set; } 14 | public string Description { get; set; } 15 | public DateTime End { get; set; } 16 | public string EndTimezone { get; set; } 17 | public bool IsAllDay { get; set; } 18 | public string RecurrenceException { get; set; } 19 | public int? RecurrenceID { get; set; } 20 | public string RecurrenceRule { get; set; } 21 | public int? RoomID { get; set; } 22 | public DateTime Start { get; set; } 23 | public string StartTimezone { get; set; } 24 | public string Title { get; set; } 25 | 26 | public virtual ICollection MeetingAttendees { get; set; } 27 | public virtual Meeting Recurrence { get; set; } 28 | public virtual ICollection InverseRecurrence { get; set; } 29 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/MeetingAttendee.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class MeetingAttendee 7 | { 8 | public int MeetingID { get; set; } 9 | public int AttendeeID { get; set; } 10 | 11 | public virtual Meeting Meeting { get; set; } 12 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Order.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Order 7 | { 8 | public Order() 9 | { 10 | OrderDetails = new HashSet(); 11 | } 12 | 13 | public int OrderID { get; set; } 14 | public string CustomerID { get; set; } 15 | public int? EmployeeID { get; set; } 16 | public decimal? Freight { get; set; } 17 | public DateTime? OrderDate { get; set; } 18 | public string RequiredDate { get; set; } 19 | public string ShipAddress { get; set; } 20 | public string ShipCity { get; set; } 21 | public string ShipCountry { get; set; } 22 | public string ShipName { get; set; } 23 | public DateTime? ShippedDate { get; set; } 24 | public string ShipPostalCode { get; set; } 25 | public string ShipRegion { get; set; } 26 | public int? ShipVia { get; set; } 27 | 28 | public virtual ICollection OrderDetails { get; set; } 29 | public virtual Customer Customer { get; set; } 30 | public virtual Employee Employee { get; set; } 31 | public virtual Shipper ShipViaNavigation { get; set; } 32 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/OrderDetail.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class OrderDetail 7 | { 8 | public int OrderID { get; set; } 9 | public int ProductID { get; set; } 10 | public double Discount { get; set; } 11 | public int Quantity { get; set; } 12 | public double UnitPrice { get; set; } 13 | 14 | public virtual Order Order { get; set; } 15 | public virtual Product Product { get; set; } 16 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/OrgChartConnection.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class OrgChartConnection 7 | { 8 | public long Id { get; set; } 9 | public long? FromPointX { get; set; } 10 | public long? FromPointY { get; set; } 11 | public long? FromShapeId { get; set; } 12 | public string Text { get; set; } 13 | public long? ToPointX { get; set; } 14 | public long? ToPointY { get; set; } 15 | public long? ToShapeId { get; set; } 16 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/OrgChartShape.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class OrgChartShape 7 | { 8 | public int Id { get; set; } 9 | public string Color { get; set; } 10 | public string JobTitle { get; set; } 11 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Product.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Product 7 | { 8 | public Product() 9 | { 10 | OrderDetails = new HashSet(); 11 | } 12 | 13 | public int ProductID { get; set; } 14 | public int? CategoryID { get; set; } 15 | public bool Discontinued { get; set; } 16 | public string ProductName { get; set; } 17 | public string QuantityPerUnit { get; set; } 18 | public int? ReorderLevel { get; set; } 19 | public int? SupplierID { get; set; } 20 | public decimal? UnitPrice { get; set; } 21 | public int? UnitsInStock { get; set; } 22 | public int? UnitsOnOrder { get; set; } 23 | 24 | public virtual ICollection OrderDetails { get; set; } 25 | public virtual Category Category { get; set; } 26 | public virtual Supplier Supplier { get; set; } 27 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Region.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Region 7 | { 8 | public Region() 9 | { 10 | Territories = new HashSet(); 11 | } 12 | 13 | public int RegionID { get; set; } 14 | public string RegionDescription { get; set; } 15 | 16 | public virtual ICollection Territories { get; set; } 17 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Shipper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Shipper 7 | { 8 | public Shipper() 9 | { 10 | Orders = new HashSet(); 11 | } 12 | 13 | public int ShipperID { get; set; } 14 | public string CompanyName { get; set; } 15 | public string Phone { get; set; } 16 | 17 | public virtual ICollection Orders { get; set; } 18 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Stock.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Stock 7 | { 8 | public int ID { get; set; } 9 | public decimal Close { get; set; } 10 | public DateTime Date { get; set; } 11 | public decimal High { get; set; } 12 | public decimal Low { get; set; } 13 | public decimal Open { get; set; } 14 | public string Symbol { get; set; } 15 | public long Volume { get; set; } 16 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Supplier.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Supplier 7 | { 8 | public Supplier() 9 | { 10 | Products = new HashSet(); 11 | } 12 | 13 | public int SupplierID { get; set; } 14 | public string Address { get; set; } 15 | public string City { get; set; } 16 | public string CompanyName { get; set; } 17 | public string ContactName { get; set; } 18 | public string ContactTitle { get; set; } 19 | public string Country { get; set; } 20 | public string Fax { get; set; } 21 | public string HomePage { get; set; } 22 | public string Phone { get; set; } 23 | public string PostalCode { get; set; } 24 | public string Region { get; set; } 25 | 26 | public virtual ICollection Products { get; set; } 27 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Task.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Task 7 | { 8 | public int TaskID { get; set; } 9 | public string Description { get; set; } 10 | public DateTime End { get; set; } 11 | public string EndTimezone { get; set; } 12 | public bool IsAllDay { get; set; } 13 | public int? OwnerID { get; set; } 14 | public string RecurrenceException { get; set; } 15 | public int? RecurrenceID { get; set; } 16 | public string RecurrenceRule { get; set; } 17 | public DateTime Start { get; set; } 18 | public string StartTimezone { get; set; } 19 | public string Title { get; set; } 20 | 21 | public virtual Task Recurrence { get; set; } 22 | public virtual ICollection InverseRecurrence { get; set; } 23 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Territory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public partial class Territory 7 | { 8 | public Territory() 9 | { 10 | EmployeeTerritories = new HashSet(); 11 | } 12 | 13 | public string TerritoryID { get; set; } 14 | public int RegionID { get; set; } 15 | public string TerritoryDescription { get; set; } 16 | 17 | public virtual ICollection EmployeeTerritories { get; set; } 18 | public virtual Region Region { get; set; } 19 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/UrbanArea.cs: -------------------------------------------------------------------------------- 1 | using System.ComponentModel.DataAnnotations.Schema; 2 | 3 | namespace signalr_for_aspnet_core.Models; 4 | 5 | public partial class UrbanArea 6 | { 7 | public int ID { get; set; } 8 | public string City { get; set; } 9 | public string Country { get; set; } 10 | public string Country_ISO3 { get; set; } 11 | public double Latitude { get; set; } 12 | public double Longitude { get; set; } 13 | public long Pop1950 { get; set; } 14 | public long Pop1955 { get; set; } 15 | public long Pop1960 { get; set; } 16 | public long Pop1965 { get; set; } 17 | public long Pop1970 { get; set; } 18 | public long Pop1975 { get; set; } 19 | public long Pop1980 { get; set; } 20 | public long Pop1985 { get; set; } 21 | public long Pop1990 { get; set; } 22 | public long Pop1995 { get; set; } 23 | public long Pop2000 { get; set; } 24 | public long Pop2005 { get; set; } 25 | public long Pop2010 { get; set; } 26 | public long Pop2015 { get; set; } 27 | public long Pop2020 { get; set; } 28 | public long Pop2025 { get; set; } 29 | public long Pop2050 { get; set; } 30 | 31 | [NotMapped] 32 | public double[] Location 33 | { 34 | get 35 | { 36 | return new double[] { Latitude, Longitude }; 37 | } 38 | 39 | private set { } 40 | } 41 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SamplesEntities/Weather.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace signalr_for_aspnet_core.Models; 4 | 5 | public partial class Weather 6 | { 7 | public int ID { get; set; } 8 | public string Station { get; set; } 9 | public DateTime Date { get; set; } 10 | public decimal TMax { get; set; } 11 | public decimal TMin { get; set; } 12 | public decimal Wind { get; set; } 13 | public decimal? Gust { get; set; } 14 | public decimal Rain { get; set; } 15 | public decimal? Snow { get; set; } 16 | public string Events { get; set; } 17 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Models/SchedulerEvent.cs: -------------------------------------------------------------------------------- 1 | 2 | using System; 3 | 4 | namespace signalr_for_aspnet_core.Models; 5 | 6 | public abstract class SchedulerEvent 7 | { 8 | public string Title { get; set; } 9 | public string Description { get; set; } 10 | 11 | public string StartTimezone { get; set; } 12 | 13 | private DateTime start; 14 | public DateTime Start 15 | { 16 | get 17 | { 18 | return start; 19 | } 20 | set 21 | { 22 | start = value.ToUniversalTime(); 23 | } 24 | } 25 | 26 | 27 | private DateTime end; 28 | public DateTime End 29 | { 30 | get 31 | { 32 | return end; 33 | } 34 | set 35 | { 36 | end = value.ToUniversalTime(); 37 | } 38 | } 39 | 40 | 41 | public string EndTimezone { get; set; } 42 | public string RecurrenceRule { get; set; } 43 | public int? RecurrenceID { get; set; } 44 | public string RecurrenceException { get; set; } 45 | public bool IsAllDay { get; set; } 46 | } 47 | -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Program.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore.Builder; 2 | using Microsoft.EntityFrameworkCore; 3 | using Microsoft.Extensions.DependencyInjection; 4 | using signalr_for_aspnet_core.Hubs; 5 | using signalr_for_aspnet_core.Models; 6 | 7 | var builder = WebApplication.CreateBuilder(args); 8 | 9 | builder.Services.AddCors(corsOption => corsOption.AddPolicy("CorsPolicy", corsBuilder => 10 | corsBuilder 11 | .AllowAnyOrigin() 12 | .AllowAnyMethod() 13 | .AllowAnyHeader() 14 | )); 15 | 16 | builder.Services.AddDbContext(options => options.UseSqlite()); 17 | 18 | builder.Services.AddSignalR().AddJsonProtocol(options => { 19 | options.PayloadSerializerOptions.PropertyNamingPolicy = null; 20 | }); 21 | 22 | builder.Services.AddHealthChecks(); 23 | 24 | var app = builder.Build(); 25 | 26 | app.UseHttpsRedirection(); 27 | app.UseCors("CorsPolicy"); 28 | app.UseRouting(); 29 | app.MapHealthChecks("/health"); 30 | app.MapHub("/products"); 31 | app.MapHub("/meetings"); 32 | 33 | app.Run(); -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "iisSettings": { 3 | "windowsAuthentication": false, 4 | "anonymousAuthentication": true, 5 | "iisExpress": { 6 | "applicationUrl": "http://localhost:55085", 7 | "sslPort": 44301 8 | } 9 | }, 10 | "profiles": { 11 | "IIS Express": { 12 | "commandName": "IISExpress", 13 | "launchBrowser": true, 14 | "environmentVariables": { 15 | "ASPNETCORE_ENVIRONMENT": "Development" 16 | } 17 | }, 18 | "signalr_for_aspnet_core": { 19 | "commandName": "Project", 20 | "launchBrowser": true, 21 | "applicationUrl": "https://localhost:5001;http://localhost:5000", 22 | "environmentVariables": { 23 | "ASPNETCORE_ENVIRONMENT": "Development" 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Debug", 5 | "System": "Information", 6 | "Microsoft": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "Debug", 6 | "System": "Information", 7 | "Microsoft": "Information" 8 | } 9 | }, 10 | "AllowedHosts": "*" 11 | } 12 | -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/signalr-for-aspnet-core.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | net8.0 4 | InProcess 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /signalr-hubs/signalr-for-aspnet-core/wwwroot/App_Data/sample.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telerik/kendo-ui-demos-service/c3d2ff2f98467d7c750176399d1dbe7c196652b8/signalr-hubs/signalr-for-aspnet-core/wwwroot/App_Data/sample.db --------------------------------------------------------------------------------