add button now mostly working for deployments
diff --git a/planetstack/core/xoslib/static/js/xoslib/xosHelper.js b/planetstack/core/xoslib/static/js/xoslib/xosHelper.js
index 11d97d6..0fc9496 100644
--- a/planetstack/core/xoslib/static/js/xoslib/xosHelper.js
+++ b/planetstack/core/xoslib/static/js/xoslib/xosHelper.js
@@ -126,9 +126,12 @@
     addShower: function(detailName, collection_name, regionName, title) {

         var app=this;

         return function() {

+            model = new xos[collection_name].model();

             detailViewClass = app[detailName];

-            detailView = new detailViewClass();

+            detailView = new detailViewClass({model: model});

             app[regionName].show(detailView);

+            $("#xos-detail-button-box").show();

+            $("#xos-listview-button-box").hide();

         }

     },

 

@@ -341,7 +344,7 @@
              addClicked: function(e) {
                 console.log("add");
                 e.preventDefault();
-                this.app.Router.navigate("add" + firstCharUpper(this.collection.modelName));
+                this.app.Router.navigate("add" + firstCharUpper(this.collection.modelName), {trigger: true});
              },
 

              initialize: function() {

diff --git a/planetstack/core/xoslib/tools/make_defaults.py b/planetstack/core/xoslib/tools/make_defaults.py
index 5a6a48f..ad5377c 100644
--- a/planetstack/core/xoslib/tools/make_defaults.py
+++ b/planetstack/core/xoslib/tools/make_defaults.py
@@ -12,7 +12,7 @@
 from django.core import serializers
 import json
 
-print "function xosdefault() {"
+print "function xos_get_defaults() {"
 
 for c in dir(core.models):
     c = getattr(core.models,c)
@@ -37,4 +37,5 @@
         print "  this." + classname + " = " + fields_json + ";"
 
 print "};"
+print "xosdefaults = new xos_get_defaults();"