Changeset 362 for Dev/branches/rest-dojo-ui/client/config/db.js
- Timestamp:
- 07/16/12 16:27:40 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Dev/branches/rest-dojo-ui/client/config/db.js
r361 r362 20 20 parser.parse(); 21 21 22 query("#log").forEach(function(n){ logNode = n;});22 query("#log").forEach(function(n){logNode = n;}); 23 23 usernameInput = registry.byId('username'); 24 24 passwordInput = registry.byId('password'); … … 31 31 32 32 log("Give CouchDB admin username & password and click 'Configure' to start.\nIf the database already exists, rft_admin password will suffice.",true); 33 34 33 35 34 function configure(){ 35 var docs; 36 36 37 log("Configuring CouchDB for RFT:",true); 37 38 … … 40 41 var reset = resetInput.get('value'); 41 42 42 var docs = json.fromJson(docsJson); 43 log("Downloading most recent configuration."); 44 xhr('GET',{ 45 url: 'docs.json', 46 handleAs: 'json', 47 sync: true 48 },true) 49 .then(function(result){ 50 docs = result; 51 }); 43 52 44 53 function req(method,url,body) { … … 47 56 contentType: 'application/json', 48 57 handleAs: 'json', 49 sync: true, 50 error: function(err) { 51 log("ERROR: "+err); 52 } 58 sync: true 53 59 }; 54 60 if ( !body || lang.isObject(body) ) {
Note: See TracChangeset
for help on using the changeset viewer.