Changeset 468 for Dev/trunk/src/client/qed-client/store
- Timestamp:
- 06/26/13 21:17:41 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Dev/trunk/src/client/qed-client/store/CouchStore.js
r466 r468 28 28 _responseIdProperty: "id", 29 29 _responseRevProperty: "rev", 30 request: request, 30 31 constructor: function(options){ 31 32 declare.safeMixin(this, options); … … 39 40 info: function(){ 40 41 var dfd = new Deferred(); 41 request(this.target, {42 this.request(this.target, { 42 43 method: "GET", 43 44 handleAs: "json", … … 58 59 get: function(id){ 59 60 var dfd = new Deferred(); 60 request(this.target + encodeURIComponent(id), {61 this.request(this.target + encodeURIComponent(id), { 61 62 method: "GET", 62 63 handleAs: "json", … … 103 104 var id = options.id ? options.id : this.getIdentity(object); 104 105 var hasId = typeof id !== "undefined"; 105 request(hasId ? this.target + encodeURIComponent(id) : this.target, {106 this.request(hasId ? this.target + encodeURIComponent(id) : this.target, { 106 107 method: hasId ? "PUT" : "POST", 107 108 data: json.toJson(object), … … 129 130 remove: function(id,rev){ 130 131 var dfd = new Deferred(); 131 request(this.target + encodeURIComponent(id), {132 this.request(this.target + encodeURIComponent(id), { 132 133 method: "DELETE", 133 134 headers: { … … 243 244 } 244 245 245 request(this.target + query, {246 this.request(this.target + query, { 246 247 method: "GET", 247 248 handleAs: "json",
Note: See TracChangeset
for help on using the changeset viewer.