528
edits
No edit summary |
|||
Line 54: | Line 54: | ||
Remember that when an external link is opened, in order to auto-close the pop-up modal hosting the external link, the child page must fire an iFrame event with the event_id attribute set to “'''3bonboarding_externalLink'''”. | Remember that when an external link is opened, in order to auto-close the pop-up modal hosting the external link, the child page must fire an iFrame event with the event_id attribute set to “'''3bonboarding_externalLink'''”. | ||
== '''Document Context''' == | |||
By default, we determine the displayed document context as that of the logged in user. So, if you create a Document or a Form, they will be displayed with context record Contact (that of the logged in user). | |||
Often, we need to create documents and forms that use a context object different than that of the Contact, for example an Application, Placement, Opportunity etc. | |||
To allow documents and forms to be merged with the correct context, all an admin needs to do is add a Lookup relationship on the Document Assignment looking up to the new context object (say, Target Recruit Job Applicant object). Then, when a Document Assignment is created, it must have the new lookup set to the record to be used for merging, and of course, any implementing documents and forms must also be built with the same context object as the core object. | |||
A document pack may have a mix between different merge contexts, we derive the merge context from the Form or Document (Template) record, there should be a field named "Core Object". | |||
== '''Creating a new Document''' == | == '''Creating a new Document''' == | ||
Line 98: | Line 107: | ||
You can then select who you want to assign the document pack. At the end of the process, the contact(s) selected will be assigned with a new record of the object type “Document Assignment” for each document pack that was selected to be assigned. | You can then select who you want to assign the document pack. At the end of the process, the contact(s) selected will be assigned with a new record of the object type “Document Assignment” for each document pack that was selected to be assigned. | ||
The '''Document Assignment record''' links the Contact and Document Pack and tells the MyDocuments page/plugin to render the document pack for the candidate. | |||
The '''Document Assignment record''' links the Contact and Document Pack and tells the MyDocuments page/plugin to render the document pack for the candidate. | The '''Document Assignment record''' links the Contact and Document Pack and tells the MyDocuments page/plugin to render the document pack for the candidate. | ||
Line 108: | Line 118: | ||
== '''My Documents Plugin''' == | == '''My Documents Plugin''' == | ||
My Documents plugin can be used outside of Salesforce or on a specially branded Visualforce page by importing the component using the following example:<syntaxhighlight lang="javascript"> | |||
<apex:page showHeader="false" sidebar="false" standardStylesheets="false" controller="GlobalRemotingRouter" | |||
docType="HTML-5.0" applyHtmlTag="false" applyBodyTag="false"> | |||
<html> | |||
<head> | |||
<title>Documents</title> | |||
<meta charset="utf-8"/> | |||
<meta name="viewport" content="initial-scale = 1.0,maximum-scale = 1.0" /> | |||
<!-- Load Supporting Components and Global Functions --> | |||
<script src="{!URLFOR($Resource.b3o__GeneralUtils, 'index.js')}" defer="true" type="module"></script> | |||
<!-- This Component --> | |||
<script src="{!URLFOR($Resource.b3o__MyDocuments, 'index.js')}" defer="true" type="module"></script> | |||
<style> | |||
</style> | |||
</head> | |||
<body> | |||
<div class="container"> | |||
<div id="my-documents" class="documents-wrapper"> | |||
</div> | |||
<user-documents | |||
public-site="{!$Site.baseUrl}" | |||
></user-documents> | |||
</div> | |||
<script> | |||
const globals = { | |||
sessionId: '{!GETSESSIONID()}', | |||
siteUrl: '{!$Site.baseUrl}', | |||
useREST: false, | |||
router: b3o.GlobalRemotingRouter | |||
}; | |||
window['globals'] = globals; | |||
</script> | |||
</body> | |||
</html> | |||
</apex:page> | |||
</syntaxhighlight> | |||
== '''Distribution''' == | == '''Distribution''' == |