~shikharkohli/sahana-eden/gsoc1

« back to all changes in this revision

Viewing changes to controllers/budget.py

  • Committer: Shikhar Kohli
  • Date: 2010-08-11 18:40:09 UTC
  • mfrom: (802.1.156 eden)
  • Revision ID: shikharkohli@gmail.com-20100811184009-yy8zag5dowlam0ip
Merge trunk and update (a bit) of JS

Show diffs side-by-side

added added

removed removed

Lines of Context:
229
229
        from reportlab.lib.pagesizes import A4
230
230
        from reportlab.lib.enums import TA_CENTER, TA_RIGHT
231
231
    except ImportError:
232
 
        session.error = T("ReportLab module not available within the running Python - this needs installing to do PDF Reporting!")
 
232
        session.error = REPORTLAB_ERROR
233
233
        redirect(URL(r=request, c="item"))
234
234
    try:
235
235
        from geraldo import Report, ReportBand, ReportGroup, Label, ObjectValue, SystemField, landscape, BAND_WIDTH
236
236
        from geraldo.generators import PDFGenerator
237
237
    except ImportError:
238
 
        session.error = T("Geraldo module not available within the running Python - this needs installing to do PDF Reporting!")
 
238
        session.error = GERALDO_ERROR
239
239
        redirect(URL(r=request, c="item"))
240
240
 
241
241
    table = db.budget_item
520
520
    try:
521
521
        import xlwt
522
522
    except ImportError:
523
 
        session.error = T("xlwt module not available within the running Python - this needs installing to do XLS Reporting!")
 
523
        session.error = XLWT_ERROR
524
524
        redirect(URL(r=request, c="kit"))
525
525
 
526
526
    import StringIO
606
606
        from reportlab.lib.pagesizes import A4
607
607
        from reportlab.lib.enums import TA_CENTER, TA_RIGHT
608
608
    except ImportError:
609
 
        session.error = T("ReportLab module not available within the running Python - this needs installing to do PDF Reporting!")
 
609
        session.error = REPORTLAB_ERROR
610
610
        redirect(URL(r=request, c="kit"))
611
611
    try:
612
612
        from geraldo import Report, ReportBand, SubReport, Label, ObjectValue, SystemField, landscape, BAND_WIDTH
613
613
        from geraldo.generators import PDFGenerator
614
614
    except ImportError:
615
 
        session.error = T("Geraldo module not available within the running Python - this needs installing to do PDF Reporting!")
 
615
        session.error = GERALDO_ERROR
616
616
        redirect(URL(r=request, c="kit"))
617
617
 
618
618
    table = db.budget_kit