fix: fix the project id info for volume backups

Use the os-backup-project-attr:project_id as the project id for volume backup data

Closes-Bug: #1988964
Change-Id: Ic6d43c5b6fe6a68fcc8963740c97179ed74e2c5f
This commit is contained in:
Jingwei.Zhang 2022-09-07 17:44:14 +08:00
parent 1a3f4deed6
commit b5eb669efa

View File

@ -29,6 +29,13 @@ export class BackupStore extends Base {
return true;
}
get mapperBeforeFetchProject() {
return (data) => ({
...data,
project_id: data.project_id || data['os-backup-project-attr:project_id'],
});
}
updateParamsSortPage = (params, sortKey, sortOrder) => {
if (sortKey && sortOrder) {
params.sort = `${sortKey}:${sortOrder === 'descend' ? 'desc' : 'asc'}`;