<?php if(is_array($this->view->structure)): ?>
	<?php $counter = 0; ?>
	<?php foreach($this->view->structure as $group_index => $structure): ?>
		<?php if(!is_null($structure['group']['label'])): ?>
		
			<?php if (trim($structure['group']['label']) != ''): ?>
				<div class="form-group col-lg-12 margin-bottom-40 margin-top-40">
					<div class="strike-center strike-large"><span><?php echo $structure['group']['label']; ?></span></div>
				</div>
			<?php else: ?>
				<?php if ($structure['group']['separator']): ?>
					<div class="form-group col-lg-12 margin-top-40"><hr></div>
				<?php endif; ?>
			<?php endif; ?>
			
		<?php endif; ?>
		
		<?php foreach($structure['items'] as $item_index => $item): ?>
			<?php echo $this->partial('Survey/input', ['type'=>$item['type'], 'group'=>$group_index, 'index'=>$counter, 'item'=>$item]); ?>
			<?php $counter++; ?>
		<?php endforeach; ?>
		
	<?php endforeach; ?>
<?php endif; ?>