def post(self, request, *args, **kwargs): sql = request.POST.get('sql') connection = request.POST.get('connection', '') query = Query(sql=sql, connection=connection, title='') ql = query.log(request.user) query.title = 'Playground - %s' % ql.id return _export(request, query)
def post(self, request, *args, **kwargs): sql = request.POST.get('sql') connection = request.POST.get('connection') query = Query(sql=sql, connection=connection, title='') ql = query.log(request.user) query.title = 'Playground - %s' % ql.id return _export(request, query)
def download_from_sql(request): sql = request.POST.get('sql') query = Query(sql=sql, title='') ql = query.log(request.user) query.title = 'Playground - %s' % ql.id return _export(request, query)