wangshan пре 8 година
родитељ
комит
71b3bc0d4e
1 измењених фајлова са 89 додато и 11 уклоњено
  1. 89 11
      src/web/templates/weixin/wxpush.html

+ 89 - 11
src/web/templates/weixin/wxpush.html

@@ -43,6 +43,10 @@ $(function(){
 	var tabletype = ""
 	var tableptname = ""
 	var tableagency = ""
+	var budget = ""
+	var bidopentime = ""
+	var winner = ""
+	var bidamount = ""
 	if(bmatch){
 		$(".findnull").hide();
 	}else{
@@ -59,6 +63,10 @@ $(function(){
 			projectname[i]=o_pushinfo[i]["projectname"];
 			projectid[i]=o_pushinfo[i]["projectid"];
 			agency[i]=o_pushinfo[i]["agency"];
+			budget[i]=o_pushinfo[i]["budget"];
+			bidopentime[i]=o_pushinfo[i]["bidopentime"];
+			winner[i]=o_pushinfo[i]["winner"];
+			bidamount[i]=o_pushinfo[i]["bidamount"];
 		}
 	}
 	if(typeof(s_words) != "undefined" && s_words.length > 0){
@@ -97,6 +105,10 @@ $(function(){
 					'<td>公告类型</td>'+
 					'<td>招标单位</td>'+
 					'<td>项目名称</td>'+
+					'<td>预算<br>(万元)</td>'+
+					'<td>开标时间</td>'+
+					'<td>中标单位</td>'+
+					'<td>中标金额<br>(万元)</td>'+
 					'</tr>'+
 					'</thead>'+
 					'<tbody>';
@@ -183,8 +195,48 @@ $(function(){
 					'<td>'+tabletime+'</td>'+
 					'<td>'+tabletype+'公告</td>'+
 					'<td>'+tableagency+'</td>'+
-					'<td>'+tableptname+'</td>'+
-					'</tr>'
+					'<td>'+tableptname+'</td>'
+					
+		
+		if(typeof(budget[xh]) != "undefined" && budget[xh] != null && budget[xh] != ""){
+			var budgetone =parseInt(budget[xh])/10000
+			if(budgetone.toString().length>6){
+				if(budgetone.toString().indexOf(".")==5){
+					budgetone=budgetone.toString().substr(0,7)
+				}else{
+					budgetone=budgetone.toString().substr(0,6)
+				}
+			}
+			tablehtml += '<td>'+budgetone+'</td>';
+		}else{
+			tablehtml += '<td></td>';
+		}
+		
+		if(typeof(bidopentime[xh]) != "undefined" && bidopentime[xh] != null && bidopentime[xh] != ""){
+			var diff = formatDate(Number(bidopentime[xh]),"l");
+			tablehtml += '<td><div>'+diff+'</div></td>';
+		}else{
+			tablehtml += '<td><div></div></td>';
+		}
+		if(typeof(winner[xh]) != "undefined" && winner[xh] != null && winner[xh] != ""){
+			tablehtml += '<td class="tt-l"><div>'+winner[xh]+'</div></td>';
+		}else{
+			tablehtml += '<td class="tt-l"><div></div></td>';
+		}
+		if(typeof(bidamount[xh]) != "undefined" && bidamount[xh] != null && bidamount[xh] != ""){
+			var bidamountone = parseInt(bidamount[xh])/10000
+			if(bidamountone.toString().length>6){
+				if(bidamountone.toString().indexOf(".")==5){
+					bidamountone=bidamountone.toString().substr(0,7)
+				}else{
+					bidamountone=bidamountone.toString().substr(0,6)
+				}
+			}
+			tablehtml += '<td class="tt-r"><div>'+bidamountone+'</div></td>';
+		}else{
+			tablehtml += '<td class="tt-r"><div></div></td>';
+		}
+		tablehtml +='</tr>'
 	});
 	tablehtml +='</tbody></table>';
 	$("#jytables").append(tablehtml);
@@ -233,20 +285,33 @@ function tablejump(eid,href){
 		newredirect(zbadd,href,eid,sds);
 	}
 }
+
 //
-function   formatDate(date)   { 
+function formatDate(date,sl)   { 
 	var myDate = new Date(date*1000);      
     var   year=myDate.getFullYear();
-    var   month=myDate.getMonth()+1;    
-	if(month<10){
+    var   month=myDate.getMonth()+1; 
+	if(month<10&&sl!="1"){
 		month="0"+month
 	} 
     var   date=myDate.getDate();      
-	if(date<10){
+	if(date<10&&sl!="1"){
 		date="0"+date
 	} 
-    return   year+" "+month+""+date;     
-} 
+	var hour = myDate.getHours()
+	var min = myDate.getMinutes()
+	if(sl=="l"){
+		if(hour<10){
+			hour="0"+hour
+		} 
+		if(min<10){
+			min="0"+min
+		} 
+		return   year+"-"+month+"-"+date+"<br>"+hour+":"+min; 
+	}else{
+		return   year+"<br>"+month+""+date; 
+	}
+}
 //
 function open_window(link){
 	if(!/^http/.test(link)){
@@ -371,6 +436,7 @@ a{
 #jytables{
 	/*不需要可自己删除*/
 	padding: .2rem;
+	width:880px;
 }
 #jytables table{
 	width: 100%;
@@ -400,9 +466,6 @@ a{
 	width: 100%;
     overflow-x: scroll;
 }
-#jytables{
-	width: 525px;
-}
 #jytables thead>tr>td:nth-child(1){
 	padding:.3rem 0;
 	width:30px;
@@ -432,6 +495,21 @@ a{
 .blue{
 	color:#0987ff;
 }
+#jytables tbody>tr>td:nth-child(6){
+	width:70px;
+}
+#jytables tbody>tr>td:nth-child(7){
+	width:85px;
+}
+#jytables tbody>tr>td:nth-child(8) div{
+	width:110px;
+}
+#jytables tbody>tr>td:nth-child(8){
+	width:110px;
+}
+#jytables tbody>tr>td:nth-child(9){
+	width:72px;
+}
 </style>
 </head>