Difference between revisions of "Custom Field Type: Special - Web Page View"

From SmartWiki
Jump to: navigation, search
Line 49: Line 49:
  
 
{{PDFOptions}}
 
{{PDFOptions}}
Note: if you want to hide the instructions that display inside the caption, only on this web page view or PDF, add the following to your webpage view.
+
Note: if you want to hide the instructions that display inside the caption, only on this web page view or PDF, add the following to your webpage view:
  
 
  <nowiki>
 
  <nowiki>

Revision as of 08:37, 17 August 2016

Click here to peruse our selection of custom fields.

General Description

A Web Page View field is used to create a “document” based on underlying entity data. The field type has a wide variety of document management options associated including the conversion to PDF or XML.

Field Display

Display only wpv ex1.png
Display Only - Web Page View, in View Mode


Display only wpv ex2.png
Display Only - Web Page View, in Document Window – some Options enabled

Field Options

Option Description Format
Custom Field ID The unique ID number associated with the custom field. Not Applicable
Field Type The list of available Field Types. @fieldtype@
Field Name The name of the field, used internally to reference the user's input; @fieldname@
Caption  The leading question or prologue before the field. @caption@
Display Order  The order (relative to other fields) in which this field is displayed. @displayorder@
Description Definition and general description of the custom field. Will not be displayed. @description@
  • Button Label: Text to be displayed on the field's button. If no text is entered, the system will use a default label.
  • Appear Mandatory: Makes the field appear as though it is a required field. Typically used in conjunction with browser scripts, JavaScript Validation or Submit Logic that perform validation.
  • Tool Tip: When the user hovers their mouse pointer over the caption of a field, the text in this section will appear.
  • On New Record: Controls how the field should be displayed until record has been saved once.
    • Always Display: Field will be exposed both before and after the record is saved.
    • Hide on New Record: Field will be hidden until record is saved.
    • Only Show on New Record: Field will be exposed until record is saved, and then it will be hidden. This option is useful for fields that provide instructions for filling out forms before saving.
  • Custom Field Ids: See Custom Field IDs for instructions.

Special Field Options

  • HTML Template – the body of the document combined with variables from the underlying entity. The content of this field should conform to any Accessibility legislation.
  • SmartField Sample Template - click this option to convert the HTML Template into a SmartField Template view for easy document formatting.
  • Custom Field IDs -

Options

General Options

  • Mandatory: Selecting this option means that this field is required and must be completed.
  • Disable Field From Global Search: Selecting this option means that the contents of this field will not be displayed in Global Search results.

Document Options

General Options

  • Allow Printing – enables the user to print the resultant document.
  • Allow Editing – enables the user to edit the document with the HTML Editor
  • Allow New Window – displays the document in a new window so the browser’s print function can be used.
  • Allow New Window Automatically – automatically displays the document in a new window so the browser’s print function can be used.
  • Allow Switching Language - adds a Language Switcher dropdown at the top of the Web Page View: Cf-wpv-3.png
  • Is XML – indicates that the document is to be prepared as an XML output.
  • Automatically Use User ID as File Name - when using the PDF or HTML Save to Multiple File Field options (explained below) the filename of the file stored within the Multiple Files field will be named with the userid of the current user. See also the File Name PDF option below.
Note: if a file with that name already exists in the Multiple Files field it will be replaced with the new one, unless the Keep Version setting is enabled on the Multiple Files field.
  • Open in Lightbox - displays the document in a Lightbox.
  • Directly Export to PDF - with this field selected, the document will be exported to PDF format.
  • Deprecated - HCAI Enabled - See HCAI Overview for additional information.
  • Deprecated - HCAI Automatically Redirect - See HCAI Overview for additional information.

PDF Options

  • Open Directly as PDF - this setting automatically exports the web page view to PDF format. This eliminates the step of loading the web page view in a modal window and clicking export to PDF.
  • Enable Online Signature - enables the online signature feature to be applied to the document.
  • Enable Password Protection – this setting is used in conjunction with the PDF settings of Enable Email as Attachment and Save to Server. If this setting is toggled on and the user clicks Email as PDF or Save To Server as PDF, then the user will be prompted to enter a password that will lock the PDF. The Password the user entered will be required to open the PDF generated and emailed or saved to server.
  • Enable Email as Attachment – enables the user to send the PDF as an attachment to an email message.
  • Enable Export – adds an Export as DOCX button to the modal window, that allows the user to save a local copy of the web page view content in a Word document. Note formatting will not be maintained and some field types may not render as expected.
  • Enable Save to server – enables the user to save the document as a PDF into any multiple file type fields in the related entity.

Note: if you want to hide the instructions that display inside the caption, only on this web page view or PDF, add the following to your webpage view:

<style>
 .FormInstructions{display:none;}
</style>

HTML Options

  • Enable Email as Attachment – enables the user to send the document as the body of an email message.
  • Enable Save to Server – enables the user to save the document as a HTML document into any multiple file type fields in the related entity.
  • Enable Export – enables the user to save a local copy of the HTML document.

Value Storage

  • Value Storage: Enables linking two different custom fields to the same user data. See Value Stores To page.
  • Enforce Selection - makes the Multiple Files custom field selected as the Value Storage field the only field the file can be stored to.


Permissions & Availability Tab


Notes

sslogic Web Page View fields can use a unique SmartSimple logic interpreter. Web page logic gives you the ability to display certain content or perform certain actions only when specified conditions are met. SmartSimple logic follows the following template:

<!--@sslogic(CONDITION)-->
 The content to be displayed when condition is true
<!--@end-->

See here for further details.

Hyperlink to Web Page View You can create a link to a web page view field using the following syntax:

<a href="@wpv.value@">Open WPV</a>

Where wpv is the name of the Web Page View field.

Multi-Line Text

To include Multi-Line Text fields in a Web Page View you need use the following syntax to ensure that line breaks are displayed correctly when the page is converted to PDF format.

<div style="display:block;pd4ml-display:none;white-space:pre-wrap;" >~Narrative~</div>
<div style="display:none;pd4ml-display:block;white-space:pre;word-wrap:break-word;" >~Narrative~</div>

The first div displays correctly in the Web Page View and the second div displays correctly in the PDF version

See Also