123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103 |
- <%@ page contentType="text/html;charset=UTF-8" %>
- <%@ include file="/webpage/include/taglib.jsp"%>
- <html>
- <head>
- <title>导入Excel</title>
- <meta name="decorator" content="ani"/>
- <style type="text/css">
- .common-style {
- width:80%;
- display: inline-block;
- height: 34px;
- padding: 6px 12px;
- margin: 0px 2px;
- font-size: 14px;
- line-height: 1.42857143;
- color: #555;
- background-color: #fff;
- background-image: none;
- border: 1px solid #ccc;
- border-radius: 4px;
- -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
- box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
- -webkit-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
- transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
- }
- .btn-style {
- display: inline-block;
- height: 34px;
- margin-left: 105px;
- font-size: 14px;
- line-height: 1.42857143;
- color: #555;
- background-image: none;
- border: 1px solid #ccc;
- border-radius: 4px;
- -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
- box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
- -webkit-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
- transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
- }
- </style>
- <script>
- $(document).ready(function() {
- });
- function importExcel() {
- if($('#classificationFile').val()==null || $('#classificationFile').val()==''){
- jp.warning("请上传待匹配文件!");
- return;
- }
- var url = '${ctx}/sg/classification/classify';
- var importForm =$("#importForm")[0];
- jp.loading(' 正在匹配,请稍等...');
- jp.uploadFile(importForm, url,function (data){
- if(data.success){
- var address = '${ctx}/sg/classification/download?tempFileName='+data.body.tempFileName;
- jp.downloadFile(address);
- jp.close();
- }else{
- jp.error(data.msg);
- }
- });//调用保存事件
- }
- </script>
- </head>
- <body class="bg-white">
- <div class="wrapper wrapper-content">
- <div class="row">
- <div class="col-md-12">
- <div class="panel panel-primary">
- <div class="panel-body">
- <form id="importForm" action="${url}" method="post" enctype="multipart/form-data" class="form-horizontal">
- <div class="form-group" style="margin:15px 25%">
- <label class="col-sm-4 control-label">待匹配文件:</label>
- <div class="col-sm-8">
- <div class=" input-group" style=" width: 100%;">
- <input id="classificationFile" class="common-style" name="classificationFile" type="file" />
- </div>
- </div>
- </div>
- </form>
- <div class="col-lg-6" style="margin:15px 25%">
- <div class="form-group text-center" >
- <div>
- <button class="btn btn-primary btn-lg btn-parsley" onclick="importExcel()">开始匹配</button>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </body>
- </html>
|