VivoQuant 5.4.1
Loading...
Searching...
No Matches
Public Slots | Public Member Functions | List of all members
WebECRF Class Reference

Object to manage an eCRF web form. More...

#include <WebECRF.h>

Public Slots

void waitForLoad ()
 Lock execution until current page has finished loading.
 

Public Member Functions

Object getElement (string query)
 Gets a specific element from DOM.
 
Object getAllElements (string query)
 Gets a list of element from DOM.
 
void evalJavaScript (string js)
 Allows running custom JavaScript code on the provided page.
 
void updateFormModel ()
 Update form model with the values previously set. Use this when evalJavaScript is called to edit the fields.
 
void setDebug (bool debug)
 Enable/disable HTML source text view.
 
void setQuiet (bool quiet)
 Enable/disable the display of message boxes.
 
void setSelectedDataIndex (int index)
 Sets the data to which the form should be associated with.
 
void clearCredentials ()
 Resets the credentials used by the webview.
 
bool isDigitalSignatureRequired ()
 Checks if the digital signature is required or not.
 
bool hasError ()
 Checks if the eCRF module has error.
 
string getLastMessage ()
 Gets the last success or error message.
 
void enableRefresh (bool enabled)
 Set the refresh button state of the eCRF from.
 
void setReadOnly (bool readOnly)
 Set the eCRF content to be read only.
 
void hide ()
 Hides the form.
 
void show ()
 Shows the form (will only work if hide() was previously called)
 
void cancel ()
 Close the form (same behavior as closing the form with the X)
 

Detailed Description

Object to manage an eCRF web form.

This object can be used display an iPACS form

See also ScriptMaster::eCRF() to obtain this object.

Member Function Documentation

◆ enableRefresh()

void enableRefresh ( bool  enabled)

Set the refresh button state of the eCRF from.

Parameters
enabledTrue to enable, false otherwise

◆ evalJavaScript()

void evalJavaScript ( string  js)

Allows running custom JavaScript code on the provided page.

Parameters
jsthe custom javascript code

◆ getAllElements()

Object getAllElements ( string  query)

Gets a list of element from DOM.

Parameters
queryThe query based on css selectors (see https://www.w3schools.com/cssref/css_selectors.asp)
Returns
a ScriptableWebElement object list

◆ getElement()

Object getElement ( string  query)

Gets a specific element from DOM.

Parameters
queryThe query based on css selectors (see https://www.w3schools.com/cssref/css_selectors.asp)
Returns
a ScriptableWebElement object

◆ getLastMessage()

string getLastMessage ( )
inline

Gets the last success or error message.

Returns
A string containing the last error message.

◆ hasError()

bool hasError ( )
inline

Checks if the eCRF module has error.

Returns
True if an error occured, false otherwise

◆ isDigitalSignatureRequired()

bool isDigitalSignatureRequired ( )

Checks if the digital signature is required or not.

Returns
Returns true if the digital signature is required for the form

◆ setDebug()

void setDebug ( bool  debug)

Enable/disable HTML source text view.

Parameters
debugSet to true to enable the debug output

◆ setQuiet()

void setQuiet ( bool  quiet)
inline

Enable/disable the display of message boxes.

Parameters
quietSet to true to enable quiet mode

◆ setReadOnly()

void setReadOnly ( bool  readOnly)

Set the eCRF content to be read only.

Parameters
readOnlyTrue to be read only, false otherwise

◆ setSelectedDataIndex()

void setSelectedDataIndex ( int  index)

Sets the data to which the form should be associated with.

Parameters
indexThe DataManager index