Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

Once defined, multiple ways to export table.

Project description

PMongo

A small Python MongoDB Document-Based access engine.

Install

 pip install onetable

Useage

from onetable import DefualtTable, HtmlRender, XlsRender, XlsxRender, PdfRender, CSVRender

table = DefualtTable({'fontSize': 10, 'color': 'red'})
table.setStyles(
    ('x', {'fontSize': 14}),
    ('red', {'color': 'red'}),
    ('title', {'color': 'black', 'font': u'宋体', 'fontSize': 16, 'align': 'center'})
)
table.writeNextRowCols([('Title1', 3, 'title')])
table.pushStatus()
table.popStatus()
table.writeNextRowCols([1, 2, 3])
table.writeNextRowCols([3, 2, 1, 1], style='red')
with open('test.xls', 'wb') as out:
    XlsRender().save(tab=table, out=out)

CHANGES

0.0.1

  • first version

0.0.2

  • add usage

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for onetable, version 0.0.2
Filename, size File type Python version Upload date Hashes
Filename, size onetable-0.0.2.tar.gz (7.9 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page