| 12345678910111213141516171819202122232425262728293031 |
- <?php
- Lib::loadClass('Api_WfsNs');
- class Route_UrlAction_BiAuditGraph extends RouteBase {
- function defaultAction() {
- UI::layout([$this, 'defaultView']);
- }
- function defaultView() {
- // typeName = "default_db__x3A__BI_audit_KRS_person:BI_audit_KRS_person"
- $namespace = 'default_db/BI_audit_KRS_person/BI_audit_KRS_person'; // V::get('namespace', '', $_GET);
- if (!$namespace) throw new Exception("Missing namespace");
- $primaryKey = V::get('primaryKey', '', $_GET);
- if (!$primaryKey) throw new Exception("Missing primaryKey");
- echo UI::h('div', [ 'id' => "ref_graph_node", 'style' => "width:98%; height:500px; border:1px solid silver; margin:8px auto; padding:0" ], [
- "Pobieranie danych..."
- ]);
- echo UI::h('script', [ 'src' => "static/visjs/vis.min.js" ]);
- echo UI::h('style', [ 'type' => "text/css", 'src' => "static/visjs/vis.min.css" ]);
- UI::inlineJS(__FILE__ . '.view.js', [
- 'HTML_ID_REF_GRAPH' => 'ref_graph_node',
- 'TYPENAME' => Api_WfsNs::typeName($namespace),
- 'PRIMARY_KEY' => $primaryKey,
- 'WFS_URL' => Router::getRoute('WfsBiAudit')->getLink(),
- 'DBG' => (V::get('DBG', 0, $_GET, 'int') > 0),
- ]);
- }
- }
|