statistical categories:
.example view for reports
-----------
+------------------------------------------------------------
create view extend_reporter.patronstats as
select u.id,
grp.name as "ptype",
left join actor.stat_cat_entry_usr_map ag
on (u.id = ag.target_usr and ag.stat_cat = 1)
where u.active = 't' and u.deleted <> 't';
------------
+------------------------------------------------------------
Add a new class to fm_IDL.xml for your data source
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
in the previous section.
.example class definition for reports
-----------
+------------------------------------------------------------
<class id="erpstats" controller="open-ils.reporter-store"
oils_obj:fieldmapper="extend_reporter::patronstats"
oils_persist:tablename="extend_reporter.patronstats" oils_persist:readonly="true"
<link field="home_lib_id" reltype="has_a" key="id" map="" class="aou"/>
</links>
</class>
----------
+------------------------------------------------------------
NOTE: _fm_IDL.xml_ is used by other core Evergreen DAO services, including cstore
and permacrud. So changes to this file can affect the entire Evergreen