Skip to content
This repository has been archived by the owner on Apr 19, 2021. It is now read-only.

Validation Not Working when Submit button is clicked #164

Open
moderateepheezy opened this issue Aug 14, 2017 · 0 comments
Open

Validation Not Working when Submit button is clicked #164

moderateepheezy opened this issue Aug 14, 2017 · 0 comments

Comments

@moderateepheezy
Copy link

fileprivate func loadForm() {
        let form = FormDescriptor(title: "Address")
        
        let section1 = FormSectionDescriptor(headerTitle: nil, footerTitle: nil)
        
        var row = FormRowDescriptor(tag: Static.fullNameTag, type: .name, title: "Full Name")
        row.configuration.cell.appearance = ["textField.placeholder" : "John Doe" as AnyObject, "textField.textAlignment" : NSTextAlignment.right.rawValue as AnyObject]
        row.configuration.cell.required = true
        section1.rows.append(row)
        
        row = FormRowDescriptor(tag: Static.emailTag, type: .email, title: "Email")
        row.configuration.cell.appearance = ["textField.placeholder" : "e.g johndoe@gmail.com" as AnyObject, "textField.textAlignment" : NSTextAlignment.right.rawValue as AnyObject]
        row.configuration.cell.required = true
        section1.rows.append(row)
        
        form.sections = [section1]
        form.validateForm()
        
        self.form = form
}
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant