summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorprashant2016-03-16 18:48:09 +0530
committerprashant2016-03-16 18:48:09 +0530
commit9d3336d75df7534baee27f2140a8e4dbf0637f7c (patch)
tree0e33083a07f16387c135a8d734784f898b1efd9e
parent642b5cd19801ae2385b86b8d5f5004f05bb42da8 (diff)
downloadcertificate-generator-9d3336d75df7534baee27f2140a8e4dbf0637f7c.tar.gz
certificate-generator-9d3336d75df7534baee27f2140a8e4dbf0637f7c.tar.bz2
certificate-generator-9d3336d75df7534baee27f2140a8e4dbf0637f7c.zip
added internship certificate
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/Makefile36
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/bashful.sty544
-rw-r--r--certificate/fossee_internship_cerificate_template/cer_bg_2.pngbin0 -> 408763 bytes
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/fossee-logo.pngbin0 -> 19082 bytes
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/fossee-logo1.pngbin0 -> 79661 bytes
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/fossee_logo.pngbin0 -> 19082 bytes
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/iitb-logo.pngbin0 -> 50099 bytes
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/kannan-moudgalya-sign.pngbin0 -> 19082 bytes
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/missfont.log0
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/niceframe.sty140
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/template_FIC2016Acertificate21
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/template_FIC2016Acertificate~91
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/text.pngbin0 -> 27082 bytes
-rwxr-xr-xcertificate/fossee_internship_cerificate_template/wallpaper.sty250
-rw-r--r--certificate/templates/fossee_internship_cerificate_download.html67
-rwxr-xr-x[-rw-r--r--]certificate/templates/index.html1
-rwxr-xr-x[-rw-r--r--]certificate/templates/verify.html6
-rwxr-xr-x[-rw-r--r--]certificate/urls.py6
-rwxr-xr-x[-rw-r--r--]certificate/views.py330
19 files changed, 1490 insertions, 2 deletions
diff --git a/certificate/fossee_internship_cerificate_template/Makefile b/certificate/fossee_internship_cerificate_template/Makefile
new file mode 100755
index 0000000..c741438
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/Makefile
@@ -0,0 +1,36 @@
+# Makefile for Certificate
+
+# bashful package available @
+# http://www.ctan.org/tex-archive/macros/latex/contrib/bashful
+
+# pst-barcode package available @
+# http://www.ctan.org/tex-archive/graphics/pstricks/contrib/pst-barcode
+
+# target is not a real file
+.PHONY: help certificate clean
+
+# following line is because on server texlive is not installed system-wide
+export PATH := /usr/local/texlive/2015/bin/x86_64-linux:$(PATH)
+# default help
+help:
+ @echo "current make version is: "$(MAKE_VERSION)
+ @echo "Please use \`make <target>' where <target> is one of"
+ @echo ""
+ @echo "participant_cert file_name=xyz Generate certificate."
+ @echo "clean clean all tmp and pdf files."
+ @echo "help Show this help."
+ @echo ""
+
+name = $(file_name)
+
+# certificate
+participant_cert: $(name).tex fossee-logo.png bashful.sty
+ pdflatex -shell-escape $(name).tex
+
+paper_cert: $(name).tex fossee-logo.png bashful.sty
+ pdflatex -shell-escape $(name).tex
+
+clean:
+ @echo "removing all tmp+pdf files"
+ -rm -rvf $(name)*.pdf *~ $(name).aux $(name).log $(name).tex *.vrb *.out *.toc *.nav *.snm
+ -rm -rvf *.std* *.sh
diff --git a/certificate/fossee_internship_cerificate_template/bashful.sty b/certificate/fossee_internship_cerificate_template/bashful.sty
new file mode 100755
index 0000000..21b6f43
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/bashful.sty
@@ -0,0 +1,544 @@
+% Copyright (C) 2011,2012 by Yossi Gil yogi@cs.technion.ac.il
+% ---------------------------------------------------------------------------
+% This work may be distributed and/or modified under the conditions of the
+% LaTeX Project Public License (LPPL), either version 1.3 of this license or
+% (at your option) any later version. The latest version of this license is in
+% http://www.latex-project.org/lppl.txt and version 1.3 or later is part of all
+% distributions of LaTeX version 2005/12/01 or later.
+%
+% This work has the LPPL maintenance status `maintained'.
+%
+% The Current Maintainer of this work is Yossi Gil.
+%
+% This work consists of the files bashful.tex and bashful.sty and the derived
+% bashful.pdf
+
+\NeedsTeXFormat{LaTeX2e}%
+
+% Auxiliary identification information
+\newcommand\date@bashful{2012/03/08}%
+\newcommand\version@bashful{V 0.93}%
+\newcommand\author@bashful{Yossi Gil}%
+\newcommand\mail@bashful{yogi@cs.technion.ac.il}%
+\newcommand\signature@bashful{%
+ bashful \version@bashful{} by
+ \author@bashful{} \mail@bashful
+}%
+
+% Identify this package
+\ProvidesPackage{bashful}[\date@bashful{} \signature@bashful:
+ Write and execute a bash script within LaTeX, with, or
+ without displaying the script and/or its output.
+]
+\PackageInfo{bashful}{This is bashful, \signature@bashful}%
+
+\RequirePackage{xcolor}
+\RequirePackage{catchfile}
+\RequirePackage{xkeyval} % Use xkeyval for retrieving parameters
+\RequirePackage{textcomp} % For upquote
+
+% If true, all activities take place in a designated directory.
+\newif\if@hide@BL@\@hide@BL@false
+
+% \if@unique@BL@ is a Boolean flag, telling us whether unique names should be
+% generated for the auxiliary files (XX.sh, XX.stdout, XX.stderr and
+% XX.exitCode) in each invocation of the \bash command.
+\newif\if@unique@BL@\@unique@BL@false
+\def\unique@BL{\if@unique@BL@ @\the\inputlineno\fi}
+
+% This is the default name for a directory in which processing should
+% take place if \@hide@BL@true.
+\def\directory@BL{_00}
+
+% Use listing to display bash scripts.
+\RequirePackage{listings}%
+
+ % listings style for the script, can be redefined by client
+ \lstdefinestyle{bashfulScript}{
+ basicstyle=\ttfamily,
+ keywords={},
+ upquote=true,
+ showstringspaces=false}%
+ % listings style for the standard output file, can be redefined by client
+ \lstdefinestyle{bashfulStdout}{
+ basicstyle=\sl\ttfamily,
+ keywords={},
+ upquote=true,
+ showstringspaces=false
+ }%
+ % listings style for the standard error file, can be redefined by client
+ \lstdefinestyle{bashfulStderr}{
+ basicstyle=\sl\ttfamily\color{red},
+ keywords={},
+ upquote=true,
+ showstringspaces=false
+ }%
+
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Keys generating file names in alphabetical order:
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% dir: String = \directory@BL: Name of directory in which execution is going
+% to take place
+\define@cmdkey{bashful}[BL@]{dir}{\def\directory@BL{#1}}%
+
+% exitCodeFile: String = \BL@exitCodeFile: In which file should the exit code
+% be stored if it is not zero.
+\def\BL@exitCodeFile{\jobname\unique@BL.exitCode}%
+\define@cmdkey{bashful}[BL@]{exitCodeFile}{}%
+
+% scriptFile: String = \BL@scriptFile: In which file should the script be
+% saved?
+\def\BL@scriptFile{\jobname\unique@BL.sh}%
+\define@cmdkey{bashful}[BL@]{scriptFile}{}%
+
+% stderrFile: String = \BL@stderrFile: In which file should the standard
+% error stream be saved?
+\def\BL@stderrFile{\jobname\unique@BL.stderr}%
+\define@cmdkey{bashful}[BL@]{stderrFile}{}%
+
+% stdoutFile: String = \BL@stdoutFile: In which file should the standard
+% output stream be saved?
+\def\BL@stdoutFile{\jobname\unique@BL.stdout}%
+\define@cmdkey{bashful}[BL@]{stdoutFile}{}%
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% List configuration boolean keys
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% list: Boolean = \ifBL@script: Should we list the script we generate?
+\define@boolkey{bashful}[BL@]{script}[true]{}%
+
+% stdout: Boolean = \ifBL@stderr: Should we list the standard error?
+\define@boolkey{bashful}[BL@]{stderr}[true]{}%
+
+% stdout: Boolean = \ifBL@stdout: Should we list the standard output?
+\define@boolkey{bashful}[BL@]{stdout}[true]{}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Error checking Boolean keys.
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% stdout: Boolean = \ifBL@ignoreExitCode: Should we ignore the exit
+% code?
+\define@boolkey{bashful}[BL@]{ignoreExitCode}[true]{}
+
+% stdout: Boolean = \ifBL@ignoreStderr: Should we ignore the exit
+% code?
+\define@boolkey{bashful}[BL@]{ignoreStderr}[true]{}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Miscelaneous keys
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% environment: String = \BL@environment: Which environment should we wrap
+% the listings
+\def\BL@environment{none@BL}%
+\define@cmdkey{bashful}[BL@]{environment}{}%
+\newenvironment{none@BL}{}{} % Default, empty environment for wrapping
+ % the listings
+
+% prefix: String = \BL@prefix: What prefix should be printed before a listing.
+\def\BL@prefix{\@percentchar\space}%
+\define@cmdkey{bashful}[BL@]{prefix}{}%
+
+% shell: String = \BL@shell: Which shell should be used for execution?
+\def\BL@shell{bash}%
+\define@cmdkey{bashful}[BL@]{shell}{}%
+
+% verbose: Boolean = \ifBL@verbose: Log every step we do
+\define@boolkey{bashful}[BL@]{verbose}[true]{}%
+
+% The "unique" package flag that tells the package to generated unique names
+% for the auxiliary files. If true the generated files (XX.sh, XX.stdout,
+% XX.stderr and XX.exitCode) are given unique names in each invocation of the
+% \bash command. Unique names are generated by the pattern JOB@LINE.EXTENSION,
+% where JOB is the job's name, LINE is the number of the line in the input in
+% which the \bash command was invoked, and EXTENSION is one of "sh", "stdout",
+% "stderr" and "exitCode".
+\DeclareOptionX{unique} {\@unique@BL@true}
+\DeclareOptionX{hide} {\@hide@BL@true}
+\DeclareOptionX{dir} {\@hide@BL@true\def\directory@BL{#1}}
+\DeclareOptionX{verbose} {\BL@verbosetrue}
+
+\ExecuteOptionsX{}
+\ProcessOptionsX\relax
+
+% \bash: the main command we define. It chains to \bashI which chains to
+% \bashII, etc.
+\begingroup
+ %\where@BL
+ \catcode`\^^M\active%
+ \gdef\bash{%
+ \logBL{Beginning a group so that all cat code changes are local}%
+ \begingroup%
+ \logBL{Making \^\^M a true newline}%
+ \catcode`\^^M\active%
+ \def^^M{^^J}%
+ \logBL{Checking for optional arguments}%
+ \@ifnextchar[{\bashI}{\bashI[]}%
+ }%
+\endgroup
+
+% \bashI: Process the optional arguments and continue
+\def\bashI[#1]{\setKeys@BL{#1}\bashII}
+
+% \bashII: Set category codes of all characters to special, and proceed.
+\begingroup
+ \catcode`\^^M\active%
+ \gdef\bashII{%
+ \logBL{bashII: Making \^\^M a true new line}%
+ \catcode`\^^M\active%
+ \def^^M{^^J}%
+ \logBL{bashII: Making all characters other}%
+ \let\do\@makeother%
+ \dospecials%
+ \bashIII}%
+\endgroup
+
+% \bashIII: Consume all tokens until \END (but ignoring the preceding and
+% terminating newline), and proceed.
+\begingroup
+ \catcode`\@=0\relax
+ \catcode`\^^M\active
+ @catcode`@\=12@relax%
+ @gdef@bashIII^^M#1^^M%
+ \END{@bashIV{#1}@bashV{#1}@logBL{bashV: Done!}@endgroup}@endgroup
+
+% \bashIV: Process the tokens by storing them in a script file, and executing
+% this file,
+\newcommand\bashIV[1]{%
+ \logBL{BashIV: begin}%
+ \makeDirectory@BL
+ \generateScriptFile@BL{#1}\relax
+ \executeScriptFile@BL
+ \logBL{BashIV: done}%
+}%
+
+% \logBL: record a log message in verbose mode
+\newcommand\logBL[1]{\ifBL@verbose\typeout{L\the\inputlineno: #1}\fi}
+
+% A macro to create a new directory
+\def\makeDirectory@BL{%
+ \if@hide@BL@
+ \logBL{Making directory \directory@BL}%
+ \immediate\write18{mkdir -p \directory@BL}%
+ \else
+ \logBL{Using current directory}%
+ \fi
+}
+
+\newcommand\splice[1]{%
+ \bashIV{#1}%
+ \expandFileName@BL{\BL@stdoutFile}%
+ \CatchFileDef{\BL@file@contents}{\BL@stdoutFile}{\relax}%
+ \ignorespaces\BL@file@contents\unskip
+}
+
+% listing the script file if required, and presenting the standard output and
+% standard error files if required.
+\newcommand\bashV[1]{%
+ \logBL{Wrapping up after execution}%
+ \storeToFile@BL{\BL@prefix#1}{\BL@scriptFile}%
+ \expandFileName@BL\BL@scriptFile
+ \expandFileName@BL\BL@stdoutFile
+ \expandFileName@BL\BL@stderrFile
+ \logBL{Files are: \BL@scriptFile, \BL@stdoutFile, and \BL@stderrFile}%
+ \checkScriptErrors@BL
+ \listEverything@BL
+ \defineMacros@BL
+ \logBL{Wrap up done}}
+
+\def\expandFileName@BL#1{%
+ \logBL{Setting, if necessary, correct path of \noexpand#1 }%
+ \if@hide@BL@
+ \logBL{Prepending path (\directory@BL) to #1}%
+ \edef#1{\directory@BL/#1}%
+ \logBL{Obtained #1}%
+ \fi
+}
+
+\def\setKeys@BL#1{%
+ \logBL{Processing key=val pairs in options string [#1]}\relax
+ \setkeys{bashful}{#1}%
+}%
+
+% Store the list of tokens in the first argument into our script file
+\newcommand\generateScriptFile@BL[1]{%
+ \logBL{Generating script file \BL@scriptFile}
+ \storeToFile@BL{#1}{\BL@scriptFile}%
+}%
+
+\newwrite\writer@BL
+% Store the list of tokens in the first argument into the file given
+% in the second argument; prepend directory if necessary
+\newcommand\storeToFile@BL[2]{%
+ \logBL{ #2 :=^^J#1^^J}%
+ \if@hide@BL@
+ \logBL{File #2 will be created in \directory@BL}%
+ \storeToFileI@BL{#1}{\directory@BL/#2}
+ \else
+ \logBL{File #2 will be created in current directory}%
+ \storeToFileI@BL{#1}{#2}%
+ \fi
+ \logBL{Writing done!}%
+}%
+
+% Store the list of tokens in the first argument into the file given
+% in the second argument; the second argument could be qualified with
+% a directory name.
+\newcommand\storeToFileI@BL[2]{%
+ \logBL{Writing to file #2...}%
+ \immediate\openout\writer@BL#2%
+ \immediate\write\writer@BL{#1}%
+ \immediate\closeout\writer@BL
+}%
+
+% Execute the content of our script file.
+\newcommand\executeScriptFile@BL{%
+ \edef\command@BL{\BL@shell \space \BL@scriptFile}%
+ \if@hide@BL@
+ \logBL{Adding a "cd command"}%
+ \edef\command@BL{cd \directory@BL;\command@BL}
+ \fi%
+ \edef\command@BL{\command@BL \space >\BL@stdoutFile \space 2>\BL@stderrFile}%
+ \edef\command@BL{\command@BL \space || echo $? >\BL@exitCodeFile}%
+ \edef\command@BL{\BL@shell\space -c "\command@BL"}%
+ \logBL{Executing:^^J \command@BL}%
+ \immediate\write18{\command@BL}%
+}%
+
+\newread\reader@BL
+
+% Issue an error message if errors found during execution
+\newcommand\checkScriptErrors@BL{%
+ \logBL{Checking for script errors}%
+% \begingroup
+ \newif\ifErrorsFound@\ErrorsFound@false
+ \checkExitCodeFile@BL
+ \ifdefined\exitCode@BL
+ \logBL{Non zero exit code found (\exitCode@BL), and I was not instructed to
+ ignore it}
+ \ErrorsFound@true
+ \fi
+ \def\eoln{\par}
+ \def\firstErrorLine{\par}
+ \checkStderrFile@BL
+ \logBL{I will now print the contents of file \BL@stderrFile\space (if found)}
+ \ifx\firstErrorLine\eoln
+ \relax
+ \else
+ \logBL{Standard error was not empty, and I was not instructed to ignore it}
+ \message{Standard error not empty. Here is how
+ ^^Jfile \BL@stderrFile\space begins:
+ ^^J>>>>\firstErrorLine
+ ^^J>>>>\space
+ ^^Jbut, you really ought to examine this file yourself!}
+ \ErrorsFound@true
+ \fi
+ \ifErrorsFound@
+ \logBL{Issuing an error message since \BL@stderrFile\space was not empty}%
+ \errmessage{Your shell script failed...}%
+ \BL@verbosetrue
+ \logBL{Switching to verbose mode}%
+ \else
+ \logBL{File \BL@stderrFile\space was empty}%
+ \logBL{Proceeding as usual}%
+ \fi
+% \endgroup
+}%
+
+\newcommand\checkExitCodeFile@BL{%
+ \logBL{Considering \BL@exitCodeFile}%
+ \ifBL@ignoreExitCode
+ \logBL{Ignoring \BL@exitCodeFile, as per command flag}%
+ \else
+ \logBL{Opening \BL@exitCodeFile}%
+ \openin\reader@BL=\BL@exitCodeFile
+ \ifeof\reader@BL
+ \logBL{File \BL@exitCodeFile\space is missing, exit code was probably 0}
+ \closein\reader@BL
+ \else
+ \logBL{File \BL@exitCodeFile\space exists, let's get the exit code}%
+ \logBL{Reading first line of \BL@exitCodeFile}%
+ \catcode`\^^M=5
+ \read\reader@BL to \exitCode@BL
+ \closein\reader@BL
+ \fi
+ \fi
+}
+
+\newcommand\checkStderrFile@BL{%
+ \ifBL@stderr
+ \logBL{Will be listing \BL@stderrFile, so erroneous content is ignored}%
+ \else
+ \ifBL@ignoreStderr
+ \logBL{Ignoring \BL@stderrFile, as per command flag}%
+ \else
+ \checkStderrFileI@BL
+ \fi
+ \fi
+}
+
+\newcommand\checkStderrFileI@BL{%
+ \logBL{Opening \BL@stderrFile}%
+ \openin\reader@BL=\BL@stderrFile\relax
+ \ifeof\reader@BL
+ \logBL{Hmm... \BL@stderrFile\space does not exist (probably a package bug)}%
+ \logBL{Switching to verbose mode}%
+ \BL@verbosetrue
+ \else
+ \logBL{Reading first line of \BL@stderrFile}%
+ \catcode`\^^M=5
+ \read\reader@BL to \firstErrorLine
+ \ifeof\reader@BL
+ \ifx\firstErrorLine\eoln
+ \logBL{File \BL@stderrFile\space is empty}
+ \else
+ \logBL{File \BL@stderrFile\space has one line [\firstErrorLine]}%
+ \ErrorsFound@true
+ \fi
+ \else
+ \logBL{File \BL@stderrFile\space has two lines or more}%
+ \ErrorsFound@true
+ \fi
+ \fi
+ \closein\reader@BL
+}
+
+% List the contents of the script, stdout and stderr, as per the flags.
+\newcommand\listEverything@BL{%
+ \logBL{Checking whether any listings are required}%
+ \newif\if@listSomething@BL@
+ \ifBL@script\@listSomething@BL@true\fi
+ \ifBL@stdout\@listSomething@BL@true\fi
+ \ifBL@stderr\@listSomething@BL@true\fi
+ \if@listSomething@BL@
+ \beginWrappingEnvironment@BL
+ \listEverythingWithinEnvironment@BL
+ \endWrappingEnvironment@BL
+ \else
+ \logBL{Nothing has to be listed}%
+ \fi
+}
+
+% Auxiliary macro to list the contents of the script, stdout and stderr, as per
+% the flags.
+\newcommand\listEverythingWithinEnvironment@BL{%
+ \logBL{Laying out the correct \noexpand\lstinputlisting commands}%1
+ \ifBL@script\listScript@BL\BL@scriptFile\fi
+ \ifBL@stdout\listStdout@BL\BL@stdoutFile\fi
+ \ifBL@stderr\listStderr@BL\BL@stderrFile\fi
+}%
+
+\newcommand\listScript@BL[1]{%
+ \logBL{Listing script: #1}
+ \def\flags@BL{style=bashfulScript}
+ \logBL{Initial flags for listing #1 are \flags@BL}
+ \ifBL@stdout\edef\flags@BL{\flags@BL, belowskip=0pt}\fi
+ \ifBL@stderr\edef\flags@BL{\flags@BL, belowskip=0pt}\fi
+ \doList@BL#1\flags@BL
+}
+
+\newcommand\listStdout@BL[1]{%
+ \logBL{Listing stdout: #1}
+ \edef\flags@BL{style=bashfulStdout}
+ \logBL{Initial flags for listing stdout file are \flags@BL}
+ \ifBL@script\edef\flags@BL{\flags@BL, aboveskip=0pt}\fi
+ \ifBL@stderr\edef\flags@BL{\flags@BL, belowskip=0pt}\fi
+ \doList@BL#1\flags@BL
+}%
+
+\newcommand\listStderr@BL[1]{%
+ \logBL{Listing stderr: #1}%
+ \def\flags@BL{style=bashfulStderr}%
+ \logBL{Initial flags for listing stderr file are \flags@BL}
+ \ifBL@script\edef\flags@BL{\flags@BL, aboveskip=0pt}\fi
+ \ifBL@stdout\edef\flags@BL{\flags@BL, aboveskip=0pt}\fi
+ \doList@BL#1\flags@BL
+}%
+
+\newcommand\doList@BL[2]{%
+ \logBL{Flags for listing #1 are #2}%
+ \expandafter\lstset\expandafter{#2}%
+ \lstinputlisting{#1}%
+ }%
+
+\def\beginWrappingEnvironment@BL{%
+ \logBL{Beginning environment \BL@environment}%
+ \expandafter\csname\BL@environment\endcsname
+ \forceLTR@BL
+ \fixPolyglossiaBug@BL
+}%
+
+\def\endWrappingEnvironment@BL{%
+ \expandafter\csname end\BL@environment\endcsname
+}%
+
+% Define the \bashStdout and \bashStderr macro.
+\newcommand\defineMacros@BL{%
+ \logBL{Defining macro for the contents of the standard output file}%
+ \immediate\openin\reader@BL=\BL@stdoutFile
+ \logBL{Opened file \BL@stdoutFile}%
+ \begingroup
+ \endlinechar=-1%
+ \ifeof\reader@BL
+ \logBL{File \BL@stdoutFile was empty}%
+ \global\let\bashStdout\relax
+ \else
+ \logBL{Reading contents of \BL@stdoutFile}%
+ \immediate\read\reader@BL to \BL@temp
+ \global\let\bashStdout\BL@temp
+ \fi
+ \typeout{after EOF}%
+ \logBL{bashStdout :=^^J\bashStdout^^J}%
+ \endgroup
+ \logBL{Closing file \BL@stdoutFile}%
+ \immediate\closein\reader@BL
+ \logBL{Defining macro for the contents of the standard error file}%
+ \immediate\openin\reader@BL=\BL@stderrFile
+ \logBL{Opened file \BL@stderrFile}%
+ \begingroup
+ \endlinechar=-1%
+ \ifeof\reader@BL
+ \logBL{File \BL@stdoutFile was empty}%
+ \global\let\bashStdout\relax
+ \else
+ \logBL{Reading contents of \BL@stderrFile}%
+ \immediate\read\reader@BL to \BL@temp
+ \global\let\bashStderr\BL@temp
+ \fi
+ \logBL{bashStderr :=^^J\bashStderr^^J}%
+ \endgroup
+ \logBL{Closing file \BL@stderrFile}%
+ \immediate\closein\reader@BL
+}
+
+\newcommand\fixPolyglossiaBug@BL{%
+ \logBL{Trying to fix a Polyglossia package bug}%
+ \ifdefined\ttfamilylatin
+ \logBL{Replacing \noexpand\ttfamily with \noexpand\ttfamilylatin}%
+ \let\ttfamily=\ttfamilylatin
+ \logBL{Replacing \noexpand\rmfamily with \noexpand\rmfamilylatin}%
+ \let\rmfamily=\rmfamilylatin
+ \logBL{Replacing \noexpand\sffamily with \noexpand\sffamilylatin}%
+ \let\sffamily=\sffamilylatin
+ \logBL{Replacing \noexpand\normalfont with \noexpand\normalfontlatin}%
+ \let\normalfont=\normalfontlatin
+ \else
+ \logBL{Polyglossia package probably not loaded}%
+ \relax
+ \fi
+}%
+
+\newcommand\forceLTR@BL{%
+ \logBL{Making sure we are not in right-to-left mode}%
+ \ifdefined\setLTR
+ \logBL{Command \noexpand\setLTR is defined, invoking it}%
+ \setLTR
+ \else
+ \logBL{Command \noexpand\setLTR is not defined, we are probably LTR}%
+ \relax
+ \fi
+}%
diff --git a/certificate/fossee_internship_cerificate_template/cer_bg_2.png b/certificate/fossee_internship_cerificate_template/cer_bg_2.png
new file mode 100644
index 0000000..3d40f70
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/cer_bg_2.png
Binary files differ
diff --git a/certificate/fossee_internship_cerificate_template/fossee-logo.png b/certificate/fossee_internship_cerificate_template/fossee-logo.png
new file mode 100755
index 0000000..0f57874
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/fossee-logo.png
Binary files differ
diff --git a/certificate/fossee_internship_cerificate_template/fossee-logo1.png b/certificate/fossee_internship_cerificate_template/fossee-logo1.png
new file mode 100755
index 0000000..6feda2d
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/fossee-logo1.png
Binary files differ
diff --git a/certificate/fossee_internship_cerificate_template/fossee_logo.png b/certificate/fossee_internship_cerificate_template/fossee_logo.png
new file mode 100755
index 0000000..0f57874
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/fossee_logo.png
Binary files differ
diff --git a/certificate/fossee_internship_cerificate_template/iitb-logo.png b/certificate/fossee_internship_cerificate_template/iitb-logo.png
new file mode 100755
index 0000000..2915da3
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/iitb-logo.png
Binary files differ
diff --git a/certificate/fossee_internship_cerificate_template/kannan-moudgalya-sign.png b/certificate/fossee_internship_cerificate_template/kannan-moudgalya-sign.png
new file mode 100755
index 0000000..0f57874
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/kannan-moudgalya-sign.png
Binary files differ
diff --git a/certificate/fossee_internship_cerificate_template/missfont.log b/certificate/fossee_internship_cerificate_template/missfont.log
new file mode 100755
index 0000000..e69de29
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/missfont.log
diff --git a/certificate/fossee_internship_cerificate_template/niceframe.sty b/certificate/fossee_internship_cerificate_template/niceframe.sty
new file mode 100755
index 0000000..20afd01
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/niceframe.sty
@@ -0,0 +1,140 @@
+%%
+%% This is file `niceframe.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% niceframe.dtx (with options: `package')
+%%
+%% This file is distributed in the hope that it will be useful,
+%% but WITHOUT ANY WARRANTY; without even the implied warranty of
+%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+%%
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
+%%
+%% This work has the LPPL maintenance status `maintained'.
+%%
+%% The Current Maintainer of this work is Marcus Ohlhaut.
+%%
+%% This work consists of the files niceframe.dtx and niceframe.ins
+%% and the derived file niceframe.sty.
+%%
+%% Copyright (C) 2009 Marcus Ohlhaut (marcus@ohlhaut.de).
+%% All rights reserved.
+%%
+%% \CharacterTable
+%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
+%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
+%% Digits \0\1\2\3\4\5\6\7\8\9
+%% Exclamation \! Double quote \" Hash (number) \#
+%% Dollar \$ Percent \% Ampersand \&
+%% Acute accent \' Left paren \( Right paren \)
+%% Asterisk \* Plus \+ Comma \,
+%% Minus \- Point \. Solidus \/
+%% Colon \: Semicolon \; Less than \<
+%% Equals \= Greater than \> Question mark \?
+%% Commercial at \@ Left bracket \[ Backslash \\
+%% Right bracket \] Circumflex \^ Underscore \_
+%% Grave accent \` Left brace \{ Vertical bar \|
+%% Right brace \} Tilde \~}
+%%
+\def\fileversion{1.1c}
+\def\filedate{2009/31/08}
+\NeedsTeXFormat{LaTeX2e}[1994/06/01]
+\ProvidesPackage{niceframe}[\filedate\space v\fileversion\space niceframe package (MO)]
+\typeout{Package: niceframe v\fileversion\space <\filedate> (Marcus Ohlhaut)}
+\RequirePackage{calc}
+\font\ding dingbat scaled 1200
+\newlength{\nicefr@mechar}
+\settowidth{\nicefr@mechar}{\ding\char'141}
+\newlength{\nicefr@mewidth}
+\setlength{\nicefr@mewidth}{\hsize}
+\newlength{\nicefr@meheight}
+\setlength{\nicefr@meheight}{\vsize}
+\newlength{\@ldhsize}
+\setlength{\@ldhsize}{\hsize}
+\newcommand{\upd@ublerulefill}{\xleaders\hbox to 10pt
+ {\hss\ding\char'142 \hss}\hfill}
+\newcommand{\dnd@ublerulefill}{\xleaders\hbox to 10pt
+ {\hss\ding\char'147 \hss}\hfill}
+\newcommand{\ltd@ublerulefill}{\xleaders\vbox to 10pt
+ {\vss\hbox{\ding\char'144}\vss}\vfill}
+\newcommand{\rtd@ublerulefill}{\xleaders\vbox to 10pt
+ {\vss\hbox{\ding\char'145}\vss}\vfill}
+\newcommand{\niceframe}[2][\textwidth]{{
+ \setlength{\hsize}{#1 - 2\nicefr@mechar}
+ \setbox0=\vbox{#2}
+ \setlength{\nicefr@meheight}{\ht0 + \dp0}
+ \setlength{\nicefr@mewidth}{\wd0 + 2\nicefr@mechar}
+ \vbox{%
+ \hbox to\nicefr@mewidth{\ding\char'141\upd@ublerulefill\char'143}
+ \hbox to\nicefr@mewidth{\vbox to\nicefr@meheight{\ltd@ublerulefill}
+ \hss\raise\dp0\box0\hss
+ \vbox to\nicefr@meheight{\rtd@ublerulefill}}
+ \hbox to\nicefr@mewidth{\ding\char'146\dnd@ublerulefill\char'150}
+ }
+}}
+\newcommand{\curlyframe}[2][\textwidth]{{
+ \setlength{\hsize}{#1 - 2\nicefr@mechar}
+ \setbox0=\vbox{#2}
+ \setlength{\nicefr@meheight}{\ht0 + \dp0}
+ \setlength{\nicefr@mewidth}{\wd0 + 2\nicefr@mechar}
+ \vbox{%
+ \hbox to\nicefr@mewidth{\ding\char'105\hfill\char'106}
+ \vskip-\baselineskip
+ \hbox to\nicefr@mewidth{\hss\raise\dp0\box0\hss}
+ \vskip-\baselineskip
+ \hbox to\nicefr@mewidth{\ding\char'110\hfill\char'107}
+ }
+}}
+\newcommand{\artdecoframe}[2][\textwidth]{{
+ \setlength{\hsize}{#1 - 2\nicefr@mechar}
+ \setbox0=\vbox{#2}
+ \setlength{\nicefr@meheight}{\ht0 + \dp0}
+ \setlength{\nicefr@mewidth}{\wd0 + 2\nicefr@mechar}
+ \vbox{%
+ \hbox to\nicefr@mewidth{\ding\char'115\hfill\char'114}
+ \hbox to\nicefr@mewidth{\hss\raise\dp0\box0\hss}
+ \hbox to\nicefr@mewidth{\ding\char'112\hfill\char'113}
+ }
+}}
+\newcounter{times}
+\newlength{\fr@mecharTT}
+\newlength{\fr@mecharLL}
+\newlength{\fr@mewidth}
+\newlength{\fr@meheight}
+\newcommand{\generalframe}[9]{{
+ \settowidth{\fr@mecharTT}{#2}
+ \settoheight{\fr@mecharLL}{#4}
+ \setcounter{times}{1 * \ratio{\hsize}{\fr@mecharTT}}
+ \setlength{\fr@mewidth}{\fr@mecharTT * \value{times}}
+ \setlength{\hsize}{\fr@mewidth - 2\fr@mecharTT - 2\fboxsep}
+ \setbox0=\vbox{#9}
+ \setlength{\fr@meheight}{\ht0 + \dp0 + 2\fboxsep}
+ \setcounter{times}{1 * \ratio{\fr@meheight}{\fr@mecharLL}}
+ \setcounter{times}{\value{times} + 1}
+ \setlength{\fr@meheight}{\fr@mecharLL * \value{times}}
+ \newcommand{\up@fill}{\leaders\hbox{#2}\hfill}
+ \newcommand{\lt@fill}{\leaders\vbox{\hbox{#4}}\vfill}
+ \newcommand{\rt@fill}{\leaders\vbox{\hbox{#5}}\vfill}
+ \newcommand{\dn@fill}{\leaders\hbox{#7}\hfill}
+ \vbox{%
+ \hbox to\fr@mewidth{#1\up@fill#3}\nointerlineskip
+ \hbox to\fr@mewidth{\vbox to\fr@meheight{\lt@fill}%
+ \hfill%
+ \vbox to\fr@meheight{\vfill\box0\vfill}%
+ \hfill%
+ \vbox to\fr@meheight{\rt@fill}%
+ }\nointerlineskip
+ \hbox to\fr@mewidth{#6\dn@fill#8}\nointerlineskip
+ }
+}}
+\endinput
+%%
+%% End of file `niceframe.sty'.
diff --git a/certificate/fossee_internship_cerificate_template/template_FIC2016Acertificate b/certificate/fossee_internship_cerificate_template/template_FIC2016Acertificate
new file mode 100755
index 0000000..c040b96
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/template_FIC2016Acertificate
@@ -0,0 +1,21 @@
+* certificate template
+
+** Usage
+ - To generate a PDF file type,
+ #+BEGIN_SRC sh
+ make $command
+ #+END_SRC sh
+
+ - To clean the project
+ #+BEGIN_SRC sh
+ make clean
+ #+END_SRC sh
+
+** License
+ The tex file and all the images within this project are entirely
+ PRIVATE. It's usage outside the `Fossee Project` is an legal
+ offense and will be subject to suitable punishment by Indian law.
+
+
+** Website
+ [[http://fossee.in]]
diff --git a/certificate/fossee_internship_cerificate_template/template_FIC2016Acertificate~ b/certificate/fossee_internship_cerificate_template/template_FIC2016Acertificate~
new file mode 100755
index 0000000..8ec9c57
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/template_FIC2016Acertificate~
@@ -0,0 +1,91 @@
+%% Internship Certificate template
+\documentclass[landscape]{article}
+\usepackage{wallpaper}
+\usepackage{niceframe}
+\usepackage{xcolor}
+\usepackage{ulem}
+\usepackage{graphicx}
+\usepackage{geometry}
+\usepackage{chancery}
+\usepackage[T1]{fontenc}
+%% package to execute bash commands
+%% \usepackage{bashful}
+
+%% generate QR code
+\usepackage{pst-barcode}
+\usepackage{auto-pst-pdf}
+
+\geometry{tmargin=.2cm,bmargin=.2cm,
+ lmargin=.2cm, rmargin=.2cm}
+\usepackage{multicol}
+\setlength{\columnseprule}{1pt}
+\columnwidth=0.6\textwidth
+
+\begin{document}
+
+%% create MD5 hash of tex file and insert it in PDF
+%% \bash
+%% md5sum asd_cert.tex | cut -d " " -f 1
+%% \END
+
+%\TileWallPaper{4cm}{2cm}{aakash-logo.png}
+\TileWallPaper{28cm}{30cm}{cer_bg_2.png}
+
+\centering
+\scalebox{3.1}{\color{green!30!black!60}
+\begin{minipage}{.33\textwidth}
+\font\border=umrandb
+\generalframe
+{\border \char113} % up left
+{\border \char109} % up
+{\border \char112} % up right
+{\border \char108} % left
+{\border \char110} % right
+{\border \char114} % lower left
+{\border \char111} % bottom
+{\border \char115} % lower right
+{
+
+\begin{centering}
+%% logo - top
+%%\vspace{2.0mm}
+%%\vspace{.5mm}
+%\textcolor{red!10!black!90}
+%{\tiny Drupal Camp Mumbai 2015}\\
+\textcolor{red!30!black!90}
+{\textsc{Certificate of Internship}}\\
+\end{centering}
+\vspace{0.3cm}
+%%\medskip
+{\tiny \color{black!90} This is to certify that {\color{blue!40!black}{$name,}} {\color{blue!40!black}$student_edu_detail} from {\color{blue!40!black}$student_institute_detail,} has undertaken and successfully completed his project work entitled: {\color{blue!40!black}$paper} under the supervision of {\color{blue!40!black}$superviser_name_detail,} during {\color{blue!40!black}$internship_project_duration}.
+ }
+
+\vspace{0.6cm}
+{\color{blue!40!black}
+\hspace{122pt}
+\scalebox{0.6}{
+ \begin{tabular}{c c c}
+ \hspace{122pt}&\small{\includegraphics[height=0.6cm]{kannan-moudgalya-sign.png}}
+ &\\
+ \hspace{122pt}&\small{~~~~~~~~Prof. Kannan Moudgalya~~~~~~~~}
+ &\\
+ \hspace{122pt}&\small{Project In-charge} &\\
+ \end{tabular}
+}
+}
+\\
+\vspace{1.9mm}
+\begin{centering}
+
+\includegraphics[height=0.6cm]{fossee_logo.png}\hspace{22pt}
+\includegraphics[height=0.7cm]{iitb-logo.png}\hspace{22pt}
+\begin{pspicture}(0.1cm,0.1cm) \psbarcode{$qr_code}{eclevel=L width=0.25 height=0.25}{qrcode}\end{pspicture}\\
+\vspace{0mm}
+\hspace{100pt}\tiny{\texttt{$serial_key}}\\
+\includegraphics[height=0.095cm]{text.png}
+\end{centering}
+}
+
+\end{minipage}
+}
+\end{document}
diff --git a/certificate/fossee_internship_cerificate_template/text.png b/certificate/fossee_internship_cerificate_template/text.png
new file mode 100755
index 0000000..2f181d6
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/text.png
Binary files differ
diff --git a/certificate/fossee_internship_cerificate_template/wallpaper.sty b/certificate/fossee_internship_cerificate_template/wallpaper.sty
new file mode 100755
index 0000000..c64e8c6
--- /dev/null
+++ b/certificate/fossee_internship_cerificate_template/wallpaper.sty
@@ -0,0 +1,250 @@
+%%
+%% This is file `wallpaper.sty' v 1.10
+%%
+%% Author Michael H.F. Wilkinson
+%% April 21, 2006
+%%
+%% Create background, either centered, tiled, or in any corner
+%% relies heavily on eso-pic.sty, corrects for changes in \hoffset
+%% by classes such as sciposter.cls
+%% Problems, bugs and comments to
+%% michael@cs.rug.nl
+%% version 1.10, 2006/04/21:
+%% - Commands added for corner wallpapers
+%%
+%% version 1.01, 2005/01/18:
+%% - \providecommand{\LenToUnit} included to be compatible
+%% with earlier versions of eso-pic.sty
+%%
+%% version 1.00, 2004/12/22:
+%% - first release
+%%
+%%
+\ProvidesPackage{wallpaper}[2005/01/18, v1.01 easy wallpaper formatting (MHFW)]
+\NeedsTeXFormat{LaTeX2e}[1995/06/01]
+
+\RequirePackage{ifthen}
+\RequirePackage{calc}
+\RequirePackage{eso-pic}
+\RequirePackage{graphicx}
+
+\providecommand{\LenToUnit}[1]{#1\@gobble}
+
+
+\newlength{\wpXoffset}
+\setlength{\wpXoffset}{-\hoffset}
+\newlength{\wpYoffset}
+\setlength{\wpYoffset}{0pt}
+\newlength{\tileXoffset}
+\newlength{\tileYoffset}
+\newlength{\tilewidth}
+\newlength{\tileheight}
+\newlength{\tileX}
+\newlength{\tileY}
+
+\newcommand{\LLCornerWallPaper}[2]{%
+\AddToShipoutPicture{%
+ \AtPageLowerLeft{%
+ \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ }
+ }
+}
+
+\newcommand{\ThisLLCornerWallPaper}[2]{%
+\AddToShipoutPicture*{%
+ \AtPageLowerLeft{%
+ \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ }
+ }
+}
+
+\newcommand{\ULCornerWallPaper}[2]{%
+ \AddToShipoutPicture{%
+ \AtPageLowerLeft{%
+ \parbox[b][\paperheight]{#1\paperwidth}{%
+ \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ \vfill%
+ }
+ }
+ }
+}
+
+\newcommand{\ThisULCornerWallPaper}[2]{%
+ \AddToShipoutPicture*{%
+ \AtPageLowerLeft{%
+ \parbox[b][\paperheight]{#1\paperwidth}{%
+ \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ \vfill%
+ }
+ }
+ }
+}
+
+\newcommand{\LRCornerWallPaper}[2]{%
+ \AddToShipoutPicture{%
+ \AtPageLowerLeft{%
+ \parbox[b]{\paperwidth}{%
+ \hfill \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ }
+ }
+ }
+}
+
+\newcommand{\ThisLRCornerWallPaper}[2]{%
+ \AddToShipoutPicture*{%
+ \AtPageLowerLeft{%
+ \parbox[b]{\paperwidth}{%
+ \hfill \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ }
+ }
+ }
+}
+
+\newcommand{\URCornerWallPaper}[2]{%
+ \AddToShipoutPicture{%
+ \AtPageLowerLeft{%
+ \parbox[b][\paperheight]{\paperwidth}{%
+ \hfill \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ \vfill%
+ }
+ }
+ }
+}
+\newcommand{\ThisURCornerWallPaper}[2]{%
+ \AddToShipoutPicture*{%
+ \AtPageLowerLeft{%
+ \parbox[b][\paperheight]{\paperwidth}{%
+ \hfill \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ \vfill%
+ }
+ }
+ }
+}
+
+\newcommand{\CenterWallPaper}[2]{%
+\AddToShipoutPicture{\put(\LenToUnit{\wpXoffset},\LenToUnit{\wpYoffset}){%
+ \parbox[b][\paperheight]{\paperwidth}{%
+ \vfill
+ \centering
+ \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ \vfill
+ }}
+ }
+}
+
+\newcommand{\ThisCenterWallPaper}[2]{%
+\AddToShipoutPicture*{\put(\LenToUnit{\wpXoffset},\LenToUnit{\wpYoffset}){%
+ \parbox[b][\paperheight]{\paperwidth}{%
+ \vfill
+ \centering
+ \includegraphics[width=#1\paperwidth,height=#1\paperheight,%
+ keepaspectratio]{#2}%
+ \vfill
+ }}}
+}
+
+
+
+\newcommand{\TileSquareWallPaper}[2]{%
+\AddToShipoutPicture{%
+ \begingroup
+ \setlength{\tileYoffset}{\wpYoffset}
+ \setlength{\tilewidth}{\paperwidth/#1}%
+ \setlength{\tileheight}{\tilewidth}%
+ \setlength{\tileY}{0pt}%
+ \whiledo{\lengthtest{\tileY < \paperheight}}{%
+ \setlength{\tileX}{0pt}%
+ \setlength{\tileXoffset}{\wpXoffset}%
+ \whiledo{\lengthtest{\tileX < \paperwidth}}{%
+ \put(\LenToUnit{\tileXoffset},\LenToUnit{\tileYoffset}){%
+ \includegraphics[height=\tileheight,width=\tilewidth]{#2}}%
+ \addtolength{\tileX}{\tilewidth}
+ \addtolength{\tileXoffset}{\tilewidth}
+ }%
+ \addtolength{\tileY}{\tileheight}
+ \addtolength{\tileYoffset}{\tileheight}
+ }%
+ \endgroup
+}%
+}
+
+\newcommand{\ThisTileSquareWallPaper}[2]{%
+\AddToShipoutPicture*{%
+ \begingroup
+ \setlength{\tileYoffset}{\wpYoffset}
+ \setlength{\tilewidth}{\paperwidth/#1}%
+ \setlength{\tileheight}{\tilewidth}%
+ \setlength{\tileY}{0pt}%
+ \whiledo{\lengthtest{\tileY < \paperheight}}{%
+ \setlength{\tileX}{0pt}%
+ \setlength{\tileXoffset}{\wpXoffset}%
+ \whiledo{\lengthtest{\tileX < \paperwidth}}{%
+ \put(\LenToUnit{\tileXoffset},\LenToUnit{\tileYoffset}){%
+ \includegraphics[height=\tileheight,width=\tilewidth]{#2}}%
+ \addtolength{\tileX}{\tilewidth}
+ \addtolength{\tileXoffset}{\tilewidth}
+ }%
+ \addtolength{\tileY}{\tileheight}
+ \addtolength{\tileYoffset}{\tileheight}
+ }%
+ \endgroup
+}%
+}
+
+
+\newcommand{\TileWallPaper}[3]{%
+\AddToShipoutPicture{%
+ \begingroup
+ \setlength{\tileYoffset}{\wpYoffset}
+ \setlength{\tilewidth}{#1}%
+ \setlength{\tileheight}{#2}%
+ \setlength{\tileY}{0pt}%
+ \whiledo{\lengthtest{\tileY < \paperheight}}{%
+ \setlength{\tileX}{0pt}%
+ \setlength{\tileXoffset}{\wpXoffset}%
+ \whiledo{\lengthtest{\tileX < \paperwidth}}{%
+ \put(\LenToUnit{\tileXoffset},\LenToUnit{\tileYoffset}){%
+ \includegraphics[height=\tileheight,width=\tilewidth]{#3}}%
+ \addtolength{\tileX}{\tilewidth}
+ \addtolength{\tileXoffset}{\tilewidth}
+ }%
+ \addtolength{\tileY}{\tileheight}
+ \addtolength{\tileYoffset}{\tileheight}
+ }%
+ \endgroup
+}%
+}
+
+\newcommand{\ThisTileWallPaper}[3]{%
+\AddToShipoutPicture*{%
+ \begingroup
+ \setlength{\tileYoffset}{\wpYoffset}
+ \setlength{\tilewidth}{#1}%
+ \setlength{\tileheight}{#2}%
+ \setlength{\tileY}{0pt}%
+ \whiledo{\lengthtest{\tileY < \paperheight}}{%
+ \setlength{\tileX}{0pt}%
+ \setlength{\tileXoffset}{\wpXoffset}%
+ \whiledo{\lengthtest{\tileX < \paperwidth}}{%
+ \put(\LenToUnit{\tileXoffset},\LenToUnit{\tileYoffset}){%
+ \includegraphics[height=\tileheight,width=\tilewidth]{#3}}%
+ \addtolength{\tileX}{\tilewidth}
+ \addtolength{\tileXoffset}{\tilewidth}
+ }%
+ \addtolength{\tileY}{\tileheight}
+ \addtolength{\tileYoffset}{\tileheight}
+ }%
+ \endgroup
+}%
+}
+
+\newcommand{\ClearWallPaper}{\ClearShipoutPicture} \ No newline at end of file
diff --git a/certificate/templates/fossee_internship_cerificate_download.html b/certificate/templates/fossee_internship_cerificate_download.html
new file mode 100644
index 0000000..62e6f9a
--- /dev/null
+++ b/certificate/templates/fossee_internship_cerificate_download.html
@@ -0,0 +1,67 @@
+{% extends 'base.html' %}
+{% block header%}
+ <h1> Fossee Internship Certificate</h1>
+{% endblock %}
+{% block content %}
+ <div class="modal fade" id="invalidModal" tabindex="-1" role="dialog" aria-labelledby="invalidModalLabel" aria-hidden="true">
+ <div class="modal-dialog">
+ <div class="modal-content">
+ <div class="modal-header">
+ <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <h4 class="modal-title" id="invalidModalLabel">Invalid Category</h4>
+ </div>
+ <div class="modal-body">
+ The requested certificate is unavailable for your email address. Please select the appropriate category and retry.
+ </div>
+ </div>
+ </div>
+ </div>
+ <form class="col-lg-12" action="{% url 'certificate:fossee_internship_cerificate_download' %}" method="post">
+ {% csrf_token %}
+ {{ message }}
+ <hr>
+ &nbsp;&nbsp;<input type="hidden" name="type" id="A" value="A" checked="True">
+ <hr>
+ <div id ="paper">
+ {% if user_project %}
+ <span><h3>Papers presented</h3><span>
+ <div class="radio" style="padding-left:350px;text-align:left">
+ {% for user in user_project %}
+ <input type="hidden" name="paper" value="{{ user.project_title }}">{{ user.project_title }}<br>
+ {% endfor %}
+ </div>
+ {% endif %}
+ <input type="hidden" name="paper" value="{{ user.project_title }}">{{ user.project_title }}<br>
+ </div>
+ <div class="input-group" style="width:340px;text-align:center;margin:0 auto;">
+ <input style="width:450;" class="form-control input-lg" placeholder="Enter the email address you used for registration" type="text" id="email" name=email>
+ <span class="input-group-btn"><button class="btn btn-lg btn-primary" type="submit">Download Certificate</button></span>
+ </div>
+ </form>
+ <center><h4>Problem in downloading the certificate? Write to us at <a href="mailto:certificates@fossee.in">certificates[at]fossee[dot]in</a></h4>
+{% endblock %}
+
+{% block javascript %}
+<script>
+ $(document).ready(function(){
+ value = "{{ v }}"
+ email = ""
+ error = "{{ error }}"
+ if(error == "True"){
+ $("#invalidModal").modal();
+ }
+ if(value == "paper"){
+ $('#A').prop('checked', true)
+ email = "{{ user_project.0.email }}";
+ }
+ $('#email').val(email);
+ notreg = "{{ notregistered }}";
+ if(notreg == "1"){
+ $("#invalidModal").modal();
+ }
+ $("[name=type]").change(function(){
+ $("#paper").remove();
+ });
+ });
+</script>
+{% endblock %}
diff --git a/certificate/templates/index.html b/certificate/templates/index.html
index 363ae40..be98efb 100644..100755
--- a/certificate/templates/index.html
+++ b/certificate/templates/index.html
@@ -8,6 +8,7 @@
<p>Below links will take you to a feedback form.<br> Please fill the feedback form and download your <b>e-certificate</b>.</h5></p>
<ul class="nav nav-list">
<li><a href="{% url 'certificate:openfoam_symposium_feedback_2016' %}" >OpenFOAM Symposium 2016</a></li>
+ <li><a href="{% url 'certificate:fossee_internship_cerificate_download' %}" >Internship Certificate</a></li>
<li><a href="{% url 'certificate:scipy_feedback_2015' %}" >SciPy India Conference 2015</a></li>
<li><a href="{% url 'certificate:esim_google_feedback' %}" >eSim Faculty Meet 2015</a></li>
<li><a href="{% url 'certificate:arduino_google_feedback' %}" >Scilab Arduino Workshop 2015</a></li>
diff --git a/certificate/templates/verify.html b/certificate/templates/verify.html
index f70a20d..f83cd9c 100644..100755
--- a/certificate/templates/verify.html
+++ b/certificate/templates/verify.html
@@ -7,7 +7,11 @@
{% if serial_key %}
<div>
<table class="table table-bordered" align="center" style="width:50%">
- <caption>Participation Details</caption>
+ {% if intern_ship %}
+ <caption>Internship Details</caption>
+ {% else %}
+ <caption>Participation Details</caption>
+ {% endif %}
<tbody>
{% for key, value in detail.items %}
<tr>
diff --git a/certificate/urls.py b/certificate/urls.py
index 2174558..0da95aa 100644..100755
--- a/certificate/urls.py
+++ b/certificate/urls.py
@@ -29,4 +29,10 @@ urlpatterns = patterns('certificate.views',
url(r'^scipy_download_2015/$', 'scipy_download_2015', name='scipy_download_2015'),
url(r'^openfoam_symposium_download_2016/$', 'openfoam_symposium_download_2016', name='openfoam_symposium_download_2016'),
url(r'^openfoam_symposium_feedback_2016/$', 'openfoam_symposium_feedback_2016', name='openfoam_symposium_feedback_2016'),
+
+ #url(r'^internship_certificate_download/$', 'internship_certificate_download', name='internship_certificate_download'),
+ url(r'^fossee_internship_cerificate_download/$', 'fossee_internship_cerificate_download', name='fossee_internship_cerificate_download'),
+
+
+
)
diff --git a/certificate/views.py b/certificate/views.py
index 987e6cf..0814a5d 100644..100755
--- a/certificate/views.py
+++ b/certificate/views.py
@@ -2,7 +2,7 @@ from django.shortcuts import render
from django.http import HttpResponse
from django.shortcuts import render_to_response, redirect
from django.template import RequestContext
-from certificate.models import Scilab_participant, Certificate, Event, Scilab_speaker, Scilab_workshop, Question, Answer, FeedBack, Scipy_participant, Scipy_speaker, Drupal_camp, Tbc_freeeda, Dwsim_participant, Scilab_arduino, Esim_faculty, Scipy_participant_2015, Scipy_speaker_2015
+from certificate.models import Internship_participant, Scilab_participant, Certificate, Event, Scilab_speaker, Scilab_workshop, Question, Answer, FeedBack, Scipy_participant, Scipy_speaker, Drupal_camp, Tbc_freeeda, Dwsim_participant, Scilab_arduino, Esim_faculty, Scipy_participant_2015, Scipy_speaker_2015, OpenFOAM_Symposium_participant_2016, OpenFOAM_Symposium_speaker_2016
import subprocess
import os
from string import Template
@@ -14,6 +14,9 @@ from collections import OrderedDict
def index(request):
return render_to_response('index.html')
+#def internship_certificate_download(request):
+# return render_to_response('internship-certificate-download.html')
+
def download(request):
context = {}
err = ""
@@ -109,6 +112,7 @@ def verification(serial, _type):
certificate.verified += 1
certificate.save()
purpose, year, type = _get_detail(serial_no)
+ print purpose, year, type
if type == 'P':
if purpose == 'DWSIM Workshop':
dwsim_user = Dwsim_participant.objects.get(email=certificate.email)
@@ -125,6 +129,9 @@ def verification(serial, _type):
elif purpose == 'SciPy India':
detail = OrderedDict([('Name', name), ('Event', purpose),
('Days', '14 - 16 December'), ('Year', year)])
+ elif purpose == 'OpenFOAM Symposium':
+ detail = OrderedDict([('Name', name), ('Event', purpose),
+ ('Days', '27 February'), ('Year', year)])
elif purpose == 'DrupalCamp Mumbai':
drupal_user = Drupal_camp.objects.get(email=certificate.email)
DAY = drupal_user.attendance
@@ -148,10 +155,21 @@ def verification(serial, _type):
(name, purpose, year, paper)
if purpose == 'SciPy India':
detail = OrderedDict([('Name', name), ('Event', purpose), ('paper', paper), ('Days', '14 - 16 December'), ('Year', year)])
+ elif purpose == 'OpenFOAM Symposium':
+ detail = OrderedDict([('Name', name), ('Event', purpose), ('paper', paper), ('Days', '27 February'), ('Year', year)])
+ elif purpose == 'FOSSEE Internship':
+ intership_detail = Internship_participant.objects.get(email=certificate.email)
+ user_project_title = Internship_participant.objects.filter(email=certificate.email)
+ context['intern_ship'] = True
+ detail = OrderedDict([('Name', name), ('Internship Completed', 'Yes'),
+ ('Project', intership_detail.project_title), ('Internship Duration', intership_detail.internship_project_duration), ('Superviser Name', intership_detail.superviser_name_detail)])
+ else:
+ detail = '{0} had attended {1} {2}'.format(name, purpose, year)
elif type == 'W':
detail = '{0} had attended workshop on {3} in the {1} {2}'.format\
(name, purpose, year, workshop)
context['serial_key'] = True
+
except Certificate.DoesNotExist:
detail = 'User does not exist'
context["invalidserial"] = 1
@@ -209,6 +227,7 @@ def verify(request, serial_key=None):
return render_to_response('verify.html',{}, ci)
def _get_detail(serial_no):
+ print serial_no
purpose = None
if serial_no[0:3] == 'SLC':
purpose = 'Scilab Conference'
@@ -224,11 +243,17 @@ def _get_detail(serial_no):
purpose = 'Scilab Arduino Workshop'
elif serial_no[0:3] == 'ESM':
purpose = 'eSim Faculty Meet'
+ elif serial_no[0:3] == 'OFC':
+ purpose = 'OpenFOAM Symposium'
+ elif serial_no[0:3] == 'FIC':
+ purpose = 'FOSSEE Internship'
if serial_no[3:5] == '14':
year = '2014'
elif serial_no[3:5] == '15':
year = '2015'
+ elif serial_no[3:5] == '16':
+ year = '2016'
#if serial_no[-1] == 'P':
# type = 'Participant'
@@ -1299,3 +1324,306 @@ def create_scipy_certificate_2015(certificate_path, name, qrcode, type, paper, w
except Exception, e:
error = True
return [None, error]
+
+
+###############################################################################
+# OpenFOAM Symposium 2016
+###############################################################################
+
+def openfoam_symposium_feedback_2016(request):
+ context = {}
+ ci = RequestContext(request)
+ form = FeedBackForm()
+ questions = Question.objects.filter(purpose='OFSC2016')
+ if request.method == 'POST':
+ form = FeedBackForm(request.POST)
+ if form.is_valid():
+ data = form.cleaned_data
+ try:
+ FeedBack.objects.get(email=data['email'].strip(), purpose='OFSC2016')
+ context['message'] = 'You have already submitted the feedback. You can download your certificate.'
+ return render_to_response('openfoam_symposium_download_2016.html', context, ci)
+ except FeedBack.DoesNotExist:
+ feedback = FeedBack()
+ feedback.name = data['name'].strip()
+ feedback.email = data['email'].strip()
+ feedback.purpose = 'OFSC2016'
+ feedback.submitted = True
+ feedback.save()
+ for question in questions:
+ answered = request.POST.get('{0}'.format(question.id), None)
+ answer = Answer()
+ answer.question = question
+ answer.answer = answered.strip()
+ answer.save()
+ feedback.answer.add(answer)
+ feedback.save()
+ context['message'] = ''
+ return render_to_response('openfoam_symposium_download_2016.html', context, ci)
+
+ context['form'] = form
+ context['questions'] = questions
+
+ return render_to_response('openfoam_symposium_feedback_2016.html', context, ci)
+
+
+def openfoam_symposium_download_2016(request):
+ context = {}
+ err = ""
+ ci = RequestContext(request)
+ cur_path = os.path.dirname(os.path.realpath(__file__))
+ certificate_path = '{0}/openfoam_symposium_template_2016/'.format(cur_path)
+
+ if request.method == 'POST':
+ paper = request.POST.get('paper', None)
+ workshop = None
+ email = request.POST.get('email').strip()
+ type = request.POST.get('type')
+ if type == 'P':
+ user = OpenFOAM_Symposium_participant_2016.objects.filter(email=email)
+ if not user:
+ context["notregistered"] = 1
+ return render_to_response('openfoam_symposium_download_2016.html', context, context_instance=ci)
+ else:
+ user = user[0]
+ elif type == 'A':
+ if paper:
+ user = OpenFOAM_Symposium_speaker_2016.objects.filter(email=email, paper=paper)
+ if user:
+ user = [user[0]]
+ else:
+ user = OpenFOAM_Symposium_speaker_2016.objects.filter(email=email)
+ if not user:
+ context["notregistered"] = 1
+ return render_to_response('openfoam_symposium_download_2016.html', context, context_instance=ci)
+ if len(user) > 1:
+ context['user_papers'] = user
+ context['v'] = 'paper'
+ return render_to_response('openfoam_symposium_download_2016.html', context, context_instance=ci)
+ else:
+ user = user[0]
+ paper = user.paper
+ name = user.name
+ purpose = user.purpose
+ year = '16'
+ id = int(user.id)
+ hexa = hex(id).replace('0x','').zfill(6).upper()
+ serial_no = '{0}{1}{2}{3}'.format(purpose, year, hexa, type)
+ serial_key = (hashlib.sha1(serial_no)).hexdigest()
+ file_name = '{0}{1}'.format(email,id)
+ file_name = file_name.replace('.', '')
+ try:
+ old_user = Certificate.objects.get(email=email, serial_no=serial_no)
+ qrcode = 'Verify at: http://fossee.in/certificates/verify/{0} '.format(old_user.short_key)
+ details = {'name': name, 'serial_key': old_user.short_key}
+ certificate = create_openfoam_symposium_certificate_2016(certificate_path, details, qrcode, type, paper, workshop, file_name)
+ if not certificate[1]:
+ old_user.counter = old_user.counter + 1
+ old_user.save()
+ return certificate[0]
+ except Certificate.DoesNotExist:
+ uniqueness = False
+ num = 5
+ while not uniqueness:
+ present = Certificate.objects.filter(short_key__startswith=serial_key[0:num])
+ if not present:
+ short_key = serial_key[0:num]
+ uniqueness = True
+ else:
+ num += 1
+ qrcode = 'Verify at: http://fossee.in/certificates/verify/{0} '.format(short_key)
+ details = {'name': name, 'serial_key': short_key}
+ certificate = create_openfoam_symposium_certificate_2016(certificate_path, details,
+ qrcode, type, paper, workshop, file_name)
+ if not certificate[1]:
+ certi_obj = Certificate(name=name, email=email, serial_no=serial_no,
+ counter=1, workshop=workshop, paper=paper, serial_key=serial_key, short_key=short_key)
+ certi_obj.save()
+ return certificate[0]
+
+ if certificate[1]:
+ _clean_certificate_certificate(certificate_path, file_name)
+ context['error'] = True
+ return render_to_response('openfoam_symposium_download_2016.html', context, ci)
+ context['message'] = ''
+ return render_to_response('openfoam_symposium_download_2016.html', context, ci)
+
+
+def create_openfoam_symposium_certificate_2016(certificate_path, name, qrcode, type, paper, workshop, file_name):
+ error = False
+ try:
+ download_file_name = None
+ if type == 'P':
+ template = 'template_OFSC2016Pcertificate'
+ download_file_name = 'OFSC2016Pcertificate.pdf'
+ elif type == 'A':
+ template = 'template_OFSC2016Acertificate'
+ download_file_name = 'OFSC2016Acertificate.pdf'
+
+ template_file = open('{0}{1}'.format\
+ (certificate_path, template), 'r')
+ content = Template(template_file.read())
+ template_file.close()
+ if type == 'P':
+ content_tex = content.safe_substitute(name=name['name'].title(),
+ serial_key=name['serial_key'], qr_code=qrcode)
+ elif type == 'A':
+ content_tex = content.safe_substitute(name=name['name'].title(),
+ serial_key=name['serial_key'], qr_code=qrcode, paper=paper)
+ create_tex = open('{0}{1}.tex'.format\
+ (certificate_path, file_name), 'w')
+ create_tex.write(content_tex)
+ create_tex.close()
+ return_value, err = _make_certificate_certificate(certificate_path, type, file_name)
+ print err
+ if return_value == 0:
+ pdf = open('{0}{1}.pdf'.format(certificate_path, file_name) , 'r')
+ response = HttpResponse(content_type='application/pdf')
+ response['Content-Disposition'] = 'attachment; \
+ filename=%s' % (download_file_name)
+ response.write(pdf.read())
+ _clean_certificate_certificate(certificate_path, file_name)
+ return [response, False]
+ else:
+ error = True
+ except Exception, e:
+ error = True
+ return [None, error]
+
+
+###############################################################################
+# Scilab Internship Certificate
+###############################################################################
+
+
+def fossee_internship_cerificate_download(request):
+ context = {}
+ err = ""
+ ci = RequestContext(request)
+ cur_path = os.path.dirname(os.path.realpath(__file__))
+ certificate_path = '{0}/fossee_internship_cerificate_template/'.format(cur_path)
+
+ if request.method == 'POST':
+ paper = request.POST.get('project_title', None)
+ workshop = None
+ email = request.POST.get('email').strip()
+ type = request.POST.get('type')
+ if type == 'P':
+ user = Internship_participant.objects.filter(email=email)
+ if not user:
+ context["notregistered"] = 1
+ return render_to_response('fossee_internship_cerificate_download.html', context, context_instance=ci)
+ else:
+ user = user[0]
+ elif type == 'A':
+ if paper:
+ user = Internship_participant.objects.filter(email=email, paper=project_title, internship_project_duration=internship_project_duration, student_edu_detail=student_edu_detail, student_institute_detail=student_institute_detail, superviser_name_detail=superviser_name_detail)
+ if user:
+ user = [user[0]]
+ else:
+ user = Internship_participant.objects.filter(email=email)
+ if not user:
+ context["notregistered"] = 1
+ return render_to_response('fossee_internship_cerificate_download.html', context, context_instance=ci)
+ if len(user) > 1:
+ context['user_papers'] = user
+ context['v'] = 'paper'
+ return render_to_response('fossee_internship_cerificate_download.html', context, context_instance=ci)
+ else:
+ user = user[0]
+ paper = user.project_title
+ name = user.name
+ purpose = user.purpose
+ internship_project_duration = user.internship_project_duration
+ student_edu_detail = user.student_edu_detail
+ student_institute_detail=user.student_institute_detail
+ superviser_name_detail=user.superviser_name_detail
+ year = '16'
+ id = int(user.id)
+ hexa = hex(id).replace('0x','').zfill(6).upper()
+ serial_no = '{0}{1}{2}{3}'.format(purpose, year, hexa, type)
+ serial_key = (hashlib.sha1(serial_no)).hexdigest()
+ file_name = '{0}{1}'.format(email,id)
+ file_name = file_name.replace('.', '')
+ try:
+ old_user = Certificate.objects.get(email=email, serial_no=serial_no)
+ qrcode = 'Verify at: http://fossee.in/certificates/verify/{0} '.format(old_user.short_key)
+ details = {'name': name, 'serial_key': old_user.short_key}
+ certificate = create_fossee_internship_cerificate(certificate_path, details, qrcode, type, paper, internship_project_duration,
+ student_edu_detail, student_institute_detail, superviser_name_detail, workshop, file_name)
+ if not certificate[1]:
+ old_user.counter = old_user.counter + 1
+ old_user.save()
+ return certificate[0]
+ except Certificate.DoesNotExist:
+ uniqueness = False
+ num = 5
+ while not uniqueness:
+ present = Certificate.objects.filter(short_key__startswith=serial_key[0:num])
+ if not present:
+ short_key = serial_key[0:num]
+ uniqueness = True
+ else:
+ num += 1
+ qrcode = 'Verify at: http://fossee.in/certificates/verify/{0} '.format(short_key)
+ details = {'name': name, 'serial_key': short_key}
+ certificate = create_fossee_internship_cerificate(certificate_path, details, qrcode, type, paper,
+ internship_project_duration, student_edu_detail, student_institute_detail, superviser_name_detail, workshop, file_name)
+ if not certificate[1]:
+ certi_obj = Certificate(name=name, email=email, serial_no=serial_no, counter=1, workshop=workshop, paper=paper, serial_key=serial_key, short_key=short_key)
+ certi_obj.save()
+ return certificate[0]
+
+ if certificate[1]:
+ _clean_certificate_certificate(certificate_path, file_name)
+ context['error'] = True
+ return render_to_response('fossee_internship_cerificate_download.html', context, ci)
+ context['message'] = ''
+ return render_to_response('fossee_internship_cerificate_download.html', context, ci)
+
+
+def create_fossee_internship_cerificate(certificate_path, name, qrcode, type, paper, internship_project_duration, student_edu_detail, student_institute_detail, superviser_name_detail, workshop, file_name):
+ error = False
+ try:
+ download_file_name = None
+ if type == 'P':
+ template = 'template_FIC2016Pcertificate'
+ download_file_name = 'FIC2016Pcertificate.pdf'
+ elif type == 'A':
+ template = 'template_FIC2016Acertificate'
+ download_file_name = 'FIC2016Acertificate.pdf'
+
+ template_file = open('{0}{1}'.format\
+ (certificate_path, template), 'r')
+ content = Template(template_file.read())
+ template_file.close()
+ if type == 'P':
+ content_tex = content.safe_substitute(name=name['name'].title(),
+ serial_key=name['serial_key'], qr_code=qrcode)
+ elif type == 'A':
+ content_tex = content.safe_substitute(name=name['name'].title(),
+ serial_key=name['serial_key'], qr_code=qrcode, paper=paper,
+ internship_project_duration=internship_project_duration,
+ student_edu_detail=student_edu_detail,
+ student_institute_detail=student_institute_detail,
+ superviser_name_detail=superviser_name_detail)
+ create_tex = open('{0}{1}.tex'.format\
+ (certificate_path, file_name), 'w')
+ create_tex.write(content_tex)
+ create_tex.close()
+ return_value, err = _make_certificate_certificate(certificate_path, type, file_name)
+ print err
+ if return_value == 0:
+ pdf = open('{0}{1}.pdf'.format(certificate_path, file_name) , 'r')
+ response = HttpResponse(content_type='application/pdf')
+ response['Content-Disposition'] = 'attachment; \
+ filename=%s' % (download_file_name)
+ response.write(pdf.read())
+ _clean_certificate_certificate(certificate_path, file_name)
+ return [response, False]
+ else:
+ error = True
+ except Exception, e:
+ error = True
+ return [None, error]
+