fix: Add group by to differentiate flows

This commit is contained in:
Faruk AYDIN
2022-08-07 01:21:24 +03:00
parent 0e749936a6
commit 3a1e8b4bbd

View File

@@ -17,6 +17,7 @@ const getFlows = async (_parent: unknown, params: Params, context: Context) => {
builder.where('steps.app_key', params.appKey);
}
})
.groupBy('flows.id')
.orderBy('updated_at', 'desc');
return paginate(flowsQuery, params.limit, params.offset);