Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix packaging for cable does not respect area of interest settings #569

Merged
merged 2 commits into from
Mar 5, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 14 additions & 10 deletions qfieldsync/gui/package_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,16 +140,20 @@ def package_project(self):
self.button_box.button(QDialogButtonBox.Save).setEnabled(False)

export_folder = self.get_export_folder_from_dialog()
area_of_interest = (
self.__project_configuration.area_of_interest
if self.__project_configuration.area_of_interest
else self.iface.mapCanvas().extent().asWktPolygon()
)
area_of_interest_crs = (
self.__project_configuration.area_of_interest_crs
if self.__project_configuration.area_of_interest_crs
else QgsProject.instance().crs().authid()
)
if self.__project_configuration.offline_copy_only_aoi:
area_of_interest = (
self.__project_configuration.area_of_interest
if self.__project_configuration.area_of_interest
else self.iface.mapCanvas().extent().asWktPolygon()
)
area_of_interest_crs = (
self.__project_configuration.area_of_interest_crs
if self.__project_configuration.area_of_interest_crs
else QgsProject.instance().crs().authid()
)
else:
area_of_interest = ""
area_of_interest_crs = QgsProject.instance().crs().authid()

self.qfield_preferences.set_value("exportDirectoryProject", export_folder)
self.dirsToCopyWidget.save_settings()
Expand Down
Loading