{# Template5FCMC #}

<meta http-equiv="Content-type" content="text/html; charset=utf-8" /><meta charset="UTF-8" />
<link href='http://fonts.googleapis.com/css?family=Book+Antiqua' rel='stylesheet' type='text/css'> 
<link rel="stylesheet" href="{{data.baseUrl}}libcommon/font/font_css/font_style.css" type="text/css" charset="utf-8"/>
<link href='https://fonts.googleapis.com/css2?family=Times New Roman:ital,wght@0,400;0,700;1,400;1,700&display=swap' rel='stylesheet'>
<link href="http://fonts.cdnfonts.com/css/bookman-old-style" rel="stylesheet">             
<style>
	.p-5 {
		padding: 5mm;
	}
	.primary-table table,
	.secondary-table table {
		border-collapse: collapse !important;
		page-break-inside: auto;
	}
	.primary-table th {
		text-align: center;
		background: none !important;
		height: 5mm !important;
		border: 1px solid #C0C0C0;
		padding: 0 2mm !important;
	}
	.primary-table td {
		padding: 1mm;
		line-height: 15px !important;
		height: 6mm !important;
		border: 1px solid #C0C0C0;
		text-align: center;
		vertical-align: middle !important;
	}
	.student-details td{
		padding: 2mm;
		line-height: 15px !important;
		height: 6mm !important;
		/* border: 1px solid #C0C0C0; */
		text-align: center;
		vertical-align: middle !important;
	}
	.b-r-0{
		border: 1px solid #C0C0C0!important;
		border-style: solid none solid solid!important;
	}
	.b-l-0{
		border: 1px solid #C0C0C0!important;
		border-style: solid solid solid none!important;
	}
	.grade-table td {
		padding: 1mm;
		line-height: 15px !important;
		height: 6mm !important;
		border: 1px solid #000;
		text-align: center;
		vertical-align: middle !important;
	}
	.page-a4 {
		width: 100%;
		border: none;
		padding:4mm 20mm;
		margin: auto;
		page-break-after: always;
		color: #181818!important;
		/* wkhtmltopdf renders CSS mm lengths at ~0.8x actual size regardless of --dpi;
		   385mm here fills the true 305mm printable area (317mm page - 5mm top margin - 7mm bottom margin) */
		min-height:380mm;
		font-family: 'Times New Roman', serif;
	}
	.border-0 {
		border: none !important;
	}
	.bold {
		font-weight: 700 !important;
	}
	.text-center {
		text-align: center;
	}
	.text-left {
		text-align: left !important;
	}
	.text-right {
		text-align: right !important;
	}
	.secondary-table td {
		/* font-family: 'Book Antiqua' !important; */
		font-weight: 700 !important;
		font-size: 10pt !important;
		padding: 10px 0px 0px 0px;
		/* line-height: 7px !important;
		height: 4mm !important; */
		border: none;
		/* text-align: left; */

	}
	.abbr td{
		font-size: 11pt !important;
	}
	@font-face {
		font-family: 'Trebuchet MS';
		src: url('Trebuchet MS.otf');
	}
	.border-top-0 td{
        border:1px solid #C0C0C0 !important;
        border-style: none solid none solid!important;
    }
	.border-full{
        border:1px solid #C0C0C0 !important;
        border-style: solid solid solid solid!important;
    }
	.unbold ,.unbold th{
		font-weight:normal!important;
	}
	/* ponytail: whole card is Times New Roman — all font helpers point here */
	.font-2,
	.font-6,
	.font-7,
	.font-8,
	.font-9 {
		font-family: 'Times New Roman', serif !important;
	}
	.fsize-10{
		font-size: 10pt !important;
	}
	.fsize-9{
		font-size: 9pt !important;
	}

	.p-l-p{
		padding-left:40%!important;
	}

	.fsize-11{
		font-size: 11pt !important;
	}
	.fsize-15{
		font-size: 18px !important;
	}
	.p-l-30{
		padding-left:30px!important;
	}
	.p-r-80{
		padding-right:80px!important;
	}
	.p-l-10{
		padding-left:10px!important;
	}
    .college-header {
		height: 32mm;
		width: auto;
	}
	.water-mark {
		position: relative;
	}
	.water-mark > * {
		position: relative;
		z-index: 2;
	}
	.water-mark:after {
		content: '';
		background: #ffffff url({{data.collegeData.waterMarkFcm}}) no-repeat center 70%;
		position: absolute;
		top: 0px;
		left: 0px;
		width: 100%;
		height: 100%;
		z-index: 1;
		-webkit-background-size: 100% 100%;
		-moz-background-size: 100% 100%;
		-o-background-size: 100% 100%;
		background-size: 100% 100%;
		opacity: 0.4 !important;
	}
</style>
{% for student in  data.studentData %}
	{% if student.failedStatus == 'FAILED' %}
		{# NOT AVAILABALE #}
		<div class="page-a4{% if data.displayContentOptions.waterMarkFlag %} water-mark{% endif %}" style="page-break-after: always;">
			<div class='text-danger bold text-center fsize-14 failed'>MARK CARD NOT AVAILABLE FOR {{student.name|raw |upper}} ({{student.regNo|raw}}) </div>
		</div>
		<div class="page-a4{% if data.displayContentOptions.waterMarkFlag %} water-mark{% endif %}" style="page-break-after: always;">
			<div class='text-danger bold text-center fsize-14 failed'>MARK CARD NOT AVAILABLE FOR {{student.name|raw |upper}} ({{student.regNo|raw}}) </div>
		</div>
	{% else %}
		{% set totalSems = student.academicTerms|length %}
		{# ── PAGE 1 : header + student details + sems 1-3 + CGPA summary ── #}
		<div class="page-a4{% if data.displayContentOptions.waterMarkFlag %} water-mark{% endif %}" style="page-break-after:always!important;">
			<table style="width:100% !important; margin:20mm 0 0 0;" class="primary-table">
					<tr>
					{% if data.displayContentOptions.displayBanner %}
					<td colspan='4' class="border-0" width="100%" style="padding:0 !important;"><img src="{{data.collegeData.collegeHeaderConsolidated}}" class="college-header"></td>
					{% else %}
					<td colspan='4' class="border-0" width="100%"><div style="height:25mm;"></div></td>
					{% endif %}
				</tr>
				<tr>
					<td colspan='4' class="border-0 font-2" width="100%" style="font-size:15pt;padding-top:3mm!important;"><b>{{ student.programName|raw|upper }}({{ student.degreeName|raw|upper }}) DEGREE EXAMINATIONS</b></td>
				</tr>
				<tr>
					<td  colspan='4'class="border-0 font-2" width="100%" style="font-size:14pt;padding-top:3mm!important;padding-bottom:3mm;"><b>CONSOLIDATED STATEMENT OF GRADES</b></td>
				</tr>
			</table>
			<table style="width:100% !important; margin:0mm 0 0 0;" class="student-details">
				<tr>
					<td class="text-left b-r-0 font-6 fsize-15">Name of the Candidate</td>
					<td class="text-left b-l-0 font-7" colspan='3'>: {{student.name|raw |upper}}</td>
				</tr>
				<tr>
					<td class="text-left b-r-0 font-6 fsize-15">Department</td>
					<td class="text-left b-l-0 font-7" colspan='3'> : {{student.departmentDesc |raw |upper}}
					</td>
				</tr>
				<tr>
					<td class="b-r-0 text-left font-6 fsize-15">Specialisation</td>
					<td class="b-l-0 text-left font-7" colspan='3'>: {{student.streamDesc |raw |upper}}</td>
				</tr>
				<tr>
					<td class="b-r-0 text-left font-6 fsize-15">Duration of Programme</td>
					<td class="b-l-0 text-left font-7" colspan='3'>: 2 Years (4 Semesters)</td>
				</tr>
				<tr>
					<td class="text-left b-r-0 font-6 fsize-15">Admission Number</td>
					<td class="text-left b-l-0 font-7">: {{student.admissionNo|raw}}</td>
					<td class="text-left b-r-0 font-6 fsize-15">University Register Number</td>
					<td class="text-left b-l-0 font-7">: {{student.regNo|raw}}</td>
				</tr>
				<tr>
					<td class="text-left b-r-0 font-6 fsize-15">Year of Admission</td>
					<td class="text-left b-l-0 font-7">: {{student.admissionYear}}</td>
					<td class="text-left b-r-0 font-6 fsize-15">Month and Year of Passing</td>
					<td class="text-left b-l-0 font-7">: {{student.latestMonthYear | upper}}</td>
				</tr>
				<tr>
					<td class="text-left b-r-0 font-6 fsize-15">Date of Birth</td>
					<td class="text-left b-l-0 font-7">: {{student.dobFormat2}}</td>
					<td class="text-left b-r-0 font-6 fsize-15">Medium of Instruction</td>
					<td class="text-left b-l-0 font-7">: English</td>
				</tr>
				<tr>
					<td  class="text-left b-r-0 font-6 fsize-15">Certificate Number</td>
					<td  class="text-left b-l-0 font-7">: {{student.slNo}}</td>
					<td  class="text-left b-r-0 font-6 fsize-15">Date of Issue</td>
					<td  class="text-left b-l-0 font-7">: {{data.dateOfIssue}}</td>
				</tr>
			</table>
			<table style="width:100% !important; margin:5mm 0 0 0;" class="primary-table font-8">
				<colgroup>
					<col width="15%">
					<col width="50%">
					<col width="5%">
					<col width="5%">
					<col width="25%">
				</colgroup>
				<thead>
					<tr>
						<th>Course Code</th>
						<th>Course Name</th>
						<th>Credits</th>
						<th>Grade</th>
						<th>Month and Year of Pass</th>
					</tr>
				</thead>
				{% for index,semMark in student.academicTerms %}
					{% if loop.index <= 3 %}
					<tr class="subject-details fsize-11"><td class="text-left bold" colspan="5" style=' text-decoration: underline;'>{{semMark.semInFullName}} Semester</td></tr>
					{% for subject in semMark.subjects %}
						<tr class="subject-details fsize-10">
							<td class="text-left">{{subject.code|raw}} <sup>{{subject.isElective ? ' #':''}}</sup> <sup>{{subject.isMoocSubject ? ' $':''}}</sup></td>
							{% if not subject.markDetails.isFinalSemSubject and subject.markDetails.isProjectGroupSubject %}
							<td colspan='3'>
								<span class="text-left" style='width:50%;float:left'>{{subject.name|raw | upper}}</span>
								<span class="text-right" style='width:50%;float:right'>{{subject.failedStatus == 'FAILED' ? 'Incomplete':'Successfully Completed - '~ subject.credit ~' credits'}}</span>
							</td>
							{% else %}
							<td class="text-left">{{subject.name|raw | upper}}</td>
							<td>{{subject.credit | round}}</td>
							<td>{{(subject.showAb and subject.isAbsent ==1)? 'AB':subject.grade}}</td>
							{% endif %}
							<td>{{subject.examMonthYear | upper}}</td>
						</tr>
					{% endfor %}
					<tr class="subject-details fsize-11">
						{% if semMark.termId == student.finalSem %}
							<td colspan='4' class="text-right font-2"><b>Credits Earned : {{semMark.semCredit}}</b></td>
						{% else %}
							<td colspan='4' class="text-right font-2"><b>Credits Earned : {{semMark.semCredit}}</b></td>
						{% endif %}
						<td class = 'text-center font-2' colspan='1'><b>SGPA : {{semMark.failedStatus == 'FAILED'  ? '-': semMark.sgpa |number_format(2)}}</b></td>
					</tr>
					{% endif %}
				{% endfor %}
			</table>
		</div>
		{# Blank page for JCET #}
		{% if data.collegeData.blankPageInbetween1stAnd2ndPageInFCM %}
			<div class="page-a4 blank-page-no-count" style="page-break-after:always!important;">
			</div>
		{% endif %}
		{# ── PAGE 2 (only when > 3 sems) : remaining sems + summary + grade table ── #}
		<div class="page-a4{% if data.displayContentOptions.waterMarkFlag %} water-mark{% endif %}" style="page-break-after:always!important;">
			<table style="width:100% !important; margin:10mm 0 0 0;" class="primary-table font-8">
				<colgroup>
					<col width="15%">
					<col width="50%">
					<col width="5%">
					<col width="5%">
					<col width="25%">
				</colgroup>
				{% for index,semMark in student.academicTerms %}
					{% if loop.index > 3 %}
					<tr class="subject-details fsize-11"><td class="text-left bold" colspan="5" style=' text-decoration: underline;'>{{semMark.semInFullName}} Semester</td></tr>
					{% for subject in semMark.subjects %}
						<tr class="subject-details fsize-10">
							<td class="text-left">{{subject.code|raw}} <sup>{{subject.isElective ? ' #':''}}</sup> <sup>{{subject.isMoocSubject ? ' $':''}}</sup></td>
							{% if not subject.markDetails.isFinalSemSubject and subject.markDetails.isProjectGroupSubject %}
							<td colspan='3'>
								<span class="text-left" style='width:50%;float:left'>{{subject.name|raw | upper}}</span>
								<span class="text-right" style='width:50%;float:right'>{{subject.failedStatus == 'FAILED' ? 'Incomplete':'Successfully Completed - '~ subject.credit ~' credits'}}</span>
							</td>
							{% else %}
							<td class="text-left">{{subject.name|raw | upper}}</td>
							<td>{{subject.credit | round}}</td>
							<td>{{(subject.showAb and subject.isAbsent ==1)? 'AB':subject.grade}}</td>
							{% endif %}
							<td>{{subject.examMonthYear | upper}}</td>
						</tr>
					{% endfor %}
					<tr class="subject-details fsize-11">
						{% if semMark.termId == student.finalSem %}
							<td colspan='4' class="text-right font-2"><b>Credits Earned : {{semMark.semCredit}}</b></td>
						{% else %}
							<td colspan='4' class="text-right font-2"><b>Credits Earned : {{semMark.semCredit}}</b></td>
						{% endif %}
						<td class = 'text-center font-2' colspan='1'><b>SGPA : {{semMark.failedStatus == 'FAILED'  ? '-': semMark.sgpa |number_format(2)}}</b></td>
					</tr>
					{% endif %}
				{% endfor %}
				
			</table>
			<table style="width:100% !important;margin-top:5mm!important;font-weight:bold;" class="primary-table">
				<tr class='abbr font-2 fsize-9' style="padding-top:20px!important;">
					<td style='width:20%' colspan='1' class="text-center">Semester</td>
					{% for index,semMark in student.academicTerms %}
						<td style='width:20%' colspan='1' class="text-center">{{semMark.semInRomanLetter}}</td>
					{% endfor %}
				</tr>
				<tr class='abbr font-2 fsize-9' style=";">
					<td style='width:20%' colspan='1' class="text-center">Credits</td>
					{% for index,semMark in student.academicTerms %}
						<td style='width:20%' colspan='1' class="text-center">{{semMark.credit}}</td>
					{% endfor %}
				</tr>
				<tr class='abbr font-2 fsize-9' style=";">
					<td style='width:20%' colspan='1' class="text-center">SGPA</td>
					{% for index,semMark in student.academicTerms %}
						<td style='width:20%' colspan='1' class="text-center">{{semMark.failedStatus == 'FAILED'  ? '-': semMark.sgpa |number_format(2)}}</td>
					{% endfor %}
				</tr>
				<tr class='abbr font-2 fsize-9' style=";">
					<td style='width:20%' colspan='2' class="text-center">Total Credits</td>
					<td style='width:20%' colspan='{{totalSems - 1}}' class="text-center"> {{student.credit}}</td>
				</tr>
				<tr class='abbr font-2 fsize-9' style=";">
					<td style='width:20%' colspan='2' class="text-center">CGPA</td>
					<td style='width:20%' colspan='{{totalSems - 1}}' class="text-center"> {{student.failedStatus == 'FAILED' ? '-': student.cgpa |number_format(2)}} {{student.failedStatus == 'FAILED' ? '-': '(' ~ student.cgpaInWords ~ ')' }} </td>
				</tr>
				<tr class='abbr font-2 fsize-9' style=";">
					<td style='width:20%' colspan='2' class="text-center">Percentage</td>
					<td style='width:20%' colspan='{{totalSems - 1}}' class="text-center"> {{student.failedStatus == 'FAILED' ? '-': student.percentage }} </td>
				</tr>
				<tr class='abbr font-2 fsize-9' style=";">
					<td style='width:20%' colspan='2' class="text-center">Class</td>
					<td style='width:20%' colspan='{{totalSems - 1}}' class="text-center"> {{student.failedStatus == 'FAILED' ? '':  student.class}} </td>
				</tr>
			</table>
			<div style='width:100%; margin:10px !important' class='text-center font-8'> ***** END OF STATEMENT ***** </div>
			<div style='width:20%;float:left;padding-left:10px; margin-top:5px' class='text-left font-8'> <sup>#</sup> Elective</div>
			{% if student.isMoocSubject %}
				<div style='width:50%;float:left;padding-left:10px; margin-top:5px' class='text-left font-8'> <sup>$</sup> MOOC</div>
			{% endif %}
			<div style='width:100%;padding-top:8mm;clear:both' class='font-7'>
				<div style='width:30%;float:left;padding-left:5mm' class='text-left'>&nbsp; <br><br>Verified by:</div>
				<div style='width:20%;float:left;'class='text-right'></div>
				<div style='width:50%;float:right;font-size:16px;padding-right:10mm'class='text-right'><br><br>Controller of Examinations</div>
			</div>
			<div style='margin-left:30mm;margin-right:10mm;margin-top:5mm;clear:both'>
				{% if student.qrData %}
				<div style="text-align:center; margin-bottom:3mm;">
					<img style="width:25mm; height:25mm;" src="{{ getQr(student.qrData, 250, 0, 'L') }}"/>
				</div>
				{% endif %}
				<div style='font-weight: bold;' class="font-7">College follows 10 point grading scale</div>
				<table style="width:90% !important; margin:1mm 0 0 0;" class="grade-table font-7 fsize-10">
					<tr>
						<td colspan="3" class="text-left">Grades and Grade Points</td>
					</tr>
					<tr>
						<td>Grades</td><td class="text-left">Grade Point (GP)</td><td>% of Total Marks obtained in the Course</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">S</span></td><td>10</td><td class="text-left">90% and above</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">A+</span></td><td>9.0</td><td class="text-left">85% and above but less than 90%</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">A</span></td><td>8.5</td><td class="text-left">80% and above but less than 85%</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">B+</span></td><td>8.0</td><td class="text-left">75% and above but less than 80%</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">B</span></td><td>7.5</td><td class="text-left">70% and above but less than 75%</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">C+</span></td><td>7.0</td><td class="text-left">65% and above but less than 70%</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">C</span></td><td>6.5</td><td class="text-left">60% and above but less than 65%</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">D</span></td><td>6.0</td><td class="text-left">55% and above but less than 60%</td>
					</tr>
					<tr>
						<td class="text-left"><span class="p-l-p">P</span></td><td>5.5</td><td class="text-left">50% and above but less than 55%</td>
					</tr>
					<tr>
						<td class="text-left" colspan="2">First Class with Distinction</td><td class="text-left">CGPA 8.0 and above</td>
					</tr>
					<tr>
						<td class="text-left" colspan="2">First Class</td><td class="text-left">CGPA 6.0 and above</td>
					</tr>
				</table>
				<div class="font-7 fsize-11">
					<div style='font-weight: bold;margin-top:2mm'>Semester Grade Point Average (SGPA)</div>
					<div class='p-l-30' style="margin-top:2mm">SGPA is calculated as below:</div>
					<div style='padding-left:40mm;width:100%;text-align:left; float:right; margin:2mm 0 0 0;'>
						<div style = 'width:15%;float:left;line-height: 35px;'>
							SGPA =
						</div>
						<div style = 'width:20%; float:left; text-align:center'>
							∑ <i>C<sub>i</sub> x GP<sub>i</sub></i>
							<br/><hr style='margin: 1px 0; border-top:1px solid #000;'>
							∑ <i>C<sub>i</sub></i>
						</div>
					</div>
					<div class='p-l-30'>where 'C<sub>i</sub>' is the credit assigned for a course and 'GP<sub>i</sub>' is the grade point for that course. Summation
						is done for all courses specified in the curriculum of that semester.</br></br></div>
					<div style='font-weight: bold;'>Cumulative Grade Point Average (CGPA)</div>
					<div class='p-l-30' style="margin-top:2mm">CGPA is calculated as below:</div>
					<div style='padding-left:40mm;width:100%;text-align:left; float:right; margin:2mm 0 0 0;'>
					<div style = 'width:15%;float:left;line-height: 35px;'>
								CGPA =
					</div>
					<div style = 'width:20%; float:left; text-align:center'>
								∑ <i>C<sub>i</sub> x GP<sub>i</sub></i>
								<br/><hr style='margin: 1px 0; border-top:1px solid #000;'>
								∑ <i>C<sub>i</sub></i>
							</div>
					</div>
					<div class='p-l-30'>where 'C<sub>i</sub>' is the credit assigned for a course and 'GP<sub>i</sub>' is the grade point for that course. Summation is done for all courses up to that semester for which the 'CGPA' is calculated.</br></br></div>
					<div style='font-weight: bold;'>Conversion from CGPA to percentage</div>
					<div class='p-l-30' style="margin-top:2mm">The conversion from CGPA to % marks is as below:</div>
					<div style='padding-left:40mm;width:100%;text-align:left; float:right; margin:1mm 0 0 0;'>
						<div style = 'width:70%;float:left;line-height: 25px;' class="font-9">
							<i>Percentage Marks </i> = <i>CGPA</i> × 10
						</div>
					</div>
				</div>
			</div>
		</div>
	{% endif %}
{% endfor %}
