src/DataTableAbstract.php
public function with($key, $value = '')
    {
        if (is_array($key)) {
            $this->appends = $key;
        } elseif (is_callable($value)) {
            $this->appends[$key] = value($value);
        } else {
            $this->appends[$key] = value($value);
        }

        return $this;
    }
public function with($key, $value = '')
    {
        if (is_array($key)) {
            $this->appends = $key;
        } elseif (is_callable($value)) {
            $this->appends[$key] = value($value);
        } else {
            $this->appends[$key] = value($value);
        }

        return $this;
    }
public function with ( $ key , $ value = '' ) { if ( is_array ( $ key ) ) { $ this -> appends = $ key ; } elseif ( is_callable ( $ value ) ) { $ this -> appends [ $ key ] = value ( $ value ) ; } else { $ this -> appends [ $ key ] = value ( $ value ) ; } return $ this ; }
Append data on json response.

@param mixed $key
@param mixed $value
@return $this
Append data on json response .