waibu-rest-api 2.7.0 → 2.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/extend/waibu/boot.js +2 -2
- package/lib/doc-schema/model.js +3 -3
- package/package.json +1 -1
- package/wiki/CHANGES.md +5 -0
package/extend/waibu/boot.js
CHANGED
|
@@ -79,8 +79,8 @@ const boot = {
|
|
|
79
79
|
mod.config.pathReroutedTo = rpath
|
|
80
80
|
this.log.warn('rerouted%s%s', `${prefix}${fullPath}`, `${prefix}${rpath}`)
|
|
81
81
|
mod.url = me.config.format.asExt ? formatExt(rpath) : rpath
|
|
82
|
-
|
|
83
|
-
} else
|
|
82
|
+
me.webAppCtx.route(mod)
|
|
83
|
+
} else appCtx.route(mod)
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
}, { prefix: appPrefix })
|
package/lib/doc-schema/model.js
CHANGED
|
@@ -129,7 +129,7 @@ async function docSchemaModel ({ model, method, options = {} }) {
|
|
|
129
129
|
if (['update'].includes(method)) {
|
|
130
130
|
const { properties } = await buildPropsReqs.call(this, { model: mdl, method, options })
|
|
131
131
|
const name = 'model' + mdl.name + 'Update'
|
|
132
|
-
delete properties.
|
|
132
|
+
delete properties._ref
|
|
133
133
|
await this.docSchemaLib(name, {
|
|
134
134
|
type: 'object',
|
|
135
135
|
properties: omit(properties, ['id'])
|
|
@@ -139,7 +139,7 @@ async function docSchemaModel ({ model, method, options = {} }) {
|
|
|
139
139
|
if (['replace'].includes(method)) {
|
|
140
140
|
const { properties, required } = await buildPropsReqs.call(this, { model: mdl, method, options })
|
|
141
141
|
const name = 'model' + model.name + 'Replace'
|
|
142
|
-
delete properties.
|
|
142
|
+
delete properties._ref
|
|
143
143
|
await this.docSchemaLib(name, {
|
|
144
144
|
type: 'object',
|
|
145
145
|
properties: omit(properties, ['id']),
|
|
@@ -150,7 +150,7 @@ async function docSchemaModel ({ model, method, options = {} }) {
|
|
|
150
150
|
if (['create'].includes(method)) {
|
|
151
151
|
const { properties, required } = await buildPropsReqs.call(this, { model: mdl, method, options })
|
|
152
152
|
const name = 'model' + model.name + 'Create'
|
|
153
|
-
delete properties.
|
|
153
|
+
delete properties._ref
|
|
154
154
|
await this.docSchemaLib(name, {
|
|
155
155
|
type: 'object',
|
|
156
156
|
properties,
|
package/package.json
CHANGED
package/wiki/CHANGES.md
CHANGED