Sha256: 29847be2dc23eeb94030c22aba81bb4093768c2cb0bf021dc8c6757d92e0335d
Contents?: true
Size: 1.43 KB
Versions: 10
Compression:
Stored size: 1.43 KB
Contents
:plain <style> @import http://artfully-pdf-css.s3.amazonaws.com/helvetica.css; body { padding: 0; margin: 0; font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; font-size: 13px; line-height: 18px; color: #000; } .card { width: 3.5in; height: 2in; border: 1px solid #000; clear: both; margin-bottom: 1in; } .qr-code img { margin-left: 1px; margin-top: 1px; width: 150px; height: 150px; } .left-side { float: left } .right-side { margin-top: 10px; } .organization-name { font-weight: bold; } .membership { margin-bottom: 10px; } .person-name { font-weight: bold; } .membership-number { margin-bottom: 10px; } .expiration { font-size: 11px; } </style> :ruby member = pdfable membership = member.memberships.current.first person = member.person .card .left-side .qr-code %img{:src => (member.download_link_for(:qr_code) rescue 'http://placehold.it/150/ffffff.png&text=No+QR+Code')} .right-side .organization-name #{member.organization.name} .membership Member: #{membership.membership_type.name} .person-name #{person.first_name} #{person.last_name} .membership-number Member ##{member.member_number} .expiration Valid until #{I18n.localize membership.ends_at, :format => :date}
Version data entries
10 entries across 10 versions & 1 rubygems