Open geekelo opened 1 month ago
This ActiveAdmin configuration defines a custom report page for KYC (Know Your Customer) verifications, named KycReport
. This page provides an interface to filter KYC verifications by date range and status, and allows the export of detailed CSV reports and summary PDF reports. Here’s a detailed breakdown of the configuration:
menu parent: 'Reports', label: 'Kyc Reports'
:KycReport
to the "Reports" menu in ActiveAdmin with the label "Kyc Reports."The controller is customized to manage the filtering and exporting of KYC data.
before_action :set_date_range, only: [:index]
:set_date_range
method:index
method:generate_csv
method:generate_pdf
method:index title: "KYC Reports by Date Range"
:panel "Filter KYC Reports"
:panel "Report Downloads"
:config.filters = false
:config.batch_actions = false
:This configuration provides a robust interface for generating and downloading KYC verification reports within ActiveAdmin. It allows administrators to filter verifications by date range and status, and to export the results in either a detailed CSV format or a summarized PDF format. The use of custom controllers and Prawn for PDF generation ensures that the reports are both comprehensive and visually appealing.
FILE