module/household/themes/index/household_product/list.js

(开头部分) 1KB

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

var App=new Vue({
		el:"#App",
		data:function(){
			return {
				catid:0,
				pageLoad:false,
				catList:[],
				list:[],
				pageCatid:0,
				per_page:0,
				isFirst:0,
				orderby:""
			}
		},
		created:function(ops){
			this.catid=catid
			this.getPage();
		},
		onReachBottom:function(){
			this.getList();
		},
		methods:{
			setCat:function(catid){
				this.catid=catid;
				this.isFirst=true;
				this.per_page=0;
				this.getList();
			},
			setOrder:function(o){
				this.orderby=o;
				this.isFirst=true;
				this.per_page=0;
				this.getList();
			},
			goProduct:function(id){
				window.location="/module.php?m=household_product&a=show&id="+id;
				 
			},
			getPage:function(){
				var that=this;
				$.ajax({
					url:"/module.php?m=household_product&a=list&ajax=1",
					dataType:"json",
					data:{
						orderby:this.orderby,
						catid:that.catid
					},
					success:function(res){					
						that.per_page=res.data.per_page;
						that.list=res.data.list;
						that.catList=res.data.catList;
						that.isFirst=false;
						that.pageLoad=true;
						if(that.pageCatid==0){
							that.pageCatid=res.data.cat.catid;
						}						
						 
					}
				})
			},
后面还有 29 行代码,购买后查看完整代码

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

AI 解读

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

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