Skip to content

Commit

Permalink
🚨 Edit for forward compatibility (#74)
Browse files Browse the repository at this point in the history
* 🚨 Edit urls.py files for forward compatibility and Change xlrd version for pyexcel-xls

* 📝 Add change log in changelog.yml
  • Loading branch information
yeop-sang authored Nov 11, 2024
1 parent d764912 commit 1ddf73c
Show file tree
Hide file tree
Showing 6 changed files with 38 additions and 32 deletions.
8 changes: 8 additions & 0 deletions changelog.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
name: django-excel
organisation: pyexcel-webwares
releases:
- changes:
- action: 'Change:'
details:
- Support for django 2.0.x
- Tested against django 4.1
- Change xlrd version <=1.2.0
date: 18.08.2022
version: 0.0.12
- changes:
- action: Updated
details:
Expand Down
7 changes: 4 additions & 3 deletions mysite/urls.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
from django.conf.urls import include, url
from django.conf.urls import include
from django.urls import re_path
from django.contrib import admin


urlpatterns = [
url(r'^admin/', admin.site.urls),
url(r'^polls/', include('polls.urls'))
re_path(r'^admin/', admin.site.urls),
re_path(r'^polls/', include('polls.urls'))
]
49 changes: 24 additions & 25 deletions polls/urls.py
Original file line number Diff line number Diff line change
@@ -1,34 +1,33 @@
from django.conf.urls import url
from django.urls import re_path
from polls import views


urlpatterns = [
url(r'^$', views.upload, name='uplink'),
url(r'^download/(.*)', views.download, name="download"),
url(r'^download_attachment/(.*)/(.*)', views.download_as_attachment,
name="download_attachment"),
url(r'^exchange/(.*)', views.exchange, name="exchange"),
url(r'^parse/(.*)', views.parse, name="parse"),
url(r'^import/', views.import_data, name="import"),
url(r'^import_sheet/', views.import_sheet, name="import_sheet"),
url(r'^export/(.*)', views.export_data, name="export"),
url(r'^handson_view/', views.handson_table, name="handson_view"),
re_path(r'^$', views.upload, name='uplink'),
re_path(r'^download/(.*)', views.download, name="download"),
re_path(r'^download_attachment/(.*)/(.*)', views.download_as_attachment,
name="download_attachment"),
re_path(r'^exchange/(.*)', views.exchange, name="exchange"),
re_path(r'^parse/(.*)', views.parse, name="parse"),
re_path(r'^import/', views.import_data, name="import"),
re_path(r'^import_sheet/', views.import_sheet, name="import_sheet"),
re_path(r'^export/(.*)', views.export_data, name="export"),
re_path(r'^handson_view/', views.handson_table, name="handson_view"),

# handson table view
url(r'^embedded_handson_view/',
views.embed_handson_table, name="embed_handson_view"),
url(r'^embedded_handson_view_single/',
views.embed_handson_table_from_a_single_table,
name="embed_handson_view"),
re_path(r'^embedded_handson_view/',
views.embed_handson_table, name="embed_handson_view"),
re_path(r'^embedded_handson_view_single/',
views.embed_handson_table_from_a_single_table,
name="embed_handson_view"),
# survey_result
url('^survey_result/',
views.survey_result, name='survey_result'),
re_path('^survey_result/',
views.survey_result, name='survey_result'),

# testing purpose
url(r'^import_using_isave/',
views.import_data_using_isave_book_as),
url(r'^import_sheet_using_isave/',
views.import_sheet_using_isave_to_database),
url(r'^import_without_bulk_save/',
views.import_without_bulk_save, name="import_no_bulk_save")
re_path(r'^import_using_isave/',
views.import_data_using_isave_book_as),
re_path(r'^import_sheet_using_isave/',
views.import_sheet_using_isave_to_database),
re_path(r'^import_without_bulk_save/',
views.import_without_bulk_save, name="import_no_bulk_save")
]
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
pyexcel>=0.5.7
pyexcel-webio>=0.1.2
Django>=1.6.1
Django>=2.0
3 changes: 0 additions & 3 deletions testResponse.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@
from django.test import Client, TestCase
from django.test.utils import override_settings
import pyexcel as pe
import pyexcel.ext.xls # noqa
import pyexcel.ext.xlsx # noqa
import pyexcel.ext.ods3 # noqa
from django_excel._compact import urllib_quote
from django_excel import ExcelInMemoryUploadedFile
from nose.tools import eq_
Expand Down
1 change: 1 addition & 0 deletions tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
xlrd<=1.2.0
nose
mock;python_version<"3"
codecov
Expand Down

0 comments on commit 1ddf73c

Please sign in to comment.