|
|
|
@ -325,10 +325,16 @@ class MailRoom(Bureau):
|
|
|
|
|
msg.subject = clean_header(envelope.subject.decode("utf-8"))
|
|
|
|
|
|
|
|
|
|
# make action barcodes
|
|
|
|
|
msg.d_bc = kode256.svg("POd." + shortcode)
|
|
|
|
|
msg.sp_bc = kode256.svg("POsp." + shortcode)
|
|
|
|
|
msg.r_bc = kode256.svg("POr." + shortcode)
|
|
|
|
|
|
|
|
|
|
msg.d_bc = os.path.join("/tmp", "POd." + shortcode + ".svg")
|
|
|
|
|
with open(msg.d_bc, "w") as svgfile:
|
|
|
|
|
svgfile.write(kode256.svg("POd." + shortcode))
|
|
|
|
|
msg.r_bc = os.path.join("/tmp", "POr." + shortcode + ".svg")
|
|
|
|
|
with open(msg.r_bc, "w") as svgfile:
|
|
|
|
|
svgfile.write(kode256.svg("POr." + shortcode))
|
|
|
|
|
msg.sp_bc = os.path.join("/tmp", "POd." + shortcode + ".svg")
|
|
|
|
|
with open(msg.sp_bc, "w") as svgfile:
|
|
|
|
|
svgfile.write(kode256.svg("POsp." + shortcode))
|
|
|
|
|
|
|
|
|
|
msgs.append(msg.__dict__)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|