support for non GET methods. Closes #15

This commit is contained in:
Ayush Gupta
2012-07-17 18:31:38 -07:00
parent f42a3bf687
commit f2e63c65a7
14 changed files with 239 additions and 37 deletions

5
dist/lib/swagger.js vendored
View File

@@ -35,6 +35,7 @@
this.verbose = options.verbose;
}
this.supportHeaderParams = options.supportHeaderParams != null ? options.supportHeaderParams : false;
this.supportedSubmitMethods = options.supportedSubmitMethods != null ? options.supportedSubmitMethods : ['get'];
if (options.success != null) {
this.success = options.success;
}
@@ -371,6 +372,10 @@
return this.resource.api.supportHeaderParams;
};
SwaggerOperation.prototype.supportedSubmitMethods = function() {
return this.resource.api.supportedSubmitMethods;
};
SwaggerOperation.prototype.getQueryAndHeaderParams = function(args, includeApiKey) {
if (includeApiKey == null) {
includeApiKey = true;