Commit a478e892e0b3f8a27bdeaa917c7c30e46a0a79ec

Authored by Benjamin Renard
1 parent 8d422f34

Apply dataset time restriction in relation with the PriorID

Showing 1 changed file with 2 additions and 1 deletions   Show diff stats
php/classes/UserMgr.php
... ... @@ -729,7 +729,8 @@ class UserMgr
729 729  
730 730 if (!empty($this->datasetsTimeRestriction)) {
731 731 foreach ($this->datasetsTimeRestriction as $datasetTimeRestriction) {
732   - $nodes = $xp->query("//dataset[@xml:id='".str_replace('_','-',$datasetTimeRestriction['vi'])."']");
  732 + $dataset_id = str_replace('_','-',$datasetTimeRestriction['vi']);
  733 + $nodes = $xp->query("//dataset[@xml:id='".$dataset_id."' or @PriorID='".$dataset_id."']");
733 734 if ($nodes->length > 0) {
734 735 foreach ($nodes as $node) {
735 736 $timeRestriction = $datasetTimeRestriction['restriction'];
... ...