ecrin-github / rms-portal-new

RMS Portal with Python backend
MIT License
0 stars 0 forks source link

we need script/api for manager to assign organisation to user. #25

Closed sergiocontrino closed 3 months ago

sergiocontrino commented 5 months ago

the manager is supposed to assign the organisation to the user. at the moment done directly in the db. e.g.

update user_profiles set organisation_id='id_o'
where user_id='id_u';

or

update user_profiles set organisation_id= (select id from organisations where 
default_name=?) where user_id = (select id from users where email=?);
cudillal commented 3 months ago

@sergiocontrino It was actually already possible to edit the organisation of a user, I don't remember what was the thing about "people" that may not be actual users of the app, but at least for all users in the "users" table in the DB, a manager can assign them to an organisation by going in the "people" tab and editing a user's info.

sergiocontrino commented 3 months ago

the editing of the profile (adding superuser/organisation) works fine. nice!