Dynamic  pdf generation report/date filter

Dynamic  pdf generation report/date filter

  
Good Day guys. Please  i am in the course of wrapping up  a prototype app,but i hit a brick wall and i have just two important questions namely:

1)How can i implement a date filter were i can filter Firmposts by year, this is becuase each student firm post class is ordered by year. so i hope to have a filter were onclick event of a drop down  for a specific year it filters the firmpost of the students for that particular year.

2) secondly and most importantly , i want to implement a dynamic pdf  page generation. for example if i select 2015 in the year drop down as explained above and click on the generate pdf  button it dynamically filter the generated content to print pdf for that particular year. In my current implementation,if i click generate pdf , it generates the whole firm post student data, i cant implement customised filter so that the pdf generate content based on selected options like the year drop down filter.

Attached in this post is a sample of the application , please any help with regards to this issue will be deeply appreciated and it would also enable me in my learning process.Thanks.
Hi Tom,

In your attached oml, on which page you want to implement the date filter.

Regards,
Suraj Borade
@ suraj borade.Thanks for the reply. i want to inplement it in Firmpost Page.sorry for the late reply.Thanks for your help
Hi Tom,

I will update you tomorrow.
@ suraj .Thank you very much.Have a good day
The easiest way to make PDFs is with the "HTML2PDF" component in the Forge.

J.Ja
@ suraj borade. Good day.where you able to make changes to the oml i posted.Thanks
Hi TOM,

working on it. I am able to add the filter by years. Now implementing it on the front end.
Hi TOM,

I tried to make changes in your oml. I implemented drop down for years 2-3 ways but at the time of passing input to the aggregate it's not working properly. Please check the code. This is not the good practice which I have implemented but you can improve further.

Just think to replace Aggregate by Advance Query in list page.

I have another prioritzed tasks so now I am not able to investigate further. Sorry.

Regards,
Suraj Borade
@suraj thanks for the help. I tested it on os 9.1 and it seems to work. When I create years and filter the firm post by year it works. Please what problem did you experience so I can check out for it
Hey TOM,

Just test by creating new record in firmpost tab. You need to take care at the time of creating new record. Just check save code one more time. I have changed it in.

Problem I faced was listing of all records. It was not showing all records when I made year filter empty, ideally it should show. That problem is creating because in aggregate I have used date join. It will work great with Advance query so check with that.

If I get time I will check on weekends.

Regards,
Suraj Borade
@surajborade  hi, i made some modifications because i use platform 8.0 and implemented advanced query everything work except the combo box date filter. when i filter it by year ,it doesnt work. i am attching my modified sample. please can you check it as see if i made any mistake.Thanks
it seems the file didnt upload properly still processing upload . outsystems site issue
Hi guys, please any help with regards to solving the issue of date filtering in firmpost page would go along in helping me solve this issue. i have implemented the the advance query in the espace i attached above but the table is not filtering when i do a selection by year.Thanks .
Solution
Hey TOM,

Here is fully working OML for year filter on FirmPosting page. I have tested with all test scenarios. Only thing you need to do is add years from "Years" tab, create new records in FirmPosting page and test them.

Test all possible scenarios from your side and let me know.

Enjoy.........!

Regards,
Suraj Borade
Solution
It working!! . big thanks for your immense effort. i have seen my mistakes with regards to the advanced query implementation ,thanks. Meanwhile i am trying to build on what you have given me by trying to implement a dynamic print , which works like this , when a firm post year is filtered , i can print that particular filtered result in pdf instead of print the whole list. what i did before was to use the htmlto pdf to print the whole i list. i am working towards modifying it to print filtered results.I would also appreciate any suggestion or tips with regards to this . i will certainly update you on how it goes.Thanks once again for your help.
First i would like to thank you very very much for your steadfast help. your solution works very well in my personal environement, but my main environment is version 8 and when i recreated evrything version 8n it doesnt work. i have isolated the issue. its down to aggregate versus simple query in version 9 which you used  aggregaretes have option to bind for example year.id = session.year.year2


but in simple query the session varibale is not within scope of the query builder 
year is an input parameter of the query
i have do this year.id = year

then later assign session.year.year2 to input year as an argument.

so they work differently but the summary is i recreated your sample using version 8 but it doent filter . it works perfectly in version 9 but not 8. please is there any resolution to this very minor differences.Thank you so muc