title: While Adding New Entity, Identity value is not generated
body: <p>I am running into problem, where i extend the Entity to expose hasValidationError. Without that it works fine. Also i found that if I supply the ID before adding the entity it works fine as well. Why is the ID field not auto generating once the entity is extended on the client.</p>
  
  <p>I am now using little different version of the code(i find it more intuitive to extend the entity this way), but it still errors out in the same way.</p>
  
  <pre><code>       var Country = function () {
                             console.log("Country initialized");
                             var self = this;
                             self.Country_ID = ko.observable(""); 
                             self.Country_Code = ko.observable("");  
                             self.Country_Name = ko.observable().extend({
                                 validation: {
                                     validator: function (val, someOtherVal) {
  
                                         return false;//val === someOtherVal;
                                     },
                                     message: 'Invalid Value!',
                                     params: 5
                                 }
                             });
  
                             var prop = ko.observable(false);
  
                             var onChange = function () {
                                 var hasError = self.entityAspect.getValidationErrors().length &gt; 0;
  
                                 if (prop() === hasError) {
                                     // collection changed even though entity net error state is unchanged
                                     prop.valueHasMutated(); // force notification
                                 } else {
                                     prop(hasError); // change the value and notify
                                 }
                             };
  
                             // observable property is wired up; now add it to the entity
                             self.hasValidationErrors = prop;
  
                             //dummy property to wireup event
                             //should not be used for any other purpose
                             self.hasError =  ko.computed(
                                                  {
                                                      read: function () {
                                                          self.entityAspect // ... and when errors collection changes
                                                                  .validationErrorsChanged.subscribe(onChange);
                                                      },
  
                                                      // required because entityAspect property will not be available till Query
                                                      // return some data
                                                      deferEvaluation: true
  
                                                  });
  
  
                             self.fullName = ko.computed(
                                              function () {
                                                  return self.Country_Code() + " --- " + self.Country_Name();
                                              });
                         };
  
  
                         store.registerEntityTypeCtor("Country", Country);
  </code></pre>
  
  <p>and then in the button click i am using the following code to create new entity.</p>
  
  <pre><code>          var countryType = manager.metadataStore.getEntityType("Country"); 
                             var newCountry = countryType.createEntity(); 
                             //newCountry.Country_ID(200); //if i add this line no errors occurs
                             newCountry.Country_Code("India");
  
                             self.list.push(newCountry);
  
                             manager.addEntity(newCountry); // validation error occurs right after this line
  
                             self.selectedItem(newCountry);
                             self.list.valueHasMutated();
  </code></pre>