svv/customers.py
changeset 9 0327b83959e9
parent 6 72c73df76db2
child 10 4bdb45071c89
equal deleted inserted replaced
8:27e37082625e 9:0327b83959e9
    33                 tags.tr(
    33                 tags.tr(
    34                     tags.th("ID #"),
    34                     tags.th("ID #"),
    35                     tags.th("Nimi"),
    35                     tags.th("Nimi"),
    36                 ),
    36                 ),
    37                 (tags.tr(
    37                 (tags.tr(
    38                     tags.td(tags.a(href=self.build_url(CustomerView, id=customer[db.customers.c.id]))('#%d' % customer[db.customers.c.id])),
    38                     tags.td(tags.a(href=self.url_for(CustomerView, id=customer[db.customers.c.id]))('#%d' % customer[db.customers.c.id])),
    39                     tags.td(tags.a(href=self.build_url(CustomerView, id=customer[db.customers.c.id]))(customer[db.customers.c.name])),
    39                     tags.td(tags.a(href=self.url_for(CustomerView, id=customer[db.customers.c.id]))(customer[db.customers.c.name])),
    40                 ) for customer in customers)
    40                 ) for customer in customers)
    41             ),
    41             ),
    42 
    42 
    43             tags.table(
    43             tags.table(
    44                 tags.tr(
    44                 tags.tr(
    49                     tags.th(u"Sähköpostiosoite"),
    49                     tags.th(u"Sähköpostiosoite"),
    50                 ),
    50                 ),
    51                 (tags.tr(
    51                 (tags.tr(
    52                     tags.td(tags.a(href='#')('#%d' % row[db.contacts.c.id])),
    52                     tags.td(tags.a(href='#')('#%d' % row[db.contacts.c.id])),
    53                     tags.td(
    53                     tags.td(
    54                         tags.a(href=self.build_url(CustomerView, id=row[db.customers.c.id]))(row[db.customers.c.name])
    54                         tags.a(href=self.url_for(CustomerView, id=row[db.customers.c.id]))(row[db.customers.c.name])
    55                             if row[db.customers.c.id] else " "
    55                             if row[db.customers.c.id] else " "
    56                     ),
    56                     ),
    57                     tags.td(
    57                     tags.td(
    58                         tags.a(href='#')(row[db.contacts.c.name]),
    58                         tags.a(href='#')(row[db.contacts.c.name]),
    59                     ),
    59                     ),