Reporting and filtering a column's data on the same page
To start off, my knowledge on the Scaffolding and Reporting plugin is a grand total of 2 days, so I apologize for asking what is probably a simple question, but hopefully other people would find it useful as well.
I have created a scaffold using {table-data} and populated a few columns with data from {text-data} and {date-data}. After taking a look at the "How can I report on table-data or repeating-data?" topic, I tried to modify the provided code for my example, but i didn't really get any output ( {current-item-reporter} also came up undefined in my installation and I can't find it among the other Macros in the documentation so I guess it was taken out). What I'm trying to do is display a list of the values of a column on the same page as the table. Later on I'll try filtering these values as mentioned below, and also displaying each column from the table, but for now getting one column to work will suffice.
As a related question which I'll pursue after getting this example to work, it would be great if you can share any recommendations on how to enable filtering by matching values in several columns such as Col1 contains Val1 and Col2 contains Val2, etc (I guess that's the easier one) and sorting of the data contained in the table. I'm more interested in the filtering, but the overall effect would be so users can see a subset of the data and not the full table.
Your help is greatly appreciated - looking forward to your updated documentation also (I bet I'm not the only one).
I have created a scaffold using {table-data} and populated a few columns with data from {text-data} and {date-data}. After taking a look at the "How can I report on table-data or repeating-data?" topic, I tried to modify the provided code for my example, but i didn't really get any output ( {current-item-reporter} also came up undefined in my installation and I can't find it among the other Macros in the documentation so I guess it was taken out). What I'm trying to do is display a list of the values of a column on the same page as the table. Later on I'll try filtering these values as mentioned below, and also displaying each column from the table, but for now getting one column to work will suffice.
As a related question which I'll pursue after getting this example to work, it would be great if you can share any recommendations on how to enable filtering by matching values in several columns such as Col1 contains Val1 and Col2 contains Val2, etc (I guess that's the easier one) and sorting of the data contained in the table. I'm more interested in the filtering, but the overall effect would be so users can see a subset of the data and not the full table.
Your help is greatly appreciated - looking forward to your updated documentation also (I bet I'm not the only one).
1
person has this question
I have this question, too!
Tell me when someone answers.
The more people who ask this question, the more it gets noticed.
The more people who ask this question, the more it gets noticed.
-
Inappropriate?Hi there,
Firstly, {current-item-reporter} was renamed to {local-reporter} way back, so its mention in the other topic is a typo. Use {local-reporter} and you should be good to go.
To report on data on the same page, {local-reporter} will do the trick. Just specify something like:
{local-reporter:data:My Table}
Where 'My Table' is the name of your {table-data} field.
Filtering with on multiple columns is also quite easy - just add as many filters as you want inside the {local-reporter} macro. Eg:
{local-reporter:data:My Table}
{text-filter:data:Text Field|include=foo.*}
{number-filter:data:Number Field|minValue=5}
{local-reporter}
The above will only list rows which have a 'Text Field' value starting with 'foo' (check out [regular expression rules|http://www.regular-expressions.info]) and a 'Number Field' value which is 5 or more.
Hope that helps.
I’m happy
1 person says
this answers the question
-
Inappropriate?Thanks a lot and I'll try out your suggestions - I'm sure they will do the trick.
Two more questions from me however (one I've previously thought of while trying out some examples, but just forgot to mention):
1. How about sorting of the table-data? I read another one of your posts where you recommended {table-plus}, but it didn't work out too well for me. Just out of curiosity, any plans to incorporate sorting into Scaffolding (I know there's some options about sorting of the Reporting data, so that might be useful)?
2. Is there a way to clear out the xml file holding the metadata for the page that contains the Scaffolding table-data other than redoing the table from scratch in a new page? Instead of the scaffoldedit.action or whatever the actual name was, I substituted viewxml.action and I was able to see the XML metadata. The issue was that I was able to see some testing metadata which was deleted from the table, so I'm wondering if this might pose a performance issue as more "discarded" data overhead is created as the total number of table transactions increases. I don't have direct access to the Confluence installation, so I'm not able to browse its files - hopefully there's an easy way to clean the Scaffolding XML metadata of old entries or perhaps this wouldn't be an issue with performance.
Thank you very much for your help once again.
I’m confident
-
Actually in regards to question 1 about {table-plus}, I think I had an example working, and I see how it can be used, but I was concerned about issues with the Rich Text Editor breaking, as expressed in a few JIRA posts. I'll try the {table-plus} as well as sorting the reporting results and see what happens.
About question 2, after watching one of the Scaffolding tutorial videos, I see it might be due to the Confluence page version functionality, but it'd be great if you can offer your opinion on it. Thanks. -
Sorry about posting again, but to add another small question before you have answered, do you know of an easy way to enable the filtering in real-time? What I had in mind was having text-fields (created with the html macro) where users can type-in filtering criteria, press search, and view the results on the same page in real-time. The easier alternative is for the users to specify the filters in edit mode, save the page, and view the results, but I want to avoid that if there's another relatively simple solution. Thanks for your help once again. -
Inappropriate?Ok...let's see if I can answer all your questions...
1. Sorting directly in Scaffolding is a challenge, because of the way that data is stored and the way that you interact with it in the UI. In short, not likely to change anytime soon, unfortunately.
2. Not really, unless you have access to the database. Feel free to create a feature request and it may get implemented for a future version.
3. Real-time filtering, not really. I've commented on your question to the forum, but that's about the only option currently - build your own plugin. Again, a feature request is not out of line, but don't hold your breath on it getting implemented anytime soon unless someone pays for the update. -
Inappropriate?Thank you for your reply. I was just curious about the xml data, and have started on a custom plugin regarding the filtering.
I’m thankful
Loading Profile...



EMPLOYEE