Arreglo de bugs ordes
This commit is contained in:
@@ -7,7 +7,7 @@
|
|||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "vitest watch",
|
"test": "vitest watch",
|
||||||
"build": "yarn workspaces foreach -A run build && cp .env dist/ && yarn setup:runtime",
|
"build": "rm -rf ./dist && yarn workspaces foreach -Api run build && cp .env dist/ && yarn setup:runtime",
|
||||||
"setup:runtime": "mkdir -p dist/packages/node_modules && ln -sf ../sim-shared dist/packages/node_modules/sim-shared && ln -sf ../sf-consumidor-objenious dist/packages/node_modules/sim-consumidor-objenious",
|
"setup:runtime": "mkdir -p dist/packages/node_modules && ln -sf ../sim-shared dist/packages/node_modules/sim-shared && ln -sf ../sf-consumidor-objenious dist/packages/node_modules/sim-consumidor-objenious",
|
||||||
"start": "yarn setup:runtime && yarn workspaces foreach -Apiv --exclude sim-objenious-cron run start",
|
"start": "yarn setup:runtime && yarn workspaces foreach -Apiv --exclude sim-objenious-cron run start",
|
||||||
"typecheck": "npx tsc --noEmit",
|
"typecheck": "npx tsc --noEmit",
|
||||||
|
|||||||
@@ -50,6 +50,7 @@ export class SimNosUsecases {
|
|||||||
status: "failed",
|
status: "failed",
|
||||||
correlation_id: correlation_id,
|
correlation_id: correlation_id,
|
||||||
reason: reason,
|
reason: reason,
|
||||||
|
error: reason,
|
||||||
stackTrace: detail
|
stackTrace: detail
|
||||||
}
|
}
|
||||||
const order = await this.orderRepository.errorOrder(updateData)
|
const order = await this.orderRepository.errorOrder(updateData)
|
||||||
@@ -72,6 +73,7 @@ export class SimNosUsecases {
|
|||||||
const res = await func(args)
|
const res = await func(args)
|
||||||
|
|
||||||
if (res.error != undefined) {
|
if (res.error != undefined) {
|
||||||
|
console.log("Error peticion: ", res)
|
||||||
if (correlation_id != undefined)
|
if (correlation_id != undefined)
|
||||||
this.setFailed(correlation_id, res.error).then()
|
this.setFailed(correlation_id, res.error).then()
|
||||||
return res;
|
return res;
|
||||||
|
|||||||
@@ -402,6 +402,8 @@ export class OrderRepository {
|
|||||||
client.query<{ id: number, status: string, update_date: string }>(uOrderTracking, vOrderTracking)
|
client.query<{ id: number, status: string, update_date: string }>(uOrderTracking, vOrderTracking)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
console.log("updatedOrderResult", updatedOrderResult)
|
||||||
|
|
||||||
if (updatedOrderResult.error != undefined) {
|
if (updatedOrderResult.error != undefined) {
|
||||||
await client.query("ROLLBACK")
|
await client.query("ROLLBACK")
|
||||||
client.release()
|
client.release()
|
||||||
|
|||||||
Reference in New Issue
Block a user