604
edits
No edit summary |
No edit summary |
||
Line 747: | Line 747: | ||
=== “jobApp” === | === “jobApp” === | ||
This is the plugin that enables the job application workflow | This is the plugin that enables the job application workflow | ||
To include the plugin on a Visualforce Page, use this script:<syntaxhighlight lang="html"> | To include the plugin on a Visualforce Page, use this script:<syntaxhighlight lang="html"> | ||
<apex:includeScript value="{!URLFOR($Resource.b3o__JobAppResources, 'api/js/remote.js')}"/> | <apex:includeScript value="{!URLFOR($Resource.b3o__JobAppResources, 'api/js/remote.js')}"/> | ||
Line 802: | Line 800: | ||
|false | |false | ||
|} | |} | ||
=== “myDocs” === | |||
This is the plugin that runs the My Documents component. Include the below scripts and links:<syntaxhighlight lang="html" line="1"> | |||
<!-- Web Components --> | |||
<script src="{!URLFOR($Resource.b3o__GeneralUtils, 'utils/communication.js')}" type="module"/> | |||
<script src="{!URLFOR($Resource.b3o__GeneralUtils, 'utils/toasts.js')}" type="module"/> | |||
<script src="{!URLFOR($Resource.b3o__GeneralUtils, 'components/loading-spinner/loadingSpinner.js')}" type="module"/> | |||
<script src="{!URLFOR($Resource.b3o__MyDocuments, 'api/components/document-submissions-list/documentSubmissionsList.js')}" type="module"/> | |||
<script src="{!URLFOR($Resource.b3o__MyDocuments, 'api/components/document-pack-table/documentPackTable.js')}" type="module"/> | |||
<script src="{!URLFOR($Resource.b3o__MyDocuments, 'api/components/document-pack/documentPack.js')}" type="module"/> | |||
<!-- Plugin --> | |||
<apex:includeScript value="{!URLFOR($Resource.MyDocuments, 'api/js/app.js')}" /> | |||
<link href="{!URLFOR($Resource.b3o__MyDocuments, 'api/css/styles.css')}" rel="stylesheet" /> | |||
</syntaxhighlight> | |||
{| class="wikitable" | |||
!Property | |||
!Type | |||
!Description | |||
!Default | |||
!Required | |||
|- | |||
|rootEl | |||
|string | |||
|This is the ID of the root element where the modal will be rendered into | |||
|N/A | |||
|true | |||
|- | |||
|publicSiteURL | |||
|string | |||
|This is the Site/Community base endpoint. | |||
|{!$Setup.b3o__Onboarding_Default_Settings__c.b3o__Site_URL__c} | |||
|true | |||
|- | |||
|userId | |||
|string | |||
|Required - contact id or user id | |||
|N/A | |||
|true | |||
|- | |||
|documentPackId | |||
|string | |||
|A filter on a specific document pack to be loaded | |||
| | |||
|false | |||
|- | |||
|applicationId | |||
|string | |||
| | |||
| | |||
| | |||
|- | |||
|localeCode | |||
|string | |||
|The default locale code (en-GB, es-ES) | |||
|Retreived window.navigator.language | |||
|false | |||
|- | |||
|dateFormat | |||
|object | |||
|Date format for Date.toLocaleDateString() | |||
|{ year: 'numeric', month: 'numeric', day: 'numeric' } | |||
|false | |||
|- | |||
|showDetailsOnLoad | |||
|boolean | |||
|Whether or not to show previous submissions on page load | |||
|true | |||
|false | |||
|- | |||
|ContextLookupField | |||
|string | |||
|Secondary context to be added to 3B Forms. Usually an Application/Placement record lookup. Works with Target Recruit App, Bullhorn App or any other custom object lookup | |||
|b3o__X3B_Application__c | |||
|false | |||
|- | |||
|AssignmentBadgeFieldPaths | |||
|array | |||
|An array of field paths starting from the Document Assignment to be rendered as badges on the Document Pack | |||
|[ | |||
'b3o__X3B_Application__r.Name', | |||
'b3o__X3B_Application__r.b3o__Job__r.Name' | |||
] | |||
|false | |||
|- | |||
|LBL_HeaderComments | |||
|string | |||
|Label | |||
|Comments | |||
|false | |||
|- | |||
|LBL_HeaderStatus | |||
|string | |||
|Label | |||
|Status | |||
|false | |||
|- | |||
|LBL_HeaderDocument | |||
|string | |||
|Label | |||
|Document | |||
|false | |||
|- | |||
|BTN_Submit | |||
|string | |||
|Label | |||
|Submit | |||
|false | |||
|- | |||
|BTN_Edit | |||
|string | |||
|Label | |||
|Edit | |||
|false | |||
|- | |||
|BTN_Re_Submit | |||
|string | |||
|Label | |||
|Re-Submit | |||
|false | |||
|- | |||
|BTN_Approved | |||
|string | |||
|Label | |||
|Approved | |||
|false | |||
|- | |||
|BTN_Invalid | |||
|string | |||
|Label | |||
|Invalid | |||
|false | |||
|- | |||
|BTN_PendingSubmission | |||
|string | |||
|Label | |||
|Pending Submission | |||
|false | |||
|- | |||
|BTN_CompleteDocumentPack | |||
|string | |||
|Label | |||
|Submit for Approval | |||
|false | |||
|- | |||
|BTN_CompleteDocumentPackAgain | |||
|string | |||
|Label | |||
|Re-Submit for Approval | |||
|false | |||
|- | |||
|MSG_NoDocumentAssignments | |||
|string | |||
|Label | |||
|No documents are assigned to you currently. Please try again later | |||
|false | |||
|- | |||
|MSG_NotLoggedInMessage | |||
|string | |||
|Label | |||
|You have followed an invalid link or you are not logged in | |||
|false | |||
|- | |||
|MSG_GeneralError | |||
|string | |||
|Label | |||
|There was an unexpected error. Please try again later | |||
|false | |||
|- | |||
|MSG_ConfirmDocAssignmentSubmission | |||
|string | |||
|Label | |||
|Are you sure you want to continue | |||
|false | |||
|- | |||
|LINK_VFBaseURL | |||
|string | |||
|Base URL for displayed VF pages | |||
|{!$Setup.b3o__Onboarding_Default_Settings__c.b3o__Visualforce_External_Site_URL__c} | |||
|false | |||
|- | |||
|LINK_Form | |||
|string | |||
|3B Form template url. | |||
{0} - form Id | |||
{1} - contact id | |||
{2} - context lookup field on assignment | |||
|apex/b3f__formcomplete?id={0}&ContactId={1}&b3o__Application__cId={2}&ContextLookupField={2} | |||
|false | |||
|- | |||
|LINK_Document | |||
|string | |||
|3B Docs template url. | |||
{0} - template id | |||
{1} - contact id or context id | |||
|apex/b3d__Document?templateId={0}&recordId={1} | |||
|false | |||
|- | |||
|LINK_QuestionSet | |||
|string | |||
|3B Assessment template url. | |||
{0} - contact id | |||
{1} - question set id | |||
{2} - document id | |||
{3} - context id | |||
|apex/b3o__jobapplication?uId={0}&qsId={1}&docId={2}&applicationId={3} | |||
|false | |||
|} | |||
To include on a Visualforce Page, use the below example:<syntaxhighlight lang="javascript"> | |||
myDocs.init({ | |||
rootEl: 'my-documents', | |||
publicSiteURL: '{!$Setup.b3o__Onboarding_Default_Settings__c.b3o__Site_URL__c}', | |||
LINK_VFBaseURL: '{!$Setup.b3o__Onboarding_Default_Settings__c.b3o__Visualforce_External_Site_URL__c}', | |||
BTN_Approved: 'Approved', | |||
userId: userId, | |||
documentPackId: documentPackId, | |||
localeCode: 'en-GB', | |||
showDetailsOnLoad: {!$Setup.b3o__Onboarding_Default_Settings__c.b3o__My_Docs_Show_Expanded_Details_on_Load__c}, | |||
ContextLookupField: 'b3o__X3B_Application__c', | |||
AssignmentBadgeFieldPaths: [ | |||
'b3o__X3B_Application__r.Name', | |||
'b3o__X3B_Application__r.b3o__Job__r.Name' | |||
] | |||
}).then(value => { | |||
console.log('Loaded [MYDOCUMENTS]', value); | |||
}).catch(error => { | |||
console.error('Error Loading Component [MYDOCUMENTS]', error); | |||
}).finally(fin =>{ | |||
}); | |||
</syntaxhighlight> | |||
== '''Authentication Context''' == | == '''Authentication Context''' == | ||
3B components are designed to be running in internal user context, community user context or un-authenticated guest user context. When running our components in the later context, you are responsible for implementing a reliable and secure authentication and communication mechanism. We provide a component “jobBoardActions” that manages authentication using 3B Forms, however we view this as dangerous and prone to brute force attacks. Always implement full-blown community licenses where possible for external candidate communication. | 3B components are designed to be running in internal user context, community user context or un-authenticated guest user context. When running our components in the later context, you are responsible for implementing a reliable and secure authentication and communication mechanism. We provide a component “jobBoardActions” that manages authentication using 3B Forms, however we view this as dangerous and prone to brute force attacks. Always implement full-blown community licenses where possible for external candidate communication. |