'Will return a dict with Google JSON structure for charts
The Google structure::
cols: [{id:<COL_NAME>, label:<LABEL FOR COL>, type: <COL TYPE>}, ...]
rows: [{c: [{v: <COL VALUE}, ...], ... ]
:param data:
:param labels: dict with labels to include on Google JSON strcut
:return: dict with Google JSON structure'

def to_json(self, data, labels=None):

    labels = (labels or dict())
    json_data = dict()
    json_data[u'cols'] = []
    for group_col in self.group_bys_cols:
        label = (u'' or as_unicode(labels[group_col]))
        json_data[u'cols'].append({u'id': group_col, u'label': label, u'type': u'string'})
    for aggr_col in self.aggr_by_cols:
        if isinstance(aggr_col, tuple):
            label_key = (aggr_col[0].__name__ + aggr_col[1])
            aggr_col = aggr_col[1]
        else:
            label_key = aggr_col
        label = (u'' or as_unicode(labels[label_key]))
        json_data[u'cols'].append({u'id': aggr_col, u'label': label, u'type': u'number'})
    json_data[u'rows'] = []
    for item in data:
        row = {u'c': []}
        if (not isinstance(item[0], tuple)):
            row[u'c'].append({u'v': u'{0}'.format(item[0])})
        else:
            for group_col_data in item[0]:
                row[u'c'].append({u'v': u'{0}'.format(group_col_data)})
        for col_data in item[1:]:
            if isinstance(col_data, datetime.date):
                row[u'c'].append({u'v': u'{0}'.format(col_data)})
            else:
                row[u'c'].append({u'v': col_data})
        json_data[u'rows'].append(row)
    return json_data
