瀏覽代碼

Merge remote-tracking branch 'origin/dev' into adjust-1225

hangb 8 年之前
父節點
當前提交
6c26f12668

+ 27 - 0
jpress-web-admin/src/main/webapp/WEB-INF/admin/content/_edit_include.html

@@ -277,9 +277,33 @@
 		width: 930px;
 		height: 30px;
 	}
+
+	/*loading  block*/
+	#loading {
+		display: none;
+		position: fixed;
+		width: 100%;
+		height: 100%;
+		top: 0;
+		left: 0;
+		z-index: 1000;
+	}
+
+	#loading>i {
+		position: absolute;
+		top: 50%;
+		left: 50%;
+		margin: -33px 0 0 -33px;
+		background: url("${CPATH}/static/jpress/admin/image/loading.gif") no-repeat center center;
+		width: 66px;
+		height: 66px;
+	}
 </style>
 
 <#if module ?? && module.name=="uuhelper">
+	<!-- loading start -->
+	<div id="loading"><i></i></div>
+	<!-- loading end -->
 	<!-- 软文发布界面 -->
     <section class="content-header">
         <h1>${(module.addTitle)!}</h1>
@@ -425,6 +449,9 @@
         </form>
     </section>
 <#else>
+	<!-- loading start -->
+	<div id="loading"><i></i></div>
+	<!-- loading end -->
 	<section class="content-header">
 		<h1>${(module.addTitle)!}</h1>
 	</section>

+ 4 - 1
jpress-web-admin/src/main/webapp/WEB-INF/admin/content/edit.html

@@ -146,11 +146,13 @@ function turnPage(turnpage){
  }
  
  function doSubmit(turnpage){
+	$('#loading').css('display','block');
+
  	$("#form").ajaxSubmit({
 			type : "post", 
 			dataType : "json", 
 			success : function(data) {
-
+				$('#loading').css('display','none');
 				if(data.errorCode == 0){
 					$("#content_id").attr("value",data.data);
 					toastr.success('保存成功!','操作成功');
@@ -167,6 +169,7 @@ function turnPage(turnpage){
 				}
 			},
 			error : function() {
+				$('#loading').css('display','none');
 				alert("检查网络连接情况是否正常或标题是否重复");
 			}
 	});

二進制
jpress-web-core/src/main/webapp/static/jpress/admin/image/loading.gif