camptocamp webkit

20
Camptocamp / 13. avril 2011 / www.camptocamp.com / [email protected] Report Webkit Partner/community days presentation

Upload: nico-tristan

Post on 27-Jun-2015

4.583 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Camptocamp webkit

Camptocamp / 13. avril 2011 / www.camptocamp.com / [email protected]

Report WebkitPartner/community days presentation

Page 2: Camptocamp webkit

History of Report Webkit

First we have report workshop in community days 2010Then we have the opportunity...

Page 3: Camptocamp webkit

History of Report Webkit

Ok, so let me talk about a last detail. The printing of invoices.

Page 4: Camptocamp webkit

History of Report Webkit

First, We are going to have resellers.They should be able to have uniquestyle and header on invoices.They should be able to customizedesign easily.

Page 5: Camptocamp webkit

History of Report Webkit

Second, We have to print payment slip.With or without backgroundor formatted for easy copy paste.And some time we do not want payment slip. Simple isn’t it...

Page 6: Camptocamp webkit

History of Report Webkit

We may also want to insert commercials strips from our server.

I heard that OpenERP has a DMS.It would be nice to have invoicesin it.

Page 7: Camptocamp webkit

History of Report Webkit

Oh and more than 100’000 monthly invoices have to be printed in one night.

Page 8: Camptocamp webkit

History of Report Webkit

Is it OKAY for you.

Can you do it ?

Page 9: Camptocamp webkit

History of Report Webkit

Of course, no problem!

Agrrr

Page 10: Camptocamp webkit

History of Report Webkit

Thus was born Report Webkit

Page 11: Camptocamp webkit

OverviewMulti header report

HTML/CSS based

Javascript support (if you dare)

Mako template based

Integrated

wkhtml2pdf >= 1.0 (please use stable release)

Render PDF or HTML (for HTML fix pending)

Page 12: Camptocamp webkit

Data structureHeaderHTML

ir.header_webkit//Implicit relation filed+company_id//HTML definition of header+html//HTML definition of footer+footer_html//Report CSS (Does not apply to header)+css+name+margin_* (top, bottom, left, right)+orientation [landscape, portrait]+format [A0..Tabloïd]

ReportXMLir.actions.report.xml

//Implicit relation field !! property fields allows global header+webkit_header//HTML raw input+webkit_debug//Embedded HTML if report created in client +report_webkit_data//Report type set to webkit for WebKit+report_type//Path to mako file+report_file//Activate header or not +header

*

0..1

Companyres.company

//Absolute Path to wkhtmltopdd lib+lib_path

*0..1

Page 13: Camptocamp webkit

How to Demo

1. Set absoute lib path to wkhtml2pdf

Page 14: Camptocamp webkit

How to Demo

2. Find the correct menu

Page 15: Camptocamp webkit

How to Demo

3. Create a new report

HTML header

Osv model(_name)

Mako syntaxreport body

Report type(webkit)

Page 16: Camptocamp webkit

How to Demo

3. Create a new report:You can deactivate header

3. Create a new report:You can set a file instead of DB data

Page 17: Camptocamp webkit

How to Demo

4. You can add a print button

ORYou can do it with XML (no need to add button)

<report auto="False"id="any_text" model="any_open_erp_ovs_name" name="any_text" file="Path to file" string="Text of the button" report_type="webkit"/>

Page 18: Camptocamp webkit

More complex samples

report_webkit_sample

l10n_ch bvr report

Page 19: Camptocamp webkit

TODOFix utf8

OpenERP have a look at : https://code.launchpad.net/~c2c/openobject-addons/6.0_report_webkit_utf8_support/+merge/56716

!! wkhtml 1.0 only

Add helpers to acces header

Fix menu and acces rights

Provide a WYSIWYG edit tool based on Komposer or equivalent.(Any suggestions are welcome)

Page 20: Camptocamp webkit

20

ContactCamptocamp SAPSE A – Parc Scientifique EPFL1015 Lausanne, Suisse

Camptocamp France SASSavoie Technolac48 avenue du Lac du Bourget73372 Le Bourget du Lac, France

www.camptocamp.com

Nicolas Bessi, Technical director

Tél : +41 21 619 10 04 (CH), +33 479 44 44 95 (FR)E-mail : [email protected]