Forum

Welcome to ProjeQtOr new Forum. We migrated old forum to the new website.
You will find all your posts here, with your usual account.
Just one point : you’ll have to reinitialize your password. Use “Lost password” feature.

Specific Access Rig...
 
Notifications
Clear all

Specific Access Rights api endpoint

6 Posts
2 Users
0 Reactions
398 Views
Rafal
(@rafall92)
Posts: 10
Active Member
Topic starter
 
[#10099]

Hello. Im preparing tool which help me to manage user profile right change(monitoring script). We have many user which can manage those rights, so we want to be informed about changes. We want to know, which right was changed and what was previous and changed value, so firstly we prepared json files with current values. I can easly handle all data except Specific Access
I try to download data which is available under this tab on projeqtor. To do that i call api endpoint 

api/habilitationOther/all

But I can't process data as i wish. Data i receive looks like this

{
  "id": "100",
  "idProfile": "2",
  "nameProfile": "Supervisor",
  "scope": "canUpdateCreation",
  "rightAccess": "2"
}

Comparing to endpoint habilitation there is no property which can give me Full name of this right which is: Can update creation information. Also rightAccess is depend on scope, which means any other right can have same right value, but in different scope text value will be different. E.g. No resource, None visibile, Yes have same value: 1

Is there any api endpoint which give me full right name and correct right name based on scope? Or i have to prepare this data manually and have it hardcoded in my script?


 
Posted : 20 Apr 2026 12H46
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

Specific access is defined on objet of class HabilitationOther.


 
Posted : 02 May 2026 17H06
Rafal
(@rafall92)
Posts: 10
Active Member
Topic starter
 

Specific access is defined on objet of class HabilitationOther.

 

Yes. I know that. But my question was different.
One object of class habilitationOther look like this:

{
  "id": "100",
  "idProfile": "2",
  "nameProfile": "Supervisor",
  "scope": "canUpdateCreation",
  "rightAccess": "2"
}

How can i get correct rightAccess value. Because value 2 doesn't say anything. Comparing to class habilitation. We have:

{
  "id": "1",
  "idProfile": "1",
  "nameProfile": "Administrator",
  "idMenu": "14",
  "nameMenu": "Environmental parameters",
  "allowAccess": "1"
}

Having this, i can call endpoint api/AccessProfile/search/id=1 and assing property name. And similar ror idMenu api/Menu/search/id=1
How can i do the same for habilitationOther? Because rightAccess is not the same as allow access, and this value is depend on scope, which mean, different scope, can have different rightAccess with same id. The same for scope. How can i resolve valiue canUpdateCreation form json returned by api to value  Can update creation information which is visible on GUI


 
Posted : 07 May 2026 13H36
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

Corresponding values are stored in accessscopespecific


 
Posted : 14 May 2026 19H26
Rafal
(@rafall92)
Posts: 10
Active Member
Topic starter
 

Yes, i get this. But my problem is not fully solved.

{
  "id": "1",
  "name": "No resource",
  "accessCode": "NO",
  "sortOrder": "100",
  "idle": "0"
}

I still don't know how can i get Can update creation information(this is value on web page) from this canUpdateCreation(this is value from json). 


 
Posted : 15 May 2026 15H41
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

Find the criteria in Habilitation other file.
 

Inspect one field on the line to get parameter name
 

Then things are easy to find in DB
 

Finaly to know the value, you need to know the scope, that you'll find in view/parameter.php file
 

and find it in table list
 

So 1=Yes, 2=No
 


 
Posted : 01 Jul 2026 20H20
Share:

Scroll to Top