title: How to create 2 pages from reportlab using one PageTemplate?
body: <p>Hi all reportlab master,</p>
  
  <p>I've search the web and also here in stackoverflow but can't find a similar situation on my problem I'm trying to solve during this Holiday vacation.</p>
  
  <p>In django admin, I'm trying to create an action to view my database to a specific format. If I select one record I can view the report in one page pdf. Which is fine. In case the user try to more record that's where the problem start. For example I select multiple record, I can view the report but all content is still in one page pdf. </p>
  
  <p>Is there a way to show a record per page in pdf? All reportlab master jedi, Please help me how to do this the right way.</p>
  
  <p>Here's my code on what I did.</p>
  
  <pre><code>from django.contrib import admin
  from models import LatestRsl    
  from io import BytesIO
  from reportlab.pdfgen import canvas
  from django.http import HttpResponse
  
  
  try:
  from cStringIO import StringIO
      except ImportError:
  from StringIO import StringIO
  
  from reportlab.lib.units import inch
  from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
  from reportlab.platypus import BaseDocTemplate, PageTemplate, Paragraph, Frame
  from reportlab.lib.pagesizes import letter
  
  def go(modeladmin, request, queryset):
      response = HttpResponse(mimetype='application/pdf')
      response['Content-Disposition'] = 'filename = testframe.pdf'
  
      buffer = StringIO()
      c = canvas.Canvas(buffer)
      doc = BaseDocTemplate(buffer, showBoundary=1, leftMargin= 0.1*inch, rightMargin= 0.1*inch,
                       topMargin= 0.1*inch, bottomMargin= 0.1*inch)
  
      signfr = Frame(5.1*inch, 1.2*inch, 2.8*inch, 0.44*inch, showBoundary=1)
      modelfr = Frame(3.6*inch, 4.6*inch, 2.8*inch, 0.44*inch, showBoundary=1)
      doc.addPageTemplates([PageTemplate(id= 'rsl_frame', frames=[signfr, modelfr]),
                           PageTemplate(id= 'rsl_frame2', frames=[signfr, modelfr])])
  
      story = []
  
      styles=getSampleStyleSheet()
          styles.add(ParagraphStyle(name='Verdana9', fontName= 'Verdana', fontSize= 9))
          styles.add(ParagraphStyle(name='VerdanaB10', fontName= 'VerdanaB', fontSize= 10))
  
      for obj in queryset:
          #1st frame
          model = Paragraph(obj.make,styles["Verdana9"])
          story.append(model)
          modelfr.addFromList(story,c)
  
          #2nd frame
          signatory = Paragraph(obj.signatory,styles["VerdanaB10"])
          story.append(signatory)
          signfr.addFromList(story,c)
  
      doc.build(story)
      c.showPage()
      c.save()
      pdf = buffer.getvalue()
      buffer.close()
      response.write(pdf)
  return response
  </code></pre>