|
|
@@ -125,6 +125,10 @@ class TableAjax extends ViewAjax {
|
|
|
$this->_backRefFilter = $backRefFilter;
|
|
|
}
|
|
|
|
|
|
+ public function setChildRefFilter($childRefFilter) {
|
|
|
+ $this->_childRefFilter = $childRefFilter;
|
|
|
+ }
|
|
|
+
|
|
|
public function setFilterInit($filterInit) {
|
|
|
if ($this->_hasStateFilterInit()) {
|
|
|
return;
|
|
|
@@ -475,6 +479,23 @@ class TableAjax extends ViewAjax {
|
|
|
]);
|
|
|
}
|
|
|
?>
|
|
|
+ <?php
|
|
|
+ if ($this->_childRefFilter) {
|
|
|
+ echo UI::h('div', [ 'class' => "container" ], [
|
|
|
+ UI::h('div', [ 'class' => "alert alert-info" ], [
|
|
|
+ "Rekordy powiązane z rekordem {$this->_childRefFilter['primaryKey']} z ",
|
|
|
+ UI::h('a', [
|
|
|
+ 'href' => "index.php?_route=ViewTableAjax&namespace={$this->_childRefFilter['namespace']}",
|
|
|
+ ], $this->_childRefFilter['namespace']),
|
|
|
+ " - ",
|
|
|
+ UI::h('a', [
|
|
|
+ 'href' => $this->rootUrl,
|
|
|
+ 'style' => "color:red",
|
|
|
+ ], "usuń filtr"),
|
|
|
+ ]),
|
|
|
+ ]);
|
|
|
+ }
|
|
|
+ ?>
|
|
|
<div id="<?= $this->_htmlID; ?>"></div>
|
|
|
</div>
|
|
|
<?php
|
|
|
@@ -1255,7 +1276,7 @@ class TableAjax extends ViewAjax {
|
|
|
html: true,
|
|
|
content: _popoverCell.html()
|
|
|
}
|
|
|
- opts.template += '<div class="popover" role="tooltip" style="max-width:600px;width:400px;">';
|
|
|
+ opts.template += '<div class="popover" role="tooltip" style="max-width:600px;width:440px;">';
|
|
|
{
|
|
|
opts.template += '<div class="arrow"></div>';
|
|
|
//opts.template += '<h3 class="popover-title"></h3>';
|
|
|
@@ -5513,6 +5534,10 @@ jQuery(document).ready(function(){
|
|
|
$params['__backRef'] = $this->_backRefFilter;
|
|
|
DBG::log($params, 'array', '$params __backRef');
|
|
|
}
|
|
|
+ if ($this->_childRefFilter) {
|
|
|
+ $params['__childRef'] = $this->_childRefFilter;
|
|
|
+ DBG::log($params, 'array', '$params __childRef');
|
|
|
+ }
|
|
|
|
|
|
$filters = new stdClass();
|
|
|
$filters->currSortCol = $currSortCol;
|