[Loris-dev] [IPMSA] User insertion Loris 18.0.0

Morales Pinzon, Alfredo AMORALESPINZON at bwh.harvard.edu
Thu Nov 9 16:15:16 EST 2017


Hi Mouna,


Thank you for the answer, that's all I needed (y). I created a user linked to all the centers that I have, but as you say I am not able to create Candidate/Visits for all the Center.s I'll make some changes in my scripts to reflect the relationship user_psc_rel and move forward.


The new API sounds wonderful, hope you guys can test it and make it available soon.


Thank you one more time.


Best,

Alfredo.

________________________________
From: Mouna Safi-Harab <mouna.safi-harb at mail.mcgill.ca>
Sent: Thursday, November 9, 2017 4:04:40 PM
To: Morales Pinzon, Alfredo; loris-dev at bic.mni.mcgill.ca
Cc: Sridar Narayanan, Dr.; Guttmann, Charles,M.D.
Subject: Re: [IPMSA] User insertion Loris 18.0.0


Hi Alfredo,


My answers to your questions:


1) The CenterID column is no longer in the users table. It is now in a table called user_psc_rel which would be the relation between a user (ID column from the users table) and the center (CenterID column from the psc table).

This would allow one user to have as many rows as needed (i.e. as many center affiliations as needed).

So in your case, you would probably have a line to create the user in the users table, and another one to add that user to the user_psc_rel table with the centerID/affiliation.


2) The API in v18.0.0 allows the candidate/visit creation if the API user is at one site only. So for now, you can have an API user per site. But we will extend the API capabilities to allow users at multiple sites to create candidates/visits (changes are done and can be consulted in this pull request which is yet to be approved/tested: https://github.com/aces/Loris/pull/3014).


Let me know if this does not address all your concerns.


- Mouna

________________________________
From: loris-dev-bounces at bic.mni.mcgill.ca <loris-dev-bounces at bic.mni.mcgill.ca> on behalf of Morales Pinzon, Alfredo <AMORALESPINZON at bwh.harvard.edu>
Sent: Thursday, November 9, 2017 3:37:56 PM
To: loris-dev at bic.mni.mcgill.ca
Cc: Sridar Narayanan, Dr.; Guttmann, Charles, M.D.
Subject: [Loris-dev] [IPMSA] User insertion Loris 18.0.0


Dear Loris Dev Team,


In the past version of Loris (17.1) I was creating users for each center inside the database using a mysql script, I need to create hundreds of centers and consequently hundreds of users. In the previous version a given User had an associated CenterID but in the new one it does not. How are you handling this?


This is an example of one line of my script:


insert into users(UserID,Email,CenterID,Password_hash,Pending_approval,Password_expiry) values ('UserID','user at ipmsa.com',99,'**************','N','2055-01-01');


I remember Mouna told me that now one user can be associated to multiple centers, if that is the case,


(1) could you give me a light on how the database is structured so that I can modify my scripts, and


(2) tell me if the API is able to handle the creation of candidates and visits for a given Candidate by login with a user that is affiliated to multiple sites (right now, if I want to add a new Candidate and Visits, for that candidate, in a given Center, I have to login with the associated User to that Center)


Thank you.


Best,

Alfredo.


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.bic.mni.mcgill.ca/pipermail/loris-dev/attachments/20171109/7b871f4a/attachment-0001.html>


More information about the Loris-dev mailing list