q-koa 11.9.6 → 12.0.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.
|
@@ -9,13 +9,6 @@ exports.loadModel = async ({ app, appName }) => {
|
|
|
9
9
|
|
|
10
10
|
// const modelList = await app.model.model.findAll({ raw: true })
|
|
11
11
|
|
|
12
|
-
await Promise.all(
|
|
13
|
-
['model', 'model_attributes'].map((item) =>
|
|
14
|
-
app.model[item].sync({
|
|
15
|
-
force: true,
|
|
16
|
-
})
|
|
17
|
-
)
|
|
18
|
-
)
|
|
19
12
|
const currentDisabledFindAllList = lodash.get(
|
|
20
13
|
app,
|
|
21
14
|
'appConfig.disabledFindAllList',
|
|
@@ -222,7 +215,13 @@ exports.loadModel = async ({ app, appName }) => {
|
|
|
222
215
|
dataList.push(obj)
|
|
223
216
|
}
|
|
224
217
|
}
|
|
225
|
-
|
|
218
|
+
await Promise.all(
|
|
219
|
+
['model', 'model_attributes'].map((item) =>
|
|
220
|
+
app.model[item].sync({
|
|
221
|
+
force: true,
|
|
222
|
+
})
|
|
223
|
+
)
|
|
224
|
+
)
|
|
226
225
|
const promise1 = app.model.model.bulkCreate(
|
|
227
226
|
dataList.map((item) => {
|
|
228
227
|
return {
|
|
@@ -53,7 +53,8 @@ exports.refund = async ({
|
|
|
53
53
|
})
|
|
54
54
|
if (!orderDetail) throw new Error('不存在该订单')
|
|
55
55
|
try {
|
|
56
|
-
const
|
|
56
|
+
const length = lodash.get(orderDetail, 'order_refund_records', [])
|
|
57
|
+
const refundNumber = length + 1
|
|
57
58
|
|
|
58
59
|
const data = {
|
|
59
60
|
...rest,
|