123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- @model EMIS.ViewModel.ExcelImportResult
- @using EMIS.Web.Controls;
- @using Bowin.Common.JSON;
- @using Bowin.Web.Controls.Mvc;
- @{
- ViewBag.Title = "Import";
- }
- <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
- @using (Html.BeginForm("Import", "Score", FormMethod.Post, new { enctype = "multipart/form-data" }))
- {
- @Html.Hidden("importData", Model.Data.ToJson())
- <div class="p_title">
- <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
- 学生导入
- </div>
- <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("StudentImport")</div>
- </div>
- <div class="search_list">
- <table cellpadding="0" cellspacing="1">
- <tr>
- <td>
- <label>
- 导入文件:
- </label>
- </td>
- <td>
- <input type="file" name="file" id="file" accept="*.xls" value=" " />
- </td>
- </tr>
- <tr>
- <td colspan="2" style="text-align: center;">
- <span style="color: Red">注:<a style="color: Red;" href="~/Content/TemplateFile/报考名单学生导入模板.xls" target="_blank">模板下载</a>。</span>
- <span id="error" style="display: none;color:red"> <a id="errorExcel" style="color: Red;" href="@ViewBag.ErrorFile" target="_blank">@ViewBag.operationTips </a></span>
- @*<span id="error" style="@(Model.IsAllSuccess ? "display: none; " : "")color: red"> <a style="color: Red;" href="@Model.ErrorFilePath" target="_blank">@Model.Message</a></span>*@
- </td>
- </tr>
- </table>
- </div>
- }
- </div>
- @section scripts{
- <script src="~/Scripts/Business/ExaminationApply/StudentImport.js" type="text/javascript"></script>
- @if (Model.IsAllSuccess && Model.Data != null)
- {
- <script type="text/javascript">
- (function ($) {
- $.messager.alert("系统提示", "导入成功。");
- top.$("#@Request["WindowID"]").data("resultData", eval("(" + $("[name='importData']").val() + ")"));
- top.$("#@Request["WindowID"]").dialog("close");
- })(jQuery);
- </script>
- }
- else if(!Model.IsAllSuccess && Model.Data != null)
- {
- <script type="text/javascript">
- (function ($) {
- $.messager.alert("系统提示", "导入失败。");
- $("#errorExcel").attr("href", "@Model.ErrorFilePath");
- $("#errorExcel").text("@Model.Message");
- top.$("#@Request["WindowID"]").data("resultData", eval("(" + $("[name='importData']").val() + ")"));
- })(jQuery);
- </script>
- }
- }
|