dengzhiguo 7 years ago
parent
commit
702153b3dd
2 changed files with 58 additions and 58 deletions
  1. 7 7
      src/js/index.js
  2. 51 51
      src/js/thinkTank/thinkerDetail.js

+ 7 - 7
src/js/index.js

@@ -7,22 +7,22 @@ import './main_banner.js';
 
 $(function(){
 	var k=0;
-	var liwit=$('.need_imgs ul li').width();
-	var lilengths=$('.need_imgs ul li').length;
-	$('.need_next').click(function(){
+	var liwit=$('.index_cont div').width();
+	var lilengths=$('.index_cont>div').length;
+	$('.man_left').click(function(){
 		k++;
 		if(k>lilengths-3){							
 			k=lilengths-3
-		}				
-		$('.need_imgs ul').animate({'marginLeft':-(liwit+20)*k},500)	
+		}	
+		$('.index_cont').animate({'marginLeft':-(liwit+63)*k},500)	
 			
 	});
-	$('.need_prev').click(function(){
+	$('.man_right').click(function(){
 		k--;
 		if(k<0){
 			k=0
 		}
-		$('.need_imgs ul').animate({'marginLeft':-(liwit+20)*k},500)
+		$('.index_cont').animate({'marginLeft':-(liwit+63)*k},500)
 	});
 	//精品成果鼠标经过效果
 	$('.content .cont').hover(function(){

+ 51 - 51
src/js/thinkTank/thinkerDetail.js

@@ -86,55 +86,55 @@ $(function () {
         }
 
     });
-    $(".achieve_cont>a>div>span").click(function(){
-		var biaozhi=$(this).attr("val");
-		if(!biaozhi){
-			var p_width=$(this).siblings("p").height();
-			$(this).addClass("active").attr("val","yes").parent().animate({"height":p_width},500);
-		}else if(biaozhi=="yes"){
-			$(this).removeClass("active").attr("val","").parent().animate({"height":45},500);
-		}
-	});
-	//点击感兴趣
-    var t=0;
-    $('.basic .loves').click(function(){
-        var theId=$("#demand_id").attr("val");
-        var islogin=$("#isLogin").attr("islogin");
-        if(islogin=="true"){
-            $(".head_login").click();
-        }
-    	if($(this).find('span:first-child').hasClass('box_love')&&islogin=="false"){
-    		t=$('.dem_number').text();            		
-    	    $('.dem_number').text(parseInt(t)+1);
-    	    $(this).find('span:first-child').addClass('bj_love').removeClass('box_love');
-            $.ajax({
-                method: "post",
-                dataType: "json",
-                url: globalConfig.context + "/api/user/portal/demandInterest",
-                data: {
-                    id:theId
-                },
-                success: function (data) {
-
-                }
-            });
-    	    return false;
-    	}   	    	
-    	if($(this).find('span:first-child').hasClass('bj_love')&&islogin=="false"){
-    		t=$('.dem_number').text();         		
-    	    $('.dem_number').text(parseInt(t)-1)
-    	    $(this).find('span:first-child').addClass('box_love').removeClass('bj_love')
-            $.ajax({
-                method: "post",
-                dataType: "json",
-                url: globalConfig.context + "/api/user/portal/demandCancelInterest",
-                data: {
-                    id:theId
-                },
-                success: function (data) {
-
-                }
-            });
-    	}    	   	
-    })
+//  $(".achieve_cont>a>div>span").click(function(){
+//		var biaozhi=$(this).attr("val");
+//		if(!biaozhi){
+//			var p_width=$(this).siblings("p").height();
+//			$(this).addClass("active").attr("val","yes").parent().animate({"height":p_width},500);
+//		}else if(biaozhi=="yes"){
+//			$(this).removeClass("active").attr("val","").parent().animate({"height":45},500);
+//		}
+//	});
+//	//点击感兴趣
+//  var t=0;
+//  $('.basic .loves').click(function(){
+//      var theId=$("#demand_id").attr("val");
+//      var islogin=$("#isLogin").attr("islogin");
+//      if(islogin=="true"){
+//          $(".head_login").click();
+//      }
+//  	if($(this).find('span:first-child').hasClass('box_love')&&islogin=="false"){
+//  		t=$('.dem_number').text();            		
+//  	    $('.dem_number').text(parseInt(t)+1);
+//  	    $(this).find('span:first-child').addClass('bj_love').removeClass('box_love');
+//          $.ajax({
+//              method: "post",
+//              dataType: "json",
+//              url: globalConfig.context + "/api/user/portal/demandInterest",
+//              data: {
+//                  id:theId
+//              },
+//              success: function (data) {
+//
+//              }
+//          });
+//  	    return false;
+//  	}   	    	
+//  	if($(this).find('span:first-child').hasClass('bj_love')&&islogin=="false"){
+//  		t=$('.dem_number').text();         		
+//  	    $('.dem_number').text(parseInt(t)-1)
+//  	    $(this).find('span:first-child').addClass('box_love').removeClass('bj_love')
+//          $.ajax({
+//              method: "post",
+//              dataType: "json",
+//              url: globalConfig.context + "/api/user/portal/demandCancelInterest",
+//              data: {
+//                  id:theId
+//              },
+//              success: function (data) {
+//
+//              }
+//          });
+//  	}    	   	
+//  })
 })