title: Yii2 karthik editable column first row not working
body: <p>I used karthik grid view and editable column to edit my grid view data. it not work for the first row of the grid view and work for the other rows when i enter value to the first row it give error like this</p>
  
  <blockquote>
    <p>SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data</p>
  </blockquote>
  
  <p>my gridview code is.</p>
  
  <pre><code>&lt;?= GridView::widget([
              'dataProvider' =&gt; $dataProvider,
              'pjax' =&gt; true,
              'pjaxSettings' =&gt; [
                      'options' =&gt; [
                          'id' =&gt; 'grid', 
  
                      ]
                      ],
              'export'=&gt;false,
              'columns' =&gt; [
                  ['class' =&gt; 'yii\grid\SerialColumn'],
                  [
                      'header'=&gt;'Sub Category',
                      'value'=&gt;'item.subCategory.name',
                  ],
                  'item.code',
                  [
                      'header'=&gt;'Brand',
                      'value'=&gt;'item.brand.name',
                  ],
                  'item.description',
                  'item.pack_size',
                  [
                      'header'=&gt;'Unit',
                      'value'=&gt;'item.unit',
                  ],
                  [
                      'header'=&gt;'Last Price',
                      'value'=&gt;function($model){
                          $customerId = $model-&gt;customerOrderRequest-&gt;customer_id;
                          $lastPurchasedPrice = Item::getLastPurchasedPrice($customerId,$model-&gt;item_id);
                          return '$ ' . number_format($lastPurchasedPrice, 2);
                      }
                  ],
                  [
                      'class' =&gt; 'kartik\grid\EditableColumn',
                      'attribute'=&gt;'qty', 
                      'editableOptions' =&gt; 
                      [
                        'formOptions' =&gt; ['action' =&gt; 'customer-order-request']
                      ],
                      'header' =&gt; 'Qty',
                  ],
                  [
                      'header'=&gt;'Estimate',
                      'value'=&gt;function($model)
                      {
                          return '123123.00';
                      }
                  ],
                  [
                      'header'=&gt;'Price (UNIT)',
                      'format'=&gt;'raw',
                      'value'=&gt;function($modal){
                          $salse_rep_id = Yii::$app-&gt;user-&gt;identity-&gt;ref_id;
                          $exsist_respond = Respond::find()-&gt;where(['sales_rep_id'=&gt;$salse_rep_id,'customer_order_request_id'=&gt;$modal-&gt;customer_order_request_id])-&gt;one();
                          if(!empty($exsist_respond)){
                              $exsist_respond_item = RespondItem::find()-&gt;where(['item_id'=&gt;$modal-&gt;item_id,'respond_id'=&gt;$exsist_respond-&gt;id])-&gt;one();
                              if(!empty($exsist_respond_item)){
                              $price = $exsist_respond_item-&gt;price;    
                              }  else {
                              $price = NULL;
                              }
  
                          }  else {
                              $price = NULL;
                          }
                          if(!empty($exsist_respond) &amp;&amp; $exsist_respond-&gt;status !="Pending"){
                                return $price; 
                          }else{
  
                          return "&lt;input type='text' class='respond-item' cor='$modal-&gt;customer_order_request_id' value='$price' item_id='$modal-&gt;item_id' /&gt;";
  
                          }
  
                          },
                      'visible'=&gt;(Yii::$app-&gt;user-&gt;identity-&gt;ref_table =="sales_rep")? true:false
                  ],
  
  
              ],
          ]); ?&gt;
  </code></pre>
  
  <p>and my controller is</p>
  
  <pre><code>public function actionEditable()
  {
      if (Yii::$app-&gt;request-&gt;post('hasEditable')) 
      {
          $customerItemsId = Yii::$app-&gt;request-&gt;post('editableKey');
          print_r($customerItemsId);die();
          $model = RequestItem::findOne($customerItemsId);
  
          $out = Json::encode(['output'=&gt;'', 'message'=&gt;'']);
  
          $post = [];
          $posted = current($_POST['RequestItem']);
          $post['RequestItem'] = $posted;
  
          if ($model-&gt;load($post)) 
          {
  
              $model-&gt;save();
              $output = '';
  
              $out = Json::encode(['output'=&gt;$output, 'message'=&gt;'']);
          } 
          echo $out;
          return;
      }
  
  }
  </code></pre>
  
  <p>any one can help me with this problem.</p>