fix: transaction history by desc
This commit is contained in:
parent
074bc141eb
commit
128e915eb2
|
@ -907,7 +907,8 @@ export class TransactionService {
|
|||
.addSelect('transaction.partner_trx_id', 'partner_transaction_code')
|
||||
.addSelect('userData.name', 'buyer')
|
||||
.addSelect('product.name', 'name')
|
||||
.addSelect('product.id', 'product_id');
|
||||
.addSelect('product.id', 'product_id')
|
||||
.orderBy('transaction.created_at', 'DESC');
|
||||
|
||||
if (startDate && endDate) {
|
||||
baseQuery.andWhere(
|
||||
|
@ -947,7 +948,8 @@ export class TransactionService {
|
|||
destinationId: destinationUser,
|
||||
},
|
||||
)
|
||||
.select(['id', 'created_at as transaction_date', 'amount']);
|
||||
.select(['id', 'created_at as transaction_date', 'amount'])
|
||||
.orderBy('transaction.created_at', 'DESC');
|
||||
|
||||
const data = await baseQuery
|
||||
.offset(page * (pageSize || 10))
|
||||
|
|
Loading…
Reference in New Issue
Block a user