|
@@ -69,20 +69,29 @@
|
|
|
<li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
<input type="button" id="button" style="width: 100px;" class="scbtnbution" value="导出订单明细" />
|
|
|
</li>
|
|
|
+ <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
+ <input type="button" id="principalimput" style="width: 100px;height: 30px" class="scbtn" value=" + 导入校长" />
|
|
|
+ <div style="display: none">
|
|
|
+ <input type="file" accept="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" id="principalfile" />
|
|
|
+ </div>
|
|
|
+ </li>
|
|
|
+ <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
+ <a th:href="@{/static/sys/excel/order.xlsx?1}"><input type="button" style="background: #ccc no-repeat center;width: 100px;height: 30px" class="scbtn" value="服务失效模板" /></a>
|
|
|
+ </li>
|
|
|
<!-- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
<input type="button" id="detailbutton" style="width: 120px;" class="scbtnbution" value="各馆月度销售" />
|
|
|
</li> -->
|
|
|
- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
- <input type="button" id="ybbutton" style="width: 120px;" class="scbtnbution" value="财务月报" />
|
|
|
- </li>
|
|
|
- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
- <input type="button" id="gxbuttonA" style="width: 120px;" class="scbtnbution" value="共享模式A" />
|
|
|
- </li>
|
|
|
- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
- <input type="button" id="gxbuttonB" style="width: 120px;" class="scbtnbution" value="共享模式B" />
|
|
|
- </li>
|
|
|
- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">
|
|
|
- <input type="button" id="zbbutton" style="width: 120px;" class="scbtnbution" value="人员月度销售" />
|
|
|
+<!-- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">-->
|
|
|
+<!-- <input type="button" id="ybbutton" style="width: 120px;" class="scbtnbution" value="财务月报" />-->
|
|
|
+<!-- </li>-->
|
|
|
+<!-- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">-->
|
|
|
+<!-- <input type="button" id="gxbuttonA" style="width: 120px;" class="scbtnbution" value="共享模式A" />-->
|
|
|
+<!-- </li>-->
|
|
|
+<!-- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">-->
|
|
|
+<!-- <input type="button" id="gxbuttonB" style="width: 120px;" class="scbtnbution" value="共享模式B" />-->
|
|
|
+<!-- </li>-->
|
|
|
+<!-- <li th:if="${ #httpSession.getAttribute('admin') !=null && #lists.contains(#httpSession.getAttribute('admin').orgcodeList,'SSJ-SSJ-CW') }">-->
|
|
|
+<!-- <input type="button" id="zbbutton" style="width: 120px;" class="scbtnbution" value="人员月度销售" />-->
|
|
|
</li>
|
|
|
</ul>
|
|
|
</form>
|
|
@@ -219,7 +228,48 @@ $("#detailbutton").on('click',function(){
|
|
|
$("#seachform").submit();
|
|
|
document.getElementById("seachform").action = "[[${sysUrl}]]/sys/order/vipOrderList.html";
|
|
|
});
|
|
|
+$("#principalimput").on('click',function (){
|
|
|
+ $("#principalfile").click();
|
|
|
+})
|
|
|
+var $principalfile = $("#principalfile");
|
|
|
+$principalfile.change(function () {
|
|
|
+ if($(this).val() != ""){
|
|
|
+ filePrincipalLoad(this);
|
|
|
+ }
|
|
|
+})
|
|
|
|
|
|
+function filePrincipalLoad(ele){
|
|
|
+ var formData = new FormData();
|
|
|
+ var name = $(ele).val();
|
|
|
+ var files = $(ele)[0].files[0];
|
|
|
+ formData.append("file", files);
|
|
|
+ formData.append("name", name);
|
|
|
+ $.ajax({
|
|
|
+ url: "[[${sysUrl}]]/sys/imlibuser/principal/import",
|
|
|
+ type: 'POST',
|
|
|
+ data: formData,
|
|
|
+ processData: false,
|
|
|
+ contentType: false,
|
|
|
+ beforeSend: function () {
|
|
|
+ parent.layer.msg("数据正在导入中....",{icon:2});
|
|
|
+ },
|
|
|
+ success: function (responseStr) {
|
|
|
+ if(responseStr.meta.success){
|
|
|
+ parent.layer.msg("导入成功",{icon:1});
|
|
|
+ parent.location.reload();
|
|
|
+ parent.layer.close(parent.layer.getFrameIndex(window.name));
|
|
|
+ }else{
|
|
|
+ parent.layer.msg(responseStr.meta.message,{icon:11});
|
|
|
+ $("#principalfile").val("");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ ,
|
|
|
+ error : function (responseStr) {
|
|
|
+ parent.layer.msg("导入失败,请刷新后重试!",{icon:11});
|
|
|
+ $("#principalfile").val("");
|
|
|
+ }
|
|
|
+ });
|
|
|
+}
|
|
|
</script>
|
|
|
|
|
|
</html>
|