Browse Source

Merge branch 'abpframework:dev' into features/marked-item-feature

pull/20056/head
Suhaib 2 years ago
committed by GitHub
parent
commit
6f95fc8122
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 2
      Directory.Packages.props
  2. 101
      README.md
  3. 2
      abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/en-GB.json
  4. 20
      abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/en.json
  5. 506
      docs/cs/AspNetCore/Widgets.md
  6. 84
      docs/cs/Autofac-Integration.md
  7. BIN
      docs/cs/Best-Practices/images/postgresql-delete-initial-migrations.png
  8. BIN
      docs/cs/Best-Practices/images/postgresql-update-database.png
  9. 167
      docs/cs/CLI.md
  10. 64
      docs/cs/Contribution/Index.md
  11. 61
      docs/cs/Dapper.md
  12. 33
      docs/cs/Domain-Driven-Design.md
  13. 39
      docs/cs/Entity-Framework-Core-PostgreSQL.md
  14. 126
      docs/cs/Getting-Started-Angular-Template.md
  15. 157
      docs/cs/Getting-Started-AspNetCore-Application.md
  16. 104
      docs/cs/Getting-Started-AspNetCore-MVC-Template.md
  17. 181
      docs/cs/Getting-Started-Console-Application.md
  18. 25
      docs/cs/Index.md
  19. 26
      docs/cs/Nightly-Builds.md
  20. 376
      docs/cs/docs-nav.json
  21. BIN
      docs/cs/images/MonthlyProfitWidgetFiles.png
  22. BIN
      docs/cs/images/authorization-new-permission-ui-hierarcy.png
  23. BIN
      docs/cs/images/authorization-new-permission-ui-localized.png
  24. BIN
      docs/cs/images/authorization-new-permission-ui.png
  25. BIN
      docs/cs/images/bookstore-apis.png
  26. BIN
      docs/cs/images/bookstore-create-template.png
  27. BIN
      docs/cs/images/bookstore-homepage.png
  28. BIN
      docs/cs/images/bookstore-swagger-ui-host.png
  29. BIN
      docs/cs/images/bookstore-user-management-v2.png
  30. BIN
      docs/cs/images/bookstore-visual-studio-solution-for-spa.png
  31. BIN
      docs/cs/images/bookstore-visual-studio-solution-tiered.png
  32. BIN
      docs/cs/images/bookstore-visual-studio-solution-v3.png
  33. BIN
      docs/cs/images/build-action-embedded-resource-sample.png
  34. BIN
      docs/cs/images/create-aspnet-core-application.png
  35. BIN
      docs/cs/images/create-new-aspnet-core-application-v2.png
  36. BIN
      docs/cs/images/create-new-aspnet-core-application.png
  37. BIN
      docs/cs/images/create-new-net-core-console-application.png
  38. BIN
      docs/cs/images/dashboard1.png
  39. BIN
      docs/cs/images/db-migrator-app.png
  40. BIN
      docs/cs/images/docs-create-project.jpg
  41. BIN
      docs/cs/images/docs-module_download-new-abp-project.png
  42. BIN
      docs/cs/images/docs-module_download-sample-navigation-menu.png
  43. BIN
      docs/cs/images/docs-module_solution-explorer.png
  44. BIN
      docs/cs/images/docs-section-ui.png
  45. BIN
      docs/cs/images/github-access-token-private-repo.jpg
  46. BIN
      docs/cs/images/github-access-token-public-repo.jpg
  47. BIN
      docs/cs/images/github-myusername.jpg
  48. BIN
      docs/cs/images/issuemanagement-module-solution.png
  49. BIN
      docs/cs/images/layered-project-dependencies-module.png
  50. BIN
      docs/cs/images/layered-project-dependencies.png
  51. BIN
      docs/cs/images/localization-resource-json-files.png
  52. BIN
      docs/cs/images/microservice-sample-authserver-home.png
  53. BIN
      docs/cs/images/microservice-sample-authserver-login.png
  54. BIN
      docs/cs/images/microservice-sample-backend-ui-permissions.png
  55. BIN
      docs/cs/images/microservice-sample-backend-ui.png
  56. BIN
      docs/cs/images/microservice-sample-blogservice-permission-in-database.png
  57. BIN
      docs/cs/images/microservice-sample-diagram-2.png
  58. BIN
      docs/cs/images/microservice-sample-diagram.png
  59. BIN
      docs/cs/images/microservice-sample-kibana-1.png
  60. BIN
      docs/cs/images/microservice-sample-kibana-2.png
  61. BIN
      docs/cs/images/microservice-sample-product-module-in-solution.png
  62. BIN
      docs/cs/images/microservice-sample-public-product-list.png
  63. BIN
      docs/cs/images/microservice-sample-solution.png
  64. BIN
      docs/cs/images/microservice-sample-update-database-authserver.png
  65. BIN
      docs/cs/images/microservice-sample-update-database-products.png
  66. BIN
      docs/cs/images/module-layers-and-packages.jpg
  67. BIN
      docs/cs/images/night-build-add-nuget-package.png
  68. BIN
      docs/cs/images/night-build-add-nuget-source.png
  69. BIN
      docs/cs/images/pcm-update-database-v2.png
  70. BIN
      docs/cs/images/pcm-update-database.png
  71. BIN
      docs/cs/images/select-empty-web-application-v2.png
  72. BIN
      docs/cs/images/select-empty-web-application.png
  73. BIN
      docs/cs/images/set-as-startup-project.png
  74. BIN
      docs/cs/images/tiered-solution-applications.png
  75. BIN
      docs/cs/images/tiered-solution-servers.png
  76. BIN
      docs/cs/images/volodocs-iis-add-website.png
  77. BIN
      docs/cs/images/volodocs-iis-application-pool.png
  78. BIN
      docs/cs/images/widget-basic-files.png
  79. 10
      docs/docs-langs.json
  80. 67
      docs/en/Blog-Posts/2024-06-27 v8_2_Release_Stable/POST.md
  81. BIN
      docs/en/Blog-Posts/2024-06-27 v8_2_Release_Stable/cover-image.png
  82. 2
      docs/en/CLI.md
  83. 302
      docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/How to use Aspire with ABP framework.md
  84. BIN
      docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-dashboard.png
  85. BIN
      docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-metrics.png
  86. BIN
      docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-structured-logs.png
  87. BIN
      docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-traces.png
  88. 130
      docs/en/Community-Articles/2024-07-01-Use_User-Defined_Function_Mapping_For_Global_Filter/POST.md
  89. 17
      docs/en/Contribution/Index.md
  90. 83
      docs/en/Data-Filtering.md
  91. 10
      docs/en/Modules/Docs.md
  92. 16
      docs/en/Road-Map.md
  93. 4
      docs/en/UI/AspNetCore/Static-JavaScript-Proxies.md
  94. 4
      docs/en/UI/Blazor/Pwa-Configuration.md
  95. BIN
      docs/en/images/book-mastering-abp-framework.png
  96. BIN
      docs/en/images/cmskit-module-comments-settings.png
  97. BIN
      docs/en/images/db-options.png
  98. BIN
      docs/en/images/ddd-microservice-simple.png
  99. BIN
      docs/en/images/ui-options.png
  100. 140
      docs/es/Getting-Started-AspNetCore-Application.md

2
Directory.Packages.props

@ -49,7 +49,7 @@
<PackageVersion Include="LibGit2Sharp" Version="0.28.0" />
<PackageVersion Include="Magick.NET-Q16-AnyCPU" Version="13.4.0" />
<PackageVersion Include="MailKit" Version="4.3.0" />
<PackageVersion Include="Markdig.Signed" Version="0.33.0" />
<PackageVersion Include="Markdig.Signed" Version="0.37.0" />
<PackageVersion Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="8.0.4" />
<PackageVersion Include="Microsoft.AspNetCore.Authentication.OpenIdConnect" Version="8.0.4" />
<PackageVersion Include="Microsoft.AspNetCore.Authorization" Version="8.0.4" />

101
README.md

@ -1,22 +1,18 @@
# ABP Framework
![build and test](https://img.shields.io/github/actions/workflow/status/abpframework/abp/build-and-test.yml?branch=dev&style=flat-square)
[![codecov](https://codecov.io/gh/abpframework/abp/branch/dev/graph/badge.svg?token=jUKLCxa6HF)](https://codecov.io/gh/abpframework/abp)
[![NuGet](https://img.shields.io/nuget/v/Volo.Abp.Core.svg?style=flat-square)](https://www.nuget.org/packages/Volo.Abp.Core)
[![NuGet (with prereleases)](https://img.shields.io/nuget/vpre/Volo.Abp.Core.svg?style=flat-square)](https://www.nuget.org/packages/Volo.Abp.Core)
[![MyGet (nightly builds)](https://img.shields.io/myget/abp-nightly/vpre/Volo.Abp.svg?style=flat-square)](https://docs.abp.io/en/abp/latest/Nightly-Builds)
[![NuGet Download](https://img.shields.io/nuget/dt/Volo.Abp.Core.svg?style=flat-square)](https://www.nuget.org/packages/Volo.Abp.Core)
[![Code of Conduct](https://img.shields.io/badge/Contributor%20Covenant-v2.0%20adopted-ff69b4.svg)](https://github.com/abpframework/abp/blob/dev/CODE_OF_CONDUCT.md)
[![CLA Signed](https://cla-assistant.io/readme/badge/abpframework/abp)](https://cla-assistant.io/abpframework/abp)
[![ABP Discord server](https://img.shields.io/discord/951497912645476422?label=Discord)](https://discord.gg/abp)
ABP Framework is a complete **infrastructure** based on **ASP.NET Core** to create **modern web applications** and **APIs** by following the software development **best practices** and the **latest technologies**. Check out https://abp.io
![build and test](https://img.shields.io/github/actions/workflow/status/abpframework/abp/build-and-test.yml?branch=dev&style=flat-square) 🔹 [![codecov](https://codecov.io/gh/abpframework/abp/branch/dev/graph/badge.svg?token=jUKLCxa6HF)](https://codecov.io/gh/abpframework/abp) 🔹 [![NuGet](https://img.shields.io/nuget/v/Volo.Abp.Core.svg?style=flat-square)](https://www.nuget.org/packages/Volo.Abp.Core) 🔹 [![NuGet (with prereleases)](https://img.shields.io/nuget/vpre/Volo.Abp.Core.svg?style=flat-square)](https://www.nuget.org/packages/Volo.Abp.Core) 🔹 [![MyGet (nightly builds)](https://img.shields.io/myget/abp-nightly/vpre/Volo.Abp.svg?style=flat-square)](https://docs.abp.io/en/abp/latest/Nightly-Builds) 🔹
[![NuGet Download](https://img.shields.io/nuget/dt/Volo.Abp.Core.svg?style=flat-square)](https://www.nuget.org/packages/Volo.Abp.Core) 🔹 [![Code of Conduct](https://img.shields.io/badge/Contributor%20Covenant-v2.0%20adopted-ff69b4.svg)](https://github.com/abpframework/abp/blob/dev/CODE_OF_CONDUCT.md) 🔹 [![CLA Signed](https://cla-assistant.io/readme/badge/abpframework/abp)](https://cla-assistant.io/abpframework/abp) 🔹 [![Discord Shield](https://discord.com/api/guilds/951497912645476422/widget.png?style=shield)](https://discord.gg/abp)
ABP Framework is a complete **infrastructure** based on **ASP.NET Core** that creates **modern web applications** and **APIs** by following the software development **best practices** and the **latest technologies**.
[![ABP Platform](https://github.com/abpframework/abp/assets/9526587/47531496-4088-406d-9c69-63cb0ffec2ba)](https://abp.io)
## Getting Started
- [Quick Start](https://docs.abp.io/en/abp/latest/Tutorials/Todo/Index) is a single-part, quick-start tutorial to build a simple application with the ABP Framework. Start with this tutorial if you want to quickly understand how ABP works.
- [Getting Started guide](https://docs.abp.io/en/abp/latest/Getting-Started) can be used to create and run ABP based solutions with different options and details.
- [Web Application Development Tutorial](https://docs.abp.io/en/abp/latest/Tutorials/Part-1) is a complete tutorial to develop a full stack web application with all aspects of a real-life solution.
- [Quick Start](https://docs.abp.io/en/abp/latest/Tutorials/Todo/Index) is a single-part, quick-start tutorial to build a simple application with the ABP Framework. Start with this tutorial if you want to understand how ABP works quickly.
- [Getting Started guide](https://docs.abp.io/en/abp/latest/Getting-Started) can be used to create and run ABP-based solutions with different options and details.
- [Web Application Development Tutorial](https://docs.abp.io/en/abp/latest/Tutorials/Part-1) is a complete tutorial on developing a full-stack web application with all aspects of a real-life solution.
### Quick Start
@ -34,28 +30,26 @@ Create a new solution:
> See the [CLI documentation](https://docs.abp.io/en/abp/latest/CLI) for all available options.
### UI Framework Options
<img width="500" src="docs/en/images/ui-options.png">
### Database Provider Options
<img width="500" src="docs/en/images/db-options.png">
## The Book: Mastering ABP Framework
Written by the creator of ABP Framework, this book will help you to gain a complete understanding of the ABP Framework and modern web application development techniques.
* [Buy on Amazon](https://www.amazon.com/gp/product/B097Z2DM8Q)
* [Buy on Packt Publishing](https://www.packtpub.com/product/mastering-abp-framework/9781801079242)
* [More details about the book](https://abp.io/books/mastering-abp-framework)
![book-mastering-abp-framework](docs/en/images/book-mastering-abp-framework.png)
## What ABP Provides?
ABP provides a **full stack developer experience**.
### Architecture
<img src="docs/en/images/ddd-microservice-simple.png">
@ -64,30 +58,48 @@ ABP offers a complete, **modular** and **layered** software architecture based o
ABP Framework is suitable for **[microservice solutions](https://docs.abp.io/en/abp/latest/Microservice-Architecture)** as well as monolithic applications.
### Infrastructure
There are a lot of features provided by the ABP Framework to achieve real world scenarios easier, like [Event Bus](https://docs.abp.io/en/abp/latest/Event-Bus), [Background Job System](https://docs.abp.io/en/abp/latest/Background-Jobs), [Audit Logging](https://docs.abp.io/en/abp/latest/Audit-Logging), [BLOB Storing](https://docs.abp.io/en/abp/latest/Blob-Storing), [Data Seeding](https://docs.abp.io/en/abp/latest/Data-Seeding), [Data Filtering](https://docs.abp.io/en/abp/latest/Data-Filtering), etc.
There are a lot of features provided by the ABP Framework to achieve real-world scenarios easier, like [Event Bus](https://docs.abp.io/en/abp/latest/Event-Bus), [Background Job System](https://docs.abp.io/en/abp/latest/Background-Jobs), [Audit Logging](https://docs.abp.io/en/abp/latest/Audit-Logging), [BLOB Storing](https://docs.abp.io/en/abp/latest/Blob-Storing), [Data Seeding](https://docs.abp.io/en/abp/latest/Data-Seeding), [Data Filtering](https://docs.abp.io/en/abp/latest/Data-Filtering), etc.
### Cross-Cutting Concerns
ABP also simplifies (and even automates wherever possible) cross-cutting concerns and common non-functional requirements like [Exception Handling](https://docs.abp.io/en/abp/latest/Exception-Handling), [Validation](https://docs.abp.io/en/abp/latest/Validation), [Authorization](https://docs.abp.io/en/abp/latest/Authorization), [Localization](https://docs.abp.io/en/abp/latest/Localization), [Caching](https://docs.abp.io/en/abp/latest/Caching), [Dependency Injection](https://docs.abp.io/en/abp/latest/Dependency-Injection), [Setting Management](https://docs.abp.io/en/abp/latest/Settings), etc.
### Cross Cutting Concerns
ABP also simplifies (and even automates wherever possible) cross cutting concerns and common non-functional requirements like [Exception Handling](https://docs.abp.io/en/abp/latest/Exception-Handling), [Validation](https://docs.abp.io/en/abp/latest/Validation), [Authorization](https://docs.abp.io/en/abp/latest/Authorization), [Localization](https://docs.abp.io/en/abp/latest/Localization), [Caching](https://docs.abp.io/en/abp/latest/Caching), [Dependency Injection](https://docs.abp.io/en/abp/latest/Dependency-Injection), [Setting Management](https://docs.abp.io/en/abp/latest/Settings), etc.
### Application Modules
ABP is a modular framework and the Application Modules provide **pre-built application functionalities**;
- [**Account**](https://docs.abp.io/en/abp/latest/Modules/Account): Provides UI for the account management and allows user to login/register to the application.
- **[Identity](https://docs.abp.io/en/abp/latest/Modules/Identity)**: Manages organization units, roles, users and their permissions, based on the Microsoft Identity library.
- **[Identity](https://docs.abp.io/en/abp/latest/Modules/Identity)**: Manages organization units, roles, users and their permissions based on the Microsoft Identity library.
- [**OpenIddict**](https://docs.abp.io/en/abp/latest/Modules/OpenIddict): Integrates to OpenIddict.
- [**Tenant Management**](https://docs.abp.io/en/abp/latest/Modules/Tenant-Management): Manages tenants for a [multi-tenant](https://docs.abp.io/en/abp/latest/Multi-Tenancy) (SaaS) application.
See the [Application Modules](https://docs.abp.io/en/abp/latest/Modules/Index) document for all pre-built modules.
### Startup Templates
The [Startup templates](https://docs.abp.io/en/abp/latest/Startup-Templates/Index) are pre-built Visual Studio solution templates. You can create your own solution based on these templates to **immediately start your development**.
## ABP Community
## Mastering ABP Framework Book
This book will help you to gain a complete understanding of the ABP Framework and modern web application development techniques. It is written by the creator and team lead of the ABP Framework. You can buy from [Amazon](https://www.amazon.com/gp/product/B097Z2DM8Q) or [Packt Publishing](https://www.packtpub.com/product/mastering-abp-framework/9781801079242). Find further info about the book at [abp.io/books/mastering-abp-framework](https://abp.io/books/mastering-abp-framework).
![book-mastering-abp-framework](docs/en/images/book-mastering-abp-framework.png)
## The Community
### ABP Community Web Site
@ -103,28 +115,31 @@ See the [sample projects](https://docs.abp.io/en/abp/latest/Samples/Index) built
### Want to Contribute?
ABP is a community-driven open source project. See [the contribution guide](https://docs.abp.io/en/abp/latest/Contribution/Index) if you want to be a part of this project.
ABP is a community-driven open-source project. See [the contribution guide](https://docs.abp.io/en/abp/latest/Contribution/Index) if you want to participate in this project.
## Official Links
* <a href="https://abp.io/" target="_blank">Main Web Site</a>
* <a href="https://abp.io/get-started" target="_blank">Get Started</a>
* <a href="https://abp.io/features" target="_blank">Features</a>
* <a href="https://docs.abp.io/" target="_blank">Documentation</a>
* <a href="https://docs.abp.io/en/abp/latest/Samples/Index" target="_blank">Samples</a>
* <a href="https://blog.abp.io/" target="_blank">Blog</a>
* <a href="https://community.abp.io/" target="_blank">Community</a>
* <a href="https://stackoverflow.com/questions/tagged/abp" target="_blank">Stack overflow</a>
* <a href="https://twitter.com/abpframework" target="_blank">Twitter</a>
* [Home Website](https://abp.io)
* [Get Started](https://abp.io/get-started)
* [Features](https://abp.io/features)
* [Documents](https://docs.abp.io/)
* [Samples](https://docs.abp.io/en/abp/latest/Samples/Index)
* [Blog](https://blog.abp.io/)
* [Community](https://community.abp.io/)
* [Stackoverflow](https://stackoverflow.com/questions/tagged/abp)
* [Twitter](https://twitter.com/abpframework)
## Support ABP
## Support the ABP Framework
GitHub repository stars are an important indicator of popularity and the size of the community. If you like ABP Framework, support us by clicking the star :star: on the repository.
Love ABP Framework? **Please give a star** to this repository :star:
## Discord Channel
You can use this link to join the ABP Community Discord Server: https://discord.gg/abp
## Discord Server
## ABP Commercial
We have a Discord server where you can chat with other ABP users. Share your ideas, report technical issues, showcase your creations, share the tips that worked for you and catch up with the latest news and announcements about ABP Framework. Join 👉 https://discord.gg/abp.
See also [ABP Commercial](https://commercial.abp.io/) if you are looking for pre-built application modules, professional themes, code generation tooling and premium support for the ABP Framework.

2
abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/en-GB.json

@ -59,7 +59,7 @@
"MilestoneErrorMessage": "Couldn't get the current milestone details from Github.",
"QuestionItemErrorMessage": "Couldn't get the latest question details from Stackoverflow.",
"Oops": "Oops!",
"CreatePostSuccessMessage": "The Post has been successfully submitted. It will be published once it has been reviewed by the site admin.",
"CreatePostSuccessMessage": "Your post has been successfully submitted. It will be published after review by the site administrator.",
"ChooseCoverImage": "Choose a cover image...",
"CoverImage": "Cover Image",
"ShareYourExperiencesWithTheABPFramework": "Share your experiences with the ABP Framework!",

20
abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/en.json

@ -16,7 +16,7 @@
"Title": "Title",
"CreationTime": "Creation time",
"Save": "Save",
"SameUrlAlreadyExist": "Same url already exists if you want to add this post, you should change the url!",
"SameUrlAlreadyExist": "Same URL already exists! You must change the URL!",
"UrlIsNotValid": "Url is not valid.",
"UrlNotFound": "Url not found.",
"UrlContentNotFound": "Url content not found.",
@ -33,7 +33,7 @@
"FeatureRequest": "Feature Request",
"CreatePostTitleInfo": "Title of the post to be shown on the post list.",
"CreatePostSummaryInfo": "A short summary of the post to be shown on the post list. Maximum length: <b>{0}</b>",
"CreatePostCoverInfo": "For creating an effective post, add a cover photo. Upload 16:9 aspect ratio pictures for the best view.<br/> Maximum file size: <b>1MB.</b>",
"CreatePostCoverInfo": "To create an effective post, add a cover photo. Upload <b>16:9 aspect ratio</b> pictures for the best view.<br/> Maximum file size is <b>1MB.</b>",
"ThisExtensionIsNotAllowed": "This extension is not allowed.",
"TheFileIsTooLarge": "The file is too large.",
"GoToThePost": "Go to the Post",
@ -56,7 +56,7 @@
"MilestoneErrorMessage": "Could not get the current milestone details from Github.",
"QuestionItemErrorMessage": "Could not get the latest question details from Stackoverflow.",
"Oops": "Oops!",
"CreatePostSuccessMessage": "The Post has been successfully submitted. It will be published after a review from the site admin.",
"CreatePostSuccessMessage": "Your post has been successfully submitted. It will be published after review by the site administrator.",
"Browse": "Browse",
"CoverImage": "Cover Image",
"ShareYourExperiencesWithTheABPFramework": "Share your experiences with the ABP Framework!",
@ -125,7 +125,7 @@
"YoutubeVideoSubmitStepTwo": "<span class=\"font-weight-bold\">2.</span> Submit the video URL using the form.",
"YoutubeVideoSubmitStepThree": "<span class=\"font-weight-bold\">3.</span> Visitors will be able to watch your video content directly on this website.",
"ExternalContent": "External Content",
"ExternalContentSubmitStepOne": "<span class=\"font-weight-bold\">1.</span> Create a content on any public platform (Medium, your own blog or anywhere you like).",
"ExternalContentSubmitStepOne": "<span class=\"font-weight-bold\">1.</span> Create content on any public platform (Medium, your own blog or anywhere you like).",
"ExternalContentSubmitStepTwo": "<span class=\"font-weight-bold\">2.</span> Submit your content URL using the form.",
"ExternalContentSubmitStepThree": "<span class=\"font-weight-bold\">3.</span> Visitors are redirected to the content on the original website.",
"ChooseYourContentType": "Please choose the way you want to add your content.",
@ -135,12 +135,12 @@
"GitHubUserNameValidationMessage": "Your Github username can not include whitespace, please make sure your Github username is correct.",
"PersonalSiteUrlValidationMessage": "Your personal site URL can not include whitespace, please make sure your personal site URL is correct.",
"TwitterUserNameValidationMessage": "Your Twitter username can not include whitespace, please make sure your Twitter username is correct.",
"LinkedinUrlValidationMessage": "Your Linkedin URL can not include whitespace, please make sure your Linkedin URL is correct.",
"LinkedinUrlValidationMessage": "Your LinkedIn URL can not include whitespace, please make sure your LinkedIn URL is correct.",
"NoPostsFound": "No posts found!",
"SearchInPosts": "Search in posts...",
"MinimumSearchContent": "You must enter at least 3 characters!",
"Volo.AbpIo.Domain:060001": "Source URL(\"{PostUrl}\") is not Github URL",
"Volo.AbpIo.Domain:060002": "Post Content is not available from Github(\"{PostUrl}\") resource.",
"Volo.AbpIo.Domain:060002": "Post Content is not available from GitHub(\"{PostUrl}\") resource.",
"Volo.AbpIo.Domain:060003": "No post content found!",
"SeeMore": "See More",
"JoinTheABPCommunity": "Join the ABP Community",
@ -171,14 +171,14 @@
"Discord_Page_Announce": "We are happy to announce ABP Community Discord Server!",
"Discord_Page_Description_1": "ABP Community has been growing since day one. We wanted to take it to the next step by creating an official ABP Discord server so the ABP Community can interact with each other using the wonders of instant messaging.",
"Discord_Page_Description_2": "ABP Community Discord Server is the place where you can showcase your creations using ABP Framework, share the tips that worked for you, catch up with the latest news and announcements about ABP Framework, just chat with community members to exchange ideas, and have fun!",
"Discord_Page_Description_3": "This ABP Community Discord Server is the official one with the ABP Core Team is present on the server to monitor.",
"Discord_Page_Description_3": "This ABP Community Discord Server is the official one with the ABP Core Team present on the server to monitor.",
"Discord_Page_JoinToServer": "Join ABP Discord Server",
"Events_Page_MetaTitle": "ABP Community Events",
"Events_Page_MetaDescription": "The live shows, hosted by the ABP Team, are casual sessions full of community content, demos, Q&A, and discussions around what's happening in ABP.",
"Events_Page_Title": "ABP<span class=\"gradient-community\"> Community</span> Talks",
"Members_Page_WritingFromUser": "Read writing from {0} on ABP Community.",
"Post_Create_Page_MetaTitle": "New Post",
"Post_Create_Page_MetaDescription": "Create your post for sharing your experiences about ABP framework and contributing the ABP Community.",
"Post_Create_Page_MetaDescription": "Create your post for sharing your experiences about the ABP framework and contributing to the ABP Community.",
"Post_Create_Page_CreateNewPost": "Create New Post",
"Post_Index_Page_MetaDescription": "ABP Community's purpose is to create a contribution environment for developers who use the ABP framework.",
"Layout_Title": "{0} | ABP Community",
@ -193,7 +193,7 @@
"AbpCommunityTitleContent": "ABP Community - Open Source ABP Framework",
"CommunitySlogan": "A unique community platform for <span class=\"{0}\">ABP Lovers</span>",
"RaffleIsNotActive": "Raffle is not active",
"YouAreAlreadyJoinedToThisRaffle": "You already joined to this raffle!",
"YouAreAlreadyJoinedToThisRaffle": "You already joined this raffle!",
"InvalidSubscriptionCode": "Invalid subscription code",
"Raffle:{0}": "Raffle: {0}",
"Join": "Join",
@ -266,4 +266,4 @@
"DailyPostCreateLimitation": "You have reached the daily post creation limit. You can create a new post in {0}.",
"YourAccountDisabled": "Your user account is disabled!"
}
}
}

506
docs/cs/AspNetCore/Widgets.md

@ -1,506 +0,0 @@
# Widgety
ABP poskytuje model a infastrukturu k vytváření **znovu použitelných widgetů**. Systém widgetů je rozšíření pro [ASP.NET Core pohledové komponenty](https://docs.microsoft.com/en-us/aspnet/core/mvc/views/view-components). Widgety jsou zvláště užitečné, když chcete;
* Mít závislosti na **skriptech & stylech** ve vašem widgetu.
* Vytvářet **řídící panely** za použítí widgetů.
* Definovat widgety v znovu použitelných **[modulech](../Module-Development-Basics.md)**.
* Spolupráci widgetů s **[authorizačními](../Authorization.md)** a **[svazovacími](Bundling-Minification.md)** systémy.
## Základní definice widgetu
### Tvorba pohledové komponenty
Jako první krok, vytvořte běžnou ASP.NET Core pohledovou komponentu:
![widget-basic-files](../images/widget-basic-files.png)
**MySimpleWidgetViewComponent.cs**:
````csharp
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
namespace DashboardDemo.Web.Pages.Components.MySimpleWidget
{
public class MySimpleWidgetViewComponent : AbpViewComponent
{
public IViewComponentResult Invoke()
{
return View();
}
}
}
````
Dědění z `AbpViewComponent` není vyžadováno. Můžete dědit ze standardního ASP.NET Core `ViewComponent`. `AbpViewComponent` pouze definuje pár základních a užitečných vlastnosti.
Můžete vložit službu a pomocí metody `Invoke` z ní získat některá data. Možná budete muset provést metodu Invoke jako asynchronní `public async Task<IViewComponentResult> InvokeAsync()`. Podívejte se na dokument [ASP.NET Core ViewComponents](https://docs.microsoft.com/en-us/aspnet/core/mvc/views/view-components) pro všechna další použítí.
**Default.cshtml**:
```xml
<div class="my-simple-widget">
<h2>My Simple Widget</h2>
<p>This is a simple widget!</p>
</div>
```
### Definice widgetu
Přidejte atribut `Widget` k třídě `MySimpleWidgetViewComponent` pro označení této pohledové komponenty jako widgetu:
````csharp
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.Widgets;
namespace DashboardDemo.Web.Pages.Components.MySimpleWidget
{
[Widget]
public class MySimpleWidgetViewComponent : AbpViewComponent
{
public IViewComponentResult Invoke()
{
return View();
}
}
}
````
## Vykreslení widgetu
Vykreslení widgetu je vcelku standardní. Použijte metodu `Component.InvokeAsync` v razor pohledu/stránce jako s kteroukoliv jinou pohledovou komponentou. Příklady:
````xml
@await Component.InvokeAsync("MySimpleWidget")
@await Component.InvokeAsync(typeof(MySimpleWidgetViewComponent))
````
První přístup používá název widgetu, zatímco druhý používá typ pohledové komponenty.
### Widgety s argumenty
Systém ASP.NET Core pohledových komponent umožňuje přijímat argumenty pro pohledové komponenty. Níže uvedená pohledová komponenta přijímá `startDate` a `endDate` a používá tyto argumenty k získání dat ze služby.
````csharp
using System;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.Widgets;
namespace DashboardDemo.Web.Pages.Shared.Components.CountersWidget
{
[Widget]
public class CountersWidgetViewComponent : AbpViewComponent
{
private readonly IDashboardAppService _dashboardAppService;
public CountersWidgetViewComponent(IDashboardAppService dashboardAppService)
{
_dashboardAppService = dashboardAppService;
}
public async Task<IViewComponentResult> InvokeAsync(
DateTime startDate, DateTime endDate)
{
var result = await _dashboardAppService.GetCountersWidgetAsync(
new CountersWidgetInputDto
{
StartDate = startDate,
EndDate = endDate
}
);
return View(result);
}
}
}
````
Nyní musíte předat anonymní objekt k předání argumentů tak jak je ukázáno níže:
````xml
@await Component.InvokeAsync("CountersWidget", new
{
startDate = DateTime.Now.Subtract(TimeSpan.FromDays(7)),
endDate = DateTime.Now
})
````
## Název widgetu
Výchozí název pohledových komponent je vypočítán na základě názvu typu pohledové komponenty. Pokud je typ pohledové komponenty `MySimpleWidgetViewComponent` potom název widgetu bude `MySimpleWidget` (odstraní se `ViewComponent` postfix). Takto ASP.NET Core vypočítává název pohledové komponenty.
Chcete-li přizpůsobit název widgetu, stačí použít standardní atribut `ViewComponent` z ASP.NET Core:
```csharp
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.Widgets;
namespace DashboardDemo.Web.Pages.Components.MySimpleWidget
{
[Widget]
[ViewComponent(Name = "MyCustomNamedWidget")]
public class MySimpleWidgetViewComponent : AbpViewComponent
{
public IViewComponentResult Invoke()
{
return View("~/Pages/Components/MySimpleWidget/Default.cshtml");
}
}
}
```
ABP bude respektovat přizpůsobený název při zpracování widgetu.
> Pokud jsou názvy pohledové komponenty a složky, která pohledovou komponentu obsahuje rozdílné, pravděpodobně budete muset ručně uvést cestu pohledu tak jako je to provedeno v tomto příkladu.
### Zobrazovaný název
Můžete také definovat čitelný & lokalizovatelný zobrazovaný název pro widget. Tento zobrazovaný název může být využít na uživatelském rozhraní kdykoliv je to potřeba. Zobrazovaný název je nepovinný a lze ho definovat pomocí vlastností atributu `Widget`:
````csharp
using DashboardDemo.Localization;
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.Widgets;
namespace DashboardDemo.Web.Pages.Components.MySimpleWidget
{
[Widget(
DisplayName = "MySimpleWidgetDisplayName", // Lokalizační klíč
DisplayNameResource = typeof(DashboardDemoResource) // Lokalizační zdroj
)]
public class MySimpleWidgetViewComponent : AbpViewComponent
{
public IViewComponentResult Invoke()
{
return View();
}
}
}
````
Podívejte se na [dokument lokalizace](../Localization.md) pro více informací o lokalizačních zdrojích a klíčích.
## Závislosti na stylech & skriptech
Problémy když má widget soubory skriptů a stylů;
* Každý stránka, která používá widget musí také přidat soubory **skriptů & stylů** tohoto widgetu.
* Stránka se také musí postarat o **závislé knihovny/soubory** widgetu.
ABP tyto problémy řeší, když správně propojíme zdroje s widgetem. O závislosti widgetu se při jeho používání nestaráme.
### Definování jednoduchých cest souborů
Níže uvedený příklad widgetu přidá stylové a skriptové soubory:
````csharp
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.Widgets;
namespace DashboardDemo.Web.Pages.Components.MySimpleWidget
{
[Widget(
StyleFiles = new[] { "/Pages/Components/MySimpleWidget/Default.css" },
ScriptFiles = new[] { "/Pages/Components/MySimpleWidget/Default.js" }
)]
public class MySimpleWidgetViewComponent : AbpViewComponent
{
public IViewComponentResult Invoke()
{
return View();
}
}
}
````
ABP bere v úvahu tyto závislosti a správně je přidává do pohledu/stránky při použití widgetu. Stylové/skriptové soubory mohou být **fyzické nebo virtuální**. Plně integrováno do [virtuálního systému souborů](../Virtual-File-System.md).
### Definování přispěvatelů balíku
Všechny zdroje použité ve widgetech na stránce jsou přidány jako **svazek** (svázány & minifikovány v produkci pokud nenastavíte jinak). Kromě přidání jednoduchého souboru můžete využít plnou funkčnost přispěvatelů balíčků.
Níže uvedený ukázkový kód provádí totéž co výše uvedený kód, ale definuje a používá přispěvatele balíků:
````csharp
using System.Collections.Generic;
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.Bundling;
using Volo.Abp.AspNetCore.Mvc.UI.Widgets;
namespace DashboardDemo.Web.Pages.Components.MySimpleWidget
{
[Widget(
StyleTypes = new []{ typeof(MySimpleWidgetStyleBundleContributor) },
ScriptTypes = new[]{ typeof(MySimpleWidgetScriptBundleContributor) }
)]
public class MySimpleWidgetViewComponent : AbpViewComponent
{
public IViewComponentResult Invoke()
{
return View();
}
}
public class MySimpleWidgetStyleBundleContributor : BundleContributor
{
public override void ConfigureBundle(BundleConfigurationContext context)
{
context.Files
.AddIfNotContains("/Pages/Components/MySimpleWidget/Default.css");
}
}
public class MySimpleWidgetScriptBundleContributor : BundleContributor
{
public override void ConfigureBundle(BundleConfigurationContext context)
{
context.Files
.AddIfNotContains("/Pages/Components/MySimpleWidget/Default.js");
}
}
}
````
Systém přispěvatelů balíků je velmi schopný. Pokud váš widget používá k vykreslení grafu JavaScript knihovnu, můžete ji deklarovat jako závislost, díky tomu se knihovna pokud nebyla dříve přidána automaticky přidá na stránku Tímto způsobem se stránka využívající váš widget nestará o závislosti.
Podívejte se na dokumentaci [svazování & minifikace](Bundling-Minification.md) pro více informací o tomto systému.
## RefreshUrl
Widget může navrhnout `RefreshUrl`, který se používá vždy, když je potřeba widget aktualizovat. Je-li definován, widget se při každé aktualizaci znovu vykreslí na straně serveru (viz refresh `methoda` u `WidgetManager` níže).
````csharp
[Widget(RefreshUrl = "Widgets/Counters")]
public class CountersWidgetViewComponent : AbpViewComponent
{
}
````
Jakmile pro svůj widget definujete `RefreshUrl`, musíte poskytnout koncový bod pro jeho vykreslení a vrátit ho:
````csharp
[Route("Widgets")]
public class CountersWidgetController : AbpController
{
[HttpGet]
[Route("Counters")]
public IActionResult Counters(DateTime startDate, DateTime endDate)
{
return ViewComponent("CountersWidget", new {startDate, endDate});
}
}
````
Trasa `Widgets/Counters` předchozímu `RefreshUrl`.
> Widget lze obnovit dvěma způsoby: Prvním způsobem je použití `RefreshUrl`, kdy se znovu vykreslí na serveru a nahradí HTML vrácené tím ze serveru. Druhým způsobem widget získá data (obvykle JSON objekt) ze serveru a obnoví se sám u klienta (viz refresh metoda v sekci Widget JavaScript API).
## JavaScript API
Možná bude potřeba vykreslit a obnovit widget na straně klienta. V takových případech můžete použít ABP `WidgetManager` a definovat API pro vaše widgety.
### WidgetManager
`WidgetManager` se používá k inicializaci a aktualizaci jednoho nebo více widgetů. Vytvořte nový `WidgetManager` jako je ukázáno níže:
````js
$(function() {
var myWidgetManager = new abp.WidgetManager('#MyDashboardWidgetsArea');
})
````
`MyDashboardWidgetsArea` může obsahovat jeden nebo více widgetů.
> Použíti `WidgetManager` uvnitř document.ready (jako nahoře) je dobrá praktika jelikož jeho funkce používají DOM a potřebují, aby byl DOM připraven.
#### WidgetManager.init()
`init` jednoduše inicializuje `WidgetManager` a volá metody `init` v souvisejících widgetech pokud je obsahují (podívejte se na sekci Widget JavaScript API section níže)
```js
myWidgetManager.init();
```
#### WidgetManager.refresh()
`refresh` metoda obnoví všechny widgety související s tímto `WidgetManager`:
````
myWidgetManager.refresh();
````
#### WidgetManager možnosti
WidgetManager má několik dalších možností.
##### Filtrační formulář
Pokud vaše widgety vyžadují parametry/filtry pak budete obvykle mít formulář pro filtrování widgetů. V takových případech můžete vytvořit formulář, který obsahuje prvky formuláře a oblast řídicího panelu s nějakými widgety uvnitř. Příklad:
````xml
<form method="get" id="MyDashboardFilterForm">
...prvky formuláře
</form>
<div id="MyDashboardWidgetsArea" data-widget-filter="#MyDashboardFilterForm">
...widgety
</div>
````
`data-widget-filter` atribut propojuje formulář s widgety. Kdykoli je formulář odeslán, všechny widgety jsou automaticky aktualizovány pomocí polí formuláře jako filtru.
Místo atributu `data-widget-filter`, můžete použít parametr `filterForm` v konstruktoru `WidgetManager`. Příklad:
````js
var myWidgetManager = new abp.WidgetManager({
wrapper: '#MyDashboardWidgetsArea',
filterForm: '#MyDashboardFilterForm'
});
````
##### Zpětné volání filtru
Možná budete chtít mít lepší kontrolu nad poskytováním filtrů při inicializaci a aktualizaci widgetů. V tomto případě můžete použít volbu `filterCallback`:
````js
var myWidgetManager = new abp.WidgetManager({
wrapper: '#MyDashboardWidgetsArea',
filterCallback: function() {
return $('#MyDashboardFilterForm').serializeFormToObject();
}
});
````
Tento příklad ukazuje výchozí implementaci `filterCallback`. Pomocí polí můžete vrátit jakýkoli JavaScript objekt. Příklad:
````js
filterCallback: function() {
return {
'startDate': $('#StartDateInput').val(),
'endDate': $('#EndDateInput').val()
};
}
````
Vrácené filtry jsou předávány všem widgetům na `init` a` refresh`.
### Widget JavaScript API
Widget může definovat rozhraní API jazyka JavaScript, které je v případě potřeby vyvoláno přes `WidgetManager`. Ukázku kódu níže lze použít k definování API pro widget.
````js
(function () {
abp.widgets.NewUserStatisticWidget = function ($wrapper) {
var getFilters = function () {
return {
...
};
}
var refresh = function (filters) {
...
};
var init = function (filters) {
...
};
return {
getFilters: getFilters,
init: init,
refresh: refresh
};
};
})();
````
`NewUserStatisticWidget` je tady název widgetu. Měl by odpovídat názvu widgetu definovanému na straně serveru. Všechny funkce jsou volitelné.
#### getFilters
Pokud má widget vlastní interní filtry, měla by tato funkce vrátit objekt filtru. Příklad:
````js
var getFilters = function() {
return {
frequency: $wrapper.find('.frequency-filter option:selected').val()
};
}
````
Tuto metodu používá `WidgetManager` při vytváření filtrů.
#### init
Slouží k inicializaci widgetu kdykoli je potřeba. Má argument filtru, který lze použít při získávání dat ze serveru. Metoda `init` je použita když je volána funkce `WidgetManager.init()`. Použita je i v případě že váš widget vyžaduje úplné obnovení při aktualizaci. Viz `RefreshUrl` v možnostech widgetu.
#### refresh
Slouží k aktualizaci widgetu kdykoli je potřeba. Má argument filtru, který lze použít při získávání dat ze serveru. Metoda `refresh` se používá kdykoliv je volána funkce `WidgetManager.refresh()`.
## Autorizace
Některé widgety budou pravděpodobně muset být dostupné pouze pro ověřené nebo autorizované uživatele. V tomto případě použijte následující vlastnosti atributu `Widget`:
* `RequiresAuthentication` (`bool`): Nastavte na true, aby byl tento widget použitelný pouze pro ověřené uživatele (uživatel je přihlášen do aplikace).
* `RequiredPolicies` (`List<string>`): Seznam názvů zásad k autorizaci uživatele. Další informace o zásadách naleznete v [dokumentu autorizace](../Authorization.md).
Příklad:
````csharp
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.Widgets;
namespace DashboardDemo.Web.Pages.Components.MySimpleWidget
{
[Widget(RequiredPolicies = new[] { "MyPolicyName" })]
public class MySimpleWidgetViewComponent : AbpViewComponent
{
public IViewComponentResult Invoke()
{
return View();
}
}
}
````
## WidgetOptions
Jako alternativu k atributu `Widget` můžete ke konfiguraci widgetů použít `AbpWidgetOptions`:
```csharp
Configure<AbpWidgetOptions>(options =>
{
options.Widgets.Add<MySimpleWidgetViewComponent>();
});
```
Toto vepište do metody `ConfigureServices` vašeho [modulu](../Module-Development-Basics.md). Veškerá konfigurace udělaná přes atribut `Widget` je dostupná i za pomoci `AbpWidgetOptions`. Příklad konfigurace, která přidává styl pro widget:
````csharp
Configure<AbpWidgetOptions>(options =>
{
options.Widgets
.Add<MySimpleWidgetViewComponent>()
.WithStyles("/Pages/Components/MySimpleWidget/Default.css");
});
````
> Tip: `AbpWidgetOptions` lze také použít k získání existujícího widgetu a ke změně jeho konfigurace. To je obzvláště užitečné, pokud chcete změnit konfiguraci widgetu uvnitř modulu používaného vaší aplikací. Použíjte `options.Widgets.Find` k získání existujícího `WidgetDefinition`.
## Podívejte se také na
* [Příklad projektu (zdrojový kód)](https://github.com/abpframework/abp-samples/tree/master/DashboardDemo).

84
docs/cs/Autofac-Integration.md

@ -1,84 +0,0 @@
# Autofac integrace
Autofac je jedním z nejpoužívanějších frameworků pro .Net pro vkládání závislostí (DI). Poskytuje pokročilejší funkce v porovnáním se standardní .Net Core DI knihovnou, jako dynamickou proxy a injekci vlastností.
## Instalace Autofac integrace
> Všechny startovací šablony a vzorky jsou s Autofac již integrovány. Takže většinou nemusíte tento balíček instalovat ručně.
Nainstalujte do vašeho projektu balíček [Volo.Abp.Autofac](https://www.nuget.org/packages/Volo.Abp.Autofac) (pro víceprojektovou aplikaci se doporučuje přidat do spustitelného/webového projektu.)
````
Install-Package Volo.Abp.Autofac
````
Poté přídejte k vašemu modulu závislost na `AbpAutofacModule`:
```csharp
using Volo.Abp.Modularity;
using Volo.Abp.Autofac;
namespace MyCompany.MyProject
{
[DependsOn(typeof(AbpAutofacModule))]
public class MyModule : AbpModule
{
//...
}
}
```
Nakonec nastavte `AbpApplicationCreationOptions` aby nahradil výchozí služby pro vkládání závislostí na Autofac. Záleží na typu aplikace.
### ASP.NET Core aplikace
Volejte `UseAutofac()` v souboru **Startup.cs** jako je ukázáno níže:
````csharp
public class Startup
{
public IServiceProvider ConfigureServices(IServiceCollection services)
{
services.AddApplication<MyWebModule>(options =>
{
//Integrace Autofac!
options.UseAutofac();
});
return services.BuildServiceProviderFromFactory();
}
public void Configure(IApplicationBuilder app)
{
app.InitializeApplication();
}
}
````
### Konzolová aplikace
Volejte metodu `UseAutofac()` v možnostech `AbpApplicationFactory.Create` jako je ukázáno níže:
````csharp
using System;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp;
namespace AbpConsoleDemo
{
class Program
{
static void Main(string[] args)
{
using (var application = AbpApplicationFactory.Create<AppModule>(options =>
{
options.UseAutofac(); //Autofac integrace
}))
{
//...
}
}
}
}
````

BIN
docs/cs/Best-Practices/images/postgresql-delete-initial-migrations.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.0 KiB

BIN
docs/cs/Best-Practices/images/postgresql-update-database.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.6 KiB

167
docs/cs/CLI.md

@ -1,167 +0,0 @@
# ABP CLI
ABP CLI (Command Line Interface) je nástroj v příkazovém řádku k provádění některých běžných úkonů v řešeních založených na ABP.
## Instalace
ABP CLI je [dotnet global tool](https://docs.microsoft.com/en-us/dotnet/core/tools/global-tools). Nainstalujete jej pomocí okna příkazového řádku:
````bash
dotnet tool install -g Volo.Abp.Cli
````
Aktualizace stávající instalace:
````bash
dotnet tool update -g Volo.Abp.Cli
````
## Příkazy
### new
Vygeneruje nové řešení založené na ABP [startovací šabloně](Startup-Templates/Index.md).
Základní použití:
````bash
abp new <název-řešení> [možnosti]
````
Příklad:
````bash
abp new Acme.BookStore
````
* `Acme.BookStore` je tady název řešení.
* Běžná konvence je nazvat řešení stylem *VaseSpolecnost.VasProjekt*. Nicméně můžete použít i jiné pojmenování jako *VasProjekt* (jednostupňový jmenný prostor) nebo *VaseSpolecnost.VasProjekt.VasModul* (třístupňový jmenný prostor).
#### Možnosti
* `--template` nebo `-t`: Určuje název šablony. Výchozí šablona je `app`, která generuje webovou aplikaci. Dostupné šablony:
* `app` (výchozí): [Aplikační šablona](Startup-Templates/Application.md). Dodatečné možnosti:
* `--ui` nebo `-u`: Určuje UI framework. Výchozí framework je `mvc`. Dostupné frameworky:
* `mvc`: ASP.NET Core MVC. Pro tuto šablonu jsou dostupné dodatečné možnosti:
* `--tiered`: Vytvoří stupňovité řešení, kde jsou vrstvy Web a Http API fyzicky odděleny. Pokud není uvedeno, tak vytvoří vrstvené řešení, které je méně složité a vhodné pro většinu scénářů.
* `angular`: Angular. Pro tuto šablonu jsou dostupné dodatečné možnosti:
* `--separate-auth-server`: Oddělí Auth Server aplikaci od API host aplikace. Pokud není uvedeno, bude na straně serveru jediný koncový bod.
* `none`: Bez UI. Pro tuto šablonu jsou dostupné dodatečné možnosti:
* `--separate-auth-server`: Oddělí Auth Server aplikaci od API host aplikace. Pokud není uvedeno, bude na straně serveru jediný koncový bod.
* `--database-provider` nebo `-d`: Určuje poskytovatele databáze. Výchozí poskytovatel je `ef`. Dostupní poskytovatelé:
* `ef`: Entity Framework Core.
* `mongodb`: MongoDB.
* `module`: [Šablona modulu](Startup-Templates/Module.md). Dodatečné možnosti:
* `--no-ui`: Určuje nezahrnutí uživatelského rozhraní. Umožňuje vytvořit moduly pouze pro služby (a.k.a. mikroslužby - bez uživatelského rozhraní).
* `--output-folder` nebo `-o`: Určuje výstupní složku. Výchozí hodnota je aktuální adresář.
* `--version` nebo `-v`: Určuje verzi ABP & šablony. Může to být [štítek vydání](https://github.com/abpframework/abp/releases) nebo [název větve](https://github.com/abpframework/abp/branches). Pokud není uvedeno, používá nejnovější vydání. Většinou budete chtít použít nejnovější verzi.
### add-package
Přidá ABP balíček do projektu,
* Přidáním souvisejícícho nuget balíčku jako závislost do projektu.
* Přidáním `[DependsOn(...)]` atributu k modulové tříde v projektu (podívejte se na [dokument vývoje modulu](Module-Development-Basics.md)).
> Všimněte si, že přidaný modul může vyžadovat další konfiguraci, která je obecně uvedena v dokumentaci příslušného balíčku.
Základní použití:
````bash
abp add-package <název-balíčku> [možnosti]
````
Příklad:
````
abp add-package Volo.Abp.MongoDB
````
* Tento příklad přidá do projektu balíček Volo.Abp.MongoDB.
#### Možnosti
* `--project` nebo `-p`: Určuje cestu k projektu (.csproj). Pokud není zadáno, CLI se pokusí najít soubor .csproj v aktuálním adresáři.
### add-module
Přidá [více-balíčkový aplikační modul](Modules/Index) k řešení tím, že najde všechny balíčky modulu, vyhledá související projekty v řešení a přidá každý balíček do odpovídajícího projektu v řešení.
> Modul se obecně skládá z několika balíčků (z důvodu vrstvení, různých možností poskytovatele databáze nebo jiných důvodů). Použití příkazu `add-module` dramaticky zjednodušuje přidání modulu do řešení. Každý modul však může vyžadovat další konfiguraci, která je obecně uvedena v dokumentaci příslušného modulu.
Základní použití:
````bash
abp add-module <název-modulu> [možnosti]
````
Příklad:
```bash
abp add-module Volo.Blogging
```
* Tento příklad přidá do projektu modul Volo.Blogging.
#### Možnosti
* `--solution` nebo `-s`: Určuje cestu k řešení (.sln). Pokud není zadáno, CLI se pokusí najít soubor .sln v aktuálním adresáři.
* `--skip-db-migrations`: Pro poskytovatele databáze EF Core automaticky přidá nový kód první migrace (`Add-Migration`) a v případě potřeby aktualizuje databázi (`Update-Database`). Tuto možnost určete k vynechání této operace.
* `-sp` nebo `--startup-project`: Relativní cesta ke složce spouštěcího projektu. Výchozí hodnota je aktuální adresář.
* `--with-source-code`: Místo balíčků NuGet/NPM přidejte zdrojový kód modulu.
### update
Aktualizace všech balíčků souvisejících s ABP může být únavná, protože existuje mnoho balíčků frameworku a modulů. Tento příkaz automaticky aktualizuje na poslední verze všechny související ABP NuGet a NPM balíčky v řešení nebo projektu.
Použití:
````bash
abp update [možnosti]
````
* Pokud spouštíte v adresáři se souborem .sln, aktualizuje všechny balíčky všech projektů v řešení souvisejících s ABP na nejnovější verze.
* Pokud spouštíte v adresáři se souborem .csproj, aktualizuje všechny balíčky v projektu na nejnovější verze.
#### Možnosti
* `--include-previews` nebo `-p`: Zahrne náhledové, beta a rc balíčky při kontrole nových verzí.
* `--npm`: Aktualizuje pouze balíčky NPM.
* `--nuget`: Aktualizuje pouze balíčky NuGet.
### login
Některé funkce CLI vyžadují přihlášení k platformě abp.io. Chcete-li se přihlásit pomocí svého uživatelského jména, napište
```bash
abp login <username>
```
Všimněte si, že nové přihlášení s již aktivní relací ukončí předchozí relaci a vytvoří novou.
### logout
Odhlásí vás odebráním tokenu relace z počítače.
```
abp logout
```
### help
Vypíše základní informace k používání CLI.
Použítí:
````bash
abp help [název-příkazu]
````
Příklady:
````bash
abp help # Zobrazí obecnou nápovědu.
abp help new # Zobrazí nápovědu k příkazu "new".
````

64
docs/cs/Contribution/Index.md

@ -1,64 +0,0 @@
## Průvodce pro přispěvatele
ABP je [open source](https://github.com/abpframework) a komunitně řízený projekt. Tento průvodce má za cíl pomoci každému kdo chce do projektu nějak přispět.
### Příspěvek kódu
Vždy můžete zaslat pull request do Github repositáře.
- Naklonujte [ABP repozitář](https://github.com/abpframework/abp/) z Githubu.
- Učiňte potřebné změny.
- Zašlete pull request.
Než budete dělat nějaké změny, diskutujte o nich prosím na [Github problémy](https://github.com/abpframework/abp/issues). Díky tomu nebude žádný jiný vývojář pracovat na stejném problému a Váš PR má lepší šanci na to být přijat.
#### Opravy chyb a vylepšení
Pokud chcete opravit známou chybu nebo pracovat na plánovaném vylepšení podívejte se na [seznam problémů](https://github.com/abpframework/abp/issues) na Githubu.
#### Požadavky na funkce
Pokud máte nápad na funkci pro framework nebo modul [vytvořte problém](https://github.com/abpframework/abp/issues/new) na Githubu nebo se připojte ke stávající diskuzi. V případě přijetí komunitou ho pak můžete implementovat.
### Překlad dokumentů
Pokud chcete přeložit celou [dokumentaci](https://abp.io/documents/) (včetně této stránky) do Vašeho rodného jazyka, následujte tyto kroky:
* Naklonujte [ABP repozitář](https://github.com/abpframework/abp/) z Githubu.
* K přidání nového jazyka vytvořte novou složku v [docs](https://github.com/abpframework/abp/tree/master/docs). Název složky musí být "en", "es", "fr", "tr" atd. v závislosti na jazyku (navštivte [všechny jazykové kódy](https://msdn.microsoft.com/en-us/library/hh441729.aspx)).
* Pro referenci použijte ["en" složku](https://github.com/abpframework/abp/tree/master/docs/en) a její názvy souborů a strom složek. Při překladu této dokumentace zachovejte prosím tyto názvy stejné.
* Zašlete pull request (PR) po překladu jakéhokoliv dokumentu klidně i po jednom. Nečekejte až budete mít překlad všech dokumentů.
Existuje několik základních dokumentů, které je třeba přeložit než bude jazyk uveřejněn na [stránkách ABP dokumentace](https://docs.abp.io)
* Začínáme dokumenty
* Tutoriály
* CLI
Nový jazyk je publikován jakmile jsou minimálně tyto překlady dokončeny.
### Lokalizace zdrojů
ABP framework má flexibilní [lokalizační systém](../Localization.md). Můžete tak vytvořit lokalizované uživatelské prostředí pro svou vlastní aplikaci.
K tomu mají framework a vestavěné moduly již lokalizované texty. Například [lokalizační texty pro Volo.Abp.UI balík](https://github.com/abpframework/abp/blob/master/framework/src/Volo.Abp.UI/Localization/Resources/AbpUi/en.json).
Můžete vytvořit nový soubor ve [stejné složce](https://github.com/abpframework/abp/tree/master/framework/src/Volo.Abp.UI/Localization/Resources/AbpUi) k přidání překladu.
* Naklonujte [ABP repozitář](https://github.com/abpframework/abp/) z Githubu.
* Vytvořte nový soubor pro cílový jazyk pro lokalizační text v (json) souboru (u souboru en.json).
* Zkopírujte veškerý text ze souboru en.json.
* Přeložte texty.
* Zašlete pull request na Githubu.
K překladu lokalizovaných textů můžete také použít příkaz `abp translate` of [ABP CLI](CLI.md).
ABP je modulářní framework, proto je zde mnoho zdrojů lokalizačních textů, jeden pro každý modul. K najití všech .json souborů, vyhledejte po naklonování repozitáře soubory "en.json". Můžete se taky podívat na [tento seznam](Localization-Text-Files.md) souborů lokalizačních textů.
### Příspevky do blogu a návody
Pokud se rozhodnete pro ABP vytvořit nějaké návody nebo příspěvky do blogu, dejte nám vědět (prostřednictvím [Github problémy](https://github.com/abpframework/abp/issues)), ať můžeme přidat odkaz na Váš návod/příspěvek v oficiální dokumentaci a oznámit na našem [Twitter účtu](https://twitter.com/abpframework).
### Zpráva o chybě
Pokud najdete chybu, [vytvořte prosím problém v Github repozitáři](https://github.com/abpframework/abp/issues/new).

61
docs/cs/Dapper.md

@ -1,61 +0,0 @@
# Dapper integrace
Jelikož myšlenka Dapper je taková, že sql příkaz má přednost, tak hlavně poskytuje metody rozšíření pro `IDbConnection` rozhraní.
Abp nezapouzdřuje přílíš mnoho funkcí pro Dapper. Abp Dapper poskytuje základní třídu `DapperRepository<TDbContext>` založenou na Abp EntityFrameworkCore, který poskytuje vlastnosti `IDbConnection` a `IDbTransaction` vyžadované v Dapper.
Tyto dvě vlastnosti fungují dobře s [jednotkou práce](Unit-Of-Work.md).
## Instalace
Nainstalujte a nakonfigurujte EF Core podle [EF Core integrační dokumentace](Entity-Framework-Core.md).
`Volo.Abp.Dapper` je hlavní NuGet balík pro Dapper integraci. Nainstalujte jej proto do vašeho projektu (pro strukturovanou aplikaci do datové/infrastrukturní vrstvy):
```shell
Install-Package Volo.Abp.Dapper
```
Poté přidejte závislost na `AbpDapperModule` modulu (atribut `DependsOn`) do Vašeho [modulu](Module-Development-Basics.md):
````C#
using Volo.Abp.Dapper;
using Volo.Abp.Modularity;
namespace MyCompany.MyProject
{
[DependsOn(typeof(AbpDapperModule))]
public class MyModule : AbpModule
{
//...
}
}
````
## Implementace Dapper repozitáře
Následující kód implementuje repozitář `Person`, který vyžaduje `DbContext` z EF Core (MyAppDbContext). Můžete vložit `PersonDapperRepository` k volání jeho metod.
`DbConnection` a `DbTransaction` jsou ze základní třídy `DapperRepository`.
```C#
public class PersonDapperRepository : DapperRepository<MyAppDbContext>, ITransientDependency
{
public PersonDapperRepository(IDbContextProvider<MyAppDbContext> dbContextProvider)
: base(dbContextProvider)
{
}
public virtual async Task<List<string>> GetAllPersonNames()
{
return (await DbConnection.QueryAsync<string>("select Name from People", transaction: DbTransaction))
.ToList();
}
public virtual async Task<int> UpdatePersonNames(string name)
{
return await DbConnection.ExecuteAsync("update People set Name = @NewName", new { NewName = name },
DbTransaction);
}
}
```

33
docs/cs/Domain-Driven-Design.md

@ -1,33 +0,0 @@
# Domain Driven Design
## Co je DDD?
ABP framework poskytuje **infrastrukturu**, která zjednodušuje implementaci vývoje založeného na **DDD**. DDD je [definován ve Wikipedii](https://en.wikipedia.org/wiki/Domain-driven_design) takto:
> **Domain-driven design** (**DDD**) je přístup k vývoji softwaru pro komplexní potřeby propojením implementace s vyvíjejícím se modelem. Předpoklad DDD je následující:
>
> - Primární zaměření projektu je na jádře domény a doménové logice;
> - Zakládání komplexních návrhů na modelu domény;
> - Iniciování tvůrčí spolupráce mezi technickými a doménovými odborníky s cílem iterativně zdokonalit koncepční model, který řeší konkrétní problémy v doméně.
### Vrstvy
ABP dodržuje principy a vzorce DDD pro dosažení vrstveného aplikačního modelu, který se skládá ze čtyř základních vrstev:
- **Prezentační vrstva**: Poskytuje uživateli rozhraní. Používá *Aplikační vrstvu* k dosažení uživatelských interakcí.
- **Aplikační vrstva**: Prostředník mezi prezentační a doménovou vrstvou. Instrumentuje business objekty k provádění specifických úloh aplikace. Implementuje případy použití jako logiku aplikace.
- **Doménová vrstva**: Zahrnuje business objekty a jejich business pravidla. Je jádrem aplikace.
- **Vrstva infrastruktury**: Poskytuje obecné technické možnosti, které podporují vyšší vrstvy většinou pomocí knihoven třetích stran.
## Obsah
* **Doménová vrstva**
* [Entity & agregované kořeny](Entities.md)
* Hodnotové objekty
* [Repozitáře](Repositories.md)
* Doménové služby
* Specifikace
* **Aplikační vrstva**
* [Aplikační služby](Application-Services.md)
* [Objekty přenosu dat (DTOs)](Data-Transfer-Objects.md)
* Jednotka práce

39
docs/cs/Entity-Framework-Core-PostgreSQL.md

@ -1,39 +0,0 @@
# Přepnutí na EF Core PostgreSQL providera
Tento dokument vysvětluje, jak přepnout na poskytovatele databáze **PostgreSQL** pro **[spouštěcí šablonu aplikace](Startup-Templates/Application.md)**, která je dodávána s předem nakonfigurovaným SQL poskytovatelem.
## Výměna balíku Volo.Abp.EntityFrameworkCore.SqlServer
Projekt `.EntityFrameworkCore` v řešení závisí na NuGet balíku [Volo.Abp.EntityFrameworkCore.SqlServer](https://www.nuget.org/packages/Volo.Abp.EntityFrameworkCore.SqlServer). Odstraňte tento balík a přidejte stejnou verzi balíku [Volo.Abp.EntityFrameworkCore.PostgreSql](https://www.nuget.org/packages/Volo.Abp.EntityFrameworkCore.PostgreSql).
## Nahrazení závislosti modulu
Najděte třídu ***YourProjectName*EntityFrameworkCoreModule** v projektu `.EntityFrameworkCore`, odstraňte `typeof(AbpEntityFrameworkCoreSqlServerModule)` z atributu `DependsOn`, přidejte `typeof(AbpEntityFrameworkCorePostgreSqlModule)` (také nahraďte `using Volo.Abp.EntityFrameworkCore.SqlServer;` za `using Volo.Abp.EntityFrameworkCore.PostgreSql;`).
## UseNpgsql()
Najděte volání `UseSqlServer()` v *YourProjectName*EntityFrameworkCoreModule.cs uvnitř projektu `.EntityFrameworkCore` a nahraďte za `UseNpgsql()`.
Najděte volání `UseSqlServer()` v *YourProjectName*MigrationsDbContextFactory.cs uvnitř projektu `.EntityFrameworkCore.DbMigrations` a nahraďte za `UseNpgsql()`.
> V závislosti na struktuře řešení můžete najít více volání `UseSqlServer()`, které je třeba změnit.
## Změna connection stringů
PostgreSql connection stringy se od těch pro SQL Server liší. Je proto potřeba zkontrolovat všechny soubory `appsettings.json` v řešení a connection stringy v nich nahradit. Podívejte se na [connectionstrings.com](https://www.connectionstrings.com/postgresql/) pro více detailů o možnostech PostgreSql connection stringů.
Typicky je potřeba změnit `appsettings.json` v projektech `.DbMigrator` a `.Web` projects, ale to záleží na vaší struktuře řešení.
## Regenerace migrací
Startovací šablona používá [Entity Framework Core Code First migrace](https://docs.microsoft.com/en-us/ef/core/managing-schemas/migrations/). EF Core migrace závisí na zvoleném DBMS poskytovateli. Tudíž změna DBMS poskytovatele způsobí selhání migrace.
* Smažte složku Migrations v projektu `.EntityFrameworkCore.DbMigrations` and znovu sestavte řešení.
* Spusťte `Add-Migration "Initial"` v Package Manager Console (je nutné zvolit `.DbMigrator` (nebo `.Web`) projekt jako startovací projekt v Solution Explorer a zvolit projekt `.EntityFrameworkCore.DbMigrations` jako výchozí v Package Manager Console).
Tímto vytvoříte migraci databáze se všemi nakonfigurovanými databázovými objekty (tabulkami).
Spusťte projekt `.DbMigrator` k vytvoření databáze a vložení počátečních dat.
## Spuštění aplikace
Vše je připraveno. Stačí už jen spustit aplikaci a užívat si kódování.

126
docs/cs/Getting-Started-Angular-Template.md

@ -1,126 +0,0 @@
## Začínáme s Angular aplikační šablonou
Tento tutoriál vysvětluje, jak vytvořit novou Angular aplikaci pomocí spouštěcí šablony, jak ji nakonfigurovat a spustit.
### Tvorba nového projektu
Tento tutorial používá k vytvoření nového projektu **ABP CLI**. Podívejte se na stránku [začínáme](https://abp.io/get-started) pro více možností.
Pokud jste tak dosud neučinili, nainstalujte ABP CLI pomocí okna příkazového řádku:
````bash
dotnet tool install -g Volo.Abp.Cli
````
Použíjte příkaz `abp new` v prázdné složce k vytvoření Vašeho projektu:
````bash
abp new Acme.BookStore -u angular
````
> Můžete použít různé úrovně jmenných prostorů; např. BookStore, Acme.BookStore nebo Acme.Retail.BookStore.
`-u angular` volba specifikuje Angular jako UI framework. Výchozí poskytovatel databáze je EF Core. Podívejte se na [CLI dokumentaci](CLI.md) pro všechny dostupné možnosti.
#### Předběžné požadavky
Vytvořené řešení vyžaduje;
* [Visual Studio 2019 (v16.4.0+)](https://visualstudio.microsoft.com/vs/)
* [.NET Core 3.0+](https://www.microsoft.com/net/download/dotnet-core/)
* [Node v12+](https://nodejs.org)
* [Yarn v1.19+](https://classic.yarnpkg.com/)
### Struktura řešení
Otevřete řešení ve **Visual Studio**:
![bookstore-visual-studio-solution](images/bookstore-visual-studio-solution-for-spa.png)
Řešení má vrstvenou strukturu (založenou na [domain driven designu](Domain-Driven-Design.md)) a obsahuje projekty testů jednotek a integrace správně nakonfigurované pro práci s **EF Core** & **SQLite in-memory** databází.
> Podívejte se na [dokument šablony aplikace](Startup-Templates/Application.md) k detailnímu pochopení struktury řešení.
### Databázový connection string
Zkontrolujte **connection string** v souboru `appsettings.json` u projektu `.HttpApi.Host`:
````json
{
"ConnectionStrings": {
"Default": "Server=localhost;Database=BookStore;Trusted_Connection=True"
}
}
````
Řešení je nakonfigurováno pro použití **Entity Framework Core** s **MS SQL Server**. EF Core podporuje [různé](https://docs.microsoft.com/en-us/ef/core/providers/) poskytovatele databáze, takže pokud chcete můžete použít jiný DBMS. V případě potřeby změňte connection string.
### Tvorba databáze & aplikace migrací databáze
K vytvoření databáze máte dvě možnosti.
#### Použití aplikace DbMigrator
Řešení obsahuje konzolovou aplikaci (v tomto příkladu nazvanou `Acme.BookStore.DbMigrator`), která dokáže vytvořit databázi, aplikovat migrace a vložit počáteční data. Ta je užitečná jak pro vývojové tak pro produkční prostředí.
> `.DbMigrator` má vlastní `appsettings.json`. Pokud jste změnili connection string výše, měli byste změnit i tento.
Klikněte pravým na projekt `.DbMigrator` zvolte **Set as StartUp Project**:
![set-as-startup-project](images/set-as-startup-project.png)
Zmáčkněte F5 (nebo Ctrl+F5) ke spuštění aplikace. Výstup by měl být podobný vyobrazení níže:
![set-as-startup-project](images/db-migrator-app.png)
#### Použití příkazu EF Core Update-Database
Ef Core máš příkaz `Update-Database`, který v případě potřeby vytvoří databázi a aplikuje čekající migrace. Klikněte pravým na projekt `.HttpApi.Host` a zvolte **Set as StartUp Project**:
![set-as-startup-project](images/set-as-startup-project.png)
Otevřete **Package Manager Console**, zvolte `.EntityFrameworkCore.DbMigrations` jako **Default Project** a proveďte příkaz `Update-Database`:
![pcm-update-database](images/pcm-update-database-v2.png)
Tímto vytvoříte novou databáze podle nakonfigurovaného connection string.
> Je doporučeno užití nástroje `.DbMigrator`, protože zároveň vloží i počáteční data ke správnému běhu webové aplikace.
### Spuštění aplikace
#### Spuštění API Host (na straně serveru)
Ujistěte se že je projekt `.HttpApi.Host` nastaven jako startovací a spusťte aplikaci což otevře Swagger UI:
![bookstore-homepage](images/bookstore-swagger-ui-host.png)
Tady můžete vidět API aplikace a zároveň je i otestovat. Získejte [více informací](https://swagger.io/tools/swagger-ui/) o Swagger UI.
##### Autorizace pro Swagger UI
Vetšina API aplikace vyžaduje autentizaci & autorizaci. Pokud chcete otestovat autorizované API, manuálně přejděte na stránku `/Account/Login`, vložte `admin` jako uživatelské jméno a `1q2w3E*` jako heslo k příhlášení do aplikace. Poté budete moci provádět autorizované požadavky API.
#### Spuštění Angular aplikace (na straně klienta)
Přejděte do složky `angular`, otevřete terminál příkazového řádku, proveďte příkaz `yarn` (doporučujeme používat správce balíků [yarn](https://yarnpkg.com), npm install bude v mnoha případech také fungovat):
````bash
yarn
````
Jakmile jsou načteny všechny node moduly, proveďte příkaz `yarn start` nebo `npm start`:
````bash
yarn start
````
Otevřete Váš oblíbený prohlížeč a přejděte na adresu `localhost:4200`. Počáteční uživatelské jméno je `admin` a heslo `1q2w3E*`.
Startovací šablona obsahuje moduly **správa identit** a **správa tenantů**. Jakmile se přihlásíte, zprístupní se administrační menu kde můžete spravovat **tenanty**, **role**, **uživatele** a jejich **oprávnění**.
> Doporučujeme [Visual Studio Code](https://code.visualstudio.com/) jako editor pro Angular projekt, ale klidně použijte Váš oblíbený editor.
### Co dále?
* [Tutoriál vývoje aplikace](Tutorials/Angular/Part-I.md)

157
docs/cs/Getting-Started-AspNetCore-Application.md

@ -1,157 +0,0 @@
# Začínáme s ASP.NET Core MVC aplikací
Tento tutoriál vysvětluje jak začít s ABP z ničeho s minimem závislostí. Obvykle chcete začít se **[startovací šablonou](https://abp.io/Templates)**.
## Tvorba nového projektu
1. Vytvořte novou AspNet Core Web aplikaci ve Visual Studio 2019 (16.4.0+):
![](images/create-new-aspnet-core-application-v2.png)
2. Nakonfigurujte váš nový projekt:
![](images/select-empty-web-application-v2.png)
3. Potvrďte kliknutím na tlačítko vytvořit
![create-aspnet-core-application](images/create-aspnet-core-application.png)
## Instalace Volo.Abp.AspNetCore.Mvc balíku
Volo.Abp.AspNetCore.Mvc je AspNet Core MVC integrační balík pro ABP. Takže ho nainstalujeme do projektu:
````
Install-Package Volo.Abp.AspNetCore.Mvc
````
## Tvorba prvního ABP modulu
ABP je modulární framework a proto vyžaduje **spouštěcí (kořenový) modul** což je třída dědící z ``AbpModule``:
````C#
using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.Hosting;
using Volo.Abp;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.Modularity;
namespace BasicAspNetCoreApplication
{
[DependsOn(typeof(AbpAspNetCoreMvcModule))]
public class AppModule : AbpModule
{
public override void OnApplicationInitialization(
ApplicationInitializationContext context)
{
var app = context.GetApplicationBuilder();
var env = context.GetEnvironment();
if (env.IsDevelopment())
{
app.UseDeveloperExceptionPage();
}
else
{
app.UseExceptionHandler("/Error");
}
app.UseStaticFiles();
app.UseRouting();
app.UseConfiguredEndpoints();
}
}
}
````
``AppModule`` je dobrý název pro spouštěcí modul aplikace.
ABP balíky definují modulové třídy a modul může mít závislost na jiném. V kódu výše, ``AppModule`` má závislost na ``AbpAspNetCoreMvcModule`` (definován v balíku [Volo.Abp.AspNetCore.Mvc](https://www.nuget.org/packages/Volo.Abp.AspNetCore.Mvc)). Je běžné přidat ``DependsOn`` atribute po instalaci nového ABP NuGet balíku.
Místo třídy Startup, konfigurujeme ASP.NET Core pipeline v této modulové třídě.
## Třída Startup
V dalším kroku upravíme Startup třídu k integraci ABP modulového systému:
````C#
using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.DependencyInjection;
namespace BasicAspNetCoreApplication
{
public class Startup
{
public void ConfigureServices(IServiceCollection services)
{
services.AddApplication<AppModule>();
}
public void Configure(IApplicationBuilder app)
{
app.InitializeApplication();
}
}
}
````
``services.AddApplication<AppModule>()`` přidává všechny služby definované ve všech modulech počínaje od ``AppModule``.
``app.InitializeApplication()`` v metodě ``Configure`` inicializuje a spustí aplikaci.
## Spusťte aplikaci!
To je vše! Spusťte aplikaci, bude fungovat podle očekávání.
## Použití Autofac jako frameworku pro vkládání závislostí
Ačkoliv je AspNet Core systém pro vkládání závíslostí (DI) dostatečný pro základní požadavky, [Autofac](https://autofac.org/) poskytuje pokročilé funkce jako injekce vlastností nebo záchyt metod, které jsou v ABP užity k provádění pokročilých funkcí frameworku.
Nahrazení AspNet Core DI systému za Autofac a integrace s ABP je snadná.
1. Nainstalujeme [Volo.Abp.Autofac](https://www.nuget.org/packages/Volo.Abp.Autofac) balík
````
Install-Package Volo.Abp.Autofac
````
2. Přidáme ``AbpAutofacModule`` závislost
````C#
[DependsOn(typeof(AbpAspNetCoreMvcModule))]
[DependsOn(typeof(AbpAutofacModule))] // Přidá závislost na AbpAutofacModule
public class AppModule : AbpModule
{
...
}
````
3. Upravíme `Program.cs` aby používal Autofac:
````csharp
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Hosting;
namespace BasicAspNetCoreApplication
{
public class Program
{
public static void Main(string[] args)
{
CreateHostBuilder(args).Build().Run();
}
public static IHostBuilder CreateHostBuilder(string[] args) =>
Host.CreateDefaultBuilder(args)
.ConfigureWebHostDefaults(webBuilder =>
{
webBuilder.UseStartup<Startup>();
})
.UseAutofac(); // Přidejte tento řádek
}
}
````
## Zdrojový kód
Získejte zdrojový kód vzorového projektu vytvořeného v tomto tutoriálů [z tohoto odkazu](https://github.com/abpframework/abp-samples/tree/master/BasicAspNetCoreApplication).

104
docs/cs/Getting-Started-AspNetCore-MVC-Template.md

@ -1,104 +0,0 @@
## Začínáme s ASP.NET Core MVC šablonou
Tento tutoriál vysvětluje, jak vytvořit novou ASP.NET Core MVC webovou aplikaci pomocí úvodní šablony, jak ji nakonfigurovat a spustit.
### Tvorba nového projektu
Tento tutoriál používá k tvorbě nového projektu **ABP CLI**. Podívejte se na stránku [Začínáme](https://abp.io/get-started) pro více možností.
Pokud ještě nemáte ABP CLI nainstalováno, učiňte tak pomocí okna příkazového řádku:
````bash
dotnet tool install -g Volo.Abp.Cli
````
K tvorbě vašeho projektu použijte příkaz `abp new` v prázdné složce:
````bash
abp new Acme.BookStore
````
> Můžete použít různé úrovně jmenných prostorů; např. BookStore, Acme.BookStore nebo Acme.Retail.BookStore.
Příkaz `new` vytvoří **vrstvenou MVC aplikaci** s **Entity Framework Core** jako databázovým poskytovatelem. Jsou zde však i jiné možnosti. Podívejte se na [CLI dokumnentaci](CLI.md) pro všechny další možností.
#### Požadavky
Vytvořené řešení vyžaduje;
* [Visual Studio 2019 (v16.4.0+)](https://visualstudio.microsoft.com/vs/)
* [.NET Core 3.0+](https://www.microsoft.com/net/download/dotnet-core/)
* [Node v12+](https://nodejs.org)
* [Yarn v1.19+](https://classic.yarnpkg.com/)
### Struktura řešení
Otevřete řešení ve **Visual Studio**:
![bookstore-visual-studio-solution](images/bookstore-visual-studio-solution-v3.png)
Řešení má vrstvenou strukturu (založenou na [Domain Driven Design](Domain-Driven-Design.md)) a obsahuje projekty jednotkovových a integračních testů předkonfigurované pro práci s **EF Core** & **SQLite in-memory** databází.
> Podívejte se na [dokument šablony aplikace](Startup-Templates/Application.md) k detailnímu pochopení struktury řešení.
### Connection string databáze
Zkontrolujte **connection string** v souboru `appsettings.json` v projektu `.Web`:
````json
{
"ConnectionStrings": {
"Default": "Server=localhost;Database=BookStore;Trusted_Connection=True"
}
}
````
Řešení je nakonfigurováno k používání **Entity Framework Core** s **MS SQL Server**. EF Core podporuje [různé](https://docs.microsoft.com/en-us/ef/core/providers/) databázové poskytovatele, takže můžete použít i jiné DBMS. V případě potřeby změňte connection string.
### Tvorba databáze & aplikace databázových migrací
K vytvoření databáze máte dvě možnosti.
#### Použití DbMigrator aplikace
Řešení obsahuje konzolovou aplikaci (v tomto příkladu nazvanou `Acme.BookStore.DbMigrator`), která může vytvářet databáze, aplikovat migrace a vkládat seed data. Je užitečná jak pro vývojové, tak pro produkční prostředí.
> Projekt `.DbMigrator` má vlastní `appsettings.json`. Takže pokud jste změnili connection string uvedený výše, musíte změnit také tento.
Klikněte pravým na projekt `.DbMigrator` a vyberte **Set as StartUp Project**:
![set-as-startup-project](images/set-as-startup-project.png)
Zmáčkněte F5 (nebo Ctrl+F5) ke spuštění aplikace. Výstup bude vypadat následovně:
![set-as-startup-project](images/db-migrator-app.png)
#### Použití EF Core Update-Database příkazu
Ef Core má `Update-Database` příkaz, který v případě potřeby vytvoří databázi a aplikuje čekající migrace. Klikněte pravým na projekt `.Web` a vyberte **Set as StartUp Project**:
![set-as-startup-project](images/set-as-startup-project.png)
Otevřete **Package Manager Console**, vyberte projekt `.EntityFrameworkCore.DbMigrations` jako **Default Project** and spusťte příkaz `Update-Database`:
![pcm-update-database](images/pcm-update-database-v2.png)
Dojde k vytvoření nové databáze na základě nakonfigurovaného connection stringu.
> Použití nástroje `.Migrator` je doporučený způsob, jelikož zároveň vloží seed data nutné k správnému běhu webové aplikace.
### Spuštění aplikace
Ujistěte se že je projekt `.Web` nastaven jako startovací projekt. Spusťte aplikaci což následně otevře **úvodní** stránku ve vašem prohlížeči:
![bookstore-homepage](images/bookstore-homepage.png)
Klikněte na tlačítko **Přihlásit**, vložte `admin` jako uživatelské jméno a `1q2w3E*` jako heslo k přihlášení do aplikace.
Startovací šabloná obsahuje **identity management** a **tenant management** moduly. Jakmile se přihlásite, budete mít přístup do nabídky Administrace, kde můžete spravovat **tenanty**, **role**, **uživatele** a jejich **oprávnění**. Správa uživatelů vypadá takto:
![bookstore-user-management](images/bookstore-user-management-v2.png)
### Co dále?
* [Tutoriál vývoje aplikace](Tutorials/AspNetCore-Mvc/Part-I.md)

181
docs/cs/Getting-Started-Console-Application.md

@ -1,181 +0,0 @@
# Začínáme s konzolovou aplikací
Tento tutoriál vysvětluje jak začít s ABP z ničeho s minimem závislostí. Obvykle chcete začít se **[startovací šablonou](https://abp.io/Templates)**.
## Tvorba nového projektu
Vytvořte regulérní .NET Core konzolovou aplikaci z Visual Studio:
![](images/create-new-net-core-console-application.png)
## Instalace Volo.Abp balíku
Volo.Abp.Core je základní NuGet balík k tvorbě aplikací založených na ABP. Takže ho nainstalujeme do projektu:
````
Install-Package Volo.Abp.Core
````
## Tvorba prvního ABP modulu
ABP je modulární framework a proto vyžaduje **spouštěcí (kořenový) modul** což je třída dědící z ``AbpModule``:
````C#
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp.Modularity;
namespace AbpConsoleDemo
{
public class AppModule : AbpModule
{
}
}
````
``AppModule`` je dobrý název pro spouštěcí modul aplikace.
## Inicializace aplikace
Dalším krokem je bootstrap aplikace pomocí spouštěcího modulu vytvořeného výše:
````C#
using System;
using Volo.Abp;
namespace AbpConsoleDemo
{
class Program
{
static void Main(string[] args)
{
using (var application = AbpApplicationFactory.Create<AppModule>())
{
application.Initialize();
Console.WriteLine("Press ENTER to stop application...");
Console.ReadLine();
}
}
}
}
````
``AbpApplicationFactory`` se používá k vytvoření aplikace a načtení všech modulů, s využitím ``AppModule`` jako spouštěcím modulem. ``Initialize()`` metoda spouští aplikaci.
## Ahoj světe!
Aplikace výše zatím nic nedělá. Pojďme proto vytvořit službu která už něco dělá:
````C#
using System;
using Volo.Abp.DependencyInjection;
namespace AbpConsoleDemo
{
public class HelloWorldService : ITransientDependency
{
public void SayHello()
{
Console.WriteLine("Hello World!");
}
}
}
````
``ITransientDependency`` je speciální rozhraní ABP, které automaticky registruje službu jako přechodnou (více v [dokumentu vkládání závislostí](Dependency-Injection.md)).
Nyní můžeme vyřešit ``HelloWorldService`` a vypsat naše ahoj. Změníme Program.cs podle vyobrazení níže:
````C#
using System;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp;
namespace AbpConsoleDemo
{
class Program
{
static void Main(string[] args)
{
using (var application = AbpApplicationFactory.Create<AppModule>())
{
application.Initialize();
// Vyřeší službu a použije ji
var helloWorldService =
application.ServiceProvider.GetService<HelloWorldService>();
helloWorldService.SayHello();
Console.WriteLine("Press ENTER to stop application...");
Console.ReadLine();
}
}
}
}
````
I když je to dostačující pro tento jednoduchý príklad kódu, je vždy lepší v případě přímého řešení závislostí z ``IServiceProvider`` vytvořit rámce (více v [dokumentu vkládání závislostí](Dependency-Injection.md)).
## Využití Autofac jako frameworku pro vkládání závislostí
Ačkoliv je AspNet Core systém pro vkládání závíslostí (DI) skvělý pro základní požadavky, Autofac poskytuje pokročilé funkce jako injekce vlastností nebo záchyt metod, které jsou v ABP užity k provádění pokročilých funkcí frameworku.
Nahrazení AspNet Core DI systému za Autofac a integrace s ABP je snadná.
1. Nainstalujeme [Volo.Abp.Autofac](https://www.nuget.org/packages/Volo.Abp.Autofac) balík
```
Install-Package Volo.Abp.Autofac
```
1. Přidáme ``AbpAutofacModule`` závislost
```c#
[DependsOn(typeof(AbpAutofacModule))] // Přidá závislost na AbpAutofacModule
public class AppModule : AbpModule
{
}
```
1. Změníme soubor ``Program.cs`` podle vyobrazení níže:
```c#
using System;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp;
namespace AbpConsoleDemo
{
class Program
{
static void Main(string[] args)
{
using (var application = AbpApplicationFactory.Create<AppModule>(options =>
{
options.UseAutofac(); // Autofac integrace
}))
{
application.Initialize();
// Vyřeší službu a použije ji
var helloWorldService =
application.ServiceProvider.GetService<HelloWorldService>();
helloWorldService.SayHello();
Console.WriteLine("Press ENTER to stop application...");
Console.ReadLine();
}
}
}
}
```
Stačí volat metodu `options.UseAutofac()` v možnostech `AbpApplicationFactory.Create`.
## Zdrojový kód
Získejte zdrojový kód vzorového projektu vytvořeného v tomto tutoriálů [z tohoto odkazu](https://github.com/abpframework/abp-samples/tree/master/BasicConsoleApplication).

25
docs/cs/Index.md

@ -1,25 +0,0 @@
# ABP dokumentace
ABP je **open source aplikační framework** se zaměřením na vývoj webových aplikací založených na ASP.NET Core, zároveň ho však lze využít i k vývoji jiných typů aplikací.
K procházení dokumentace využijte navigační nabídky vlevo.
## Začínáme
Nejsnazší cestou jak začít nový projekt s ABP je užití startovací šablony:
* [ASP.NET Core MVC (Razor Pages) UI Počáteční Šablona](Getting-Started-AspNetCore-MVC-Template.md)
* [Angular UI Počáteční Šablona](Getting-Started-Angular-Template.md)
Pokud chcete začít od nuly (s prázdným projektem) tak manuálně nainstalujte ABP Framework s pomocí následujících tutoriálů:
* [Konzolová Aplikace](Getting-Started-Console-Application.md)
* [ASP.NET Core Web Aplikace](Getting-Started-AspNetCore-Application.md)
## Zdrojový kód
ABP je hostovaný na GitHub. Zobrazit [zdrojový kód](https://github.com/abpframework/abp).
## Chcete přispět?
ABP je komunitně řízený open source projekt. Podívejte se na [průvodce pro přispěvatele](Contribution/Index.md) pokud chcete být součástí tohoto projektu.

26
docs/cs/Nightly-Builds.md

@ -1,26 +0,0 @@
# Noční sestavení
Všechny balíky frameworku a modulů jsou každý večer nasazeny na MyGet. Takže můžete používat nebo testovat nejnovější kód bez čekání na další vydání.
## Konfigurace Visual Studia
> Vyžaduje Visual Studio 2017+
1. Přejděte do `Tools > Options > NuGet Package Manager > Package Source`.
2. Klikněte na zelenou ikonku `+`.
3. Nastavte `ABP Nightly` jako *Name* a `https://www.myget.org/F/abp-nightly/api/v3/index.json` jako *Source* podle vyobrazení níže:
![night-build-add-nuget-source](images/night-build-add-nuget-source.png)
4. Klikněte na `Update`.
5. Klikněte na `OK` k uložení změn.
## Instalace balíku
Nyní můžete instalovat náhledové / noční balíky do Vašeho projektu z NuGet prohlížeče nebo Package Manager Console.
![night-build-add-nuget-package](images/night-build-add-nuget-package.png)
1. V nuget prohlížeči, vyberte "Include prereleases".
2. Změňte zdroj balíků na "All".
3. Vyhledejte balík. Uvidíte prerelease balík formátovaný jako `(VERZE)-preview(DATUM)` (např *v0.16.0-preview20190401* jako v tomto vzorku).
4. Můžete kliknout na `Install` k přídání balíku do projektu.

376
docs/cs/docs-nav.json

@ -1,376 +0,0 @@
{
"items": [
{
"text": "Začínáme",
"items": [
{
"text": "Ze startovacích šablon",
"items": [
{
"text": "Aplikace s MVC (Razor Pages) UI",
"path": "Getting-Started-AspNetCore-MVC-Template.md"
},
{
"text": "Aplikace s Angular UI",
"path": "Getting-Started-Angular-Template.md"
}
]
},
{
"text": "Z prázdných projektů",
"items": [
{
"text": "S ASP.NET Core Web aplikací",
"path": "Getting-Started-AspNetCore-Application.md"
},
{
"text": "S konzolovou aplikací",
"path": "Getting-Started-Console-Application.md"
}
]
}
]
},
{
"text": "Tutoriály",
"items": [
{
"text": "Vývoj aplikace",
"items": [
{
"text": "S ASP.NET Core MVC UI",
"path": "Tutorials/AspNetCore-Mvc/Part-I.md"
},
{
"text": "S Angular UI",
"path": "Tutorials/Angular/Part-I.md"
}
]
}
]
},
{
"text": "CLI",
"path": "CLI.md"
},
{
"text": "Základy",
"items": [
{
"text": "Konfigurace",
"path": "Configuration.md"
},
{
"text": "Možnosti",
"path": "Options.md"
},
{
"text": "Vkládání závislostí",
"path": "Dependency-Injection.md",
"items": [
{
"text": "AutoFac integrace",
"path": "Autofac-Integration.md"
}
]
},
{
"text": "Virtuální systém souborů",
"path": "Virtual-File-System.md"
},
{
"text": "Lokalizace",
"path": "Localization.md"
},
{
"text": "Zpracování výjimek",
"path": "Exception-Handling.md"
},
{
"text": "Validace",
"path": "Validation.md",
"items": [
{
"text": "FluentValidation integrace",
"path": "FluentValidation.md"
}
]
},
{
"text": "Autorizace",
"path": "Authorization.md"
},
{
"text": "Ukládání do mezipaměti",
"path": "Caching.md"
},
{
"text": "Audit"
},
{
"text": "Nastavení",
"path": "Settings.md"
}
]
},
{
"text": "Události",
"items": [
{
"text": "Event bus (místní)"
},
{
"text": "Distribuovaný event bus",
"items": [
{
"text": "RabbitMQ integrace"
}
]
}
]
},
{
"text": "Služby",
"items": [
{
"text": "Současný uživatel",
"path": "CurrentUser.md"
},
{
"text": "Mapování objekt na objekt",
"path": "Object-To-Object-Mapping.md"
},
{
"text": "Serializace objektu"
},
{
"text": "Serializace JSON"
},
{
"text": "Emailování"
},
{
"text": "GUIDy"
},
{
"text": "Vláknování"
},
{
"text": "Časování"
}
]
},
{
"text": "Multitenance",
"path": "Multi-Tenancy.md"
},
{
"text": "Vývoj modulů",
"items": [
{
"text": "Základy",
"path": "Module-Development-Basics.md"
},
{
"text": "Zásuvné moduly"
},
{
"text": "Nejlepší praktiky",
"path": "Best-Practices/Index.md"
}
]
},
{
"text": "Domain driven design",
"path": "Domain-Driven-Design.md",
"items": [
{
"text": "Doménová vrstva",
"items": [
{
"text": "Entity & agregované kořeny",
"path": "Entities.md"
},
{
"text": "Hodnotové objekty"
},
{
"text": "Repozitáře",
"path": "Repositories.md"
},
{
"text": "Doménové služby"
},
{
"text": "Specifikace"
}
]
},
{
"text": "Aplikační vrstva",
"items": [
{
"text": "Aplikační služby",
"path": "Application-Services.md"
},
{
"text": "Objekty přenosu dat"
},
{
"text": "Jednotka práce"
}
]
}
]
},
{
"text": "ASP.NET Core",
"items": [
{
"text": "API",
"items": [
{
"text": "Automatické API řadiče",
"path": "AspNetCore/Auto-API-Controllers.md"
},
{
"text": "Dynamičtí C# API klienti",
"path": "AspNetCore/Dynamic-CSharp-API-Clients.md"
}
]
},
{
"text": "Uživatelské rozhraní",
"items": [
{
"text": "Správa klientských balíčků",
"path": "AspNetCore/Client-Side-Package-Management.md"
},
{
"text": "Svazování & minifikace",
"path": "AspNetCore/Bundling-Minification.md"
},
{
"text": "Tag pomocníci",
"path": "AspNetCore/Tag-Helpers/Index.md"
},
{
"text": "Widgety",
"path": "AspNetCore/Widgets.md"
},
{
"text": "Motivy",
"path": "AspNetCore/Theming.md"
}
]
}
]
},
{
"text": "Přístup k datům",
"path": "Data-Access.md",
"items": [
{
"text": "Connection stringy",
"path": "Connection-Strings.md"
},
{
"text": "Poskytovatelé databází",
"items": [
{
"text": "Entity Framework Core",
"path": "Entity-Framework-Core.md",
"items": [
{
"text": "Přepnutí na MySQL",
"path": "Entity-Framework-Core-MySQL.md"
},
{
"text": "Přepnutí na PostgreSQL",
"path": "Entity-Framework-Core-PostgreSQL.md"
},
{
"text": "Přepnutí na SQLite",
"path": "Entity-Framework-Core-SQLite.md"
},
{
"text": "Přepnutí na jiný DBMS",
"path": "Entity-Framework-Core-Other-DBMS.md"
}
]
},
{
"text": "MongoDB",
"path": "MongoDB.md"
},
{
"text": "Dapper",
"path": "Dapper.md"
}
]
}
]
},
{
"text": "Pozadí",
"items": [
{
"text": "Úkony na pozadí",
"path": "Background-Jobs.md",
"items": [
{
"text": "Hangfire integrace",
"path": "Background-Jobs-Hangfire.md"
},
{
"text": "RabbitMQ integrace",
"path": "Background-Jobs-RabbitMq.md"
}
]
}
]
},
{
"text": "Startovací šablony",
"path": "Startup-Templates/Index.md",
"items": [
{
"text": "Aplikace",
"path": "Startup-Templates/Application.md"
},
{
"text": "Modul",
"path": "Startup-Templates/Module.md"
}
]
},
{
"text": "Vzorky",
"items": [
{
"text": "Mikroslužby demo",
"path": "Samples/Microservice-Demo.md"
}
]
},
{
"text": "Moduly aplikace",
"path": "Modules/Index.md"
},
{
"text": "Architektura mikroslužby",
"path": "Microservice-Architecture.md"
},
{
"text": "Testování"
},
{
"text": "Noční sestavení",
"path": "Nightly-Builds.md"
},
{
"text": "Průvodce pro přispěvatele",
"path": "Contribution/Index.md"
}
]
}

BIN
docs/cs/images/MonthlyProfitWidgetFiles.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

BIN
docs/cs/images/authorization-new-permission-ui-hierarcy.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 43 KiB

BIN
docs/cs/images/authorization-new-permission-ui-localized.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

BIN
docs/cs/images/authorization-new-permission-ui.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

BIN
docs/cs/images/bookstore-apis.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

BIN
docs/cs/images/bookstore-create-template.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

BIN
docs/cs/images/bookstore-homepage.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.4 KiB

BIN
docs/cs/images/bookstore-swagger-ui-host.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 41 KiB

BIN
docs/cs/images/bookstore-user-management-v2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

BIN
docs/cs/images/bookstore-visual-studio-solution-for-spa.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

BIN
docs/cs/images/bookstore-visual-studio-solution-tiered.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

BIN
docs/cs/images/bookstore-visual-studio-solution-v3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.6 KiB

BIN
docs/cs/images/build-action-embedded-resource-sample.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.8 KiB

BIN
docs/cs/images/create-aspnet-core-application.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 63 KiB

BIN
docs/cs/images/create-new-aspnet-core-application-v2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 119 KiB

BIN
docs/cs/images/create-new-aspnet-core-application.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

BIN
docs/cs/images/create-new-net-core-console-application.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

BIN
docs/cs/images/dashboard1.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

BIN
docs/cs/images/db-migrator-app.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.5 KiB

BIN
docs/cs/images/docs-create-project.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

BIN
docs/cs/images/docs-module_download-new-abp-project.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

BIN
docs/cs/images/docs-module_download-sample-navigation-menu.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

BIN
docs/cs/images/docs-module_solution-explorer.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.0 KiB

BIN
docs/cs/images/docs-section-ui.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

BIN
docs/cs/images/github-access-token-private-repo.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

BIN
docs/cs/images/github-access-token-public-repo.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

BIN
docs/cs/images/github-myusername.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

BIN
docs/cs/images/issuemanagement-module-solution.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

BIN
docs/cs/images/layered-project-dependencies-module.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

BIN
docs/cs/images/layered-project-dependencies.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

BIN
docs/cs/images/localization-resource-json-files.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

BIN
docs/cs/images/microservice-sample-authserver-home.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

BIN
docs/cs/images/microservice-sample-authserver-login.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.9 KiB

BIN
docs/cs/images/microservice-sample-backend-ui-permissions.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

BIN
docs/cs/images/microservice-sample-backend-ui.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

BIN
docs/cs/images/microservice-sample-blogservice-permission-in-database.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 KiB

BIN
docs/cs/images/microservice-sample-diagram-2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 119 KiB

BIN
docs/cs/images/microservice-sample-diagram.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 57 KiB

BIN
docs/cs/images/microservice-sample-kibana-1.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 50 KiB

BIN
docs/cs/images/microservice-sample-kibana-2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

BIN
docs/cs/images/microservice-sample-product-module-in-solution.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.2 KiB

BIN
docs/cs/images/microservice-sample-public-product-list.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

BIN
docs/cs/images/microservice-sample-solution.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.8 KiB

BIN
docs/cs/images/microservice-sample-update-database-authserver.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.8 KiB

BIN
docs/cs/images/microservice-sample-update-database-products.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

BIN
docs/cs/images/module-layers-and-packages.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

BIN
docs/cs/images/night-build-add-nuget-package.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

BIN
docs/cs/images/night-build-add-nuget-source.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

BIN
docs/cs/images/pcm-update-database-v2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

BIN
docs/cs/images/pcm-update-database.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

BIN
docs/cs/images/select-empty-web-application-v2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 43 KiB

BIN
docs/cs/images/select-empty-web-application.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

BIN
docs/cs/images/set-as-startup-project.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

BIN
docs/cs/images/tiered-solution-applications.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

BIN
docs/cs/images/tiered-solution-servers.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

BIN
docs/cs/images/volodocs-iis-add-website.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

BIN
docs/cs/images/volodocs-iis-application-pool.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

BIN
docs/cs/images/widget-basic-files.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.2 KiB

10
docs/docs-langs.json

@ -4,16 +4,6 @@
"DisplayName" : "English",
"Code" : "en",
"IsDefault": true
},
{
"DisplayName" : "Português",
"Code" : "pt-BR",
"IsDefault": false
},
{
"DisplayName" : "简体中文",
"Code" : "zh-Hans",
"IsDefault": false
}
]
}

67
docs/en/Blog-Posts/2024-06-27 v8_2_Release_Stable/POST.md

@ -0,0 +1,67 @@
# ABP.IO Platform 8.2 Final Has Been Released!
[ABP Framework](https://abp.io/) and [ABP Commercial](https://commercial.abp.io/) 8.2 versions have been released today.
## What's New With Version 8.2?
All the new features were explained in detail in the [8.2 RC Announcement Post](https://blog.abp.io/abp/announcing-abp-8-2-release-candidate), so there is no need to review them again. You can check it out for more details.
## Getting Started with 8.2
### Creating New Solutions
You can create a new solution with the ABP Framework version 8.2 by either using the `abp new` command or generating the CLI command on the [get started page](https://abp.io/get-started).
> See the [getting started document](https://docs.abp.io/en/abp/latest/Getting-Started) for more.
### How to Upgrade an Existing Solution
#### Install/Update the ABP CLI
First, install the ABP CLI or upgrade it to the latest version.
If you haven't installed it yet:
```bash
dotnet tool install -g Volo.Abp.Cli
```
To update the existing CLI:
```bash
dotnet tool update -g Volo.Abp.Cli
```
#### Upgrading Existing Solutions with the ABP Update Command
[ABP CLI](https://docs.abp.io/en/abp/latest/CLI) provides a handy command to update all the ABP related NuGet and NPM packages in your solution with a single command:
```bash
abp update
```
Run this command in the root folder of your solution.
## Migration Guides
There are a few breaking changes in this version that may affect your application.
Please see the following migration documents, if you are upgrading from v8.x or earlier:
* [ABP Framework 8.x to 8.2 Migration Guide](https://docs.abp.io/en/abp/8.2/Migration-Guides/Abp-8_2)
* [ABP Commercial 8.x to 8.2 Migration Guide](https://docs.abp.io/en/commercial/8.2/migration-guides/v8_2)
## Community News
### New ABP Community Posts
As always, exciting articles have been contributed by the ABP community. I will highlight some of them here:
* [How to use Angular Material with Form Validation on ABP](https://community.abp.io/posts/how-to-use-angular-material-with-form-validation-on-abp-jtheajj3) by [Mahmut Gündoğdu](https://x.com/mahmutgundogdu)
* [Tunnel your local host address to a public URL with ngrok](https://community.abp.io/posts/tunnel-your-local-host-address-to-a-public-url-with-ngrok-4cywnocj) by [Bart Van Hoey](https://github.com/bartvanhoey)
* [Antiforgery Token Validation When Angular and HTTP API Runs on the Same Server](https://community.abp.io/posts/antiforgery-token-validation-when-angular-and-http-api-runs-on-the-same-server-mzf5ppdq) by [dignite](https://x.com/dignite_adu)
Thanks to the ABP Community for all the content they have published. You can also [post your ABP-related (text or video) content](https://community.abp.io/articles/submit) to the ABP Community.
## About the Next Version
The next feature version will be 8.3. You can follow the [release planning here](https://github.com/abpframework/abp/milestones). Please [submit an issue](https://github.com/abpframework/abp/issues/new) if you have any problems with this version.

BIN
docs/en/Blog-Posts/2024-06-27 v8_2_Release_Stable/cover-image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 MiB

2
docs/en/CLI.md

@ -118,6 +118,8 @@ For more samples, go to [ABP CLI Create Solution Samples](CLI-New-Command-Sample
* `angular`: Angular UI. There are some additional options for this template:
* `--separate-auth-server`: The Auth Server project comes as a separate project and runs at a different endpoint. It separates the Auth Server from the API Host application. If not specified, you will have a single endpoint in the server side.
* `--pwa`: Specifies the project as Progressive Web Application.
* `blazor-webapp`: Blazor Web App UI. There are some additional options for this template:
* `--tiered`: The Auth Server and the API Host project comes as separate projects and run at different endpoints. It has 3 startup projects: *HttpApi.Host*, *AuthServer* and *Blazor* and and each runs on different endpoints. If not specified, you will have a single endpoint for your web project.
* `blazor`: Blazor UI. There are some additional options for this template:
* `--separate-auth-server`The Auth Server project comes as a separate project and runs at a different endpoint. It separates the Auth Server from the API Host application. If not specified, you will have a single endpoint in the server side.
* `--pwa`: Specifies the project as Progressive Web Application.

302
docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/How to use Aspire with ABP framework.md

@ -0,0 +1,302 @@
# How to use .NET Aspire with ABP framework
[.NET Aspire](https://learn.microsoft.com/en-us/dotnet/aspire/get-started/aspire-overview) is an opinionated, cloud-ready stack designed for building observable, production-ready, and distributed applications. On the other hand, the [ABP framework](https://docs.abp.io/en/abp/latest) offers a complete, modular and layered software architecture based on Domain Driven Design principles and patterns. This guide explores how to combine .NET Aspire with ABP, enabling developers to create observable, and feature-rich applications.
## When to Use .NET Aspire?
Using .NET Aspire with the ABP framework can be beneficial in various scenarios where you need to combine the strengths of both technologies. Here are some situations when using .NET Aspire with ABP can be advantageous:
- **Enterprise Web Applications:** ABP is well-suited for building enterprise web applications with its opinionated architecture and best practices. When combined with .NET Aspire, you can leverage ABP's features for rapid development of user interfaces, backend services, and business logic while benefiting from .NET Aspire's cloud-native capabilities and observability features.
- **Observability and Monitoring:** .NET Aspire's emphasis on observability, including logging, monitoring, and tracing, can enhance ABP applications by providing deeper insights into system behavior, performance metrics, and diagnostics, which is key for maintaining and optimizing enterprise-grade applications.
## Creating a new ABP Solution
To demonstrate the usage of .NET Aspire with the ABP framework, I've created an ABP solution. If you want to create the same solution from scratch, follow the steps below:
Install the ABP CLI if you haven't installed it before:
```bash
dotnet tool install -g Volo.Abp.Cli
```
Create a new solution with the ABP framework's Application Startup Template with Tiered MVC UI and EF Core database:
```bash
abp new AspirationalAbp -u mvc --database-provider ef -dbms PostgreSQL --csf --tiered
```
> The startup template selection matters for this article. I chose these options so that the demo solution can cover complex scenarios.
**Disclaimer-I:** This article is based on version `8.0.1` of .NET Aspire and version `8.2.0` of ABP Framework.
**Disclaimer-II:** ABP and .NET Aspire may not be fully compatible in some respects. This article aims to explain how these two technologies can be used together in the simplest way possible, even if they are not fully compatible.
## Add .NET Aspire
After creating the solution, run the following commands in the `src` folder of your solution to add .NET Aspire:
```bash
// Adding AppHost
dotnet new aspire-apphost -n AspirationalAbp.AppHost
dotnet sln ../AspirationalAbp.sln add ./AspirationalAbp.AppHost/AspirationalAbp.AppHost.csproj
// Adding ServiceDefaults
dotnet new aspire-servicedefaults -n AspirationalAbp.ServiceDefaults
dotnet sln ../AspirationalAbp.sln add ./AspirationalAbp.ServiceDefaults/AspirationalAbp.ServiceDefaults.csproj
```
These commands add two new projects to the solution:
- **AspirationalAbp.AppHost**: An orchestrator project designed to connect and configure the different projects and services of your app.
- **AspirationalAbp.ServiceDefaults**: A .NET Aspire shared project to manage configurations that are reused across the projects in your solution related to [resilience](https://learn.microsoft.com/en-us/dotnet/core/resilience/http-resilience), [service discovery](https://learn.microsoft.com/en-us/dotnet/aspire/service-discovery/overview), and [telemetry](https://learn.microsoft.com/en-us/dotnet/aspire/fundamentals/telemetry).
We have added .NET Aspire to our ABP based solution, but we have not registered our projects in the .NET Aspire orchestration. Now, let's enroll our projects, which implement the db migrator, web user interface, API, and auth, in .NET Aspire orchestration.
## Registering projects to .NET Aspire orchestration
First of all, we need to add the reference of related projects to the `AspirationalAbp.AppHost` project. For this, add the following `ItemGroups` to the `AspirationalAbp.AppHost/AspirationalAbp.AppHost.csproj` file:
```csharp
<ItemGroup>
<ProjectReference Include="..\AspirationalAbp.AuthServer\AspirationalAbp.AuthServer.csproj" />
<ProjectReference Include="..\AspirationalAbp.HttpApi.Host\AspirationalAbp.HttpApi.Host.csproj" />
<ProjectReference Include="..\AspirationalAbp.Web\AspirationalAbp.Web.csproj"/>
<ProjectReference Include="..\AspirationalAbp.DbMigrator\AspirationalAbp.DbMigrator.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Aspire.Hosting.PostgreSQL" Version="8.0.1" />
<PackageReference Include="Aspire.Hosting.Redis" Version="8.0.1" />
</ItemGroup>
```
With the first `ItemGroup`, we added the references of `AuthServer`, `HttpApi.Host`, `Web`, and `DbMigrator` projects to the app host project. So, we can orchestrate them within the app model.
With the second `ItemGroup`, to model the **PostgreSQL** server resource and **Redis** resource in the app host, installed the `Aspire.Hosting.PostgreSQL` and `Aspire.Hosting.Redis`
Now let's update the `Program` class of the `AspirationalAbp.AppHost` project as follows:
```csharp
using Microsoft.Extensions.Hosting;
var builder = DistributedApplication.CreateBuilder(args);
var postgres = builder
.AddPostgres("postgres")
.AddDatabase("AspirationalAbp");
var redis = builder.AddRedis("redis");
// DbMigrator
if (builder.Environment.IsDevelopment())
{
builder
.AddProject<Projects.AspirationalAbp_DbMigrator>("dbMigrator")
.WithReference(postgres, "Default")
.WithReference(redis, "Redis")
.WithReplicas(1);
}
// AuthServer
var authServerLaunchProfile = "AspirationalAbp.AuthServer";
builder
.AddProject<Projects.AspirationalAbp_AuthServer>("authserver", launchProfileName: authServerLaunchProfile)
.WithExternalHttpEndpoints()
.WithReference(postgres, "Default")
.WithReference(redis);
// HttpApi.Host
var httpApiHostLaunchProfile = "AspirationalAbp.HttpApi.Host";
builder
.AddProject<Projects.AspirationalAbp_HttpApi_Host>("httpapihost", launchProfileName: httpApiHostLaunchProfile)
.WithExternalHttpEndpoints()
.WithReference(postgres, "Default")
.WithReference(redis);
// Web
builder
.AddProject<Projects.AspirationalAbp_Web>("web", "AspirationalAbp.Web")
.WithReference(redis);
builder.Build().Run();
```
With the code above, the following operations were performed below:
1. Creates an `IDistributedApplicationBuilder` instance by calling `DistributedApplication.CreateBuilder(args)`.
2. Adds PostgreSQL and the `AspirationalAbp` database.
3. Adds Redis.
4. Adds the `DbMigrator` project with references to PostgreSQL and Redis, ensuring one replica in development.
5. Adds the `AuthServer` project with external HTTP endpoints, referencing PostgreSQL and Redis.
6. Adds the `HttpApi.Host` project with external HTTP endpoints, referencing PostgreSQL and Redis.
7. Adds the `Web` project, referencing Redis.
8. Builds and runs the application.
Now let's make the projects we added to the app host compatible with .NET Aspire.
## Configuring Projects for Aspire
To make the `AspirationalAbp.DbMigrator`, `AspirationalAbp.AuthServer`, `AspirationalAbp.HttpApi.Host`, and `AspirationalAbp.Web` projects compatible with .NET Aspire, we need to add and configure several packages. For that, we need to add the `Aspire.StackExchange.Redis` package to all these projects and the `Aspire.Npgsql.EntityFrameworkCore.PostgreSQL` package to the `AspirationalAbp.EntityFrameworkCore` project. Additionally, we will add the `AspirationalAbp.ServiceDefaults` reference to host projects except `AspirationalAbp.DbMigrator`. Also, we need to convert [Serilog](https://serilog.net/) events into [OpenTelemetry](https://opentelemetry.io/) `LogRecord`s, for that we will add a `Serilog.Sinks.OpenTelemetry` reference to host projects. Let's begin with configuring `AspirationalAbp.DbMigrator`.
### AspirationalAbp.DbMigrator
First, let's add the `Aspire.StackExchange.Redis`, and `Serilog.Sinks.OpenTelemetry` packages to the `AspirationalAbp.DbMigrator` project. For this, let's run the following .NET CLI command inside the `AspirationalAbp.DbMigrator` project:
```bash
dotnet add package Aspire.StackExchange.Redis --version 8.0.1
dotnet add package Serilog.Sinks.OpenTelemetry --version 4.0.0-dev-00313
```
Then let's override the `PreConfigureServices` method in `AspirationalAbpDbMigratorModule` as below:
```csharp
public override void PreConfigureServices(ServiceConfigurationContext context)
{
var configuration = context.Services.GetConfiguration();
configuration["Redis:Configuration"] = configuration["ConnectionStrings:Redis"];
}
```
To use the **OpenTelemetry** sink we have installed the `Serilog.Sinks.OpenTelemetry` package and now let's enable the sink. For this, let's write the following code block just before calling the `CreateLogger` method in the logger configuration in `Program.cs`:
```csharp
/// .WriteTo.Async(c => c.Console())
.WriteTo.Async(c => c.OpenTelemetry())
/// .CreateLogger();
```
Now let's continue with `AspirationalAbp.EntityFrameworkCore`.
### AspirationalAbp.EntityFrameworkCore
Now let's add the `Aspire.Npgsql.EntityFrameworkCore.PostgreSQL` package to the `AspirationalAbp.EntityFrameworkCore` project. For this, you can run the following command in the `AspirationalAbp.EntityFrameworkCore` project:
```bash
dotnet add package Aspire.Npgsql.EntityFrameworkCore.PostgreSQL --version 8.0.1
```
Now let's continue with `AspirationalAbp.AuthServer`.
### AspirationalAbp.AuthServer
First, let's add the `Serilog.Sinks.OpenTelemetry`, `Aspire.StackExchange.Redis` and `AspirationalAbp.ServiceDefaults` packages to the `AspirationalAbp.AuthServer` project. For this, let's run the following .NET CLI command inside the `AspirationalAbp.AuthServer` project:
```bash
dotnet add package Aspire.StackExchange.Redis --version 8.0.1
dotnet add reference ../AspirationalAbp.ServiceDefaults/AspirationalAbp.ServiceDefaults.csproj
dotnet add package Serilog.Sinks.OpenTelemetry --version 4.0.0-dev-00313
```
Then add the following code block after defining the builder variable in `Program.cs`:
```csharp
builder.AddServiceDefaults();
builder.AddRedisClient("redis");
builder.AddNpgsqlDbContext<AspirationalAbpDbContext>("Default",
options =>
{
options.DisableRetry = true;
});
```
Then add the following code to the `PreConfigureServices` method in the `AspirationalAbpAuthServerModule` class:
```csharp
configuration["Redis:Configuration"] = configuration["ConnectionStrings:Redis"];
```
To use the **OpenTelemetry** sink we have installed the `Serilog.Sinks.OpenTelemetry` package and now let's enable the sink. For this, let's write the following code block just before calling the `CreateLogger` method in logger configuration in `Program.cs`:
```csharp
/// .WriteTo.Async(c => c.Console())
.WriteTo.Async(c => c.OpenTelemetry())
/// .CreateLogger();
```
So far we have made `AspirationalAbp.DbMigrator`, `AspirationalAbp.EntityFrameworkCore`, and `AspirationalAbp.AuthServer` compatible with .NET Aspire. Now let's continue with `AspirationalAbp.HttpApi.Host`.
### AspirationalAbp.HttpApi.Host
First, let's add the `Serilog.Sinks.OpenTelemetry`, `Aspire.StackExchange.Redis` and `AspirationalAbp.ServiceDefaults` packages to the `AspirationalAbp.HttpApi.Host` project. For this, let's run the following .NET CLI command inside the `AspirationalAbp.HttpApi.Host` project:
```bash
dotnet add package Aspire.StackExchange.Redis --version 8.0.1
dotnet add reference ../AspirationalAbp.ServiceDefaults/AspirationalAbp.ServiceDefaults.csproj
dotnet add package Serilog.Sinks.OpenTelemetry --version 4.0.0-dev-00313
```
Then add the following code block after defining the builder variable in `Program.cs`:
```csharp
builder.AddServiceDefaults();
builder.AddRedisClient("redis");
builder.AddNpgsqlDbContext<AspirationalAbpDbContext>("Default",
options =>
{
options.DisableRetry = true;
});
```
Then let's override the `PreConfigureServices` method in `AspirationalAbpHttpApiHostModule` as below:
```csharp
public override void PreConfigureServices(ServiceConfigurationContext context)
{
var configuration = context.Services.GetConfiguration();
configuration["Redis:Configuration"] = configuration["ConnectionStrings:Redis"];
}
```
To use the **OpenTelemetry** sink we have installed the `Serilog.Sinks.OpenTelemetry` package and now let's enable the sink. For this, let's write the following code block just before calling the `CreateLogger` method in the logger configuration in `Program.cs`:
```csharp
/// .WriteTo.Async(c => c.Console())
.WriteTo.Async(c => c.OpenTelemetry())
/// .CreateLogger();
```
Finally, let's make `AspirationalAbp.Web` compatible with .NET Aspire.
### AspirationalAbp.Web
First, let's add the `Serilog.Sinks.OpenTelemetry`, `Aspire.StackExchange.Redis` and `AspirationalAbp.ServiceDefaults` packages to the `AspirationalAbp.Web` project. For this, let's run the following .NET CLI command inside the `AspirationalAbp.Web` project:
```bash
dotnet add package Aspire.StackExchange.Redis --version 8.0.1
dotnet add reference ../AspirationalAbp.ServiceDefaults/AspirationalAbp.ServiceDefaults.csproj
dotnet add package Serilog.Sinks.OpenTelemetry --version 4.0.0-dev-00313
```
Then add the following code block after defining the builder variable in `Program.cs`:
```csharp
builder.AddServiceDefaults();
builder.AddRedisClient("redis");
```
Then add the following code to the `PreConfigureServices` method in the `AspirationalAbpWebModule` class:
```bash
var configuration = context.Services.GetConfiguration();
configuration["Redis:Configuration"] = configuration["ConnectionStrings:Redis"];
```
To use the **OpenTelemetry** sink we have installed the `Serilog.Sinks.OpenTelemetry` package and now let's enable the sink. For this, let's write the following code block just before calling the `CreateLogger` method in logger configuration in `Program.cs`:
```csharp
/// .WriteTo.Async(c => c.Console())
.WriteTo.Async(c => c.OpenTelemetry())
/// .CreateLogger();
```
After making all our changes, we can run the `AspirationalAbp.AppHost` project.
![aspire-dashboard](aspire-dashboard.png)
![aspire-structured-logs](aspire-structured-logs.png)
![aspire-traces](aspire-traces.png)
![aspire-metrics](aspire-metrics.png)
## Conclusion
Combining .NET Aspire with the ABP framework creates a powerful setup for building robust, observable, and feature-rich applications. By integrating Aspire's observability and cloud capabilities with ABP's approach of focusing on your business without repeating yourself, you can develop feature-rich, scalable applications with enhanced monitoring and seamless cloud integration. This guide provides a clear path to set up and configure these technologies, ensuring your applications are well-structured, maintainable, and ready for modern cloud environments.

BIN
docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-dashboard.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

BIN
docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-metrics.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

BIN
docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-structured-logs.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

BIN
docs/en/Community-Articles/2024-06-27-how-to-use-Aspire-with-ABP-framework/aspire-traces.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

130
docs/en/Community-Articles/2024-07-01-Use_User-Defined_Function_Mapping_For_Global_Filter/POST.md

@ -0,0 +1,130 @@
# Use User-Defined Function Mapping for Global Filter
## Introduction
ABP provides data filters that can filter queries automatically based on some rules. This feature is useful for implementing multi-tenancy, soft delete, and other global filters. It uses [EF Core's Global Query Filters system](https://learn.microsoft.com/en-us/ef/core/querying/filters) for the EF Core Integration.
EF Core Global Query Filters generate filter conditions and apply them to SQL queries. ABP controls whether this filter condition takes effect through a variable. However, this variable may cause performance losses in some scenarios.
## The Filter Condition Variable
Think of a scenario with a global filter `IIsActive`, which filters out inactive entities:
```csharp
public class Book : IIsActive
{
public string Name { get; set; }
public bool IsActive { get; set; }
}
```
The SQL generated by the [EF Core Global Query Filters](https://learn.microsoft.com/en-us/ef/core/querying/filters) is as follows:
```SQL
SELECT * FROM [AppBooks] AS [a]
WHERE (@__ef_filter__p_0 = CAST(1 AS bit) OR [a].[IsActive] = CAST(1 AS bit))
```
> The `__ef_filter__p_0` variable controls whether the filter condition takes effect.
The generated SQL is not optimal, and some databases do not optimize it well.
## Using User-defined function mapping for global filters
In the [upcoming preview version of ABP, v8.3.0-rc.1](https://github.com/abpframework/abp/pull/20065), we start the [User-defined function mapping](https://learn.microsoft.com/en-us/ef/core/querying/user-defined-function-mapping) to implement global filters more efficiently. This feature is enabled by default, so you don't need to make any changes if you create a new solution and start from scratch. Otherwise, you can enable it easily by following the instructions below.
To use this new feature for your custom global filters, you need to change your `DbContext` as follows:
````csharp
protected bool IsActiveFilterEnabled => DataFilter?.IsEnabled<IIsActive>() ?? false;
protected override bool ShouldFilterEntity<TEntity>(IMutableEntityType entityType)
{
if (typeof(IIsActive).IsAssignableFrom(typeof(TEntity)))
{
return true;
}
return base.ShouldFilterEntity<TEntity>(entityType);
}
protected override Expression<Func<TEntity, bool>> CreateFilterExpression<TEntity>(ModelBuilder modelBuilder)
{
var expression = base.CreateFilterExpression<TEntity>(modelBuilder);
if (typeof(IIsActive).IsAssignableFrom(typeof(TEntity)))
{
Expression<Func<TEntity, bool>> isActiveFilter = e => !IsActiveFilterEnabled || EF.Property<bool>(e, "IsActive");
if (UseDbFunction())
{
isActiveFilter = e => IsActiveFilter(((IIsActive)e).IsActive, true);
var abpEfCoreCurrentDbContext = this.GetService<AbpEfCoreCurrentDbContext>();
modelBuilder.HasDbFunction(typeof(MyProjectNameDbContext).GetMethod(nameof(IsActiveFilter))!)
.HasTranslation(args =>
{
// (bool isActive, bool boolParam)
var isActive = args[0];
var boolParam = args[1];
if (abpEfCoreCurrentDbContext.Context?.DataFilter.IsEnabled<IIsActive>() == true)
{
// isActive == true
return new SqlBinaryExpression(
ExpressionType.Equal,
isActive,
new SqlConstantExpression(Expression.Constant(true), boolParam.TypeMapping),
boolParam.Type,
boolParam.TypeMapping);
}
// empty where sql
return new SqlConstantExpression(Expression.Constant(true), boolParam.TypeMapping);
});
}
expression = expression == null ? isActiveFilter : QueryFilterExpressionHelper.CombineExpressions(expression, isActiveFilter);
}
return expression;
}
public static bool IsActiveFilter(bool isActive, bool boolParam)
{
throw new NotSupportedException(AbpEfCoreDataFilterDbFunctionMethods.NotSupportedExceptionMessage);
}
public override string GetCompiledQueryCacheKey()
{
return $"{base.GetCompiledQueryCacheKey()}:{IsActiveFilterEnabled}";
}
````
After these changes, the SQL generated by the EF Core Global Query Filters will be as follows:
Enabling the `IIsActive` filter:
```SQL
SELECT * FROM [AppBooks] AS [a] WHERE
[a].[IsActive] = CAST(1 AS bit)
```
Disabling the `IIsActive` filter:
```SQL
SELECT * FROM [AppBooks] AS [a]
```
## Conclusion
We have implemented global filters using [User-defined function mapping](https://learn.microsoft.com/en-us/ef/core/querying/user-defined-function-mapping), which can generate more efficient SQL and thus improve performance.
Upgrade to the latest ABP version and enjoy the performance improvement!
## References
- [ABP Framework Data Filtering](https://docs.abp.io/en/abp/latest/Data-Filtering)
- [EF Core's Global Query Filters system](https://learn.microsoft.com/en-us/ef/core/querying/filters)
- [User-defined function mapping](https://learn.microsoft.com/en-us/ef/core/querying/user-defined-function-mapping)

17
docs/en/Contribution/Index.md

@ -29,23 +29,6 @@ You may want to fix a known bug or work on a planned enhancement. See [the issue
If you have a feature idea for the framework or modules, [create an issue](https://github.com/abpframework/abp/issues/new) on Github or attend to an existing discussion. Then you can implement it if it's embraced by the community.
## Document Translation
You may want to translate the complete [documentation](https://docs.abp.io) (including this one) to your mother language. If so, follow these steps:
* Clone the [ABP repository](https://github.com/abpframework/abp/) from Github.
* To add a new language, create a new folder inside the [docs](https://github.com/abpframework/abp/tree/master/docs) folder. Folder names can be "en", "es", "fr", "tr" and so on based on the language (see [all culture codes](https://msdn.microsoft.com/en-us/library/hh441729.aspx)).
* Get the ["en" folder](https://github.com/abpframework/abp/tree/master/docs/en) as a reference for the file names and folder structure. Keep the same naming if you are translating the same documentation.
* Send a pull request (PR) once you translate any document. Please translate documents & send PRs one by one. Don't wait to finish translations for all documents.
There are some fundamental documents need to be translated before publishing a language on the [ABP documentation web site](https://docs.abp.io):
* Index (Home)
* Getting Started
* Web Application Development Tutorial
A new language is published after these minimum translations have been completed.
## Resource Localization
ABP framework has a flexible [localization system](../Localization.md). You can create localized user interfaces for your own application.

83
docs/en/Data-Filtering.md

@ -217,17 +217,14 @@ protected override bool ShouldFilterEntity<TEntity>(IMutableEntityType entityTyp
return base.ShouldFilterEntity<TEntity>(entityType);
}
protected override Expression<Func<TEntity, bool>> CreateFilterExpression<TEntity>()
protected override Expression<Func<TEntity, bool>> CreateFilterExpression<TEntity>(ModelBuilder modelBuilder)
{
var expression = base.CreateFilterExpression<TEntity>();
var expression = base.CreateFilterExpression<TEntity>(modelBuilder);
if (typeof(IIsActive).IsAssignableFrom(typeof(TEntity)))
{
Expression<Func<TEntity, bool>> isActiveFilter =
e => !IsActiveFilterEnabled || EF.Property<bool>(e, "IsActive");
expression = expression == null
? isActiveFilter
: QueryFilterExpressionHelper.CombineExpressions(expression, isActiveFilter);
Expression<Func<TEntity, bool>> isActiveFilter = e => !IsActiveFilterEnabled || EF.Property<bool>(e, "IsActive");
expression = expression == null ? isActiveFilter : QueryFilterExpressionHelper.CombineExpressions(expression, isActiveFilter);
}
return expression;
@ -251,6 +248,78 @@ protected override void OnModelCreating(ModelBuilder modelBuilder)
}
````
#### Using User-defined function mapping for global filters
Using [User-defined function mapping](https://learn.microsoft.com/en-us/ef/core/querying/user-defined-function-mapping) for global filters will gain performance improvements.
To use this feature, you need to change your DbContext like below:
````csharp
protected bool IsActiveFilterEnabled => DataFilter?.IsEnabled<IIsActive>() ?? false;
protected override bool ShouldFilterEntity<TEntity>(IMutableEntityType entityType)
{
if (typeof(IIsActive).IsAssignableFrom(typeof(TEntity)))
{
return true;
}
return base.ShouldFilterEntity<TEntity>(entityType);
}
protected override Expression<Func<TEntity, bool>> CreateFilterExpression<TEntity>(ModelBuilder modelBuilder)
{
var expression = base.CreateFilterExpression<TEntity>(modelBuilder);
if (typeof(IIsActive).IsAssignableFrom(typeof(TEntity)))
{
Expression<Func<TEntity, bool>> isActiveFilter = e => !IsActiveFilterEnabled || EF.Property<bool>(e, "IsActive");
if (UseDbFunction())
{
isActiveFilter = e => IsActiveFilter(((IIsActive)e).IsActive, true);
var abpEfCoreCurrentDbContext = this.GetService<AbpEfCoreCurrentDbContext>();
modelBuilder.HasDbFunction(typeof(MyProjectNameDbContext).GetMethod(nameof(IsActiveFilter))!)
.HasTranslation(args =>
{
// (bool isActive, bool boolParam)
var isActive = args[0];
var boolParam = args[1];
if (abpEfCoreCurrentDbContext.Context?.DataFilter.IsEnabled<IIsActive>() == true)
{
// isActive == true
return new SqlBinaryExpression(
ExpressionType.Equal,
isActive,
new SqlConstantExpression(Expression.Constant(true), boolParam.TypeMapping),
boolParam.Type,
boolParam.TypeMapping);
}
// empty where sql
return new SqlConstantExpression(Expression.Constant(true), boolParam.TypeMapping);
});
}
expression = expression == null ? isActiveFilter : QueryFilterExpressionHelper.CombineExpressions(expression, isActiveFilter);
}
return expression;
}
public static bool IsActiveFilter(bool isActive, bool boolParam)
{
throw new NotSupportedException(AbpEfCoreDataFilterDbFunctionMethods.NotSupportedExceptionMessage);
}
public override string GetCompiledQueryCacheKey()
{
return $"{base.GetCompiledQueryCacheKey()}:{IsActiveFilterEnabled}";
}
````
### MongoDB
ABP abstracts the `IMongoDbRepositoryFilterer` interface to implement data filtering for the [MongoDB Integration](MongoDB.md), it works only if you use the repositories properly. Otherwise, you should manually filter the data.

10
docs/en/Modules/Docs.md

@ -34,7 +34,7 @@ abp new Acme.MyProject
### 2- Running The Empty Application
After you download the project, extract the ZIP file and open `Acme.MyProject.sln`. You will see that the solution consists of `Application`, `Application.Contracts`, `DbMigrator`, `Domain`, `Domain.Shared`, `EntityFrameworkCore`, `HttpApi`, `HttpApi.Client` and `Web` projects. Right click on `Acme.MyProject.Web` project and **Set as StartUp Project**.
After you created the project, open `Acme.MyProject.sln`. You will see that the solution consists of `Application`, `Application.Contracts`, `DbMigrator`, `Domain`, `Domain.Shared`, `EntityFrameworkCore`, `HttpApi`, `HttpApi.Client` and `Web` projects. Right click on `Acme.MyProject.Web` project and **Set as StartUp Project**.
![Create a new project](../images/docs-module_solution-explorer.png)
@ -332,7 +332,7 @@ Open `DocsProjects` in your database, and insert a new record with the following
* **DocumentStoreType**: The source of the documents (for GitHub:`GitHub`, for file system`FileSystem`)
* **ExtraProperties**: A serialized `JSON` that stores special configuration for the selected `DocumentStoreType`.
* **MainWebsiteUrl**: The URL when user clicks to the logo of the Docs module page. You can simply set as `/` to link to your website root address.
* **LatestVersionBranchName**: This is a config for GitHub. It's the branch name which to retrieve the docs. You can set it as `master`.
* **LatestVersionBranchName**: This is a config for GitHub. It's the branch name which to retrieve the docs. You can set it as `dev`.
#### Sample Project Record for "GitHub"
@ -367,7 +367,7 @@ You can use [ABP Framework](https://github.com/abpframework/abp/) GitHub documen
For `SQL` databases, you can use the below `T-SQL` command to insert the specified sample into your `DocsProjects` table:
```mssql
INSERT [dbo].[DocsProjects] ([Id], [Name], [ShortName], [Format], [DefaultDocumentName], [NavigationDocumentName], [MinimumVersion], [DocumentStoreType], [ExtraProperties], [MainWebsiteUrl], [LatestVersionBranchName], [ParametersDocumentName], [ConcurrencyStamp]) VALUES (N'12f21123-e08e-4f15-bedb-ae0b2d939659', N'ABP framework (FileSystem)', N'abp', N'md', N'Index', N'docs-nav.json', NULL, N'FileSystem', N'{"Path":"C:\\Github\\abp\\docs"}', N'/', NULL, N'', N'12f21123e08e4f15bedbae0b2d939659')
INSERT [dbo].[DocsProjects] ([Id], [Name], [ShortName], [Format], [DefaultDocumentName], [NavigationDocumentName], [MinimumVersion], [DocumentStoreType], [ExtraProperties], [MainWebsiteUrl], [LatestVersionBranchName], [ParametersDocumentName], [ConcurrencyStamp]) VALUES (N'12f21123-e08e-4f15-bedb-ae0b2d939658', N'ABP framework (GitHub)', N'abp', N'md', N'Index', N'docs-nav.json', NULL, N'GitHub', N'{"GitHubRootUrl":"https://github.com/abpframework/abp/tree/{version}/docs","GitHubAccessToken":"","GitHubUserAgent":""}', N'/', N'dev', N'', N'12f21123e08e4f15bedbae0b2d939659')
```
Be aware that `GitHubAccessToken` is masked. It's a private token and you must get your own token and replace the `***` string.
@ -402,12 +402,12 @@ You can use [ABP Framework](https://github.com/abpframework/abp/) GitHub documen
- MainWebsiteUrl: `/`
- LatestVersionBranchName: `<NULL>`
- LatestVersionBranchName: `latest`
For `SQL` databases, you can use the below `T-SQL` command to insert the specified sample into your `DocsProjects` table:
```mssql
INSERT [dbo].[DocsProjects] ([Id], [Name], [ShortName], [Format], [DefaultDocumentName], [NavigationDocumentName], [MinimumVersion], [DocumentStoreType], [ExtraProperties], [MainWebsiteUrl], [LatestVersionBranchName], [ParametersDocumentName]) VALUES (N'12f21123-e08e-4f15-bedb-ae0b2d939659', N'ABP framework (FileSystem)', N'abp', N'md', N'Index', N'docs-nav.json', NULL, N'FileSystem', N'{"Path":"C:\\Github\\abp\\docs"}', N'/', NULL, N'')
INSERT [dbo].[DocsProjects] ([Id], [Name], [ShortName], [Format], [DefaultDocumentName], [NavigationDocumentName], [MinimumVersion], [DocumentStoreType], [ExtraProperties], [MainWebsiteUrl], [LatestVersionBranchName], [ParametersDocumentName], [ConcurrencyStamp]) VALUES (N'12f21123-e08e-4f15-bedb-ae0b2d939659', N'ABP framework (FileSystem)', N'abp', N'md', N'Index', N'docs-nav.json', NULL, N'FileSystem', N'{"Path":"C:\\Github\\abp\\docs"}', N'/', N'latest', N'', N'12f21123e08e4f15bedbae0b2d939659')
```
Add one of the sample projects above and run the application. In the menu you will see `Documents` link, click the menu link to open the documents page.

16
docs/en/Road-Map.md

@ -4,17 +4,17 @@ This document provides a road map, release schedule, and planned features for th
## Next Versions
### v8.2
### v8.3
The next version will be 8.2 and planned to release the stable 8.2 version in June 2024. We will be mostly working on the following topics:
The next version will be 8.3 and planned to release the stable 8.3 version in August 2024. We will be mostly working on the following topics:
* Blazor Full-Stack UI ([#18289](https://github.com/abpframework/abp/issues/18289))
* Angular Universal ([#15782](https://github.com/abpframework/abp/issues/15782))
* Upgrading React Native template to the latest major release 0.72.7 ([#18191](https://github.com/abpframework/abp/issues/18191))
* Deployment Documents Improvements ([#15034](https://github.com/abpframework/abp/issues/15034))
* Angular generate-proxy root namespace options ([#18932](https://github.com/abpframework/abp/issues/18932))
* Blazor global JS & CSS at runtime ([#19963](https://github.com/abpframework/abp/issues/19963))
* CMS Kit - Improvement in editing approval system for comments ([#19976](https://github.com/abpframework/abp/issues/19976))
* Improvements on the existing features and provide more guides.
See the [8.2 milestone](https://github.com/abpframework/abp/milestone/95) for all the issues we've planned to work on.
See the [8.3 milestone](https://github.com/abpframework/abp/milestone/101) for all the issues we've planned to work on.
## Backlog Items
@ -23,7 +23,7 @@ The *Next Versions* section above shows the main focus of the planned versions.
Here is a list of major items in the backlog we are considering working on in the next versions.
* [#86](https://github.com/abpframework/abp/issues/86) / GrapQL Integration
* [#236](https://github.com/abpframework/abp/issues/236) / Resource based authorization system
* [#236](https://github.com/abpframework/abp/issues/236) / Resource-based authorization system
* [#2882](https://github.com/abpframework/abp/issues/2882) / Providing a gRPC integration infrastructure (while it is [already possible](https://github.com/abpframework/abp-samples/tree/master/GrpcDemo) to create or consume gRPC endpoints for your application, we plan to create endpoints for the [standard application modules](https://docs.abp.io/en/abp/latest/Modules/Index))
* [#57](https://github.com/abpframework/abp/issues/57) / Built-in CQRS infrastructure
* [#4223](https://github.com/abpframework/abp/issues/4223) / WebHook system
@ -35,7 +35,7 @@ Here is a list of major items in the backlog we are considering working on in th
* [#16756](https://github.com/abpframework/abp/issues/16756) / Blob Storing - Provider configuration UI
* [#16744](https://github.com/abpframework/abp/issues/16744) / State Management API
You can always check the milestone planning and the prioritized backlog issues on [the GitHub repository](https://github.com/abpframework/abp/milestones) for a detailed road map. The backlog items are subject to change. We are adding new items and changing priorities based on the community feedbacks and goals of the project.
You can always check the milestone planning and the prioritized backlog issues on [the GitHub repository](https://github.com/abpframework/abp/milestones) for a detailed road map. The backlog items are subject to change. We are adding new items and changing priorities based on the community feedback and goals of the project.
## Feature Requests

4
docs/en/UI/AspNetCore/Static-JavaScript-Proxies.md

@ -66,7 +66,7 @@ acme.bookStore.authors.author.get = function(id, ajaxParams) {
};
````
> `generate-proxy` command generates proxies for only the APIs you've defined in your application (assumes `app` as the module name). If you are developing a modular application, you can specify the `-m` (or `--module`) parameter to specify the module you want to generate proxies. See the *generate-proxy* section in the [ABP CLI](../CLI.md) documentation for other options.
> `generate-proxy` command generates proxies for only the APIs you've defined in your application (assumes `app` as the module name). If you are developing a modular application, you can specify the `-m` (or `--module`) parameter to specify the module you want to generate proxies. See the *generate-proxy* section in the [ABP CLI](../../CLI.md) documentation for other options.
### Using the Proxy Functions
@ -154,4 +154,4 @@ See the [jQuery.ajax](https://api.jquery.com/jQuery.ajax/) documentation for all
* [Dynamic JavaScript API Client Proxies](Dynamic-JavaScript-Proxies.md)
* [Auto API Controllers](../../API/Auto-API-Controllers.md)
* [Web Application Development Tutorial](../../Tutorials/Part-1.md)
* [Web Application Development Tutorial](../../Tutorials/Part-1.md)

4
docs/en/UI/Blazor/Pwa-Configuration.md

@ -59,7 +59,7 @@ First, you need to create a JSON file named **manifest.json** under the **wwwroo
You can add some icons for your application to be seen in specific screen sizes and define in which screen sizes icons should be displayed in the **manifest.json** file. You can see the **icons** section in the **manifest.json** file as an example above.
> You can use, default icons from our [template](https://github.com/abpframework/abp/tree/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor/wwwroot).
> You can use, default icons from our [template](https://github.com/abpframework/abp/tree/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor.Client/wwwroot).
### 3-) Configure Service Workers
@ -67,7 +67,7 @@ You can add some icons for your application to be seen in specific screen sizes
You need to create `service-worker.js` and `service-worker.published.js` files under the **wwwroot** folder of your project. These files will be used by your project to determine which PWA features you want to use.
You can get the simple configurations for the [service-worker.js](https://github.com/abpframework/abp/blob/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor/wwwroot/service-worker.js) and [service-worker.published.js](https://github.com/abpframework/abp/blob/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor/wwwroot/service-worker.published.js) files from our [template](https://github.com/abpframework/abp/tree/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor/wwwroot).
You can get the simple configurations for the [service-worker.js](https://github.com/abpframework/abp/tree/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor.Client/wwwroot/service-worker.js) and [service-worker.published.js](https://github.com/abpframework/abp/tree/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor.Client/wwwroot/service-worker.published.js) files from our [template](https://github.com/abpframework/abp/tree/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.Blazor.Client/wwwroot).
After the related service worker files are added, then we need to define them in our `.csproj` file to notify our application. So open your `*.csproj` file and add the following content:

BIN
docs/en/images/book-mastering-abp-framework.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 244 KiB

After

Width:  |  Height:  |  Size: 74 KiB

BIN
docs/en/images/cmskit-module-comments-settings.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 11 KiB

BIN
docs/en/images/db-options.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 10 KiB

BIN
docs/en/images/ddd-microservice-simple.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 41 KiB

After

Width:  |  Height:  |  Size: 60 KiB

BIN
docs/en/images/ui-options.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 41 KiB

140
docs/es/Getting-Started-AspNetCore-Application.md

@ -1,140 +0,0 @@
# Empezando con ABP y una Aplicacion AspNet Core MVC Web
Este tutorial explica como empezar una aplicacion ABP desde cero usando las dependencias minimas. Uno generalmente desea
empezar con la **[plantilla de inicio](Getting-Started-AspNetCore-MVC-Template.md)**.
## Crea un Proyecto Nuevo
1. Crea una Aplicacion Web AspNet Core nueva usando Visual Studio 2022 (17.0.0+):
![](images/create-new-aspnet-core-application-v2.png)
2. Configura el nuevo proyecto:
![](images/select-empty-web-application-v2.png)
3. Presione el boton Create:
![create-aspnet-core-application](images/create-aspnet-core-application.png)
## Instale el paquete Volo.Abp.AspNetCore.Mvc
Volo.Abp.AspNetCore.Mvc es el paquete de integracion con AspNet Core MVC para ABP. Siendo asi, instalalo en su proyecto:
````
Install-Package Volo.Abp.AspNetCore.Mvc
````
## Crea el primer modulo ABP
ABP es un marco de referencia modular y require una clase de **inicio (raíz) tipo modulo** derivada de ``AbpModule``:
````C#
using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.Hosting;
using Volo.Abp;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.Modularity;
namespace BasicAspNetCoreApplication
{
[DependsOn(typeof(AbpAspNetCoreMvcModule))]
public class AppModule : AbpModule
{
public override void OnApplicationInitialization(ApplicationInitializationContext context)
{
var app = context.GetApplicationBuilder();
var env = context.GetEnvironment();
// Configura la canalización de peticiones HTTP.
if (env.IsDevelopment())
{
app.UseExceptionHandler("/Error");
// El valor por defecto de HSTS es 30 dias. Debes cambiar esto en ambientes productivos. Referencia https://aka.ms/aspnetcore-hsts.
app.UseHsts();
}
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseRouting();
app.UseConfiguredEndpoints();
}
}
}
````
``AppModule`` es un buen nombre para el modulo de inicio de una aplicacion.
Los paquetes de ABP definen clases de tipo modulo y cada modulo puede depender de otro.
En el codigo anterior, el ``AppModule`` depende de el modulo ``AbpAspNetCoreMvcModule`` (definido por el paquete [Volo.Abp.AspNetCore.Mvc](https://www.nuget.org/packages/Volo.Abp.AspNetCore.Mvc)). Es comun agregar el atributo ``DependsOn`` despues de instalar un paquete ABP nuevo.
En vez de la clase de inicion Startup, estamos configurando una canalizacion de ASP.NET Core en este modulo.
## La clase Program
El proximo paso es modificar la clase Program para integrate el sistema de modulos ABP:
````C#
using BasicAspNetCoreApplication;
var builder = WebApplication.CreateBuilder(args);
await builder.Services.AddApplicationAsync<AppModule>();
var app = builder.Build();
await app.InitializeApplicationAsync();
await app.RunAsync();
````
``builder.Services.AddApplicationAsync<AppModule>();`` Agrega todos los servicios definidos en todos los modulos empezando desde ``AppModule``.
``app.InitializeApplicationAsync()`` inicializa y empieza la aplicacion.
## Ejecutar la Aplicación
Es todo! Ejecuta la aplicación, debe funcionar como esperado.
## Uso de Autofac como Marco de Inyección de Dependencia
Mientras el sistema de Inyección de Dependencia de ASP.NET Core es suficiente para requerimientos basico, [Autofac](https://autofac.org/) proporciona características avanzadas como Inyección de Propiedades e Intercepcion de Metodos, los cuales son necesarios para que ABP pueda llevar a cabo funciones avanzadas.
El acto de remplazar el sistema DI de ASP.NET Core por Autofac e integrarlo con ABP es facil.
1. Instala el paquete [Volo.Abp.Autofac](https://www.nuget.org/packages/Volo.Abp.Autofac)
````
Install-Package Volo.Abp.Autofac
````
2. Agrega la dependencia sobre el modulo ``AbpAutofacModule``
````C#
[DependsOn(typeof(AbpAspNetCoreMvcModule))]
[DependsOn(typeof(AbpAutofacModule))] //Agrega la dependencia sobre el modulo ABP Autofac
public class AppModule : AbpModule
{
...
}
````
3. Actualiza `Program.cs` para que use Autofac:
````C#
using BasicAspNetCoreApplication;
var builder = WebApplication.CreateBuilder(args);
builder.Host.UseAutofac(); //Agrega esta linea
await builder.Services.AddApplicationAsync<AppModule>();
var app = builder.Build();
await app.InitializeApplicationAsync();
await app.RunAsync();
````
## Codigo fuente
Obten el codigo fuente del ejemplo creado en este tutorial de [aqui](https://github.com/abpframework/abp-samples/tree/master/BasicAspNetCoreApplication).

Some files were not shown because too many files changed in this diff

Loading…
Cancel
Save