sprilukin
-
Posts
10 -
Joined
-
Last visited
Content Type
Profiles
Forum
Events
Featured Visualizations
Knowledge Base
Documentation (PDF Downloads)
Blog
Documentation (Test Area)
Documentation
Dr. Jaspersoft Webinar Series
Security Advisories
Downloads
Posts posted by sprilukin
-
-
Hello, Daning.
There is no fully dynamic way to change color, font or other properties of input controls.
There are two supported ways for now:
1. Add css class for input controls definition in jasperserverWEB-INFjspmodulesinputControlsInputControlTemplates.jsp - this will change look&feel of controls in all reports which use default report parameters form. (works for JasperReports Server of version 4.7.1 or later)
2. Change report parameters form for specific report(s) - go to Edit report -> Customization -> JSP Location
and set path to custom parameters form jsp (you can copy&paste DefaultParametersForm.jsp and customize it). This way allows you to customize input controls only for specific report(s)
Thanks,
Sergey.
-
Other suggestion is to add permission for anonymous user to run this dashboard - in this case you do not need to put credentials in url or headers.
More details about how to setup such access you can read here
-
Please check that you log in to jasperserver using same timezone as you database, and jasperserver instance.If this not help check type of your datasource JDBC or JNDI?If JDBC then try to switch to JNDI.If nothing helps as a last resort you can edit datasource and select different timezone for it, so in runtime it will show correct value but it is not recommended way, better is just to upgrade to 5.0 there several timezone issues was fixed.thanks,Sergey.
-
Hello.
In 4.7.1 was a couple fixes related to calendar popup, i think your issue should be fixed there.
Thanks,
Sergey.
-
You can use DateRange type to define ranges like day-1, week, year, quarter etc. and use this ranges as a query parameters.
For example lets say you have following parameter:
<parameter class="net.sf.jasperreports.types.date.DateRange" name="dateRange"><defaultvalueexpression><!--[CDATA[new net.sf.jasperreports.types.date.DateRangeBuilder("WEEK").toDateRange()]]--></defaultvalueexpression>
</parameter>and following query:<querystring>
<!--[CDATA[select * from test_table where $X{EQUAL, orderDate, dateRange}]]-->
</querystring>when you will run such query you will get similar SQL:
select * from test_table where orderDate >= "START DAY OF CURRENT WEEK" and orderDate <= "END DAY OF CURRENT WEEK"[/code]
As an expression for DateRangeBuilder you can use following syntax:
"DAY+/-n" - (for example "DAY+1", "DAY-23" - no spaces and all uppercase) means n-th day after (or before) current day,
"WEEK+/-n", "QUARTER+/n", "SEMI+/-n", "YEAR+/-n"
This type is compatible with Date type thus if you will create filed of such type then you will be asked to fill it you can enter either relative date expression as described above or regular date.
Also you can read javadoc for DateRangeBuilder class in sources of JasperReports library to find all possible cases how to use it.
Hope this helps.
Thanks,
Sergey.
-
I can only suggest to update to JasperReports Server 5.0: in 5.0 this case works great with ecaxtly same steps.
Issue with Date Format in input control
in Products
Posted
What version of JasperReports Server do you use?
This issue can appear in JRS v4.7
but it should not appear in latest versions. (If i remember correctly >= JRS v5.0)
Also please check jasperserver_config_<YOUR_LOCALE>.properties
it should contains consistent date format for both
date.format, datetime.format, time.format and
Properties with calendar.* prefix are used to configure jQuery datepicker calendar plugin which is used in JRS
while properties without such prefix are used in java backend to parse/format strings (see javadoc)
so for example
values date.format and calendar.date.format should provide SAME parse/format results for same dates.
P.S. these properties are duplicated because jQuery calendar plugin is a little bit different from java DateFormat pattern
Hope this helps.