Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escape special characters +-&|!(){}[]^"~*?:\ - e.g. \+ \* \!
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
 
Answered
Accessing specific user details

Hi, we are trying to get the user related data such as their Business Name, Business Email, Businees Address, Business Phone and Business SSN.

While the Business phone can be accessed via self.online_user.work_phone what are the ways in which we can access the other attributes mentioned above?

Also, how do we identify the permission levels of the user?

Thanks
Mandeep Singh

Votes Newest

Answers


Hi Mandeep,

That is correct, you can use self.online_user to retrieve user demographic information. Their business phone can be found via the self.online_user.work_phone property you mentioned, or the demographic_info attribute that we provide (self.online_user.demographic_info) which would contain other bits of information about the user (see https://docs.q2developer.com/api_references/q2_sdk/shared_models/demographic.html). It could be utilized to grab a list of phones (which could be filtered by PhoneType to retrieve the business phone) and grab a list of addresses (filter by AddressType for business address information). I don't believe we currently provide a way to differentiate user email as "Business" or other, however the DemographicInfo object does return a list of emails for that user. You can also make use of our DBObjects to retrieve customer/user information (see https://docs.q2developer.com/api_references/q2_sdk/db/db_objects/user.html and https://docs.q2developer.com/api_references/q2_sdk/db/db_objects/customer.html)

You can find more detail about access and user rights through our UserPropertyDataElement (https://docs.q2developer.com/api_references/q2_sdk/db/db_objects/user_property_data_element.html) and UserPropertyData (https://docs.q2developer.com/api_references/q2_sdk/db/db_objects/user_property_data.html) DBObjects. The UserPropertyElement DBObject is used to define the types of things the user can do (refered to as elements) while the UserPropertyData DBObject serves as a mapping with the User DBObject to determine which of those elements are turned on for a particular user). We also provide a couple of methods within our PolicyData DBObject that allow you to retrieve policy information (generated transaction rights, accounts, subsidiaries, features) for a user, customer, group and update it (see https://docs.q2developer.com/api_references/q2_sdk/db/db_objects/policy_data.html).

Thanks,
Solène

Posted 3 years ago
135 Views
1 Answer
3 years ago
3 years ago