module/flk/themes/index/flk_cart/index.js
(开头部分) 1KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
var app = new Vue({
el: "#app",
data: function() {
return {
pageData: {},
pageLoad:false,
}
},
created: function() {
this.getPage();
$("#app").show();
},
methods: {
getPage: function() {
var that = this;
$.ajax({
url: "/module.php?m=flk_cart&ajax=1",
dataType: "json",
success: function(res) {
if(res.error){
skyToast(res.message);
return false;
}
that.pageLoad=true;
that.pageData = res.data;
}
})
},
plusCart: function(id, amount, ksid) {
var that = this;
var productid = id;
var amount = amount;
var ksid = ksid == undefined ? 0 : ksid;
amount++;
$.ajax({
url: '/module.php?m=flk_cart&a=add&ajax=1',
data: {
productid: productid,
amount: amount,
ksid: ksid
},
method: 'GET',
dataType: "json",
success: function(res) {
if(res.error){
skyToast(res.message)
}
that.getPage();
}
})
},
minusCart: function(id, amount, ksid) {
var that = this;
var productid = id;
var amount = amount;
var ksid = ksid == undefined ? 0 : ksid;
amount--;
var isdelete = 0;
if (amount == 0) {
后面还有 24 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。