Esempio n. 1
0
 /// <summary>
 /// 套打-全部6张(F1)
 /// 套打-机动车驾驶培训记录*3(F2)(完成)
 /// 套打-机动车驾驶人身体条件证明(F3)(开发区完成)
 /// 套打-机动车驾驶员培训学员登记表(F4)(完成)
 /// 套打-机动车学习驾驶员登记表(F5)
 /// 套打-科目三考试成绩表(F6)(完成)
 /// 套打-机动车驾驶人档案(F7)(超过A4,无法测试)
 /// </summary>
 /// <param name="student"></param>
 public BaseStudentPrinter(StudentInfo student)
 {
     this.student = student;
 }
Esempio n. 2
0
 public F8Printer(StudentInfo student)
     : base(student)
 {
 }
Esempio n. 3
0
 /// <summary>
 /// 设置打印状态
 /// </summary>
 /// <param name="student"></param>
 public static void SetPrinted(StudentInfo student)
 {
     student.PrintedState = "已打印";
     FT.DAL.Orm.SimpleOrmOperator.Update(student);
 }
Esempio n. 4
0
        public static void Print(StudentInfo student, Keys key)
        {
            BaseStudentPrinter printer = null;

            if (key == Keys.F1)
            {
                printer = new AllPrinter(student);
            }
            else if (key == Keys.F2)
            {
                printer = new F2Printer(student);
            }
            else if (key == Keys.F3)
            {
                printer = new F3Printer(student);
            }
            else if (key == Keys.F4)
            {
                printer = new F4Printer(student);
            }
            else if (key == Keys.F5)
            {
                printer = new F5Printer(student);
                //printer = new F5Printer(this.student);
            }
            else if (key == Keys.F6)
            {
                SetPrinted(student);
                printer = new ApplyPrinter(student);
            }
            else if (key == Keys.F7)
            {
                SetPrinted(student);
                printer = new ApplyExcelPrinter(student);
                ApplyExcelPrinter tmp = printer as ApplyExcelPrinter;
                tmp.PrintExcel(false);
                return;
            }
            else if (key == Keys.F8)
            {
                printer = new F8Printer(student);
            }
            else if (key == Keys.F9)
            {
                printer = new F9Printer(student);
            }
            if (printer != null)
            {
                CommonPrinter commonPrinter = new CommonPrinter(printer);
                //commonPrinter.ShowPreviewPrinter();
                GlobalPrintSetting printSetting = StaticCacheManager.GetConfig <GlobalPrintSetting>();
                if (printSetting.PrintModel == "直接打")
                {
                    commonPrinter.Print();
                }
                else if (printSetting.PrintModel == "选择打印机")
                {
                    commonPrinter.ShowPreviewPrinter();
                }
                else
                {
                    commonPrinter.Preview();
                }
            }
        }
Esempio n. 5
0
 public ApplyExcelPrinter(StudentInfo student)
     : base(student)
 {
 }
Esempio n. 6
0
 public AllPrinter(StudentInfo student)
     : base(student)
 {
 }