code: def _to_add_with_category(self, catid):
          '''
          Used for info2.
          :param catid: the uid of category
          '''
  
          catinfo = MCategory.get_by_uid(catid)
          kwd = {
              'uid': self._gen_uid(),
              'userid': self.userinfo.user_name if self.userinfo else '',
              'gcat0': catid,
              'parentname': MCategory.get_by_uid(catinfo.pid).name,
              'catname': MCategory.get_by_uid(catid).name,
          }
  
          self.render('autogen/add/add_{0}.html'.format(catid),
                      userinfo=self.userinfo,
                      kwd=kwdf _to_add_with_category(self, catid):
          '''
          Used for info2.
          :param catid: the uid of category
          '''
  
          catinfo = MCategory.get_by_uid(catid)
          kwd = {
              'uid': self._gen_uid(),
              'userid': self.userinfo.user_name if self.userinfo else '',
              'gcat0': catid,
              'parentname': MCategory.get_by_uid(catinfo.pid).name,
              'catname': MCategory.get_by_uid(catid).name,
          }
  
          self.render('autogen/add/add_{0}.html'.format(catid),
                      userinfo=self.userinfo,
                      kwd=kwd)
docs: Used for info2.
          :param catid: the uid of category