-
-
Notifications
You must be signed in to change notification settings - Fork 34
Feature/dxf export+access control #667
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
Open
meyerlor
wants to merge
5
commits into
3liz:master
Choose a base branch
from
meyerlor:feature/dxf-export+access-control
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Contributor
|
Hi @meyerlor, Thanks for your contribution. We have update the code for configuration, sorry for that. |
Fixes two bugs in LwcVersions class that were discovered during development: - Add missing return statement in LwcVersions.oldest() method - Fix LwcVersions.find() call in version_checker.py by removing the is_dev parameter (method signature was changed but call site wasn't updated) Also updates .gitignore to exclude all .zip files, not just lizmap.*.zip pattern.
Implements access control configuration for DXF export functionality in the
QGIS plugin. This allows administrators to restrict DXF export by user groups
and configure which WFS layers are exportable.
Features:
- Global "Allow DXF export" checkbox to enable/disable the feature
- "Allowed groups" field for comma-separated Lizmap group IDs
- Auto-populated table of all WFS-enabled layers with individual enable/disable checkboxes
- Custom DXF export icon in navigation panel
- Full CFG file save/load support with backward compatibility
Implementation:
- Created dedicated DXF Export panel (lizmap/resources/ui/ui_form_dxf_export.ui)
- Added DxfExportDefinitions for configuration schema
- Implemented TableManagerDxfExport for WFS layer management
- Registered global options (dxfExportEnabled, allowedGroups) in config.py
- Added icon resources (19-dxfexport-dark.png, 19-dxfexport-white.png)
- Connected UI widgets to save/load framework
The configuration is stored in the .qgs.cfg file as:
- options.dxfExportEnabled (boolean, default: false)
- options.allowedGroups (string, comma-separated group IDs)
- dxfExport.layers[] (array of {layerId, enabled} objects)
Backward compatibility is ensured:
- Old CFG files without these keys use safe defaults (disabled)
- DXF export is disabled by default for existing projects
- Empty allowedGroups means all users are allowed (when enabled)
Note: This only implements the configuration UI in the plugin. Access control
enforcement in lizmap-web-client will be implemented separately.
1266d79 to
e782286
Compare
Author
|
@rldhont no problem! I rebased - should be ok now i think. Local tests were passing! |
- Remove unused imports (QLabel, DxfExportDefinitions, DxfExportEditionDialog) - Remove unused QWebSettings imports in WebKit fallback blocks - Move module-level imports before WebKit detection blocks - Fix import ordering (alphabetize standard library imports) - Remove trailing whitespace - Remove whitespace from blank lines - Replace try-except-pass with contextlib.suppress - Replace unnecessary elif with if after return statement
Update DXF export code to use the existing ambiguous_to_bool function instead of creating a new to_bool alias. This is cleaner and uses the established API. Changes: - lizmap/table_manager/dxf_export.py: Use ambiguous_to_bool - tests/test_dxf_export.py: Update tests to use ambiguous_to_bool Fixes ImportError in test_dxf_export.py and plugin.py.
73ddd40 to
6088f6b
Compare
0e9c376 to
73662c6
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Sorry for double PR, renamed my branch and was not aware this would delete the original PR.
Implements access control configuration for DXF export functionality in the QGIS plugin. This allows administrators to restrict DXF export by user groups and configure which WFS layers are exportable.
To test the plugin, you can download it here
Features:
Implementation:
The configuration is stored in the .qgs.cfg file as:
Backward compatibility is ensured:
Note: This only implements the configuration UI in the plugin. Access control
enforcement in lizmap-web-client will be implemented separately.
Working plugin with the changes included:

Example parts of the .qgs.cfg:
Two layer's config example: