Browse Source

提交代码。

Signed-off-by: zouap <zouap@pcl.ac.cn>
tags/v1.22.3.2^2
zouap 3 years ago
parent
commit
b9b70ce729
1 changed files with 5 additions and 5 deletions
  1. +5
    -5
      public/home/search.js

+ 5
- 5
public/home/search.js View File

@@ -692,10 +692,10 @@ function page(current){

function goPage(){
var inputpage = document.getElementById("inputpage")
var inputpage = document.getElementById("inputpage_div")
var left = inputpage.offsetLeft;
var top = inputpage.offsetTop;
var goNum = inputpage.value;
var goNum = $('#inputpage').val();
if (goNum<=0){
showTip("请输入大于0的数值。","warning",left+5,top);
}
@@ -710,8 +710,8 @@ function page(current){
function showTip(tip, type,left,top) {
var $tip = $('#tipmsg');
var tipmsg = document.getElementById("tipmsg")
console.log("left:" + left + ";top:" + top + ";position:relative")
tipmsg.style = "left:" + left + ";top:" + top + ";position:relative";
console.log("top:" + top + "px;left:" + left + "px;position:relative")
tipmsg.style = "top:" + top + "px;left:" + left + "px;position:relative"

$tip.stop(true).prop('class', 'alert alert-' + type).html(tip).fadeIn(500).delay(2000).fadeOut(500);
}
@@ -753,7 +753,7 @@ function page(current){
html += "<a class=\"item navigation\" href=\"javascript:page(" + totalPage + ")\"><span class=\"navigation_label\">末页</span></a>";
}

html +="<div class=\"item\"> 前往<div class=\"ui input\"><input id=\"inputpage\" type=\"text\"></div>页</div><div id=\"tipmsg\"></div>";
html +="<div class=\"item\"> 前往<div id=\"inputpage_div\" class=\"ui input\"><input id=\"inputpage\" type=\"text\"></div>页</div><div id=\"tipmsg\"></div>";
console.log("html=" + html)
document.getElementById("page_menu").innerHTML=html;
$('#inputpage').on('keypress',function(event){


Loading…
Cancel
Save