The SimpleForm API provide several methods to customize forms. simple-form.js is the JavaScript class containing the methods. SimpleForm methods can be used on the client side only. Use these methods to submit user changes to the form view of records, such as changing or clearing the field values, saving records and so on.
Some of these methods can also be used in other client scripts but must first be tested to confirm that they will be working correctly.
s_form.addErrorMessage(string message)
s_form.addInfoMessage(string message)
s_form.addOption(string fieldName, string choiceValue, string choiceLabel)
s_form.clearMessages()
s_form.clearOptions(string fieldName)
s_form.clearValue(string fieldName)
s_form.getLabelOf(string fieldName)
s_form.getSectionNames()
s_form.getSections()
s_form.hideRelatedList(string listTableName)
s_form.hideRelatedLists()
s_form.initialize(string table)
s_form.isNewRecord()
s_form.isSectionVisible(string sectionName)
s_form.removeOption(string fieldName, string choiceValue)
s_form.save()
s_form.setLabelOf(string fieldName, string value)
s_form.setMandatory(string fieldName, boolean mandatory)
s_form.setReadOnly(string fieldName, boolean readOnly)
s_form.setSectionDisplay(string sectionName, boolean display)
s_form.setVisible(string fieldName, boolean display)
s_form.showFieldMsg(string fieldName, string message, string type)
s_form.showRelatedList(string listTableName)
s_form.showRelatedLists()
s_form.showRelatedLists(string listTableName)
s_form.submit()