diff --git a/pinaxcon/templates/registrasion/badge.svg b/pinaxcon/templates/registrasion/badge.svg index 162e096f42b97209091ea67bf7babfadf4bebe5d..941a414c07e6988ac5f42596b575fedbcdb8d50e 100644 --- a/pinaxcon/templates/registrasion/badge.svg +++ b/pinaxcon/templates/registrasion/badge.svg @@ -5,6 +5,7 @@ {% ticket_type as ticket %} {% affiliation ticket user as aff %} {% company_split aff as split_affiliation %} +{% special user as special %} {% with name1=split_name.first name2=split_name.last affiliation1=split_affiliation.first affiliation2=split_affiliation.last %} {% include "registrasion/badge_outer.svg" %} diff --git a/pinaxcon/templates/registrasion/badge_outer.svg b/pinaxcon/templates/registrasion/badge_outer.svg index 73b872a39ccba0d036fba1e5f29326391fc99535..e69c328191fb66bdfdb5ea1d4db92aed7044dcf8 100644 --- a/pinaxcon/templates/registrasion/badge_outer.svg +++ b/pinaxcon/templates/registrasion/badge_outer.svg @@ -200,7 +200,7 @@ x1="242.77402" gradientTransform="matrix(1.7944572,0,0,0.86754101,-266.2916,412.78825)" gradientUnits="userSpaceOnUse" - id="linearGradient4469" + id="linearGradient4610" xlink:href="#linearGradient8426" /> {{ affiliation2 }} + {{ special }} + transform="matrix(-1,0,0,-1,328.65539,2102.4508)" + id="g4574"> + id="rect4582" + style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:1;fill:url(#linearGradient4610);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate" /> + id="path4584" /> + style="opacity:1;fill:url(#linearGradient4612);fill-opacity:1;stroke:#000000;stroke-width:4.54716158;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + id="path4590" /> {{ name1 }}{{ name2 }} + id="tspan4596">{{ name2 }} {{ affiliation1 }}{{ affiliation2 }} + id="tspan4602">{{ affiliation2 }} + {{ special }} diff --git a/pinaxcon/templatetags/nbpy_tags.py b/pinaxcon/templatetags/nbpy_tags.py index 21dce2039a9414e5b6fea2eb2b2c0eb66f8a761a..e27b4265938e317167c7bdc732b82619f4f89291 100644 --- a/pinaxcon/templatetags/nbpy_tags.py +++ b/pinaxcon/templatetags/nbpy_tags.py @@ -67,6 +67,21 @@ def company_split(name): return f +@register.simple_tag(takes_context=True) +def special(context, user): + organiser = user.groups.filter(name='Conference organisers').exists() + speaker = user.speaker_profile.presentations.count() != 0 + volunteer = "Volunteer" in ticket_type(context) + + if organiser: + return "Organizer" + elif speaker: + return "Speaker" + elif volunteer: + return "Staff" + else: + return "" + CLEARED = set([ "BeeWare Project",