Browse Source

Merge branch 'dev' into blazor-full-stack-web-ui

pull/18876/head
maliming 3 years ago
parent
commit
148eebcb49
No known key found for this signature in database GPG Key ID: A646B9CB645ECEA4
  1. 16
      Directory.Packages.props
  2. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/en.json
  3. 40
      abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/en.json
  4. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/ar.json
  5. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/cs.json
  6. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/de.json
  7. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/en-GB.json
  8. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/en.json
  9. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/es.json
  10. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/fi.json
  11. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/fr.json
  12. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/hi.json
  13. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/hr.json
  14. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/hu.json
  15. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/is.json
  16. 1
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/it.json
  17. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/nl.json
  18. 5
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/pl-PL.json
  19. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/pt-BR.json
  20. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/ro-RO.json
  21. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/ru.json
  22. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/sk.json
  23. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/sl.json
  24. 4
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/tr.json
  25. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/vi.json
  26. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/zh-Hans.json
  27. 3
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/zh-Hant.json
  28. 4
      docs/en/API/Auto-API-Controllers.md
  29. 239
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/POST.md
  30. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/basic-aggregate-root.png
  31. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/bulk-delete-datatable.png
  32. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/bulk-delete.png
  33. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/cover-image.png
  34. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/dotnet-conf-china-2023-watch-party.jpg
  35. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/filterable-properties.png
  36. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/ndc-london-2024.png
  37. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/page-title.png
  38. BIN
      docs/en/Blog-Posts/2024-02-16 v8_1_Preview/suite-include-entities-from-abp-modules.png
  39. 19
      docs/en/Getting-Started-Create-Solution.md
  40. 10
      docs/en/Getting-Started-Running-Solution-Single-Layer.md
  41. 17
      docs/en/Getting-Started-Running-Solution.md
  42. 16
      docs/en/Getting-Started-Setup-Environment-Single-Layer.md
  43. 15
      docs/en/Getting-Started-Setup-Environment.md
  44. 2
      docs/en/Integration-Services.md
  45. 2
      docs/en/Migration-Guides/Abp-8_0.md
  46. 61
      docs/en/Migration-Guides/Abp-8_1.md
  47. 1
      docs/en/Migration-Guides/Index.md
  48. 2
      docs/en/Modules/Docs.md
  49. 28
      docs/en/MongoDB.md
  50. 18
      docs/en/Road-Map.md
  51. 16
      docs/en/Tutorials/Part-1.md
  52. 11
      docs/en/Tutorials/Part-10.md
  53. 18
      docs/en/Tutorials/Part-2.md
  54. 18
      docs/en/Tutorials/Part-3.md
  55. 21
      docs/en/Tutorials/Part-4.md
  56. 21
      docs/en/Tutorials/Part-5.md
  57. 21
      docs/en/Tutorials/Part-6.md
  58. 21
      docs/en/Tutorials/Part-7.md
  59. 19
      docs/en/Tutorials/Part-8.md
  60. 21
      docs/en/Tutorials/Part-9.md
  61. 13
      docs/en/UI/Angular/Authorization.md
  62. 2
      docs/en/UI/Angular/Localization.md
  63. 4
      docs/zh-Hans/API/Auto-API-Controllers.md
  64. 28
      docs/zh-Hans/MongoDB.md
  65. 10
      framework/src/Volo.Abp.AspNetCore.Mvc.Client/Volo/Abp/AspNetCore/Mvc/Client/MvcRemoteTenantStore.cs
  66. 5
      framework/src/Volo.Abp.AspNetCore.Mvc.Contracts/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/ApplicationLocalizationDto.cs
  67. 29
      framework/src/Volo.Abp.AspNetCore.Mvc.Contracts/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/CurrentCultureDto.cs
  68. 2
      framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared/wwwroot/libs/abp/aspnetcore-mvc-ui-theme-shared/datatables/datatables-extensions.js
  69. 11
      framework/src/Volo.Abp.AspNetCore.Mvc/Volo/Abp/AspNetCore/Mvc/AbpAspNetCoreMvcModule.cs
  70. 23
      framework/src/Volo.Abp.AspNetCore.Mvc/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/AbpApplicationConfigurationAppService.cs
  71. 19
      framework/src/Volo.Abp.AspNetCore.Mvc/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/AbpApplicationLocalizationAppService.cs
  72. 89
      framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/ProjectBuilding/AbpIoSourceCodeStore.cs
  73. 8
      framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/ProjectBuilding/Templates/Microservice/MicroserviceTemplateBase.cs
  74. 15
      framework/src/Volo.Abp.Core/Volo/Abp/DynamicProxy/DynamicProxyIgnoreTypes.cs
  75. 8
      framework/src/Volo.Abp.Core/Volo/Abp/DynamicProxy/ProxyHelper.cs
  76. 2
      framework/src/Volo.Abp.EntityFrameworkCore/Volo/Abp/EntityFrameworkCore/AbpDbContext.cs
  77. 9
      framework/src/Volo.Abp.Json.SystemTextJson/Volo/Abp/Json/SystemTextJson/JsonConverters/AbpDateTimeConverter.cs
  78. 9
      framework/src/Volo.Abp.Json.SystemTextJson/Volo/Abp/Json/SystemTextJson/JsonConverters/AbpNullableDateTimeConverter.cs
  79. 9
      framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/IHasCreateCollectionOptions.cs
  80. 10
      framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/IHasMongoIndexManagerAction.cs
  81. 10
      framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/IMongoEntityModelBuilder.cs
  82. 15
      framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/MongoEntityModelBuilder.cs
  83. 25
      framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/MongoModelBuilder.cs
  84. 29
      framework/test/Volo.Abp.AspNetCore.Mvc.Tests/Volo/Abp/AspNetCore/Mvc/AbpAspNetCoreMvcTestModule.cs
  85. 21
      framework/test/Volo.Abp.AspNetCore.Mvc.Tests/Volo/Abp/AspNetCore/Mvc/ConventionalController_Tests.cs
  86. 52
      framework/test/Volo.Abp.Json.Tests/Volo/Abp/Json/AbpDateTimeConverter_Tests.cs
  87. 25
      framework/test/Volo.Abp.Json.Tests/Volo/Abp/Json/AbpStringToBoolean_Tests.cs
  88. 95
      framework/test/Volo.Abp.Json.Tests/Volo/Abp/Json/AbpStringToEnum_Tests.cs
  89. 13
      framework/test/Volo.Abp.MongoDB.Tests/Volo/Abp/MongoDB/Repositories/Repository_Basic_Tests.cs
  90. 8
      framework/test/Volo.Abp.MongoDB.Tests/Volo/Abp/TestApp/MongoDb/TestAppMongoDbContext.cs
  91. 17
      framework/test/Volo.Abp.TestApp/Volo/Abp/TestApp/Application/ConventionalAppService.cs
  92. 9
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/package.json
  93. 4616
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/css/all.css
  94. 2172
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/css/v4-shims.css
  95. 0
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.eot
  96. 0
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.svg
  97. BIN
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.ttf
  98. 0
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.woff
  99. BIN
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.woff2
  100. 0
      modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-regular-400.eot

16
Directory.Packages.props

@ -103,26 +103,26 @@
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageVersion Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="8.0.0" />
<PackageVersion Include="Microsoft.SourceLink.GitHub" Version="1.1.1" />
<PackageVersion Include="Minio" Version="6.0.1" />
<PackageVersion Include="Minio" Version="6.0.2" />
<PackageVersion Include="MongoDB.Driver" Version="2.22.0" />
<PackageVersion Include="NEST" Version="7.17.5" />
<PackageVersion Include="Newtonsoft.Json" Version="13.0.3" />
<PackageVersion Include="Nito.AsyncEx.Context" Version="5.1.2" />
<PackageVersion Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="8.0.0" />
<PackageVersion Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="8.0.2" />
<PackageVersion Include="NSubstitute" Version="5.1.0" />
<PackageVersion Include="NuGet.Versioning" Version="6.7.0" />
<PackageVersion Include="NUglify" Version="1.21.0" />
<PackageVersion Include="Nullable" Version="1.3.1" />
<PackageVersion Include="Octokit" Version="9.0.0" />
<PackageVersion Include="OpenIddict.Abstractions" Version="5.1.0" />
<PackageVersion Include="OpenIddict.Core" Version="5.1.0" />
<PackageVersion Include="OpenIddict.Server.AspNetCore" Version="5.1.0" />
<PackageVersion Include="OpenIddict.Validation.AspNetCore" Version="5.1.0" />
<PackageVersion Include="OpenIddict.Validation.ServerIntegration" Version="5.1.0" />
<PackageVersion Include="OpenIddict.Abstractions" Version="5.2.0" />
<PackageVersion Include="OpenIddict.Core" Version="5.2.0" />
<PackageVersion Include="OpenIddict.Server.AspNetCore" Version="5.2.0" />
<PackageVersion Include="OpenIddict.Validation.AspNetCore" Version="5.2.0" />
<PackageVersion Include="OpenIddict.Validation.ServerIntegration" Version="5.2.0" />
<PackageVersion Include="Oracle.EntityFrameworkCore" Version="8.21.121" />
<PackageVersion Include="Polly" Version="8.2.0" />
<PackageVersion Include="Polly.Extensions.Http" Version="3.0.0" />
<PackageVersion Include="Pomelo.EntityFrameworkCore.MySql" Version="8.0.0-beta.2" />
<PackageVersion Include="Pomelo.EntityFrameworkCore.MySql" Version="8.0.0" />
<PackageVersion Include="Quartz" Version="3.7.0" />
<PackageVersion Include="Quartz.Extensions.DependencyInjection" Version="3.7.0" />
<PackageVersion Include="Quartz.Plugins.TimeZoneConverter" Version="3.7.0" />

3
abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/en.json

@ -238,6 +238,7 @@
"Packages": "Packages",
"Trainings": "Trainings",
"MeetTheABPCommunity": "Meet the ABP <span class=\"gradient-community\">Community</span>",
"DisplayName:CommunityIndexPagePoll": "Community Index Page Poll"
"DisplayName:CommunityIndexPagePoll": "Community Index Page Poll",
"ReturnOfInvestment": "Return Of Investment"
}
}

40
abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/en.json

@ -1142,6 +1142,44 @@
"DisplayName:CardHolderName": "Name on Card",
"CreditCardNumberLengthWarning": "Invalid card number",
"ExpirationWarning": "Invalid expiration date",
"CreateCreditCardModal_Description": "When saving your debit/credit card, a temporary $1 charge will be authorized for verification and promptly refunded."
"CreateCreditCardModal_Description": "When saving your debit/credit card, a temporary $1 charge will be authorized for verification and promptly refunded.",
"ReturnOfInvestmentTitle": "Return of <span class=\"gradient-commercial\">Investment</span>",
"ReduceYourDevelopmentCostsDescription": "Reduce your development costs by more than 50% with the ABP Framework. How? Keep reading...",
"SettingUpTheArchitectureTitle": "Setting Up the Architecture",
"DoingEverythingFromScratch": "Doing everything from scratch",
"SettingUpTheArchitecture_Description1": "Organize code base and solution structure",
"SettingUpTheArchitecture_Description2": "Determine, install and configure essential 3rd-party libraries",
"SettingUpTheArchitecture_Description3": "Setup automated integration and unit test infrastructure",
"SettingUpTheArchitecture_Description4": "Determine and document code standards, train the development team",
"UsingTheABPFramework": "Using the ABP Framework",
"UseABPSettingUpTheArchitecture_Description": "Use ABP's startup solution templates",
"ReduceCostsWithABP": "Reduce Costs with ABP by",
"ReduceCostsBy": "80% to 100%",
"DesigningTheUserInterfaceTitle": "Designing the User Interface",
"DesigningTheUserInterface_Description1": "Create or buy a UI theme",
"DesigningTheUserInterface_Description2": "Adapt the UI theme to the solution",
"DesigningTheUserInterface_Description3": "Build the essential UI parts (layout, menu, header, footer with responsive design)",
"DesigningTheUserInterface_Description4": "Ensure the design consistency across application pages",
"UseABPDesigningTheUserInterface_Description": "Use ABP's LeptonX UI Theme",
"DevelopingApplicationFeaturesTitle": "Developing the Application Features",
"DevelopingApplicationFeatures_Description1": "Develop your own business logic",
"DevelopingApplicationFeatures_Description2": "Develop every page one by one",
"DevelopingApplicationFeatures_Description3": "Develop common business modules yourself",
"DevelopingApplicationFeatures_Description4": "Develop the authentication system (single sign on, 2 factor auth, social logins, reset password, email activation, etc...)",
"DevelopingApplicationFeatures_Description5": "Apply cross-cutting concerns in every use case (DB transactions, authorization, validation, exception handling, etc...)",
"DevelopingApplicationFeatures_Description6": "Develop common base classes and utility services",
"DevelopingApplicationFeatures_Description7": "Develop common non-business requirements (audit logging, soft-delete, background jobs, permission system, etc.)",
"UseABPDevelopingApplicationFeatures_Description1": "Develop your own business logic",
"UseABPDevelopingApplicationFeatures_Description2": "Use ABP Suite to automatically generate CRUD-like pages",
"UseABPDevelopingApplicationFeatures_Description3": "Directly use ABP's pre-built common application modules and customize based on your unique requirements",
"ReduceCostsBy_2": "40% to 60%",
"WhyABPIoPlatform": "Why ABP.IO Platform?",
"WhyShouldYouUsetheABPIOPlatform": "Why should you use the ABP.IO Platform instead of creating a new solution from scratch?",
"ExploreMore": "Explore More",
"DocumentIntroducesDescription": "If you want to <b>learn more details</b> about why should you use the ABP.IO Platform instead of creating a new solution from scratch, read the following document: ",
"ReturnOfInvestmentPageAbout": "This page covers the fundamental steps of developing a software solution and explains how the ABP.IO Platform reduces your development costs at each step.",
"LearnMore": "Learn More",
"ReturnOfInvestment": "Return of Investment",
"ReturnOfInvestment_Description": "Learn how to reduce your development costs by more than %50."
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/ar.json

@ -467,6 +467,7 @@
"Title": "العنوان",
"TitlePlaceholder": "مطور برامج، مدير تكنولوجيا المعلومات، إلخ.",
"Characters": "الأحرف",
"ABPTestimonialDescription": "ABP Framework: دعونا نسمع شهادتك"
"ABPTestimonialDescription": "ABP Framework: دعونا نسمع شهادتك",
"LeaveUsReview": "ترك لنا المراجعة"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/cs.json

@ -467,6 +467,7 @@
"Title": "Titul",
"TitlePlaceholder": "Vývojář softwaru, CTO atd.",
"Characters": "znaky",
"ABPTestimonialDescription": "ABP Framework: Pojďme slyšet vaši referenci"
"ABPTestimonialDescription": "ABP Framework: Pojďme slyšet vaši referenci",
"LeaveUsReview": "Zanechte nám recenzi"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/de.json

@ -467,6 +467,7 @@
"Title": "Titel",
"TitlePlaceholder": "Softwareentwickler, CTO usw.",
"Characters": "zeichen",
"ABPTestimonialDescription": "ABP Framework: Lass uns deine Bewertung hören"
"ABPTestimonialDescription": "ABP Framework: Lass uns deine Bewertung hören",
"LeaveUsReview": "Hinterlassen Sie uns eine Bewertung"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/en-GB.json

@ -271,6 +271,7 @@
"DDDBookEmailBody": "Thank you. <br /> To download your book, <a href=\"{0}\">click here</a>.",
"SubscribeToNewsletter": "Subscribe to the newsletter to get information about happenings in the ABP.IO Platform, like new releases, posts, offers, and more.",
"FirstEdition": "First Edition",
"SelectUITheme": "Select UI Theme"
"SelectUITheme": "Select UI Theme",
"LeaveUsReview": "Leave us review"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/en.json

@ -478,6 +478,7 @@
"PasswordLength": "The field Password must be a string with a maximum length of 32.",
"PasswordRequired": "The Password field is required.",
"AddressLength": "The field Address must be a string with a maximum length of 255.",
"GenderRequired": "The Gender field is required."
"GenderRequired": "The Gender field is required.",
"LeaveUsReview": "Leave us review"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/es.json

@ -467,6 +467,7 @@
"Title": "Título",
"TitlePlaceholder": "Desarrollador de software, CTO, etc.",
"Characters": "caracteres",
"ABPTestimonialDescription": "ABP Framework: Escuchemos tu testimonio"
"ABPTestimonialDescription": "ABP Framework: Escuchemos tu testimonio",
"LeaveUsReview": "Déjanos tu reseña"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/fi.json

@ -467,6 +467,7 @@
"Title": "Titteli",
"TitlePlaceholder": "Ohjelmistokehittäjä, CTO, jne.",
"Characters": "hahmot",
"ABPTestimonialDescription": "ABP Framework: Kuunnellaanpa sinun suosittelua"
"ABPTestimonialDescription": "ABP Framework: Kuunnellaanpa sinun suosittelua",
"LeaveUsReview": "Jätä meille arvostelu"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/fr.json

@ -467,6 +467,7 @@
"Title": "Titre",
"TitlePlaceholder": "Développeur de logiciels, CTO, etc.",
"Characters": "caractères",
"ABPTestimonialDescription": "ABP Framework : Écoutons votre témoignage"
"ABPTestimonialDescription": "ABP Framework : Écoutons votre témoignage",
"LeaveUsReview": "Laissez-nous votre avis"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/hi.json

@ -467,6 +467,7 @@
"Title": "शीर्षक",
"TitlePlaceholder": "सॉफ़्टवेयर डेवेलपर, सीटीओ, आदि।",
"Characters": "अक्षर",
"ABPTestimonialDescription": "ABP Framework: आइए आपका प्रशंसापत्र सुनें"
"ABPTestimonialDescription": "ABP Framework: आइए आपका प्रशंसापत्र सुनें",
"LeaveUsReview": "हमें समीक्षा छोड़ें"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/hr.json

@ -467,6 +467,7 @@
"Title": "Naslov",
"TitlePlaceholder": "Razvojni inženjer, CTO, itd.",
"Characters": "znakovi",
"ABPTestimonialDescription": "ABP Framework: Hajde da čujemo tvoje iskustvo"
"ABPTestimonialDescription": "ABP Framework: Hajde da čujemo tvoje iskustvo",
"LeaveUsReview": "Ostavite nam recenziju"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/hu.json

@ -467,6 +467,7 @@
"Title": "Cím",
"TitlePlaceholder": "Szoftvertervező, CTO, stb.",
"Characters": "karakterek",
"ABPTestimonialDescription": "ABP Framework: Halljuk az Ön beszámolóját"
"ABPTestimonialDescription": "ABP Framework: Halljuk az Ön beszámolóját",
"LeaveUsReview": "Hagyjon véleményt nekünk"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/is.json

@ -467,6 +467,7 @@
"Title": "Titill",
"TitlePlaceholder": "Hugbúnaðarþróunarmiðill, CTO o.s.frv.",
"Characters": "stafir",
"ABPTestimonialDescription": "ABP Framework: Við skulum heyra vitnisburð þinn"
"ABPTestimonialDescription": "ABP Framework: Við skulum heyra vitnisburð þinn",
"LeaveUsReview": "Skildu eftir okkur umsögn"
}
}

1
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/it.json

@ -468,5 +468,6 @@
"TitlePlaceholder": "Sviluppatore di software, CTO ecc.",
"Characters": "caratteri",
"ABPTestimonialDescription": "ABP Framework: Ascoltiamo la tua testimonianza",
"LeaveUsReview": "Lasciaci una recensione"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/nl.json

@ -467,6 +467,7 @@
"Title": "Titel",
"TitlePlaceholder": "Softwareontwikkelaar, CTO enz.",
"Characters": "tekens",
"ABPTestimonialDescription": "ABP Framework: Laten we uw getuigenis horen"
"ABPTestimonialDescription": "ABP Framework: Laten we uw getuigenis horen",
"LeaveUsReview": "Laat ons een beoordeling achter"
}
}

5
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/pl-PL.json

@ -467,6 +467,7 @@
"Title": "Tytuł",
"TitlePlaceholder": "Programista, CTO itp.",
"Characters": "znaki",
"ABPTestimonialDescription": "Struktura ABP: Posłuchajmy Twojej opinii"
"ABPTestimonialDescription": "Struktura ABP: Posłuchajmy Twojej opinii",
"LeaveUsReview": "Zostaw nam recenzję"
}
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/pt-BR.json

@ -467,6 +467,7 @@
"Title": "Título",
"TitlePlaceholder": "Desenvolvedor de software, CTO etc.",
"Characters": "caracteres",
"ABPTestimonialDescription": "Estrutura ABP: vamos ouvir seu depoimento"
"ABPTestimonialDescription": "Estrutura ABP: vamos ouvir seu depoimento",
"LeaveUsReview": "Deixe-nos uma avaliação"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/ro-RO.json

@ -467,6 +467,7 @@
"Title": "Titlu",
"TitlePlaceholder": "Dezvoltator software, CTO etc.",
"Characters": "caractere",
"ABPTestimonialDescription": "Cadrul ABP: Haideți să vă ascultăm mărturia"
"ABPTestimonialDescription": "Cadrul ABP: Haideți să vă ascultăm mărturia",
"LeaveUsReview": "Lasă-ne o recenzie"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/ru.json

@ -465,6 +465,7 @@
"Title": "Заголовок",
"TitlePlaceholder": "Разработчик программного обеспечения, технический директор и т. д.",
"Characters": "Символы",
"ABPTestimonialDescription": "ABP Framework: давайте послушаем ваш отзыв"
"ABPTestimonialDescription": "ABP Framework: давайте послушаем ваш отзыв",
"LeaveUsReview": "Оставьте нам отзыв"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/sk.json

@ -467,6 +467,7 @@
"Title": "Názov",
"TitlePlaceholder": "Vývojár softvéru, CTO atď.",
"Characters": "znaky",
"ABPTestimonialDescription": "Rámec ABP: Vypočujme si vaše svedectvo"
"ABPTestimonialDescription": "Rámec ABP: Vypočujme si vaše svedectvo",
"LeaveUsReview": "Zanechajte nám recenziu"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/sl.json

@ -467,6 +467,7 @@
"Title": "Naslov",
"TitlePlaceholder": "Razvijalec programske opreme, tehnični direktor itd.",
"Characters": "znaki",
"ABPTestimonialDescription": "Ogrodje ABP: poslušajmo vaše pričevanje"
"ABPTestimonialDescription": "Ogrodje ABP: poslušajmo vaše pričevanje",
"LeaveUsReview": "Pustite nam oceno"
}
}

4
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/tr.json

@ -427,7 +427,7 @@
"PasswordLength": "Şifre alanı maksimum 32 karakter olmalıdır.",
"PasswordRequired": "Şifre alanı zorunludur.",
"AddressLength": "Adres alanı maksimum uzunluğu 255 karakter olmalıdır.",
"GenderRequired": "Cinsiyet alanı zorunludur."
"GenderRequired": "Cinsiyet alanı zorunludur.",
"LeaveUsReview": "Yorumunuzu paylaşın"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/vi.json

@ -467,6 +467,7 @@
"Title": "Tiêu đề",
"TitlePlaceholder": "Nhà phát triển phần mềm, CTO, v.v.",
"Characters": "Ký tự",
"ABPTestimonialDescription": "Khung ABP: Hãy nghe lời chứng thực của bạn"
"ABPTestimonialDescription": "Khung ABP: Hãy nghe lời chứng thực của bạn",
"LeaveUsReview": "Để lại cho chúng tôi xem xét"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/zh-Hans.json

@ -469,6 +469,7 @@
"Title": "标题",
"TitlePlaceholder": "软件开发人员、CTO等",
"Characters": "字符",
"ABPTestimonialDescription": "ABP 框架:让我们听听您的感言"
"ABPTestimonialDescription": "ABP 框架:让我们听听您的感言",
"LeaveUsReview": "给我们留下评论"
}
}

3
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/zh-Hant.json

@ -469,6 +469,7 @@
"Title": "标题",
"TitlePlaceholder": "软件开发人员、CTO等",
"Characters": "字符",
"ABPTestimonialDescription": "ABP 框架:让我们听听您的感言"
"ABPTestimonialDescription": "ABP 框架:让我们听听您的感言",
"LeaveUsReview": "给我们留下评论"
}
}

4
docs/en/API/Auto-API-Controllers.md

@ -12,9 +12,9 @@ Basic configuration is simple. Just configure `AbpAspNetCoreMvcOptions` and use
[DependsOn(BookStoreApplicationModule)]
public class BookStoreWebModule : AbpModule
{
public override void ConfigureServices(ServiceConfigurationContext context)
public override void PreConfigureServices(ServiceConfigurationContext context)
{
Configure<AbpAspNetCoreMvcOptions>(options =>
PreConfigure<AbpAspNetCoreMvcOptions>(options =>
{
options
.ConventionalControllers

239
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/POST.md

@ -0,0 +1,239 @@
# ABP.IO Platform 8.1 RC Has Been Released
Today, we are happy to release the [ABP Framework](https://abp.io/) and [ABP Commercial](https://commercial.abp.io/) version **8.1 RC** (Release Candidate). This blog post introduces the new features and important changes in this new version.
Try this version and provide feedback for a more stable version of ABP v8.1! Thanks to all of you.
## Get Started with the 8.1 RC
Follow the steps below to try version 8.1.0 RC today:
1) **Upgrade** the ABP CLI to version `8.1.0-rc.1` using a command line terminal:
````bash
dotnet tool update Volo.Abp.Cli -g --version 8.1.0-rc.1
````
**or install** it if you haven't before:
````bash
dotnet tool install Volo.Abp.Cli -g --version 8.1.0-rc.1
````
2) Create a **new application** with the `--preview` option:
````bash
abp new BookStore --preview
````
See the [ABP CLI documentation](https://docs.abp.io/en/abp/latest/CLI) for all the available options.
> You can also use the [Get Started](https://abp.io/get-started) page to generate a CLI command to create a new application.
You can use any IDE that supports .NET 8.x, like [Visual Studio 2022](https://visualstudio.microsoft.com/downloads/).
## 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.0 to 8.1 Migration Guide](https://docs.abp.io/en/abp/8.1/Migration-Guides/Abp-8_1)
* [ABP Commercial 8.0 to 8.1 Migration Guide](https://docs.abp.io/en/commercial/8.1/migration-guides/v8_1)
## What's New with ABP Framework 8.1?
In this section, I will introduce some major features released in this version.
Here is a brief list of titles explained in the next sections:
* Introducing the `ExposeKeyedServiceAttribute`
* Custom Menu Component Support for MVC UI
* Introducing the `DisableAbpFeaturesAttribute`
### Introducing the `ExposeKeyedServiceAttribute`
[Keyed dependency injection (DI) services](https://learn.microsoft.com/en-us/aspnet/core/fundamentals/dependency-injection?view=aspnetcore-8.0#keyed-services) were added to the built-in DI container as a new feature with .NET 8.0. This is an important feature, which allows for registering and retrieving DI services using keys/names.
In this version, we have introduced the `ExposeKeyedServiceAttribute` to allow you to automatically register keyed services by conventions:
```csharp
[ExposeKeyedService<ITaxCalculator>("taxCalculator")]
[ExposeKeyedService<ICalculator>("calculator")]
public class TaxCalculator: ICalculator, ITaxCalculator, ICanCalculate, ITransientDependency
{
}
```
In the example above, the `TaxCalculator` class exposes the `ITaxCalculator` interface with the key `taxCalculator` and the `ICalculator` interface with the key `calculator`.
Thanks to that, then you can use the [`FromKeyedServicesAttribute`](https://learn.microsoft.com/en-us/dotnet/api/microsoft.extensions.dependencyinjection.fromkeyedservicesattribute?view=dotnet-plat-ext-8.0) to resolve a certain keyed service in the constructor:
```csharp
public class MyClass
{
//...
public MyClass([FromKeyedServices("taxCalculator")] ITaxCalculator taxCalculator)
{
TaxCalculator = taxCalculator;
}
}
```
> Notice that the `ExposeKeyedServiceAttribute` only exposes the keyed services. So, you can not inject the `ITaxCalculator` or `ICalculator` interfaces in your application without using the `FromKeyedServicesAttribute` as shown in the example above.
> If you want to learn more about the keyed dependency injection services, please refer to [Microsoft's documentation](https://learn.microsoft.com/en-us/aspnet/core/fundamentals/dependency-injection?view=aspnetcore-8.0#keyed-services) and [ABP Framework's Dependency Injection document](https://docs.abp.io/en/abp/8.1/Dependency-Injection#exposekeyedservice-attribute).
### Custom Menu Component Support for MVC UI
In this version, we have introduced the **custom menu component support**, which allows you to use a custom component for a certain menu item.
You can use the `UseComponent` extension method while defining menu items to use your custom component for the related menu item:
```csharp
context.Menu.Items.Add(
new ApplicationMenuItem("Custom.1", "My Custom Menu", "#")
.UseComponent(typeof(MyMenuComponent)));
```
Then, for the related menu item, your custom component will be rendered on the UI.
### Introducing the `DisableAbpFeaturesAttribute`
In this version, we have introduced the `DisableAbpFeaturesAttribute` to allow you to disable interceptors, middlewares, and MVC filters for a specific controller.
For example, you may want to disable interceptors for a certain controller, but you may also don't want to disable middlewares and mvc filters, in that case, you can use the `DisableAbpFeaturesAttribute` as follows:
```csharp
[Route("api/my-endpoint")]
[DisableAbpFeatures(DisableInterceptors = true, DisableMiddleware = false, DisableMvcFilters = false)]
public class MyController : AbpController
{
}
```
This can be useful if you have some APIs that are used frequently but you don't need all the features of ABP Framework.
> **Note:** If you want to disable all interceptors, middlewares, and filters for a certain controller, then you can use the `[DisableAbpFeatures]` without the need to specify the parameters, they are disabled by default.
## What's New with ABP Commercial 8.1?
We've also worked on ABP Commercial to align the features and changes made in the ABP Framework. The following sections introduce a few new features coming with ABP Commercial 8.1.
### Suite: New Features
In this version, we mostly worked on ABP Suite and implemented some wanted features, such as *bulk delete*, *filterable properties*, *customizable page title*, *allowing establishing relationships with installed ABP modules' entities* and *supporting the `BasicAggregateRoot` as the base class*.
#### Bulk Delete
From this version on, ABP Suite allows you to perform bulk deletion of records based on specified criteria.
![](bulk-delete.png)
To enable *bulk delete support*, you should enable the *Bulk delete* option in the CRUD page generation page, along with the *Create user interface* option (they are enabled by default). When you enable the *bulk delete support*, you will see the checkboxes for each line in the datatable:
![](bulk-delete-datatable.png)
By selecting these checkboxes, you can delete all records in the current datatable (10 records by default), or delete all records in the database (by selecting *select all xx items* selection), or delete any records you want by selecting them one by one.
> **Note:** This feature has already been implemented for MVC & Blazor UIs, but not implemented for Angular UI yet. We aim to implement it for Angular UI with *v8.1.0-rc.2*.
#### Filterable Properties
ABP Suite has been generating advanced filters for entities for a while and before this version, if you enabled the *create user interface* option, then all of the properties that you specified were included in the advanced filter section automatically.
In this version, we have introduced the **filterable properties** feature to allow you to select which properties should be filterable and which are not:
![](filterable-properties.png)
Now, you have full control to select which properties should be included as filter inputs and shown on the advanced filters section on your generated pages.
In other words, once, you select a property as *not filterable*, then the property will not be included in the filter inputs and in the advanced filter section. Also, if there are not any filterable properties for an entity, then the advanced filters section will not be generated.
#### Customizable Page Title
In this version on, ABP Suite allows you to specify the page title for the current entity.
![](page-title.png)
You just need to specify the *page title* on the CRUD page generation page for a specific entity and then it will be used as a localization key in the application (and also will be localized - for example, if you specify it as 'MyPageTitle', then it will be localized in English as 'My Page Title'), so you can localize it for different languages later on.
#### Allowing Establishing Relationships with Installed ABP Modules' Entities
In this version, ABP Suite allows you to establish one-to-many relationship with pre-installed ABP Modules. You can add any entity from pre-installed ABP modules as a navigation property, by checking the **Include entities from ABP modules** checkbox in the navigation property model and choosing the related module entity as in the following figure:
![](suite-include-entities-from-abp-modules.png)
In the example above, the `IdentityUser` entity is selected as the navigation property but you can also choose any entity from the installed ABP modules in the navigation property model.
> **Note:** Ensure that your solution is built properly before establishing relationship between your own entity and a module entity because ABP Suite scans assemblies and finds which ABP modules you are using and lists their entities in the navigation property model if you have checked the **Include entities from ABP modules** checkbox.
#### Support `BasicAggregateRoot` Base Class
In this version on, ABP Suite allows you to choose the `BasicAggregateRoot` as the base class while generating an entity:
![](basic-aggregate-root.png)
> You can choose the [BasicAggregateRoot](https://github.com/abpframework/abp/blob/dev/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Entities/BasicAggregateRoot.cs) if you want to create an aggregate root without the `IHasExtraProperties` and `IHasConcurrencyStamp` interfaces implemented (extra properties & concurrency check).
### ABP Studio v0.6.5 Has Been Released!
We have just released v0.6.5 for ABP Studio and with this version, we fixed many minor bugs reported by you, started supporting running multiple ABP Studio instances, and added important features, such as adding a public website to the new microservice template, and so on...
In addition to all of this, we continue to enrich ABP Studio's documentation as always and you can read them at [https://docs.abp.io/en/commercial/latest/studio/overview](https://docs.abp.io/en/commercial/latest/studio/overview).
Please try ABP Studio v0.6.5 and [provide feedback](https://support.abp.io/QA/Questions/6416/ABP-Studio-Bugs--Issues) to help us release more stable versions. Thanks in advance!
## Community News
### .NET Conf China 2023 Watch Party
![](dotnet-conf-china-2023-watch-party.jpg)
ABP.IO was thrilled to sponsor the first .NET Community event in 2024 held in Shenzen on January 14, 2024.
The event included four wonderful technical lectures to reveal big data and AI's potential opportunities and innovations. It was a transfer of knowledge and a platform for communication and cooperation among technology enthusiasts and we are happy to be attended.
> If you want to learn more about the .NET Conf China 2023 Watch Party event, please check [the blog post](https://blog.abp.io/abp/2024-First-Community-Event).
### Volosoft Attended NDC London 2024
![](ndc-london-2024.png)
Core team members of the ABP Framework, [Halil Ibrahim Kalkan](https://twitter.com/hibrahimkalkan), [Alper Ebicoglu](https://twitter.com/alperebicoglu), [Engincan Veske](https://twitter.com/EngincanVeske), and [Bige Beşikci Yaman](https://twitter.com/bigedediki) attended [NDC London 2024](https://ndclondon.com/) from the 31st of January to the 2nd of February.
It was the 5th time in a row we were a proud sponsor of NDC London. It, now, basically feels like home spending 3 days in Queen Elizabeth Centre II with NDC London for the [ABP.IO](https://abp.io/) team to be there.
These 3 days with the team were all about chatting and having fun with amazing attendees and speakers. We met with talented and passionate software developers and introduced the [open source ABP Framework](https://github.com/abpframework/abp) - web application framework built on ASP.NET Core and [ABP Commercial](https://commercial.abp.io/) - the complete web application development platform built on open source ABP Framework - to them.
> We shared our insights and key highlights from the NDC London 2024 event, which you can find at [https://blog.abp.io/abp/NDC-London-2024-ABP.IO-Key-Highlights](https://blog.abp.io/abp/NDC-London-2024-ABP.IO-Key-Highlights).
### New ABP Community Articles
There are exciting articles contributed by the ABP community as always. I will highlight some of them here:
* [Every Programmer Should Know #2: Optimistic Concurrency Control](https://community.abp.io/posts/every-programmer-should-know-2-optimistic-concurrency-control-sms9xs9n) by [Berkan Sasmaz](https://github.com/berkansasmaz)
* [Global Error Handling in Angular](https://community.abp.io/posts/global-error-handling-in-angular-gjcb2f1e) by [Sinan Öztürk](https://github.com/Sinan997)
* [ABP Framework goes Azure](https://community.abp.io/posts/abp-framework-goes-azure-ub4u5ax5) by [Bart Van Hoey](https://github.com/bartvanhoey)
* [ABP Supports .NET8](https://community.abp.io/posts/abp-supports-.net8-e4gve6ih) by [Alper Ebicoglu](https://community.abp.io/members/alper)
* [Engincan Veske](https://github.com/EngincanV) has created **three** new community articles:
* [ABP Now Supports Keyed Services!](https://community.abp.io/posts/abp-now-supports-keyed-services-6k92wz7h)
* [Mutation Testing in C# with Stryker](https://community.abp.io/posts/mutation-testing-in-c-with-stryker-tp6u599h)
* [ABP Suite: Best CRUD Page Generation Tool for .NET](https://community.abp.io/posts/abp-suite-best-crud-page-generation-tool-for-.net-cmm9xs3n)
* [Ahmed Tarek](https://github.com/AhmedTarekHasan) has created **nine** new community articles:
* [📑 Cover IO Based Apps With Unit Tests in .NET C# 🧪](https://community.abp.io/posts/-cover-io-based-apps-with-unit-tests-in-.net-c--zp6kip2r)
* [Better Enhanced Repository Pattern Implementation in .NET C#](https://community.abp.io/posts/better-enhanced-repository-pattern-implementation-in-.net-c-hpkbxr3l)
* [When Not To Use DI, IoC, and IoC Containers in .NET C#](https://community.abp.io/posts/when-not-to-use-di-ioc-and-ioc-containers-in-.net-c-n769hq8u)
* [⏰ Best Practice for Using Timers in .NET C# ⏳](https://community.abp.io/posts/-best-practice-for-using-timers-in-.net-c--3cqvew5o)
* [How to Fully Cover .NET C# Console Application With Unit Tests](https://community.abp.io/posts/how-to-fully-cover-.net-c-console-application-with-unit-tests-3h248yhe)
* [Web Scraping in .NET C#](https://community.abp.io/posts/web-scraping-in-.net-c-6pkp1abi)
* [Step by step guide to develop a Fluent API from scratch in .NET C# using the Builder Design Pattern](https://community.abp.io/posts/step-by-step-guide-to-develop-a-fluent-api-from-scratch-in-.net-c-using-the-builder-design-pattern-sbww0vky)
* [A Best Practice for Designing Interfaces in .NET C#](https://community.abp.io/posts/a-best-practice-for-designing-interfaces-in-.net-c-9xqc4h8d)
* [Invariance, Covariance, and Contravariance in .NET C#](https://community.abp.io/posts/invariance-covariance-and-contravariance-in-.net-c-9blmuhme)
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/posts/submit) to the ABP Community.
## Conclusion
This version comes with some new features and a lot of enhancements to the existing features. You can see the [Road Map](https://docs.abp.io/en/abp/8.1/Road-Map) documentation to learn about the release schedule and planned features for the next releases. Please try ABP v8.1 RC and provide feedback to help us release a more stable version.
Thanks for being a part of this community!

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/basic-aggregate-root.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/bulk-delete-datatable.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/bulk-delete.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 107 KiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/cover-image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 207 KiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/dotnet-conf-china-2023-watch-party.jpg

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/filterable-properties.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/ndc-london-2024.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/page-title.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

BIN
docs/en/Blog-Posts/2024-02-16 v8_1_Preview/suite-include-entities-from-abp-modules.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

19
docs/en/Getting-Started-Create-Solution.md

@ -8,6 +8,19 @@
"Tiered": ["Yes", "No"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Running the solution",
"Path": "Getting-Started-Running-Solution"
},
"Previous": {
"Name": "Setup Your Development Environment",
"Path": "Getting-Started-Setup-Environment"
}
}
````
> This document assumes that you prefer to use **{{ UI_Value }}** as the UI framework and **{{ DB_Value }}** as the database provider. For other options, please change the preference on top of this document.
@ -66,8 +79,4 @@ Configure<AbpUnitOfWorkDefaultOptions>(options =>
> Or you can delete that code since `Auto` is already the default behavior.
{{ end }}
## Next Step
* [Running the solution](Getting-Started-Running-Solution.md)
{{ end }}

10
docs/en/Getting-Started-Running-Solution-Single-Layer.md

@ -8,6 +8,16 @@
}
````
````json
//[doc-nav]
{
"Previous": {
"Name": "Creating a new solution",
"Path": "Getting-Started-Create-Solution-Single-Layer"
}
}
````
> This document assumes that you prefer to use **{{ UI_Value }}** as the UI framework and **{{ DB_Value }}** as the database provider. For other options, please change the preference on top of this document.
## Create the Database

17
docs/en/Getting-Started-Running-Solution.md

@ -9,6 +9,16 @@
}
````
````json
//[doc-nav]
{
"Previous": {
"Name": "Creating a new solution",
"Path": "Getting-Started-Create-Solution"
}
}
````
> This document assumes that you prefer to use **{{ UI_Value }}** as the UI framework and **{{ DB_Value }}** as the database provider. For other options, please change the preference on top of this document.
## Create the Database
@ -258,9 +268,4 @@ It may take a longer time for the first build. Once it finishes, it opens the An
{{ end }}
Enter **admin** as the username and **1q2w3E*** as the password to login to the application. The application is up and running. You can start developing your application based on this startup template.
## See Also
* [Web Application Development Tutorial](Tutorials/Part-1.md)
* [Application Startup Template](Startup-Templates/Application.md)
Enter **admin** as the username and **1q2w3E*** as the password to login to the application. The application is up and running. You can start developing your application based on this startup template.

16
docs/en/Getting-Started-Setup-Environment-Single-Layer.md

@ -8,6 +8,16 @@
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Creating a new solution",
"Path": "Getting-Started-Create-Solution-Single-Layer"
}
}
````
> This document assumes that you prefer to use **{{ UI_Value }}** as the UI framework and **{{ DB_Value }}** as the database provider. For other options, please change the preference on top of this document.
## Setup Your Development Environment
@ -42,8 +52,4 @@ If you've already installed, you can update it using the following command:
````shell
dotnet tool update -g Volo.Abp.Cli
````
## Next Step
* [Creating a new solution](Getting-Started-Create-Solution-Single-Layer.md)
````

15
docs/en/Getting-Started-Setup-Environment.md

@ -8,6 +8,15 @@
"Tiered": ["Yes", "No"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Creating a new solution",
"Path": "Getting-Started-Create-Solution"
}
}
````
> This document assumes that you prefer to use **{{ UI_Value }}** as the UI framework and **{{ DB_Value }}** as the database provider. For other options, please change the preference on top of this document.
@ -46,8 +55,4 @@ If you've already installed, you can update it using the following command:
````shell
dotnet tool update -g Volo.Abp.Cli
````
## Next Step
* [Creating a new solution](Getting-Started-Create-Solution.md)
````

2
docs/en/Integration-Services.md

@ -93,7 +93,7 @@ Configure<AbpAuditingOptions>(options =>
You can filter integration services (or non-integration services) while creating [Auto API Controllers](API/Auto-API-Controllers.md), using the `ApplicationServiceTypes` option of the `ConventionalControllerSetting` by configuring the `AbpAspNetCoreMvcOptions` as shown below:
```csharp
Configure<AbpAspNetCoreMvcOptions>(options =>
PreConfigure<AbpAspNetCoreMvcOptions>(options =>
{
options.ConventionalControllers.Create(
typeof(MyApplicationModule).Assembly,

2
docs/en/Migration-Guides/Abp-8_0.md

@ -269,7 +269,7 @@ You can see the following list of NuGet libraries that have been upgraded with .
| OpenIddict.Validation.ServerIntegration | 4.8.0 | 5.0.0 |
| Oracle.EntityFrameworkCore | 7.21.8 | 8.21.121 |
| Polly | 7.2.3 | 8.2.0 |
| Pomelo.EntityFrameworkCore.MySql | 7.0.0 | 8.0.0-beta.2 |
| Pomelo.EntityFrameworkCore.MySql | 7.0.0 | 8.0.0 |
| Quartz | 3.4.0 | 3.7.0 |
| Quartz.Extensions.DependencyInjection | 3.4.0 | 3.7.0 |
| Quartz.Plugins.TimeZoneConverter | 3.4.0 | 3.7.0 |

61
docs/en/Migration-Guides/Abp-8_1.md

@ -83,3 +83,64 @@ public partial class Add_NormalizedName : Migration
See https://learn.microsoft.com/en-us/ef/core/managing-schemas/migrations/managing?tabs=dotnet-core-cli#adding-raw-sql to learn how to add raw SQL to migrations.
## Use `Asp.Versioning.Mvc` to replace `Microsoft.AspNetCore.Mvc.Versioning`
The Microsoft.AspNetCore.Mvc.Versioning packages are now deprecated and superseded by Asp.Versioning.Mvc.
See the announcement here: https://github.com/dotnet/aspnet-api-versioning/discussions/807
The namespace of the `[ControllerName]` attribute has changed to `using Asp.Versioning`, Please update your code to use the new namespace.
Related PR: https://github.com/abpframework/abp/pull/18380
## New asynchronous methods for `IAppUrlProvider`
The `IsRedirectAllowedUrl` method of `IAppUrlProvider` has been changed to `IsRedirectAllowedUrlAsync` and it is now an async method.
You should update your usage of `IAppUrlProvider` to use the new method.
Related PR: https://github.com/abpframework/abp/pull/18492
## New attribute: `ExposeKeyedServiceAttribute`
The new `ExposeKeyedServiceAttribute` is used to control which keyed services are provided by the related class. Example:
````C#
[ExposeKeyedService<ITaxCalculator>("taxCalculator")]
[ExposeKeyedService<ICalculator>("calculator")]
public class TaxCalculator: ICalculator, ITaxCalculator, ICanCalculate, ITransientDependency
{
}
````
In the example above, the `TaxCalculator` class exposes the `ITaxCalculator` interface with the key `taxCalculator` and the `ICalculator` interface with the key `calculator`. That means you can get keyed services from the `IServiceProvider` as shown below:
````C#
var taxCalculator = ServiceProvider.GetRequiredKeyedService<ITaxCalculator>("taxCalculator");
var calculator = ServiceProvider.GetRequiredKeyedService<ICalculator>("calculator");
````
Also, you can use the [`FromKeyedServicesAttribute`](https://learn.microsoft.com/en-us/dotnet/api/microsoft.extensions.dependencyinjection.fromkeyedservicesattribute?view=dotnet-plat-ext-8.0) to resolve a certain keyed service in the constructor:
```csharp
public class MyClass
{
//...
public MyClass([FromKeyedServices("taxCalculator")] ITaxCalculator taxCalculator)
{
TaxCalculator = taxCalculator;
}
}
```
> Notice that the `ExposeKeyedServiceAttribute` only exposes the keyed services. So, you can not inject the `ITaxCalculator` or `ICalculator` interfaces in your application without using the `FromKeyedServicesAttribute` as shown in the example above. If you want to expose both keyed and non-keyed services, you can use the `ExposeServicesAttribute` and `ExposeKeyedServiceAttribute` attributes together as shown below:
````C#
[ExposeKeyedService<ITaxCalculator>("taxCalculator")]
[ExposeKeyedService<ICalculator>("calculator")]
[ExposeServices(typeof(ITaxCalculator), typeof(ICalculator))]
public class TaxCalculator: ICalculator, ITaxCalculator, ICanCalculate, ITransientDependency
{
}
````
This is a small **Breaking Change** because `IOnServiceExposingContext` has changed. You should update your usage of `IOnServiceExposingContext` if you have related code.
Related PR: https://github.com/abpframework/abp/pull/18819

1
docs/en/Migration-Guides/Index.md

@ -2,6 +2,7 @@
The following documents explain how to migrate your existing ABP applications. We write migration documents only if you need to take an action while upgrading your solution. Otherwise, you can easily upgrade your solution using the [abp update command](../Upgrading.md).
- [8.0 to 8.1](Abp-8_1.md)
- [7.x to 8.0](Abp-8_0.md)
- [7.3 to 7.4](Abp-7_4.md)
- [7.2 to 7.3](Abp-7_3.md)

2
docs/en/Modules/Docs.md

@ -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]) 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'')
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')
```
Be aware that `GitHubAccessToken` is masked. It's a private token and you must get your own token and replace the `***` string.

28
docs/en/MongoDB.md

@ -82,6 +82,34 @@ If you only need to configure the collection name, you can also use `[MongoColle
public IMongoCollection<Question> Questions => Collection<Question>();
````
### Configure Indexes and CreateCollectionOptions for a Collection
You can configure indexes and `CreateCollectionOptions` for your collections by overriding the `CreateModel` method. Example:
````csharp
protected override void CreateModel(IMongoModelBuilder modelBuilder)
{
base.CreateModel(modelBuilder);
modelBuilder.Entity<Question>(b =>
{
b.CreateCollectionOptions.Collation = new Collation(locale:"en_US", strength: CollationStrength.Secondary);
b.ConfigureIndexes(indexes =>
{
indexes.CreateOne(
new CreateIndexModel<BsonDocument>(
Builders<BsonDocument>.IndexKeys.Ascending("MyProperty"),
new CreateIndexOptions { Unique = true }
)
);
}
);
});
}
````
This example sets a collation for the collection and creates a unique index for the `MyProperty` property.
### Configure the Connection String Selection
If you have multiple databases in your application, you can configure the connection string name for your DbContext using the `[ConnectionStringName]` attribute. Example:

18
docs/en/Road-Map.md

@ -1,33 +1,31 @@
# ABP Framework Road Map
This document provides a road map, release schedule and planned features for the ABP Framework.
This document provides a road map, release schedule, and planned features for the ABP Framework.
## Next Versions
### v8.1
### v8.2
The next version will be 8.1 and planned to release the stable 8.1 version in February, 2024. We will be mostly working on the following topics:
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:
* Blazor Full-Stack UI ([#16156](https://github.com/abpframework/abp/issues/16156))
* Upgrade to OpenIddict 5.x ([#17605](https://github.com/abpframework/abp/issues/17605))
* Blazor Full-Stack UI ([#18289](https://github.com/abpframework/abp/issues/18289))
* Angular Universal ([#15782](https://github.com/abpframework/abp/issues/15782))
* Blazor - Forms & Validation Documentation ([#16400](https://github.com/abpframework/abp/issues/16400))
* 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))
* Improvements on the existing features and provide more guides.
See the [8.1 milestone](https://github.com/abpframework/abp/milestone/94) for all the issues we've planned to work on.
See the [8.2 milestone](https://github.com/abpframework/abp/milestone/95) for all the issues we've planned to work on.
## Backlog Items
The *Next Versions* section above shows the main focus of the planned versions. However, in each release we add new features to the core framework and the [application modules](Modules/Index.md).
The *Next Versions* section above shows the main focus of the planned versions. However, in each release, we add new features to the core framework and the [application modules](Modules/Index.md).
Here is a list of major items in the backlog we are considering working on in the next versions.
* [#6655](https://github.com/abpframework/abp/pull/6655) / Use Typescript for the MVC UI
* [#86](https://github.com/abpframework/abp/issues/86) / GrapQL Integration
* [#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
* [#2532](https://github.com/abpframework/abp/issues/2532) / CosmosDB integration with EF Core and MongoDB API
* [#4223](https://github.com/abpframework/abp/issues/4223) / WebHook system
* [#162](https://github.com/abpframework/abp/issues/162) / Azure ElasticDB Integration for multitenancy
* [#2296](https://github.com/abpframework/abp/issues/2296) / Feature toggling infrastructure

16
docs/en/Tutorials/Part-1.md

@ -6,6 +6,16 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "The Book List Page",
"Path": "Tutorials/Part-2"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -510,8 +520,4 @@ If you try to execute the `[GET] /api/app/book` API to get a list of books, the
}
````
That's pretty cool since we haven't written a single line of code to create the API controller, but now we have a fully working REST API!
## The Next Part
See the [next part](Part-2.md) of this tutorial.
That's pretty cool since we haven't written a single line of code to create the API controller, but now we have a fully working REST API!

11
docs/en/Tutorials/Part-10.md

@ -6,6 +6,17 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Previous": {
"Name": "Authors: User Interface",
"Path": "Tutorials/Part-9"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:

18
docs/en/Tutorials/Part-2.md

@ -6,6 +6,20 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Creating, Updating and Deleting Books",
"Path": "Tutorials/Part-3"
},
"Previous": {
"Name": "Creating the Server Side",
"Path": "Tutorials/Part-1"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -668,7 +682,3 @@ You can run the application! The final UI of this part is shown below:
This is a fully working, server side paged, sorted and localized table of books.
{{end # UI }}
## The Next Part
Check the [next part](Part-3.md) of this tutorial.

18
docs/en/Tutorials/Part-3.md

@ -6,6 +6,21 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Integration Tests",
"Path": "Tutorials/Part-4"
},
"Previous": {
"Name": "The Book List Page",
"Path": "Tutorials/Part-2"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -1554,6 +1569,3 @@ Here's the complete code to create the book management CRUD page, that has been
{{end}}
## The Next Part
Check out the [next part](Part-4.md) of this tutorial.

21
docs/en/Tutorials/Part-4.md

@ -6,6 +6,21 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Authorization",
"Path": "Tutorials/Part-5"
},
"Previous": {
"Name": "Creating, Updating and Deleting Books",
"Path": "Tutorials/Part-3"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -282,8 +297,4 @@ Open the **Test Explorer Window** (use Test -> Windows -> Test Explorer menu if
![bookstore-appservice-tests](./images/bookstore-appservice-tests.png)
Congratulations, the **green icons** indicates that the tests have been successfully passed!
## The Next Part
See the [next part](Part-5.md) of this tutorial.
Congratulations, the **green icons** indicates that the tests have been successfully passed!

21
docs/en/Tutorials/Part-5.md

@ -6,6 +6,21 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Authors: Domain Layer",
"Path": "Tutorials/Part-6"
},
"Previous": {
"Name": "Integration Tests",
"Path": "Tutorials/Part-4"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -562,8 +577,4 @@ private async Task ConfigureMainMenuAsync(MenuConfigurationContext context)
}
````
{{end}}
## The Next Part
See the [next part](Part-6.md) of this tutorial.
{{end}}

21
docs/en/Tutorials/Part-6.md

@ -6,6 +6,21 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Authors: Database Integration",
"Path": "Tutorials/Part-7"
},
"Previous": {
"Name": "Authorization",
"Path": "Tutorials/Part-5"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -263,8 +278,4 @@ We will implement this repository in the next part.
This part covered the domain layer of the authors functionality of the book store application. The main files created/updated in this part was highlighted in the picture below:
![bookstore-author-domain-layer](images/bookstore-author-domain-layer.png)
## The Next Part
See the [next part](Part-7.md) of this tutorial.
![bookstore-author-domain-layer](images/bookstore-author-domain-layer.png)

21
docs/en/Tutorials/Part-7.md

@ -6,6 +6,21 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Authors: Application Layer",
"Path": "Tutorials/Part-8"
},
"Previous": {
"Name": "Authors: Domain Layer",
"Path": "Tutorials/Part-6"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -226,8 +241,4 @@ public class MongoDbAuthorRepository
> See the [MongoDB Integration document](../MongoDB.md) for more information on the MongoDB based repositories.
{{end}}
## The Next Part
See the [next part](Part-8.md) of this tutorial.
{{end}}

19
docs/en/Tutorials/Part-8.md

@ -6,6 +6,21 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Authors: User Interface",
"Path": "Tutorials/Part-9"
},
"Previous": {
"Name": "Authors: Database Integration",
"Path": "Tutorials/Part-7"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -589,7 +604,3 @@ public class MongoDBAuthorAppService_Tests : AuthorAppService_Tests<BookStoreMon
{{end}}
Created some tests for the application service methods, which should be clear to understand.
## The Next Part
See the [next part](Part-9.md) of this tutorial.

21
docs/en/Tutorials/Part-9.md

@ -6,6 +6,21 @@
"DB": ["EF","Mongo"]
}
````
````json
//[doc-nav]
{
"Next": {
"Name": "Book to Author Relation",
"Path": "Tutorials/Part-10"
},
"Previous": {
"Name": "Authors: Application Layer",
"Path": "Tutorials/Part-8"
}
}
````
## About This Tutorial
In this tutorial series, you will build an ABP based web application named `Acme.BookStore`. This application is used to manage a list of books and their authors. It is developed using the following technologies:
@ -1242,8 +1257,4 @@ That's all! This is a fully working CRUD page, you can create, edit and delete t
> **Tip**: If you run the `.DbMigrator` console application after defining a new permission, it automatically grants these new permissions to the admin role and you don't need to manually grant the permissions yourself.
{{end}}
## The Next Part
See the [next part](Part-10.md) of this tutorial.
{{end}}

13
docs/en/UI/Angular/Authorization.md

@ -59,9 +59,9 @@ The `AuthErrorFilterService` is an abstract service that needs to be replaced wi
> By default, this service is replaced in the `@abp/ng.oauth` package
**Usage**
### Usage
1.Create an auth-filter.provider
#### 1.Create an auth-filter.provider
```js
import { APP_INITIALIZER, inject } from '@angular/core';
@ -96,12 +96,11 @@ function configureAuthFilter() {
```
- `AuthErrorFilter:` is a model for filter object and it have 3 properties
- `id:` a unique key in the list for the filter object
- `executable:` a status for the filter object. If it's false then it won't work, yet it'll stay in the list
- `execute:` a function that stores the skip logic
2.Add to the FeatureConfigModule
#### 2.Add to the FeatureConfigModule
```js
import { ModuleWithProviders, NgModule } from "@angular/core";
@ -120,11 +119,11 @@ export class CustomersConfigModule {
Now it'll skip the clearing of OAuth storage keys for `LinkedUser` grant_type if any `OAuthErrorEvent` occurs
**Replace with custom implementation**
#### Replace with custom implementation
- Use the `AbstractAuthErrorFilter<T,E>` class for signs of process.
Use the `AbstractAuthErrorFilter<T,E>` class for signs of process.
**Example**
#### Example
`my-auth-error-filter.service.ts`

2
docs/en/UI/Angular/Localization.md

@ -113,7 +113,7 @@ this.localizationService.get({
## UI Localizations
Localizations can be determined on backend side. Angular UI gets the localizations from the `application-configuration` API's response. You can also determine localizations on the UI side.
Localizations can be determined on backend side. Angular UI gets the localization resources from the `application-localization` API's response and merges these resources with `configuration state` in [`ConfigStateService`](Config-State-Service.md). You can also determine localizations on the UI side.
See an example:

4
docs/zh-Hans/API/Auto-API-Controllers.md

@ -12,9 +12,9 @@ ABP可以按照惯例 **自动** 将你的应用程序服务配置为API控制
[DependsOn(BookStoreApplicationModule)]
public class BookStoreWebModule : AbpModule
{
public override void ConfigureServices(ServiceConfigurationContext context)
public override void PreConfigureServices(ServiceConfigurationContext context)
{
Configure<AbpAspNetCoreMvcOptions>(options =>
PreConfigure<AbpAspNetCoreMvcOptions>(options =>
{
options
.ConventionalControllers

28
docs/zh-Hans/MongoDB.md

@ -51,6 +51,34 @@ public class MyDbContext : AbpMongoDbContext
* 为每一个mongo集合添加一个公共的 `IMongoCollection<TEntity>` 属性.ABP默认使用这些属性创建默认的仓储
* 重写 `CreateModel` 方法,可以在方法中配置集合(如设置集合在数据库中的名字)
### 为集合配置索引和 CreateCollectionOptions
你可以在 `CreateModel` 方法中配置集合的索引和 `CreateCollectionOptions`:
````csharp
protected override void CreateModel(IMongoModelBuilder modelBuilder)
{
base.CreateModel(modelBuilder);
modelBuilder.Entity<Question>(b =>
{
b.CreateCollectionOptions.Collation = new Collation(locale:"en_US", strength: CollationStrength.Secondary);
b.ConfigureIndexes(indexes =>
{
indexes.CreateOne(
new CreateIndexModel<BsonDocument>(
Builders<BsonDocument>.IndexKeys.Ascending("MyProperty"),
new CreateIndexOptions { Unique = true }
)
);
}
);
});
}
````
在这个例子中,我们设置了集合的排序规则和一个唯一的索引.
### 将 Db Context 注入到依赖注入中
在你的模块中使用 `AddAbpDbContext` 方法将Db Context注入到[依赖注入](Dependency-Injection.md)系统中.

10
framework/src/Volo.Abp.AspNetCore.Mvc.Client/Volo/Abp/AspNetCore/Mvc/Client/MvcRemoteTenantStore.cs

@ -40,9 +40,9 @@ public class MvcRemoteTenantStore : ITenantStore, ITransientDependency
}
var tenantConfiguration = await Cache.GetAsync(cacheKey);
if (tenantConfiguration == null)
if (tenantConfiguration?.Value == null)
{
await TenantAppService.FindTenantByNameAsync(normalizedName);
var tenant = await TenantAppService.FindTenantByNameAsync(normalizedName);
tenantConfiguration = await Cache.GetAsync(cacheKey);
}
@ -65,7 +65,7 @@ public class MvcRemoteTenantStore : ITenantStore, ITransientDependency
}
var tenantConfiguration = await Cache.GetAsync(cacheKey);
if (tenantConfiguration == null)
if (tenantConfiguration?.Value == null)
{
await TenantAppService.FindTenantByIdAsync(id);
tenantConfiguration = await Cache.GetAsync(cacheKey);
@ -90,7 +90,7 @@ public class MvcRemoteTenantStore : ITenantStore, ITransientDependency
}
var tenantConfiguration = Cache.Get(cacheKey);
if (tenantConfiguration == null)
if (tenantConfiguration?.Value == null)
{
AsyncHelper.RunSync(async () => await TenantAppService.FindTenantByNameAsync(normalizedName));
tenantConfiguration = Cache.Get(cacheKey);
@ -115,7 +115,7 @@ public class MvcRemoteTenantStore : ITenantStore, ITransientDependency
}
var tenantConfiguration = Cache.Get(cacheKey);
if (tenantConfiguration == null)
if (tenantConfiguration?.Value == null)
{
AsyncHelper.RunSync(async () => await TenantAppService.FindTenantByIdAsync(id));
tenantConfiguration = Cache.Get(cacheKey);

5
framework/src/Volo.Abp.AspNetCore.Mvc.Contracts/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/ApplicationLocalizationDto.cs

@ -8,8 +8,11 @@ public class ApplicationLocalizationDto
{
public Dictionary<string, ApplicationLocalizationResourceDto> Resources { get; set; }
public CurrentCultureDto CurrentCulture { get; set; }
public ApplicationLocalizationDto()
{
Resources = new Dictionary<string, ApplicationLocalizationResourceDto>();
CurrentCulture = new CurrentCultureDto();
}
}
}

29
framework/src/Volo.Abp.AspNetCore.Mvc.Contracts/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/CurrentCultureDto.cs

@ -1,4 +1,5 @@
using System;
using System.Globalization;
namespace Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations;
@ -22,4 +23,32 @@ public class CurrentCultureDto
public string NativeName { get; set; } = default!;
public DateTimeFormatDto DateTimeFormat { get; set; } = default!;
/// <summary>
/// Creates a new <see cref="CurrentCultureDto"/> object based on the current CultureInfo.
/// </summary>
public static CurrentCultureDto Create()
{
return new CurrentCultureDto
{
Name = CultureInfo.CurrentUICulture.Name,
DisplayName = CultureInfo.CurrentUICulture.DisplayName,
EnglishName = CultureInfo.CurrentUICulture.EnglishName,
NativeName = CultureInfo.CurrentUICulture.NativeName,
IsRightToLeft = CultureInfo.CurrentUICulture.TextInfo.IsRightToLeft,
CultureName = CultureInfo.CurrentUICulture.TextInfo.CultureName,
TwoLetterIsoLanguageName = CultureInfo.CurrentUICulture.TwoLetterISOLanguageName,
ThreeLetterIsoLanguageName = CultureInfo.CurrentUICulture.ThreeLetterISOLanguageName,
DateTimeFormat = new DateTimeFormatDto
{
CalendarAlgorithmType = CultureInfo.CurrentUICulture.DateTimeFormat.Calendar.AlgorithmType.ToString(),
DateTimeFormatLong = CultureInfo.CurrentUICulture.DateTimeFormat.LongDatePattern,
ShortDatePattern = CultureInfo.CurrentUICulture.DateTimeFormat.ShortDatePattern,
FullDateTimePattern = CultureInfo.CurrentUICulture.DateTimeFormat.FullDateTimePattern,
DateSeparator = CultureInfo.CurrentUICulture.DateTimeFormat.DateSeparator,
ShortTimePattern = CultureInfo.CurrentUICulture.DateTimeFormat.ShortTimePattern,
LongTimePattern = CultureInfo.CurrentUICulture.DateTimeFormat.LongTimePattern,
}
};
}
}

2
framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared/wwwroot/libs/abp/aspnetcore-mvc-ui-theme-shared/datatables/datatables-extensions.js

@ -258,7 +258,7 @@ var abp = abp || {};
var cells = $(nRow).children("td");
for (var i = 0; i < cells.length; i++) {
var cell = cells[i];
if (cell._DT_CellIndex && cell._DT_CellIndex.row === iDisplayIndex && cell._DT_CellIndex.column === colIndex) {
if (cell._DT_CellIndex && cell._DT_CellIndex.column === colIndex) {
var $actionButton = $(cell).find(".abp-action-button");
if ($actionButton.length === 0) {
$(cell).empty().append($actionContainer);

11
framework/src/Volo.Abp.AspNetCore.Mvc/Volo/Abp/AspNetCore/Mvc/AbpAspNetCoreMvcModule.cs

@ -215,6 +215,17 @@ public class AbpAspNetCoreMvcModule : AbpModule
context.Services.GetSingletonInstance<ApplicationPartManager>(),
context.Services.GetSingletonInstance<IModuleContainer>()
);
var preConfigureActions = context.Services.GetPreConfigureActions<AbpAspNetCoreMvcOptions>();
DynamicProxyIgnoreTypes.Add(preConfigureActions.Configure()
.ConventionalControllers
.ConventionalControllerSettings.SelectMany(x => x.ControllerTypes).ToArray());
Configure<AbpAspNetCoreMvcOptions>(options =>
{
preConfigureActions.Configure(options);
});
}
public override void OnApplicationInitialization(ApplicationInitializationContext context)

23
framework/src/Volo.Abp.AspNetCore.Mvc/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/AbpApplicationConfigurationAppService.cs

@ -258,28 +258,7 @@ public class AbpApplicationConfigurationAppService : ApplicationService, IAbpApp
private static CurrentCultureDto GetCurrentCultureInfo()
{
return new CurrentCultureDto
{
Name = CultureInfo.CurrentUICulture.Name,
DisplayName = CultureInfo.CurrentUICulture.DisplayName,
EnglishName = CultureInfo.CurrentUICulture.EnglishName,
NativeName = CultureInfo.CurrentUICulture.NativeName,
IsRightToLeft = CultureInfo.CurrentUICulture.TextInfo.IsRightToLeft,
CultureName = CultureInfo.CurrentUICulture.TextInfo.CultureName,
TwoLetterIsoLanguageName = CultureInfo.CurrentUICulture.TwoLetterISOLanguageName,
ThreeLetterIsoLanguageName = CultureInfo.CurrentUICulture.ThreeLetterISOLanguageName,
DateTimeFormat = new DateTimeFormatDto
{
CalendarAlgorithmType =
CultureInfo.CurrentUICulture.DateTimeFormat.Calendar.AlgorithmType.ToString(),
DateTimeFormatLong = CultureInfo.CurrentUICulture.DateTimeFormat.LongDatePattern,
ShortDatePattern = CultureInfo.CurrentUICulture.DateTimeFormat.ShortDatePattern,
FullDateTimePattern = CultureInfo.CurrentUICulture.DateTimeFormat.FullDateTimePattern,
DateSeparator = CultureInfo.CurrentUICulture.DateTimeFormat.DateSeparator,
ShortTimePattern = CultureInfo.CurrentUICulture.DateTimeFormat.ShortTimePattern,
LongTimePattern = CultureInfo.CurrentUICulture.DateTimeFormat.LongTimePattern,
}
};
return CurrentCultureDto.Create();
}
private async Task<ApplicationSettingConfigurationDto> GetSettingConfigAsync()

19
framework/src/Volo.Abp.AspNetCore.Mvc/Volo/Abp/AspNetCore/Mvc/ApplicationConfigurations/AbpApplicationLocalizationAppService.cs

@ -1,4 +1,5 @@
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.Extensions.Localization;
@ -9,7 +10,7 @@ using Volo.Abp.Localization.External;
namespace Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations;
public class AbpApplicationLocalizationAppService :
public class AbpApplicationLocalizationAppService :
ApplicationService,
IAbpApplicationLocalizationAppService
{
@ -23,14 +24,14 @@ public class AbpApplicationLocalizationAppService :
ExternalLocalizationStore = externalLocalizationStore;
LocalizationOptions = localizationOptions.Value;
}
public virtual async Task<ApplicationLocalizationDto> GetAsync(ApplicationLocalizationRequestDto input)
{
if (!CultureHelper.IsValidCultureCode(input.CultureName))
{
throw new AbpException("The selected culture is not valid! Make sure you enter a valid culture name.");
}
using (CultureHelper.Use(input.CultureName))
{
var resources = LocalizationOptions
@ -40,8 +41,10 @@ public class AbpApplicationLocalizationAppService :
await ExternalLocalizationStore.GetResourcesAsync()
).ToArray();
var localizationConfig = new ApplicationLocalizationDto {
Resources = new Dictionary<string, ApplicationLocalizationResourceDto>(resources.Length)
var localizationConfig = new ApplicationLocalizationDto
{
Resources = new Dictionary<string, ApplicationLocalizationResourceDto>(resources.Length),
CurrentCulture = CurrentCultureDto.Create()
};
foreach (var resource in resources)
@ -51,7 +54,7 @@ public class AbpApplicationLocalizationAppService :
if (localizer != null)
{
Dictionary<string, LocalizedString>? staticLocalizedStrings = null;
if (input.OnlyDynamics)
{
staticLocalizedStrings = (await localizer.GetAllStringsAsync(
@ -60,7 +63,7 @@ public class AbpApplicationLocalizationAppService :
includeDynamicContributors: false
)).ToDictionary(x => x.Name);
}
var localizedStringsWithDynamics = await localizer.GetAllStringsAsync(
includeParentCultures: true,
includeBaseLocalizers: false,
@ -93,4 +96,4 @@ public class AbpApplicationLocalizationAppService :
return localizationConfig;
}
}
}
}

89
framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/ProjectBuilding/AbpIoSourceCodeStore.cs

@ -93,60 +93,63 @@ public class AbpIoSourceCodeStore : ISourceCodeStore, ITransientDependency
version = latestVersion;
}
var currentCliVersion = await CliVersionService.GetCurrentCliVersionAsync();
var templateVersion = SemanticVersion.Parse(version);
var outputWarning = false;
if (!trustUserVersion)
if (type == SourceCodeTypes.Template)
{
if (currentCliVersion.Major != templateVersion.Major || currentCliVersion.Minor != templateVersion.Minor)
{
// major and minor version are different
outputWarning = true;
}
else if (currentCliVersion.Major == templateVersion.Major &&
currentCliVersion.Minor == templateVersion.Minor &&
currentCliVersion.Patch < templateVersion.Patch)
{
// major and minor version are same but patch version is lower
outputWarning = true;
}
else if(currentCliVersion.Major == templateVersion.Major &&
currentCliVersion.Minor == templateVersion.Minor &&
currentCliVersion.Patch == templateVersion.Patch &&
currentCliVersion.IsPrerelease && templateVersion.IsPrerelease)
var currentCliVersion = await CliVersionService.GetCurrentCliVersionAsync();
var templateVersion = SemanticVersion.Parse(version);
var outputWarning = false;
if (!trustUserVersion)
{
// major and minor and patch version are same but prerelease version may be lower
var cliRcVersion = currentCliVersion.ReleaseLabels.LastOrDefault();
var templateRcVersion = templateVersion.ReleaseLabels.LastOrDefault();
if (cliRcVersion != null && templateRcVersion != null)
if (currentCliVersion.Major != templateVersion.Major || currentCliVersion.Minor != templateVersion.Minor)
{
// major and minor version are different
outputWarning = true;
}
else if (currentCliVersion.Major == templateVersion.Major &&
currentCliVersion.Minor == templateVersion.Minor &&
currentCliVersion.Patch < templateVersion.Patch)
{
// major and minor version are same but patch version is lower
outputWarning = true;
}
else if(currentCliVersion.Major == templateVersion.Major &&
currentCliVersion.Minor == templateVersion.Minor &&
currentCliVersion.Patch == templateVersion.Patch &&
currentCliVersion.IsPrerelease && templateVersion.IsPrerelease)
{
if (int.TryParse(cliRcVersion, out var cliRcVersionNumber) && int.TryParse(templateRcVersion, out var templateRcVersionNumber))
// major and minor and patch version are same but prerelease version may be lower
var cliRcVersion = currentCliVersion.ReleaseLabels.LastOrDefault();
var templateRcVersion = templateVersion.ReleaseLabels.LastOrDefault();
if (cliRcVersion != null && templateRcVersion != null)
{
if (cliRcVersionNumber < templateRcVersionNumber)
if (int.TryParse(cliRcVersion, out var cliRcVersionNumber) && int.TryParse(templateRcVersion, out var templateRcVersionNumber))
{
outputWarning = true;
if (cliRcVersionNumber < templateRcVersionNumber)
{
outputWarning = true;
}
}
}
}
}
}
if (outputWarning)
{
Logger.LogWarning(userSpecifiedVersion
? $"The specified template version ({templateVersion}) is different than the CLI version ({currentCliVersion}). This may cause compatibility issues."
: $"The latest template version ({templateVersion}) is different than the CLI version ({currentCliVersion}). This may cause compatibility issues.");
Logger.LogWarning("Please upgrade/downgrade the CLI version to the template version.");
Logger.LogWarning($"> dotnet tool uninstall -g volo.abp.cli");
Logger.LogWarning(!templateVersion.IsPrerelease
? $"> dotnet tool install -g volo.abp.cli --version \"{templateVersion.Major}.{templateVersion.Minor}.*\""
: $"> dotnet tool install -g volo.abp.cli --version {templateVersion}");
if (userSpecifiedVersion)
if (outputWarning)
{
Logger.LogWarning($"We have changed the template version as the cli version.");
Logger.LogWarning($"New version: {version}");
Logger.LogWarning(userSpecifiedVersion
? $"The specified template version ({templateVersion}) is different than the CLI version ({currentCliVersion}). This may cause compatibility issues."
: $"The latest template version ({templateVersion}) is different than the CLI version ({currentCliVersion}). This may cause compatibility issues.");
Logger.LogWarning("Please upgrade/downgrade the CLI version to the template version.");
Logger.LogWarning($"> dotnet tool uninstall -g volo.abp.cli");
Logger.LogWarning(!templateVersion.IsPrerelease
? $"> dotnet tool install -g volo.abp.cli --version \"{templateVersion.Major}.{templateVersion.Minor}.*\""
: $"> dotnet tool install -g volo.abp.cli --version {templateVersion}");
if (userSpecifiedVersion)
{
Logger.LogWarning($"We have changed the template version as the cli version.");
Logger.LogWarning($"New version: {version}");
}
}
}

8
framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/ProjectBuilding/Templates/Microservice/MicroserviceTemplateBase.cs

@ -131,6 +131,14 @@ public abstract class MicroserviceTemplateBase : TemplateInfo
private static void DeleteUnrelatedProjects(ProjectBuildContext context, List<ProjectBuildPipelineStep> steps)
{
if (!context.BuildArgs.PublicWebSite)
{
steps.Add(new RemoveProjectFromSolutionStep("MyCompanyName.MyProjectName.PublicWeb", null, "apps/public-web/src/MyCompanyName.MyProjectName.PublicWeb"));
steps.Add(new RemoveFolderStep("/apps/public-web"));
steps.Add(new RemoveProjectFromTyeStep("public-web"));
steps.Add(new RemoveProjectFromPrometheusStep("public-web"));
}
//TODO: move common tasks to methods
switch (context.BuildArgs.UiFramework)
{

15
framework/src/Volo.Abp.Core/Volo/Abp/DynamicProxy/DynamicProxyIgnoreTypes.cs

@ -17,10 +17,23 @@ public static class DynamicProxyIgnoreTypes
private static HashSet<Type> IgnoredTypes { get; } = new HashSet<Type>();
public static void Add<T>()
{
Add(typeof(T));
}
public static void Add(Type type)
{
lock (IgnoredTypes)
{
IgnoredTypes.AddIfNotContains(type);
}
}
public static void Add(params Type[] types)
{
lock (IgnoredTypes)
{
IgnoredTypes.AddIfNotContains(typeof(T));
IgnoredTypes.AddIfNotContains(types);
}
}

8
framework/src/Volo.Abp.Core/Volo/Abp/DynamicProxy/ProxyHelper.cs

@ -8,6 +8,14 @@ public static class ProxyHelper
{
private const string ProxyNamespace = "Castle.Proxies";
/// <summary>
/// Checks if given object is a dynamic proxy.
/// </summary>
public static bool IsProxy(object obj)
{
return obj.GetType().Namespace == ProxyNamespace;
}
/// <summary>
/// Returns dynamic proxy target object if this is a proxied object, otherwise returns the given object.
/// It supports Castle Dynamic Proxies.

2
framework/src/Volo.Abp.EntityFrameworkCore/Volo/Abp/EntityFrameworkCore/AbpDbContext.cs

@ -316,7 +316,7 @@ public abstract class AbpDbContext<TDbContext> : DbContext, IAbpEfCoreDbContext,
break;
case EntityState.Modified:
ApplyAbpConceptsForModifiedEntity(entry);
if (entry.Properties.Any(x => x.IsModified && x.Metadata.ValueGenerated == ValueGenerated.Never))
if (entry.Properties.Any(x => x.IsModified && (x.Metadata.ValueGenerated == ValueGenerated.Never || x.Metadata.ValueGenerated == ValueGenerated.OnAdd)))
{
if (entry.Entity is ISoftDelete && entry.Entity.As<ISoftDelete>().IsDeleted)
{

9
framework/src/Volo.Abp.Json.SystemTextJson/Volo/Abp/Json/SystemTextJson/JsonConverters/AbpDateTimeConverter.cs

@ -46,6 +46,15 @@ public class AbpDateTimeConverter : JsonConverter<DateTime>, ITransientDependenc
return _clock.Normalize(d3);
}
var dateText = reader.GetString();
if (!dateText.IsNullOrWhiteSpace())
{
if (DateTime.TryParse(dateText, CultureInfo.CurrentUICulture, DateTimeStyles.None, out var d4))
{
return _clock.Normalize(d4);
}
}
throw new JsonException("Can't get datetime from the reader!");
}

9
framework/src/Volo.Abp.Json.SystemTextJson/Volo/Abp/Json/SystemTextJson/JsonConverters/AbpNullableDateTimeConverter.cs

@ -46,6 +46,15 @@ public class AbpNullableDateTimeConverter : JsonConverter<DateTime?>, ITransient
return _clock.Normalize(d2);
}
var dateText = reader.GetString();
if (!dateText.IsNullOrWhiteSpace())
{
if (DateTime.TryParse(dateText, CultureInfo.CurrentUICulture, DateTimeStyles.None, out var d3))
{
return _clock.Normalize(d3);
}
}
return null;
}

9
framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/IHasCreateCollectionOptions.cs

@ -0,0 +1,9 @@
using MongoDB.Bson;
using MongoDB.Driver;
namespace Volo.Abp.MongoDB;
public interface IHasCreateCollectionOptions
{
CreateCollectionOptions<BsonDocument> CreateCollectionOptions { get; }
}

10
framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/IHasMongoIndexManagerAction.cs

@ -0,0 +1,10 @@
using System;
using MongoDB.Bson;
using MongoDB.Driver;
namespace Volo.Abp.MongoDB;
public interface IHasMongoIndexManagerAction
{
Action<IMongoIndexManager<BsonDocument>>? IndexesAction { get; set; }
}

10
framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/IMongoEntityModelBuilder.cs

@ -1,5 +1,7 @@
using System;
using MongoDB.Bson;
using MongoDB.Bson.Serialization;
using MongoDB.Driver;
namespace Volo.Abp.MongoDB;
@ -10,6 +12,10 @@ public interface IMongoEntityModelBuilder<TEntity>
string CollectionName { get; set; }
BsonClassMap<TEntity> BsonMap { get; }
CreateCollectionOptions<BsonDocument> CreateCollectionOptions { get; }
void ConfigureIndexes(Action<IMongoIndexManager<BsonDocument>> action);
}
public interface IMongoEntityModelBuilder
@ -19,4 +25,8 @@ public interface IMongoEntityModelBuilder
string CollectionName { get; set; }
BsonClassMap BsonMap { get; }
CreateCollectionOptions<BsonDocument> CreateCollectionOptions { get; }
void ConfigureIndexes(Action<IMongoIndexManager<BsonDocument>> action);
}

15
framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/MongoEntityModelBuilder.cs

@ -1,19 +1,28 @@
using MongoDB.Bson.Serialization;
using System;
using MongoDB.Bson;
using MongoDB.Driver;
namespace Volo.Abp.MongoDB;
public class MongoEntityModelBuilder<TEntity> :
IMongoEntityModel,
IHasBsonClassMap,
IHasCreateCollectionOptions,
IHasMongoIndexManagerAction,
IMongoEntityModelBuilder,
IMongoEntityModelBuilder<TEntity>
{
public Type EntityType { get; }
public string CollectionName { get; set; } = default!;
public Action<IMongoIndexManager<BsonDocument>>? IndexesAction { get; set; }
public CreateCollectionOptions<BsonDocument> CreateCollectionOptions { get; }
BsonClassMap IMongoEntityModelBuilder.BsonMap => _bsonClassMap;
BsonClassMap<TEntity> IMongoEntityModelBuilder<TEntity>.BsonMap => _bsonClassMap;
private readonly BsonClassMap<TEntity> _bsonClassMap;
@ -23,10 +32,16 @@ public class MongoEntityModelBuilder<TEntity> :
EntityType = typeof(TEntity);
_bsonClassMap = new BsonClassMap<TEntity>();
_bsonClassMap.ConfigureAbpConventions();
CreateCollectionOptions = new CreateCollectionOptions<BsonDocument>();
}
public BsonClassMap GetMap()
{
return _bsonClassMap;
}
public void ConfigureIndexes(Action<IMongoIndexManager<BsonDocument>>? indexesAction)
{
IndexesAction = indexesAction;
}
}

25
framework/src/Volo.Abp.MongoDB/Volo/Abp/MongoDB/MongoModelBuilder.cs

@ -74,7 +74,10 @@ public class MongoModelBuilder : IMongoModelBuilder
baseClasses.AddRange(entityModel.EntityType.GetBaseClasses(includeObject: false));
CreateCollectionIfNotExists(dbContext, entityModel.CollectionName);
var createCollectionOptions = entityModel.As<IHasCreateCollectionOptions>().CreateCollectionOptions;
var indexesAction = entityModel.As<IHasMongoIndexManagerAction>().IndexesAction;
CreateCollectionIfNotExists(dbContext, entityModel.CollectionName, createCollectionOptions);
CreateCollectionIndexes(dbContext, entityModel.CollectionName, indexesAction);
}
baseClasses = baseClasses.Distinct().ToList();
@ -141,7 +144,7 @@ public class MongoModelBuilder : IMongoModelBuilder
typeof(MongoEntityModelBuilder<>).MakeGenericType(entityType)
)!
);
buildAction?.Invoke(model);
}
@ -150,14 +153,24 @@ public class MongoModelBuilder : IMongoModelBuilder
return _entityModelBuilders.Values.Cast<IMongoEntityModel>().ToImmutableList();
}
protected virtual void CreateCollectionIfNotExists(AbpMongoDbContext dbContext, string collectionName)
protected virtual void CreateCollectionIfNotExists(AbpMongoDbContext dbContext, string collectionName, CreateCollectionOptions createCollectionOptions)
{
var filter = new BsonDocument("name", collectionName);
var options = new ListCollectionNamesOptions { Filter = filter };
var options = new ListCollectionsOptions { Filter = filter };
if (!dbContext.Database.ListCollections(options).Any())
{
dbContext.Database.CreateCollection(collectionName, createCollectionOptions);
}
}
if (!dbContext.Database.ListCollectionNames(options).Any())
protected virtual void CreateCollectionIndexes(AbpMongoDbContext dbContext, string collectionName, Action<IMongoIndexManager<BsonDocument>>? indexesAction = null)
{
var collection = dbContext.Database.GetCollection<BsonDocument>(collectionName);
if (collection != null)
{
dbContext.Database.CreateCollection(collectionName);
indexesAction?.Invoke(collection.Indexes);
}
}
}

29
framework/test/Volo.Abp.AspNetCore.Mvc.Tests/Volo/Abp/AspNetCore/Mvc/AbpAspNetCoreMvcTestModule.cs

@ -19,6 +19,7 @@ using Volo.Abp.Localization;
using Volo.Abp.MemoryDb;
using Volo.Abp.Modularity;
using Volo.Abp.TestApp;
using Volo.Abp.TestApp.Application;
using Volo.Abp.Threading;
using Volo.Abp.Validation.Localization;
using Volo.Abp.VirtualFileSystem;
@ -44,6 +45,21 @@ public class AbpAspNetCoreMvcTestModule : AbpModule
typeof(AbpAspNetCoreMvcTestModule).Assembly
);
});
context.Services.PreConfigure<AbpAspNetCoreMvcOptions>(options =>
{
options.ConventionalControllers.Create(typeof(TestAppModule).Assembly, opts =>
{
opts.UrlActionNameNormalizer = urlActionNameNormalizerContext =>
string.Equals(urlActionNameNormalizerContext.ActionNameInUrl, "phone", StringComparison.OrdinalIgnoreCase)
? "phones"
: urlActionNameNormalizerContext.ActionNameInUrl;
opts.TypePredicate = type => type != typeof(ConventionalAppService);
});
options.ExposeIntegrationServices = true;
});
}
public override void ConfigureServices(ServiceConfigurationContext context)
@ -79,19 +95,6 @@ public class AbpAspNetCoreMvcTestModule : AbpModule
});
});
Configure<AbpAspNetCoreMvcOptions>(options =>
{
options.ConventionalControllers.Create(typeof(TestAppModule).Assembly, opts =>
{
opts.UrlActionNameNormalizer = urlActionNameNormalizerContext =>
string.Equals(urlActionNameNormalizerContext.ActionNameInUrl, "phone", StringComparison.OrdinalIgnoreCase)
? "phones"
: urlActionNameNormalizerContext.ActionNameInUrl;
});
options.ExposeIntegrationServices = true;
});
Configure<AbpVirtualFileSystemOptions>(options =>
{
options.FileSets.AddEmbedded<AbpAspNetCoreMvcTestModule>();

21
framework/test/Volo.Abp.AspNetCore.Mvc.Tests/Volo/Abp/AspNetCore/Mvc/ConventionalController_Tests.cs

@ -0,0 +1,21 @@
using Shouldly;
using Volo.Abp.DynamicProxy;
using Volo.Abp.TestApp.Application;
using Xunit;
namespace Volo.Abp.AspNetCore.Mvc;
public class ConventionalController_Tests : AspNetCoreMvcTestBase
{
[Fact]
public void Conventional_Controller_Should_Disable_DynamicProxy()
{
// PeopleAppService is a conventional controller
var peopleAppService = GetRequiredService<PeopleAppService>();
ProxyHelper.IsProxy(peopleAppService).ShouldBeFalse();
// ConventionalAppService is not a conventional controller
var conventionalAppService = GetRequiredService<ConventionalAppService>();
ProxyHelper.IsProxy(conventionalAppService).ShouldBeTrue();
}
}

52
framework/test/Volo.Abp.Json.Tests/Volo/Abp/Json/AbpDateTimeConverter_Tests.cs

@ -0,0 +1,52 @@
using System;
using System.Globalization;
using System.Text.Json;
using System.Text.Json.Serialization.Metadata;
using Shouldly;
using Volo.Abp.Json.SystemTextJson.Modifiers;
using Volo.Abp.Localization;
using Xunit;
namespace Volo.Abp.Json;
public class AbpDatetimeToEnum_Tests : AbpJsonSystemTextJsonTestBase
{
[Theory]
[InlineData("tr", "14.02.2024")]
[InlineData("en-US", "2/14/2024")]
[InlineData("en-GB", "14/02/2024")]
public void Test_Read(string culture, string datetime)
{
var options = new JsonSerializerOptions()
{
TypeInfoResolver = new DefaultJsonTypeInfoResolver()
{
Modifiers = { new AbpDateTimeConverterModifier().CreateModifyAction(ServiceProvider) }
}
};
using(CultureHelper.Use(culture))
{
var testClass = JsonSerializer.Deserialize<TestClass>($"{{\"DateTime\": \"{datetime}\", \"NullableDateTime\": \"{datetime}\"}}", options);
testClass.ShouldNotBeNull();
testClass.DateTime.ToString(CultureInfo.CurrentCulture).ShouldStartWith(datetime);
testClass.NullableDateTime.ShouldNotBeNull();
testClass.NullableDateTime.Value.ToString(CultureInfo.CurrentCulture).ShouldStartWith(datetime);
}
using(CultureHelper.Use(culture))
{
var testClass = JsonSerializer.Deserialize<TestClass>($"{{\"DateTime\": \"{datetime}\", \"NullableDateTime\": null}}", options);
testClass.ShouldNotBeNull();
testClass.DateTime.ToString(CultureInfo.CurrentCulture).ShouldStartWith(datetime);
testClass.NullableDateTime.ShouldBeNull();
}
}
class TestClass
{
public DateTime DateTime { get; set; }
public DateTime? NullableDateTime { get; set; }
}
}

25
framework/test/Volo.Abp.Json.Tests/Volo/Abp/Json/AbpStringToBoolean_Tests.cs

@ -3,13 +3,13 @@ using Shouldly;
using Volo.Abp.Json.SystemTextJson.JsonConverters;
using Xunit;
namespace Volo.Abp.Json
namespace Volo.Abp.Json;
public class AbpStringToBoolean_Tests
{
public class AbpStringToBoolean_Tests
[Fact]
public void Test_Read()
{
[Fact]
public void Test_Read()
{
var options = new JsonSerializerOptions()
{
Converters =
@ -27,9 +27,9 @@ namespace Volo.Abp.Json
testClass.Enabled.ShouldBe(true);
}
[Fact]
public void Test_Write()
{
[Fact]
public void Test_Write()
{
var options = new JsonSerializerOptions()
{
Converters =
@ -46,9 +46,8 @@ namespace Volo.Abp.Json
testClassJson.ShouldBe("{\"Enabled\":true}");
}
class TestClass
{
public bool Enabled { get; set; }
}
class TestClass
{
public bool Enabled { get; set; }
}
}
}

95
framework/test/Volo.Abp.Json.Tests/Volo/Abp/Json/AbpStringToEnum_Tests.cs

@ -5,69 +5,68 @@ using Shouldly;
using Volo.Abp.Json.SystemTextJson.JsonConverters;
using Xunit;
namespace Volo.Abp.Json
namespace Volo.Abp.Json;
public class AbpStringToEnum_Tests
{
public class AbpStringToEnum_Tests
[Fact]
public void Test_Read()
{
[Fact]
public void Test_Read()
var options = new JsonSerializerOptions()
{
var options = new JsonSerializerOptions()
Converters =
{
Converters =
{
new AbpStringToEnumFactory()
}
};
new AbpStringToEnumFactory()
}
};
var testClass = JsonSerializer.Deserialize<TestClass>("{\"Day\": \"Monday\"}", options);
testClass.ShouldNotBeNull();
testClass.Day.ShouldBe(DayOfWeek.Monday);
var testClass = JsonSerializer.Deserialize<TestClass>("{\"Day\": \"Monday\"}", options);
testClass.ShouldNotBeNull();
testClass.Day.ShouldBe(DayOfWeek.Monday);
testClass = JsonSerializer.Deserialize<TestClass>("{\"Day\": 1}", options);
testClass.ShouldNotBeNull();
testClass.Day.ShouldBe(DayOfWeek.Monday);
testClass = JsonSerializer.Deserialize<TestClass>("{\"Day\": 1}", options);
testClass.ShouldNotBeNull();
testClass.Day.ShouldBe(DayOfWeek.Monday);
var dictionary = JsonSerializer.Deserialize<Dictionary<DayOfWeek, string>>("{\"Monday\":\"Mo\"}", options);
dictionary.ShouldNotBeNull();
dictionary.Keys.ShouldContain(DayOfWeek.Monday);
dictionary.Values.ShouldContain("Mo");
var dictionary = JsonSerializer.Deserialize<Dictionary<DayOfWeek, string>>("{\"Monday\":\"Mo\"}", options);
dictionary.ShouldNotBeNull();
dictionary.Keys.ShouldContain(DayOfWeek.Monday);
dictionary.Values.ShouldContain("Mo");
dictionary = JsonSerializer.Deserialize<Dictionary<DayOfWeek, string>>("{\"1\":\"Mo\"}", options);
dictionary.ShouldNotBeNull();
dictionary.Keys.ShouldContain(DayOfWeek.Monday);
dictionary.Values.ShouldContain("Mo");
}
dictionary = JsonSerializer.Deserialize<Dictionary<DayOfWeek, string>>("{\"1\":\"Mo\"}", options);
dictionary.ShouldNotBeNull();
dictionary.Keys.ShouldContain(DayOfWeek.Monday);
dictionary.Values.ShouldContain("Mo");
}
[Fact]
public void Test_Write()
[Fact]
public void Test_Write()
{
var options = new JsonSerializerOptions()
{
var options = new JsonSerializerOptions()
Converters =
{
Converters =
{
new AbpStringToEnumFactory()
}
};
new AbpStringToEnumFactory()
}
};
var testClassJson = JsonSerializer.Serialize(new TestClass()
{
Day = DayOfWeek.Monday
});
var testClassJson = JsonSerializer.Serialize(new TestClass()
{
Day = DayOfWeek.Monday
});
testClassJson.ShouldBe("{\"Day\":1}");
testClassJson.ShouldBe("{\"Day\":1}");
testClassJson = JsonSerializer.Serialize(new Dictionary<DayOfWeek, string>
{
{DayOfWeek.Monday, "Mo"}
}, options);
testClassJson = JsonSerializer.Serialize(new Dictionary<DayOfWeek, string>
{
{DayOfWeek.Monday, "Mo"}
}, options);
testClassJson.ShouldBe("{\"Monday\":\"Mo\"}");
}
testClassJson.ShouldBe("{\"Monday\":\"Mo\"}");
}
class TestClass
{
public DayOfWeek Day { get; set; }
}
class TestClass
{
public DayOfWeek Day { get; set; }
}
}

13
framework/test/Volo.Abp.MongoDB.Tests/Volo/Abp/MongoDB/Repositories/Repository_Basic_Tests.cs

@ -3,6 +3,7 @@ using System.Linq;
using System.Threading.Tasks;
using MongoDB.Driver.Linq;
using Shouldly;
using Volo.Abp.Domain.Repositories;
using Volo.Abp.TestApp;
using Volo.Abp.TestApp.Domain;
using Volo.Abp.TestApp.Testing;
@ -64,4 +65,16 @@ public class Repository_Basic_Tests : Repository_Basic_Tests<AbpMongoDbTestModul
person.Phones.Count.ShouldBe(1);
person.Phones.Any(p => p.PersonId == person.Id && p.Number == "1234567890").ShouldBeTrue();
}
[Fact]
public async Task Filter_Case_Insensitive()
{
(await CityRepository.GetMongoQueryableAsync()).FirstOrDefault(c => c.Name == "ISTANBUL").ShouldBeNull();
(await CityRepository.GetMongoQueryableAsync()).FirstOrDefault(c => c.Name == "istanbul").ShouldBeNull();
(await CityRepository.GetMongoQueryableAsync()).FirstOrDefault(c => c.Name == "Istanbul").ShouldNotBeNull();
(await PersonRepository.GetQueryableAsync()).FirstOrDefault(p => p.Name == "douglas").ShouldNotBeNull();
(await PersonRepository.GetQueryableAsync()).FirstOrDefault(p => p.Name == "DOUGLAS").ShouldNotBeNull();
(await PersonRepository.GetQueryableAsync()).FirstOrDefault(p => p.Name == "Douglas").ShouldNotBeNull();
}
}

8
framework/test/Volo.Abp.MongoDB.Tests/Volo/Abp/TestApp/MongoDb/TestAppMongoDbContext.cs

@ -1,4 +1,5 @@
using MongoDB.Driver;
using MongoDB.Bson;
using MongoDB.Driver;
using Volo.Abp.Data;
using Volo.Abp.DependencyInjection;
using Volo.Abp.EntityFrameworkCore.TestApp.FourthContext;
@ -35,5 +36,10 @@ public class TestAppMongoDbContext : AbpMongoDbContext, ITestAppMongoDbContext,
{
b.CollectionName = "MyCities";
});
modelBuilder.Entity<Person>(b =>
{
b.CreateCollectionOptions.Collation = new Collation(locale:"en_US", strength: CollationStrength.Secondary);
});
}
}

17
framework/test/Volo.Abp.TestApp/Volo/Abp/TestApp/Application/ConventionalAppService.cs

@ -0,0 +1,17 @@
using System.Threading.Tasks;
using Microsoft.AspNetCore.Authorization;
using Volo.Abp.Application.Services;
using Volo.Abp.DependencyInjection;
using Volo.Abp.Uow;
namespace Volo.Abp.TestApp.Application;
public class ConventionalAppService : IApplicationService, ITransientDependency
{
[Authorize]
[UnitOfWork]
public virtual Task GetAsync()
{
return Task.CompletedTask;
}
}

9
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/package.json

@ -3,9 +3,8 @@
"name": "asp.net",
"private": true,
"dependencies": {
"@abp/aspnetcore.mvc.ui.theme.shared": "~8.0.3",
"@abp/prismjs": "^~7.3.2",
"@abp/highlight.js": "^~7.3.2"
},
"devDependencies": {}
"@abp/aspnetcore.mvc.ui.theme.shared": "~8.1.0-rc.1",
"@abp/prismjs": "~8.1.0-rc.1",
"@abp/highlight.js": "~8.1.0-rc.1"
}
}

4616
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/css/all.css

File diff suppressed because it is too large

2172
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/css/v4-shims.css

File diff suppressed because it is too large

0
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.eot → modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.eot

0
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.svg → modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.svg

Before

Width:  |  Height:  |  Size: 730 KiB

After

Width:  |  Height:  |  Size: 730 KiB

BIN
modules/blogging/app/Volo.BloggingTestApp/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.eot → modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.ttf

Binary file not shown.

0
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.woff → modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.woff

BIN
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-brands-400.woff2

Binary file not shown.

0
modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-regular-400.eot → modules/basic-theme/test/Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.Demo/wwwroot/libs/@fortawesome/fontawesome-free/webfonts/fa-regular-400.eot

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

Loading…
Cancel
Save