Field /api/projects Returning Erroneous is_active Value?
08/11/2015
There was an interesting question. /api/projects call returns a field named is_active with a value of true/false. This indicates which project is currently active in the given UI session. This could be easily mistaken as project status.
Q. /api/projects call returns is_active, a value of true/false. But it is not reporting correctly. Please see the images below.
In UI, every project is “Active”:
With /api/projects, is_active is false, which is wrong:
When I check the same project via the /api/project call, is_active field is not available. However, the status field shows active, which is correct.
A. Actually, there is a confusion here. is_active that /api/projects returns is not corresponding to “status” of a project in the UI. It indicates if the given project is currently active in the UI. In the UI session, you can have only one active project at a given time. Field remembers the last active project when you logout.
If you would like to check the status of project, you will need to check the “status” field that /api/project returns.
Another example that a better documentation is needed.
Mikako