https://github.com/luminousmen/django-sql
A simple app for executing SQL queries in Django admin panel.
https://github.com/luminousmen/django-sql
django django-admin-panel django-sql sql
Last synced: 11 months ago
JSON representation
A simple app for executing SQL queries in Django admin panel.
- Host: GitHub
- URL: https://github.com/luminousmen/django-sql
- Owner: luminousmen
- License: mit
- Created: 2016-10-05T18:49:21.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2024-02-07T19:37:36.000Z (about 2 years ago)
- Last Synced: 2024-07-07T00:42:51.315Z (over 1 year ago)
- Topics: django, django-admin-panel, django-sql, sql
- Language: Python
- Homepage:
- Size: 18.6 KB
- Stars: 2
- Watchers: 3
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[](https://travis-ci.org/luminousmen/django-sql)
[](https://coveralls.io/github/luminousmen/django-sql?branch=master)
[](https://badge.fury.io/py/django-sql)
[](https://github.com/luminousmen/django-sql/blob/master/LICENCE)
Django-SQL
====
A simple app for executing SQL queries in Django admin panel.
*! WARNINIG !*
_Do not install this app if you afraid of consequences of giving access to database from admin panel._
##### Requirements
* Python3
* Django 1.9
##### Installation
```
pip install django-sql
```
Add to your `INSTALLED_APPS` in `settings.py`:
```python
INSTALLED_APPS = [
...
'sqlapp',
]
```
Add to your `urls.py`:
```python
from sqlapp.sqlapp import execute_sql
urlpatterns = [
url(r'^admin/sqlapp/(?:sql/)?$', execute_sql, name='sql'),
url(r'^admin/', include(admin.site.urls), name='admin'),
]
```
**Note:** The `sqlapp` URL pattern must come BEFORE the `admin` pattern as shown above.
##### Contributors
* [luminousmen](https://github.com/luminousmen)
* [un-def](https://github.com/un-def)