fix(approval): fixed sort by createAt (#1396)

Reviewed-on: daoyoucloud/tachybase#1396
Reviewed-by: sealday <zhanglin@daoyoucloud.com>
Co-authored-by: bai.zixv <bai.zixv@foxmail.com>
Co-committed-by: bai.zixv <bai.zixv@foxmail.com>
This commit is contained in:
bai.zixv 2024-07-26 14:19:33 +08:00 committed by sealday
parent 3a32909091
commit 021a96e85f
2 changed files with 10 additions and 2 deletions

View File

@ -22,7 +22,11 @@ export const InitiationsItem = observer((props) => {
api
.request({
url: 'workflows:list',
params: { pageSize: 9999, filter: { ...params?.[tabKey] } },
params: {
pageSize: 9999,
filter: { ...params?.[tabKey] },
sort: 'createdAt',
},
})
.then((res) => {
const option = res?.data?.data.map((value) => {

View File

@ -33,7 +33,11 @@ export const ApprovalBlockLaunchApplication = (props) => {
{
resource: decorator?.collection,
action: decorator?.action,
params: { pageSize: 99999, filter: { ...decorator?.params?.filter } },
params: {
pageSize: 99999,
filter: { ...decorator?.params?.filter },
sort: 'createdAt',
},
},
{
manual: true,