     
     var nameField: UITextField?
     var scoreField: UITextField?
+    
+    var selectedDate: Date = Date()
     
     // MARK: - Overrides
     

    
    
    @IBAction func onSave(_ sender: UIBarButtonItem) {
    }
    
    func datePickerChange(sender: UIDatePicker) {
        let formatter = DateFormatter()
        formatter.dateStyle = .long
        formatter.timeStyle = .none
        
        self.dateLabel.text = formatter.string(from: sender.date)
    }
    

//

import UIKit
import RealmSwift

class AddEditAssignmentTableViewController: UITableViewController, UITextFieldDelegate,
                                            UIPickerViewDelegate, UIPickerViewDataSource {

    // MARK: - Properties
    
    // Realm database object
    let realm = try! Realm()
    
    @IBOutlet weak var saveButton: UIBarButtonItem!
    var parentClass: Class!
    
