Skip to content

User

User table stores information about Individual who is accessing nuphi portal.

Info

User must be either belongs to organization or Service provider company.

Attributes

email: Unique Email Address of the user. Also primary key of the table.

uuid: Unique uuid generated by system.

firstName: First name of the user.

lastName: Last name of the user.

password: Password of the user account in encrypted form.

designation: Designation of the user in organisation.

countryCode: Country code of the user's phone Number.

phoneNumber: Phone number of the user.

isVerified: Boolean value indicating whether user account is verified or not.

lastLogin: Date field which stores information about user last login activity.

metaData: JSON object to stores information about other meta data information which does not require any computation.

orgId: Foreign key of Organisation table. This field stores the information of the organisation in which user belongs.

orgRoleId: Foreign key of Organisation Role table. This field stores the information of the organisation role which is assigned to the user.

servProvId: Foreign key of Service provider table. This field stores the information of the Service provider company in which user belongs.

isRootUser: Boolean value indicating whether user account is root account or not.

Info

Root account user has access to all the module by default.

isTwoFactor: Boolean value indicating whether user account has enabled two factor authentication.

preferences: JSON object to stores information about email notification preferences.


Associations

Organisation

User always belongs any one organisation

OrganisationRole

USer always belongs any one organisation role.

ServiceProvider

User always belongs any one service provider.