Skip to content

Conversation

@ofr1tz
Copy link
Collaborator

@ofr1tz ofr1tz commented Jan 16, 2025

The Mapillary image filter section on the new project form for projects of type Street has a checkbox input to determine whether Mapillary imagery should be filtered for 360° panoramic images or not.

Before this fix, leaving the box unchecked would result in adding a isPano field with the value false to the project draft, which in return would mean that the python creation worker would filter available imagery for non-panoramic images.

With this fix, isPano is not added to the project draft if the checkbox is left unmarked, meaning that both panoramic and non-panoramic images are used, as was originally intended.

@ofr1tz ofr1tz requested a review from Gigaszi January 16, 2025 15:29
creatorId?: number;
isPano?: boolean;
panoOnly?: boolean;
isPano?: boolean | null;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldnt isPano be removed here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this needs to remain as a type check for valuesToCopy.isPano.


valuesToCopy.startTimestamp = valuesToCopy.dateRange?.startDate ?? null;
valuesToCopy.endTimestamp = valuesToCopy.dateRange?.endDate ?? null;
valuesToCopy.isPano = valuesToCopy.panoOnly ? true : null;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so it can not be false. or? Is this intended?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is as originally intended. The input allows a project creator to decide whether they want all images (isPano = null) or only panoramic ones (isPano = true). In case there should be a need for creating projects with only non-panoramic features, we could adapt the Manager Dashboard later accordingly.

@ofr1tz ofr1tz merged commit e62d69b into dev Jan 30, 2025
1 check passed
@ofr1tz ofr1tz deleted the fix/street-pano-filter branch January 30, 2025 13:58
@ofr1tz ofr1tz mentioned this pull request Feb 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants