You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

PrintSignFlow.cshtml 4.1 KiB

4 years ago
4 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. 
  2. @{
  3. Layout = null;
  4. }
  5. @model Learun.Application.TwoDevelopment.EducationalAdministration.StuInfoFreshEntity
  6. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  7. <html xmlns="http://www.w3.org/1999/xhtml">
  8. <head>
  9. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  10. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
  11. <meta name="renderer" content="webkit" />
  12. <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no" />
  13. <meta name="format-detection" content="telephone=no" />
  14. <title>学期成绩表</title>
  15. <meta name="keywords" content="学期成绩表" />
  16. <meta name="description" content="学期成绩表" />
  17. <script src="~/Content/js/jquery.js"></script>
  18. <script src="~/Content/Lodop/LodopFuncs.js"></script>
  19. <style id="style1">
  20. body,
  21. html {
  22. font-size: 13px;
  23. font-family: "微软雅黑";
  24. color: #333;
  25. overflow-x: hidden;
  26. }
  27. table {
  28. border-collapse: collapse;
  29. table-layout: fixed;
  30. }
  31. .title {
  32. font-size: 24px;
  33. text-align: center;
  34. }
  35. .table {
  36. width: 100%;
  37. font-size: 14px;
  38. border: 1px solid #000;
  39. margin-top: 10px;
  40. }
  41. .table td {
  42. border-top: 1px solid #000;
  43. border-left: 1px solid #000;
  44. padding: 8px 6px;
  45. line-height: 26px;
  46. width: 16.666667%;
  47. }
  48. .printTxt {
  49. font-size: 14px;
  50. line-height: 26px;
  51. }
  52. .btn {
  53. width: 300px;
  54. height: 40px;
  55. background: #7d7dec;
  56. text-align: center;
  57. line-height: 40px;
  58. border-radius: 4px;
  59. margin: 30px auto;
  60. color: #fff;
  61. cursor: pointer;
  62. }
  63. </style>
  64. </head>
  65. <body>
  66. <!-- / warpper -->
  67. <div class="printBox" style="overflow: hidden;">
  68. <div class="title">塔里木职业技术学院</div>
  69. <div class="title">2019年新生报到流程单</div>
  70. <table cellspacing="0" cellpadding="0" class="table">
  71. <tr>
  72. <td style="width:17%">姓名</td>
  73. <td style="width:23%">@Model.StuName</td>
  74. <td style="width:10%">专业</td>
  75. <td style="width:50%">@Model.MajorName</td>
  76. </tr>
  77. <tr>
  78. <td>身份证号</td>
  79. <td colspan="3">@Model.IdentityCardNo</td>
  80. </tr>
  81. <tr style="height:170px;">
  82. <td>招生就业处</td>
  83. <td colspan="3"></td>
  84. </tr>
  85. <tr style="height:170px;">
  86. <td>财务处</td>
  87. <td colspan="3"></td>
  88. </tr>
  89. <tr style="height:170px;">
  90. <td>辅导员</td>
  91. <td colspan="3"></td>
  92. </tr>
  93. </table>
  94. <div class="printTxt">此表由辅导员收齐交回招生就业处</div>
  95. </div>
  96. <!-- / warpper -->
  97. <div class="btn">打印</div>
  98. </body>
  99. <script>
  100. var html = $('.printBox').html();
  101. $('.btn').click(function () {
  102. AddPrintContent(html);
  103. });
  104. function AddPrintContent(html) {
  105. var myHtml = myHtml = html;
  106. var strBodyStyle = "<style>" + document.getElementById("style1").innerHTML + "</style>";
  107. var strFormHtml = strBodyStyle + "<body>" + myHtml + "</body>";
  108. LODOP = getLodop();
  109. LODOP.PRINT_INIT("个人授课表");
  110. LODOP.SET_PRINT_PAGESIZE(1, 0, 0, "A5"); //1 竖向 2横向
  111. LODOP.SET_PRINT_MODE("PRINT_DUPLEX", 2);
  112. LODOP.SET_PRINT_MODE("PRINT_DEFAULTSOURCE", 7);
  113. LODOP.ADD_PRINT_HTM(20, 17, '132mm', '200mm', strFormHtml);
  114. //打印预览
  115. // LODOP.PRINT_DESIGN()
  116. var TaskID1 = LODOP.PREVIEW();
  117. // 直接打印
  118. // var TaskID1=LODOP.PRINT();
  119. };
  120. </script>
  121. </html>