When a field on a custom template popup is marked as “required” (UI required, not SFDC required), the record is allowed to be saved without specifying a value in the field.
Steps to reproduce:
- Create new Account Detail page
- Add template field to field editor
- Set template to “{{BillingCity}}”
- Choose “Show custom popup”
- Change the “Billing City” field in the popup to required leaving all other default config
- Preview the page
- Go in to edit mode of the popup and make sure there is no value
- If “Save” isn’t enabled, make a change on Name field
- Save the record
Actual Result
Record is saved
Expected Result
Validation error for Required field BillingCity should be displayed
Sample Page XML
<skuidpage unsavedchangeswarning="yes" showsidebar="true" showheader="true" tabtooverride="Account"> <models>
<model id="Account" limit="1" query="true" createrowifnonefound="false" sobject="Account">
<fields>
<field id="Name"/>
<field id="CreatedDate"/>
<field id="BillingCity"/>
<field id="BillingCountry"/>
</fields>
<conditions>
<condition type="param" enclosevalueinquotes="true" operator="=" field="Id" value="id"/>
</conditions>
<actions/>
</model>
</models>
<components>
<pagetitle model="Account">
<maintitle>
<template>{{Name}}</template>
</maintitle>
<subtitle>
<template>{{Model.label}}</template>
</subtitle>
<actions>
<action type="savecancel" window="self"/>
</actions>
</pagetitle>
<basicfieldeditor showsavecancel="false" showheader="true" model="Account" mode="read" buttonposition="" layout="">
<columns>
<column width="100%">
<sections>
<section title="Basics" collapsible="no">
<fields>
<field id="Name" valuehalign="" type=""/>
<field type="COMBO" valuehalign="" editmodebehavior="custompopup">
<label>Billing City Template</label>
<template>{{BillingCity}}</template>
<editmodepopup title="Billing City Template" width="450">
<components>
<basicfieldeditor showsavecancel="false" mode="edit" model="Account">
<columns>
<column width="100%">
<sections>
<section title="">
<fields>
<field id="BillingCity" valuehalign="" type="" required="true"/>
</fields>
</section>
</sections>
</column>
</columns>
</basicfieldeditor>
</components>
</editmodepopup>
</field>
</fields>
</section>
</sections>
</column>
</columns>
</basicfieldeditor>
</components>
<resources>
<labels/>
<css/>
<javascript/>
</resources>
</skuidpage>