@veeva/myinsights_javascript_library v0.0.9
Table of Contents
- DataAccessLibrary- queryRecord
- runQuery
- querySalesData
- joinQueries
- getInStatement
- getDataForCurrentObject
- getObjectLabels
- getFieldLabels
- getPicklistValueLabels
- getVeevaMessagesWithDefault
- checkQueryQueue
- newRecord
- viewRecord
- smartLinking
- executeSuggestionAction
- launchMediaForAccount
- getAvailableObjects
- getObjectMetadata
- getRecordTypeLabels
- queryVDSRecord
 
- OnlineAPI
- Utilities
DataAccessLibrary
queryRecord
Parameters
- queryObjectObject
Returns Promise
runQuery
Parameters
- queryConfigObject
Returns Promise
querySalesData
Parameters
- queryObject
- Object
Returns Promise
joinQueries
Parameters
- q1Object The query to which to outerjoin q2
- q2Object The query to which to outerjoin to q1
- keyForIDString The member name of what to consider as the primary key
- fieldsLabelsToExcludeArray
- primaryObjectNameString The object name assigned to the query desired to be the primary query to which to join the non-primary query.
Returns Object Joined query result
getInStatement
Generates an in-statment fragment to be included in a query.
Parameters
- idsArray the ids to include in the generated in-statement
Returns string In-statement to use in a query
getDataForCurrentObject
Returns the value of a field for a specific record related to the current object
Parameters
- objectString The api name of the object on which the field can be found.
- fieldString The name of the field whose value you want returned.
Returns Promise
getObjectLabels
Parameters
- objectsArray API names of objects for which to retrieve object labels.
Returns Promise
getFieldLabels
Parameters
- queryConfigObject
Returns Promise
getPicklistValueLabels
Returns the translated label for each of the picklist values of the specified field
Parameters
Returns Promise
getVeevaMessagesWithDefault
Parameters
- tokensArray The tokens for which to get translations
- languageLocaleKeyString Locale key of the translations to return.
Returns Promise
checkQueryQueue
Returns Promise
newRecord
Parameters
- configObjectObject
Returns Promise
viewRecord
Parameters
- configObjectObject
Returns Promise
smartLinking
Parameters
- configObjectObject
Returns Promise
executeSuggestionAction
Parameters
Returns Promise
launchMediaForAccount
Parameters
Returns Promise
getAvailableObjects
Returns Promise
getObjectMetadata
Parameters
- queryObjectObject
Returns Promise
getRecordTypeLabels
Parameters
- objectNameString
Returns Promise
queryVDSRecord
CDW Query Record
Parameters
- configObject
- Object
Returns Promise
Meta
- copyright: All rights reserved
OnlineAPI
Extends DataAccessLibrary
Overrides for the online environment.
genericQueryErrorHandler
Parameters
- eObject Error
Returns null
queryRecord
Parameters
- queryObjectObject
Returns Promise
querySalesData
Parameters
- queryObject
- Object
Returns Promise
query
Parameters
- queryConfigObject
Returns Promise
getDataForCurrentObject
Returns the value of a field for a specific record related to the current object
Parameters
- objectString The api name of the object on which the field can be found.
- fieldString The name of the field whose value you want returned.
Returns Promise
getObjectLabels
Parameters
- objectsArray API names of objects for which to retrieve object labels.
Returns Promise
getFieldLabels
Parameters
- queryConfigObject
Returns Promise
getTranslation
Parameters
Returns Promise
getPicklistValueLabels
Returns the translated label for each of the picklist values of the specified field
Parameters
Returns Promise
newRecord
Parameters
- configObjectObject
Returns Promise
viewRecord
Parameters
- configObjectObject
Returns Promise
smartLinking
Parameters
- configObjectObject
Returns Promise
getAvailableObjects
Returns Promise
getObjectMetadata
Parameters
- queryObjectObject
Returns Promise
getRecordTypeLabels
Parameters
- objectNameString
Returns Promise
Utilities
Provided for your convenience.
isWin8
Returns Boolean Returns true if the client is Windows 8
isOnline
Returns Boolean
addMessageListener
Adds a listener for the rest api call callback
Parameters
- callbackFunction Listener function
Returns Function The callback function passed in.
removeMessageListener
Parameters
- callbackFunction Listener function to remove
Returns undefined
mergeObjects
Parameters
- dstobject Source of truth object to which to add members from src object.
- srcobject Object from which to copy members to dst
- clobberboolean Boolean to indicate if src members should override dst members.
Returns object
copyObject
Parameters
- objObject Object to copy
Returns Object
deepCopy
Parameters
- originalObjectObject The object to copy.
Returns Object
replaceStringInWhereClause
Parameters
- whereClauseString
- inputString String to use in place of stringToBeReplaced
- stringToBeReplacedString The string to replace with the input.
Returns String