Merge branch 'development' into 'devops-staging'
fix: transaction history by desc See merge request empatnusabangsa/ppob/ppob-backend!82
This commit is contained in:
commit
4b7cf13c8c
|
@ -907,7 +907,8 @@ export class TransactionService {
|
||||||
.addSelect('transaction.partner_trx_id', 'partner_transaction_code')
|
.addSelect('transaction.partner_trx_id', 'partner_transaction_code')
|
||||||
.addSelect('userData.name', 'buyer')
|
.addSelect('userData.name', 'buyer')
|
||||||
.addSelect('product.name', 'name')
|
.addSelect('product.name', 'name')
|
||||||
.addSelect('product.id', 'product_id');
|
.addSelect('product.id', 'product_id')
|
||||||
|
.orderBy('transaction.created_at', 'DESC');
|
||||||
|
|
||||||
if (startDate && endDate) {
|
if (startDate && endDate) {
|
||||||
baseQuery.andWhere(
|
baseQuery.andWhere(
|
||||||
|
@ -947,7 +948,8 @@ export class TransactionService {
|
||||||
destinationId: destinationUser,
|
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
|
const data = await baseQuery
|
||||||
.offset(page * (pageSize || 10))
|
.offset(page * (pageSize || 10))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user