Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


English

This is a quick tutorial on using an HTML form to pass parameters to the JasperReports UI Menu, to demonstrate how to filter the results of a report based on input values.

First, add a JasperReports menu into your UI Builder and configure it as usual.

Then, write in the code as seen in the "UI > Custom Header" option, as shown in the screenshot below. The code specified here will create a HTML form to allow filter values to be submitted.

After then, use the Request Parameters Hash Variable to re-populate the submitted value.


Thai

นี่คือการสอนด่วนเกี่ยวกับการใช้แบบฟอร์ม HTML เพื่อส่งผ่านพารามิเตอร์ไปยัง JasperReports UI Menu เพื่อสาธิตวิธีการกรองผลลัพธ์ของรายงานตามค่าอินพุต

ขั้นแรกเพิ่มเมนู JasperReports ลงใน UI Builder ของคุณและกำหนดค่าตามปกติ

จากนั้นเขียนรหัสตามที่เห็นในตัวเลือก "UI> ส่วนหัวที่กำหนดเอง" ดังที่แสดงในภาพหน้าจอด้านล่าง รหัสที่ระบุที่นี่จะสร้างฟอร์ม HTML เพื่ออนุญาตให้ส่งค่าตัวกรอง

หลังจากนั้นใช้ Request Parameters Hash Variable  เพื่อเติมค่าที่ส่งอีกครั้ง

...