'Creates a custom certificate template entry in DB.'

def _create_custom_template(self, org_id=None, mode=None, course_key=None):

    template_html = '\n                                                <%namespace    name=\'static\'    file=\'static_content.html\'/>\n                                                <html>\n                                                <body>\n                                                                lang:    ${LANGUAGE_CODE}\n                                                                course    name:    ${accomplishment_copy_course_name}\n                                                                mode:    ${course_mode}\n                                                                ${accomplishment_copy_course_description}\n                                                                ${twitter_url}\n                                                                <img    class="custom-logo"    src="${static.certificate_asset_url(\'custom-logo\')}"    />\n                                                </body>\n                                                </html>\n                                '
    template = CertificateTemplate(name='custom    template', template=template_html, organization_id=org_id, course_key=course_key, mode=mode, is_active=True)
    template.save()
