themes/pc/home/index.js

(开头部分) 1KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

var App=new Vue({
	el:"#App",
	data:function(){
		return {
			list:[],
			pageLoad:false,
			user:{}
			 
		}
	},
	created:function(){
		this.getPage();
		this.getAsk();
	},
	watch:{
		pageLoad:function(n,o){
			console.log(n,o)
		}
	},
	methods:{
		goPm:function(userid){
			window.location="/index.php?m=pm&a=detail&userid="+userid;
			 
		},  
		goBlog:function(askid){
			window.location="/module.php?m=ask&a=show&askid="+askid;
		},
		getPage:function(){
			var that=this;
			
			$.ajax({
				url:"/index.php?m=home&ajax=1",
				data:{
					userid:userid
				},
				dataType:"json",
				success:function(res){
					console.log(that.pageLoad);
					that.user=res.data.user;
					that.pageLoad=true;
				}
			})
		},
		getAsk:function(){
			var that=this;
			
			$.ajax({
				url:"/module.php?m=ask&a=user&ajax=1",
				data:{
					userid:userid
				},
				dataType:"json",
				success:function(res){
					that.list=res.data.list;
				}
			})
		},
		toggleFollow:function(item){
			var that=this;
			$.ajax({
后面还有 17 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。