package cn.com.qmth.stmms.admin.dto;

import java.math.BigDecimal;

import cn.com.qmth.stmms.biz.exam.model.ExamStudent;
import cn.com.qmth.stmms.common.annotation.ExcelField;

public class ScoreExportDTO {

    @ExcelField(title = "学号", align = 2, sort = 10)
    private String studentCode;

    @ExcelField(title = "姓名", align = 2, sort = 20)
    private String name;
    
    @ExcelField(title = "条形码标识", align = 2, sort = 30)
    private String examNumber;

    @ExcelField(title = "考试成绩", align = 2, sort = 40)
    private double totalScore;

    public ScoreExportDTO(ExamStudent student) {
        setStudentCode(student.getStudentCode());
        setName(student.getName());
        setExamNumber(student.getExamNumber());
        setTotalScore(new BigDecimal(student.getTotalScore()).setScale(0, BigDecimal.ROUND_HALF_UP).doubleValue());
    }

	public String getStudentCode() {
		return studentCode;
	}

	public void setStudentCode(String studentCode) {
		this.studentCode = studentCode;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getExamNumber() {
		return examNumber;
	}

	public void setExamNumber(String examNumber) {
		this.examNumber = examNumber;
	}

	public double getTotalScore() {
		return totalScore;
	}

	public void setTotalScore(double totalScore) {
		this.totalScore = totalScore;
	}
}

