apinf / platform

Apinf - Open source API management platform with multi proxy and protocol support
https://apinf.com/
European Union Public License 1.1
74 stars 33 forks source link

API number is inconsistent in Organization Card and Organization Profile #2535

Closed Nazarah closed 7 years ago

Nazarah commented 7 years ago

Reproduce:

  1. go to https://nightly.apinf.io and navigate to organization catalog. (sign in as admin)
  2. observe API number in organization card for "Daria's Organization" (shows 5 APIs) image
  3. Go to the organization profile.

Result

In organization profile, only 3 APIs appear. Found this issue only for this particular organization image

Environment

vellames2 commented 7 years ago

@Nazarah I did some testing in my local environment and i found the problem: Organization cards at / organizations are counting all apis (including privates api). The list of apis in the organization profile (organizations/darias-organization) is counting only public apis Thats the difference

I will open a PR to fix this :)

Nazarah commented 7 years ago

@Vellames thanks for finding the problem. :) If you are accessing as APInf site admin, then you should be able to see private APIs as well. Also If you are the manager of an Organization and a private API is connected to the organization, then you automatically become the API Manager. In this case, you should be able to see the API as well.

marla-singer commented 7 years ago

@Nazarah Specifically for this case the problem is incorrect data in database. I think so because it is reproduced only for this Orgnaization