Open Closed

How to disable the API of the default module #1512


User avatar
0
deathmid2233@gmail.com created

ABP Framework version: v4.3 UI type: MVC DB provider: EF Core

How to disable the API controller of the default module?

I tried to comment part of the code But no effect

what should I do?


8 Answer(s)
  • User Avatar
    0
    yekalkan created
    Support Team Fullstack Developer

    Do you want to hide them or remove/disable them?

  • User Avatar
    0
    deathmid2233@gmail.com created

    Do you want to hide them or remove/disable them?

    i want disable them

  • User Avatar
    0
    yekalkan created
    Support Team Fullstack Developer

    Disabling those controllers will break your project. None of the UI pages will work stable. Because javascript api calls won't work without these api's.

  • User Avatar
    0
    deathmid2233@gmail.com created

    Disabling those controllers will break your project. None of the UI pages will work stable. Because javascript api calls won't work without these api's.

    Acme.BookStore.Web this is WEB project

    I created another WEB API project Acme.BookStore.WebAPI

    I just want to open the book api controller on Acme.BookStore.WebAPI

  • User Avatar
    0
    yekalkan created
    Support Team Fullstack Developer

    Is Acme.BookStore.WebAPI dependent on Acme.BookStore.Web?

  • User Avatar
    0
    deathmid2233@gmail.com created

    Is Acme.BookStore.WebAPI dependent on Acme.BookStore.Web?

    like this

    Same as Acme.BookStore.Web

    But does not rely on Acme.BookStore.Web

  • User Avatar
    0
    yekalkan created
    Support Team Fullstack Developer

    You need to create new a Application Layer and a HttpApi Layer as well. So, you can move Book Api related code to new projects and keep module-related api's in old projects. Then reference just new projects from Acme.BookStore.WebApi.

  • User Avatar
    0
    deathmid2233@gmail.com created

    You need to create new a Application Layer and a HttpApi Layer as well. So, you can move Book Api related code to new projects and keep module-related api's in old projects. Then reference just new projects from Acme.BookStore.WebApi.

    I understand, thank you

Made with ❤️ on ABP v9.1.0-preview. Updated on December 13, 2024, 06:09