q-koa 9.5.4 → 9.6.0
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/core/app.js +10 -6
- package/package.json +1 -1
package/core/app.js
CHANGED
|
@@ -979,12 +979,16 @@ class APP {
|
|
|
979
979
|
|
|
980
980
|
if (referenceInclude) {
|
|
981
981
|
const _referenceInclude = Object.keys(referenceInclude).map(
|
|
982
|
-
(model) =>
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
982
|
+
(model) => {
|
|
983
|
+
const { required = true, ...rest } = referenceInclude[model]
|
|
984
|
+
return {
|
|
985
|
+
model: app[appName].model[model],
|
|
986
|
+
where: {
|
|
987
|
+
...rest,
|
|
988
|
+
},
|
|
989
|
+
required,
|
|
990
|
+
}
|
|
991
|
+
}
|
|
988
992
|
)
|
|
989
993
|
myInclude = [...myInclude, ..._referenceInclude]
|
|
990
994
|
}
|