Skip to content

Commit

Permalink
Merge pull request #22024 from abpframework/auto-merge/rel-9-0/3437
Browse files Browse the repository at this point in the history
Merge branch rel-9.1 with rel-9.0
  • Loading branch information
maliming authored Jan 27, 2025
2 parents 6e1a7c7 + 5bd2e1a commit e33967e
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 6 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 5 additions & 2 deletions docs/en/tutorials/modular-crm/part-03.md
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,10 @@ Configure<AbpAspNetCoreMvcOptions>(options =>
options.ConventionalControllers.Create(typeof(ModularCrmModule).Assembly);

//ADD THE FOLLOWING LINE:
options.ConventionalControllers.Create(typeof(ProductsApplicationModule).Assembly);
options.ConventionalControllers.Create(typeof(ProductsApplicationModule).Assembly, settings =>
{
settings.RootPath = "products";
});
});
````

Expand All @@ -409,7 +412,7 @@ Once you see the user interface of the web application, type `/swagger` at the e

![abp-studio-swagger-ui-in-browser](images/abp-studio-swagger-ui-in-browser.png)

Expand the `/api/app/product` API and click the *Try it out* button as shown in the following figure:
Expand the `/api/products/product` API and click the *Try it out* button as shown in the following figure:

![abp-studio-swagger-ui-create-product-try](images/abp-studio-swagger-ui-create-product-try.png)

Expand Down
16 changes: 12 additions & 4 deletions docs/en/tutorials/modular-crm/part-05.md
Original file line number Diff line number Diff line change
Expand Up @@ -345,18 +345,26 @@ public class OrderAppService : OrderingAppService, IOrderAppService
}
````

Open the `ModularCrmModule` class in the main application's solution (the `ModularCrm` solution), find the `ConfigureAutoApiControllers` method and add the following lines inside that method:
### Exposing Application Services as HTTP API Controllers

After implementing the application service, now we need to create HTTP API endpoints for the ordering module. For that purpose, open the `ModularCrmModule` class in the main application's solution (the `ModularCrm` solution), find the `ConfigureAutoApiControllers` method and add the following lines inside that method:

````csharp
private void ConfigureAutoApiControllers()
{
Configure<AbpAspNetCoreMvcOptions>(options =>
{
options.ConventionalControllers.Create(typeof(ModularCrmModule).Assembly);
options.ConventionalControllers.Create(typeof(ProductsApplicationModule).Assembly);
options.ConventionalControllers.Create(typeof(ProductsApplicationModule).Assembly, settings =>
{
settings.RootPath = "products";
});

//ADD THE FOLLOWING LINE:
options.ConventionalControllers.Create(typeof(OrderingModule).Assembly);
options.ConventionalControllers.Create(typeof(OrderingModule).Assembly, settings =>
{
settings.RootPath = "orders";
});
});
}
````
Expand All @@ -373,7 +381,7 @@ Once you see the user interface of the web application, type `/swagger` at the e

![abp-studio-ordering-swagger-ui-in-browser](images/abp-studio-ordering-swagger-ui-in-browser.png)

Expand the `/api/app/order` API and click the *Try it out* button. Then, create a few orders by filling in the request body and clicking the *Execute* button:
Expand the `/api/orders/order` API and click the *Try it out* button. Then, create a few orders by filling in the request body and clicking the *Execute* button:

![abp-studio-swagger-ui-create-order-execute](images/abp-studio-swagger-ui-create-order-execute.png)

Expand Down

0 comments on commit e33967e

Please sign in to comment.