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

Unable to retrieve variables from another layout item #26893

Closed
qgib opened this issue May 30, 2018 · 6 comments
Closed

Unable to retrieve variables from another layout item #26893

qgib opened this issue May 30, 2018 · 6 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Print Layouts Related to QGIS Print Layouts, Atlas or Reporting frameworks Regression Something which used to work, but doesn't anymore

Comments

@qgib
Copy link
Contributor

qgib commented May 30, 2018

Author Name: Harrissou Santanna (@DelazJ)
Original Redmine Issue: 19063
Affected QGIS version: 3.1(master)
Redmine category:map_composer/printing


According to the function help and documentation @map_get(item_variables('Map 1'), 'map_scale')@ would help me retrieve the scale of a map item and use it for example in a label. This does no longer work unless I manually set the Item ID property of the map item, using only digits (eg. 1 or 124).
I'm not sure it makes sense and it's a nice UX to have for example my map named 1 instead of Map1 or my local map...
Using e7da103


@qgib
Copy link
Contributor Author

qgib commented May 31, 2018

Author Name: Nyall Dawson (@nyalldawson)


This works fine for me (and there's multiple unit tests protecting this) - can you attach a sample project?

Note that no items have an id by default - you always need to manually set ids.


  • status_id was changed from Open to Feedback

@qgib
Copy link
Contributor Author

qgib commented Jun 4, 2018

Author Name: Harrissou Santanna (@DelazJ)


Nyall Dawson wrote:

Note that no items have an id by default - you always need to manually set ids.

Then what does represent the "Map 1", "Map 2" texts that appear at the top of the map item properties, and replaced by the "Item ID" when set? aren't they some kind of default internal IDs? Should they not be used for such a feature?

can you attach a sample project?

Done (project, data and screenshot).


  • 12778 was configured as DEPARTEMENT.7z
  • 12775 was configured as item_variables.PNG
  • 12777 was configured as item_variables.qgz

@qgib
Copy link
Contributor Author

qgib commented Jun 4, 2018

Author Name: Harrissou Santanna (@DelazJ)


  • 12775 removed item_variables.PNG

@qgib
Copy link
Contributor Author

qgib commented Jun 4, 2018

Author Name: Harrissou Santanna (@DelazJ)


  • 12777 removed item_variables.qgz

@qgib
Copy link
Contributor Author

qgib commented Jun 4, 2018

Author Name: Harrissou Santanna (@DelazJ)


Added new files as there was an error in what i previously sent


  • 12779 was configured as item_variables.qgz
  • 12780 was configured as item_variables.PNG

@qgib
Copy link
Contributor Author

qgib commented Jun 8, 2018

Author Name: Nyall Dawson (@nyalldawson)


Applied in changeset 57c442a.


  • done_ratio was changed from 0 to 100
  • status_id was changed from Feedback to Closed

@qgib qgib closed this as completed Jun 8, 2018
@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Print Layouts Related to QGIS Print Layouts, Atlas or Reporting frameworks Regression Something which used to work, but doesn't anymore labels May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Print Layouts Related to QGIS Print Layouts, Atlas or Reporting frameworks Regression Something which used to work, but doesn't anymore
Projects
None yet
Development

No branches or pull requests

1 participant