Skip to content

Commit

Permalink
fix index
Browse files Browse the repository at this point in the history
  • Loading branch information
goxiaoy committed Aug 12, 2023
1 parent 7d458f8 commit 2acd022
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions packages/flutter_survey_js/lib/ui/element_node.dart
Original file line number Diff line number Diff line change
Expand Up @@ -148,11 +148,16 @@ class ElementNode {
if (element is s.Matrixdynamic || element is s.Paneldynamic) {
params.prePanelIndex = 0;
params.prePanelIndexOfAll = 0;

if (visibleIf ?? true) {
indexInPage = params.preIndexInPage;
params.preIndexInPage++;
indexAll = params.preIndexOfAll;
params.preIndexOfAll++;
}
for (final c in children) {
c.calIndexAfterExpression(params, insideDynamic: true);
}
} else if (element is s.Question) {
} else if (element is s.Question && element is! Nonvalue) {
isInsideDynamic = insideDynamic;
pageIndex = params.pageIndex;
if (insideDynamic) {
Expand Down

0 comments on commit 2acd022

Please sign in to comment.