title: Child class post method to return different template and context
body: <p>I want to be able to take the same form input and use it to do calculations (using different urls) for different products and send product results to a product template</p>
  
  <p>I tried having a base class with get and post methods from which child classes(different product urls) will inherit especially the post method to remain DRY</p>
  
  <pre><code>from .models import InputForm
  
  class InputView(TemplateView):
      template_name = 'input.html'
  
      def get(self, request, *args, **kwargs):
          form = InputForm()
          return render(request, self.template_name, {'form': form})
  
  
      def post(self, request, *args, **kwargs):
          form = InputForm(request.POST)
          if form.is_valid():
              cleaned_data = form.cleaned_data
              a =cleaned_data['mbr_l']
              b =cleaned_data['es_l']
              c =cleaned_data['wic_l']
              d =cleaned_data['br2_l']
  
              length = a + b + c + d
  
              qty = 0.8*length
  
              return render(request, 'result.html',  {'qty': qty})
  
  
          else:
              return render(request, self.template_name, {'form': form})
  
  class B(InputView):
      def post(self, request, *args, **kwargs):
          qty2 = super().post(self, request, *args, **kwargs)
  
          return super().render(request, 'result2.html',  {'qty2': qty2})
  url conf:
  urlpatterns = [
      path('product1', InputView.as_view()),
      path('product2',B.as_view()),
   ]
  
  templates:
  
  template1
  &lt;td&gt;{{qty1}}&lt;/td&gt;
  
  template2
  &lt;td&gt;{{qty2}}&lt;/td&gt;
  
  
  
  
  </code></pre>
  
  <p>I expect the url product2 in url conf to do calculation and send context(qty2) to results2.html but it always renders results.html with qty which is correct because B is inheriting InputView and all methods.I dont really expect the call to super of render method to be valid but that was the last of my many trials.</p>