Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*pyc
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This is an enhanced class based on `MultiWidget` that lets you control the rende
class AddressWidget(MultiWidgetLayout):
def __init__(self, attrs=None):
layout = [
"<label for='%(id)s'>Street:</label>", TextInput()
"<label for='%(id)s'>Street:</label>", TextInput(),
"<label for='%(id)s'>Number:</label>", TextInput(),
"<label for='%(id)s'>Zip Code:</label>", TextInput()
]
Expand Down
20 changes: 20 additions & 0 deletions multiwidgetlayout/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
"""
An enhanced class based on MultiWidget that lets you easily control the
rendering using a layout
"""

__version_info__ = {
'major': 0,
'minor': 1,
'micro': 0,
}


def get_version():
vers = ["%(major)i.%(minor)i" % __version_info__, ]

if __version_info__['micro']:
vers.append(".%(micro)i" % __version_info__)
return ''.join(vers)

__version__ = get_version()
45 changes: 45 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
#!/usr/bin/env python

# from python
import os
from setuptools import setup, find_packages

# from project
import multiwidgetlayout


# TODO: You should include a requirements.txt with the minimum version of
# Django supported
#try:
#REQS = open(os.path.join(os.path.dirname(__file__),
#'requirements.txt')).read()
#except (IOError, OSError):
#REQS = ''

with open(os.path.join(os.path.dirname(__file__), 'README.md')) as file:
long_description = file.read()


setup(
name='django-multiwidgetlayout',
version=multiwidgetlayout.get_version(),
author='Miguel Araujo',
author_email='miguel.araujo.perez@gmail.com',
description=multiwidgetlayout.__doc__,
long_description=long_description,
url='https://github.com/Fandekasp/django-MultiWidgetLayout',
license='BSD License',
platforms=['OS Independent'],
packages=find_packages(),
include_package_data=True,
#install_requires=REQS,
classifiers=[
"Development Status :: 4 - Beta",
"License :: OSI Approved :: BSD License",
"Framework :: Django",
"Environment :: Web Environment",
"Intended Audience :: Developers",
"Operating System :: OS Independent",
"Programming Language :: Python",
],
)