fixed file bug for indent issue and param type check
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "swagger-ui",
|
"name": "swagger-ui",
|
||||||
"version": "0.1.7",
|
"version": "0.1.8",
|
||||||
"description": "Swagger UI is a dependency-free collection of HTML, Javascript, and CSS assets that dynamically generate beautiful documentation from a Swagger-compliant API",
|
"description": "Swagger UI is a dependency-free collection of HTML, Javascript, and CSS assets that dynamically generate beautiful documentation from a Swagger-compliant API",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "PATH=$PATH:./node_modules/.bin cake dist",
|
"build": "PATH=$PATH:./node_modules/.bin cake dist",
|
||||||
|
|||||||
@@ -76,9 +76,9 @@ class OperationView extends Backbone.View
|
|||||||
# requires HTML5 compatible browser
|
# requires HTML5 compatible browser
|
||||||
bodyParam = new FormData()
|
bodyParam = new FormData()
|
||||||
|
|
||||||
# add params
|
# add params except file
|
||||||
for param in @model.parameters
|
for param in @model.parameters
|
||||||
if param.paramType is 'body'
|
if param.paramType is 'body' and param.name isnt 'file'
|
||||||
bodyParam.append(param.name, map[param.name])
|
bodyParam.append(param.name, map[param.name])
|
||||||
|
|
||||||
# add files
|
# add files
|
||||||
@@ -87,10 +87,10 @@ class OperationView extends Backbone.View
|
|||||||
|
|
||||||
console.log(bodyParam)
|
console.log(bodyParam)
|
||||||
else
|
else
|
||||||
bodyParam = null
|
bodyParam = null
|
||||||
for param in @model.parameters
|
for param in @model.parameters
|
||||||
if param.paramType is 'body'
|
if param.paramType is 'body'
|
||||||
bodyParam = map[param.name]
|
bodyParam = map[param.name]
|
||||||
|
|
||||||
log "bodyParam = " + bodyParam
|
log "bodyParam = " + bodyParam
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user