Skip to content

RequestQueryBuilder.create() sort option is not work. #848

@ak4784183

Description

@ak4784183

Bug Report

let createQueryParams = {
search: {
$and: [
$CONT('name', searchForm.name),
encode?.encode ? $EQUAL('encode', encode?.encode) : $CONT('encode', searchForm.encode),
]
},
sort: [{ field: "encode", order: "ASC" }],
page: currentPage.value,
limit: pageSize.value,
resetCache: true,
};

const query = '?' + RequestQueryBuilder.create(createQueryParams).query();

Current behavior

the sort/order query option was not work. the response data is not sorted.if I set Crud decorator on controllers,the response data is sorted by 'encode' field.

Input Code

const your = (code) => here;

Expected behavior

Possible Solution

Environment


Package version: X.Y.Z

 
For Tooling issues:
- Node version: XX  
- Platform:  
- Database 

Others:

Repository with minimal reproduction

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions