Renders a dynamically refreshing table built client-side from JSON data fetched via RPC, with configurable column labels, widths, and alignment.
SMARTTABLE — set as ReportType in def_report.
def Render(self, Param1="", Param2="", Param3="") -> str:
Param1, Param2, Param3 — substituted into $param1$, $param2$, $param3$ placeholders in the query, passed to RpcGetlist.Returns an HTML div containing JavaScript that calls RemoteProcedureCall on a timer to invoke RpcGetlist, then builds a jQuery-based <table> inside a container div.
RpcGetlist(data)Executes self._Query with $param1$, $param2$, $param3$, $user$, $usergroups$, $usercompany$, and $company$ substituted from the RPC payload. Returns a list of dicts (one per row), with dates converted to strings and binary prefixes stripped.
get_columm_options(report_options)Parses self._Options JSON and returns the columns sub-object for per-column configuration.
Options read from self._Options JSON:
| Key | Effect |
|---|---|
columns |
Dict keyed by column name. Each entry may have label, width, and align. |
axion.rpc.js for the RemoteProcedureCall function.self._Refresh (seconds); multiplied by 1000 for milliseconds. Defaults to 10 seconds if unset or invalid. Set to 0 to disable auto-refresh.document.visibilityState === "visible".