title: Ember.js - How to clear the form data after saving the record?
body: <p>I'm using Ember App Kit.  I have a form that takes a student name and I can save the data into a database without any problem.  The problem is the data (student name) retains on the form whenever I get transition back to this route (<code>http://localhost:8000/#/students/new</code>) from another page.  If I refresh the screen, then the data will be cleared out and I will get a fresh form. What am I doing wrong? </p>
  
  <p>Also, if I decide not to save or add the record and go to see the list of students, I see an empty record on screen.  That record is not in the database though.  How can I prevent that?</p>
  
  <pre><code>//--------------------------------------------
  // Controller
  
  var StudentsNewController = Ember.ObjectController.extend({
      init: function() {
          var newSystem = this.store.createRecord('student');
          this.set('newStudent', newStudent);
          this._super();
      },
      actions: {
          acceptChanges: function () {
              var self = this;
              self.get('newStudent').save().then(function(student){
                  self.transitionToRoute('students');
              });
          }
      }
  });
  
  export default StudentsNewController;
  
  //--------------------------------------------    
  // Model
  
  var Student = DS.Model.extend({
      name: DS.attr('string'),
      major: DS.belongsTo('major')
  
  });
  
  export default Student;
  
  //--------------------------------------------    
  // Template
  
      &lt;form  {{action 'updateSystem' on="submit"}}&gt;
          &lt;fieldset&gt;
                  &lt;div&gt;
                      &lt;label&gt;Student Name&lt;/label&gt;
                      {{input value=newStudent.name size="50"}}
                  &lt;/div&gt;
                  &lt;button {{action 'acceptChanges'}}&gt;Add&lt;/button&gt;
          &lt;/fieldset&gt;
      &lt;/form&gt;
  </code></pre>