title: YII2 - How to merge row yii2 gridview?
body: <p>i have gridview table like this :
  <a href="https://i.stack.imgur.com/SEQ5j.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/SEQ5j.png" alt="Gridview Storelist"></a></p>
  
  <p>i want to merge store 1(example) with 4 row detail information. is it possible to do it with?
  i have a code in gridview :</p>
  
  <pre><code>&lt;?php Pjax::begin(['id' =&gt; 'pjax_filesetting','timeout'=&gt;false]) ?&gt;
  &lt;?php 
  
      $this-&gt;registerJs(
      "
          $('.btneditfile').click(function(){
              var hqid = $(this).attr('data-hqid');
              var storeid = $(this).attr('data-storeid');
              var filename = $(this).attr('data-filename');
  
          location.href = '/pos/editfilesetting?hqid='+hqid+'&amp;storeid='+storeid+'&amp;filename='+filename;
              return false;
              });
      ");
  ?&gt;
      &lt;?= GridView::widget([
          'dataProvider' =&gt; $dataProvider,
          'options' =&gt; ['class' =&gt; 'grid-view active-table'],
          'columns' =&gt; 
              [
                  ['class' =&gt; 'yii\grid\SerialColumn'],
                  [
                      'label' =&gt; 'Store Name',
                      'attribute' =&gt; 'store_name',
                      'encodeLabel' =&gt; false,
                  ],
                  [
                      'label' =&gt; 'Filename',
                      'attribute' =&gt; 'filename',
                      'encodeLabel' =&gt; false,
                  ],
                  [
                      'label' =&gt; 'Datecheck',
                      'attribute' =&gt; 'datecheck',
                      'encodeLabel' =&gt; false,
                      'value' =&gt; function($model){
  
                                  $datecheck = $model["datecheck"];
  
                                  if($datecheck)
                                  {
                                      return $model["datecheck"] = "Check";
                                  }
                                  else
                                  {
                                      return $model["datecheck"] = "Not Check";
  
                                  }
                          }
                  ],
                  [
                      'label' =&gt; 'Timecheck',
                      'attribute' =&gt; 'timecheck',
                      'encodeLabel' =&gt; false,
                      'value' =&gt; function($model){
  
                                  $timecheck = $model["timecheck"];
  
                                  if($timecheck)
                                  {
                                      return $model["timecheck"] = "Check";
                                  }
                                  else
                                  {
                                      return $model["timecheck"] = "Not Check";
  
                                  }
                             }
                  ],
                  [
                      'label' =&gt; 'Maintenance code',
                      'attribute' =&gt; 'maincode',
                      'encodeLabel' =&gt; false,
                  ],
                  [
                      'label' =&gt; 'Final Filename',
                      'attribute' =&gt; 'usedfilename',
                      'encodeLabel' =&gt; false,
                  ],
                  [
                      'class' =&gt; 'yii\grid\ActionColumn',
                      'template' =&gt; '&lt;div align="center"&gt;{update} {delete}&lt;/div&gt;',
                              'buttons' =&gt; [                    
                                  'update' =&gt; function ($url, $model) use ($controller) {
                                      return Html::button(
                                          '&lt;span class="glyphicon glyphicon-pencil"&gt;&lt;/span&gt;',
                                          [
                                          'class' =&gt; 'btn btn-primary btn-xs btneditfile',
                                          'title' =&gt; Yii::t( $controller-&gt;transmodule, 'Edit' ),
                                          'style' =&gt; ['padding-top' =&gt; '5px', 'padding-bottom' =&gt; '5px'],
                                          'id' =&gt; 'editfile',
                                          'data-storeid' =&gt; $model['id'],
                                          'data-hqid' =&gt; $model['cmshqid'],
                                          'data-filename' =&gt; $model['filename'] 
                                      ]
                                  );
                              },
  
                              'delete' =&gt; function ($url, $model)use ($controller){   
                                  return Html::button(
                                  '&lt;span class="glyphicon glyphicon-trash"&gt;&lt;/span&gt;',
                                  [
                                      'class' =&gt; 'btn btn-danger btn-xs btndeletefile',
                                      'title' =&gt; Yii::t( $controller-&gt;transmodule, 'Delete' ),
                                      'style' =&gt; ['padding-top' =&gt; '5px', 'padding-bottom' =&gt; '5px'],
                                      'data-storeid' =&gt; $model['id'],
                                      'data-hqid' =&gt; $model['cmshqid'],
                                      'data-filename' =&gt; $model['filename'] 
                                  ]
                              );
                          },        
                      ],
                  ]
              ],
      ]) ?&gt;
      &lt;?php Pjax::end() ?&gt;
  </code></pre>
  
  <p>what must i do to merge it?
  what i need is if the store name is same, merge it column .</p>