Initial import: H5 front-end and houtai backend (exclude secrets and uploads).
Made-with: Cursor
This commit is contained in:
411
h5/static/js/pages-sub-pages-promote-prize-index.710193f9.readable.js
Executable file
411
h5/static/js/pages-sub-pages-promote-prize-index.710193f9.readable.js
Executable file
@@ -0,0 +1,411 @@
|
||||
// ============================================
|
||||
// 反编译后的可读版本
|
||||
// 原文件: pages-sub-pages-promote-prize-index.710193f9.js
|
||||
// 页面: 推广奖金明细页
|
||||
// ============================================
|
||||
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([
|
||||
["pages-sub-pages-promote-prize-index"],
|
||||
{
|
||||
// ==================== 模块 04d0: 页面逻辑 ====================
|
||||
"04d0": function(module, exports, require) {
|
||||
"use strict";
|
||||
require("6a54");
|
||||
var asyncToGenerator = require("f5bd").default;
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.default = void 0;
|
||||
|
||||
var regeneratorRuntime = asyncToGenerator(require("2634"));
|
||||
var _asyncToGenerator = asyncToGenerator(require("2fdc"));
|
||||
|
||||
// Vue组件配置对象
|
||||
var component = {
|
||||
// 数据
|
||||
data: function() {
|
||||
return {
|
||||
current: 0, // 当前选中的标签索引
|
||||
cateList: [
|
||||
{ id: 1, name: "收入明细" },
|
||||
{ id: 2, name: "支出明细" }
|
||||
],
|
||||
dataList: [], // 数据列表
|
||||
userinfo: {
|
||||
share_bonus: 0, // 推广奖金
|
||||
today_share: 0 // 今日推广奖金
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
// 页面显示时触发
|
||||
onShow: function() {
|
||||
var self = this;
|
||||
this.getUser();
|
||||
this.$nextTick((function() {
|
||||
return self.$refs.paging.reload();
|
||||
}))
|
||||
},
|
||||
|
||||
// 页面加载时触发
|
||||
onLoad: function() {
|
||||
// 空方法
|
||||
},
|
||||
|
||||
// 方法
|
||||
methods: {
|
||||
// 获取用户信息
|
||||
getUser: function() {
|
||||
var self = this;
|
||||
return (0, _asyncToGenerator.default)(
|
||||
(0, regeneratorRuntime.default)().mark((function asyncFunc() {
|
||||
var response;
|
||||
return (0, regeneratorRuntime.default)().wrap((function(context) {
|
||||
while (1) {
|
||||
switch (context.prev = context.next) {
|
||||
case 0:
|
||||
// 调用API获取用户信息
|
||||
return context.next = 2, self.$api.user();
|
||||
|
||||
case 2:
|
||||
response = context.sent;
|
||||
// 如果返回成功,更新用户信息
|
||||
if (0 == response.code) {
|
||||
self.userinfo = response.data;
|
||||
}
|
||||
|
||||
case 4:
|
||||
case "end":
|
||||
return context.stop();
|
||||
}
|
||||
}
|
||||
}), asyncFunc);
|
||||
}))
|
||||
)();
|
||||
},
|
||||
|
||||
// 获取资金记录
|
||||
getMoneyLog: function(page, limit) {
|
||||
var self = this;
|
||||
return (0, _asyncToGenerator.default)(
|
||||
(0, regeneratorRuntime.default)().mark((function asyncFunc() {
|
||||
var currentCate, params, response, responseData;
|
||||
return (0, regeneratorRuntime.default)().wrap((function(context) {
|
||||
while (1) {
|
||||
switch (context.prev = context.next) {
|
||||
case 0:
|
||||
// 构建请求参数
|
||||
params = {
|
||||
cate: 4, // 推广奖金类型
|
||||
type: null === (currentCate = self.cateList[self.current]) ||
|
||||
void 0 === currentCate ? void 0 : currentCate.id,
|
||||
page: page,
|
||||
limit: limit,
|
||||
loading: true
|
||||
};
|
||||
|
||||
// 调用API
|
||||
return context.next = 3, self.$api.moneyLog(params);
|
||||
|
||||
case 3:
|
||||
response = context.sent;
|
||||
// 如果成功,完成分页加载
|
||||
if (0 == response.code) {
|
||||
self.$refs.paging.complete(
|
||||
null === (responseData = response.data) ||
|
||||
void 0 === responseData ? void 0 : responseData.list
|
||||
);
|
||||
}
|
||||
|
||||
case 5:
|
||||
case "end":
|
||||
return context.stop();
|
||||
}
|
||||
}
|
||||
}), asyncFunc);
|
||||
}))
|
||||
)();
|
||||
},
|
||||
|
||||
// 切换标签
|
||||
changeTab: function(index) {
|
||||
this.current = index;
|
||||
this.$refs.paging.reload();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
exports.default = component;
|
||||
},
|
||||
|
||||
// ==================== 模块 1b9a: 主导出 ====================
|
||||
"1b9a": function(module, exports, require) {
|
||||
"use strict";
|
||||
require.r(exports);
|
||||
|
||||
var render = require("568c");
|
||||
var script = require("3e7e");
|
||||
|
||||
// 合并模块
|
||||
for (var key in script) {
|
||||
if (["default"].indexOf(key) < 0) {
|
||||
(function(k) {
|
||||
require.d(exports, k, (function() {
|
||||
return script[k];
|
||||
}));
|
||||
})(key);
|
||||
}
|
||||
}
|
||||
|
||||
require("c153"); // 样式
|
||||
|
||||
var componentNormalizer = require("828b");
|
||||
var component = Object(componentNormalizer["a"])(
|
||||
script["default"],
|
||||
render["b"],
|
||||
render["c"],
|
||||
false,
|
||||
null,
|
||||
"6dabb4ce",
|
||||
null,
|
||||
false,
|
||||
render["a"],
|
||||
void 0
|
||||
);
|
||||
|
||||
exports["default"] = component.exports;
|
||||
},
|
||||
|
||||
// ==================== 模块 3e7e: 脚本导出 ====================
|
||||
"3e7e": function(module, exports, require) {
|
||||
"use strict";
|
||||
require.r(exports);
|
||||
|
||||
var component = require("04d0");
|
||||
var componentDefault = require.n(component);
|
||||
|
||||
for (var key in component) {
|
||||
if (["default"].indexOf(key) < 0) {
|
||||
(function(k) {
|
||||
require.d(exports, k, (function() {
|
||||
return component[k];
|
||||
}));
|
||||
})(key);
|
||||
}
|
||||
}
|
||||
|
||||
exports["default"] = componentDefault.a;
|
||||
},
|
||||
|
||||
// ==================== 模块 568c: 渲染函数 ====================
|
||||
"568c": function(module, exports, require) {
|
||||
"use strict";
|
||||
|
||||
// 导出渲染函数
|
||||
require.d(exports, "b", (function() {
|
||||
return render;
|
||||
}));
|
||||
|
||||
require.d(exports, "c", (function() {
|
||||
return staticRenderFns;
|
||||
}));
|
||||
|
||||
require.d(exports, "a", (function() {
|
||||
return components;
|
||||
}));
|
||||
|
||||
// 组件依赖
|
||||
var components = {
|
||||
zPaging: require("a943").default,
|
||||
uTabs: require("2a38").default
|
||||
};
|
||||
|
||||
// 主渲染函数
|
||||
var render = function() {
|
||||
var vm = this;
|
||||
var createElement = vm.$createElement;
|
||||
var createVNode = vm._self._c || createElement;
|
||||
|
||||
return createVNode("z-paging", {
|
||||
ref: "paging",
|
||||
attrs: {
|
||||
auto: false,
|
||||
"auto-scroll-to-top-when-reload": false,
|
||||
"auto-clean-list-when-reload": false
|
||||
},
|
||||
on: {
|
||||
query: function(event) {
|
||||
arguments[0] = event = vm.$handleEvent(event);
|
||||
vm.getMoneyLog.apply(void 0, arguments);
|
||||
}
|
||||
},
|
||||
scopedSlots: vm._u([{
|
||||
key: "top",
|
||||
fn: function() {
|
||||
return [
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "b-bg-white "
|
||||
}, [
|
||||
// 显示推广奖金总额
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "b-text-48 b-text-c u-p-tb-30 b-text-B-d"
|
||||
}, [vm._v(vm._s(vm.userinfo.share_bonus))]),
|
||||
|
||||
// 今日推广和提现按钮区域
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "u-p-b-50 u-p-lr-20 b-flex-x b-flex-wrap b-flex-space b-text-30"
|
||||
}, [
|
||||
createVNode("v-uni-view", {}, [
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "u-p-b-10"
|
||||
}, [vm._v("当天推广奖金:" + vm._s(vm.userinfo.today_share))]),
|
||||
|
||||
createVNode("v-uni-view", {}, [
|
||||
vm._v("全部推广奖金:" + vm._s(vm.userinfo.total_share))
|
||||
])
|
||||
], 1),
|
||||
|
||||
// 提现按钮
|
||||
createVNode("v-uni-button", {
|
||||
staticClass: "b-btn b-btn-round withdraw-btn ",
|
||||
on: {
|
||||
click: function(event) {
|
||||
arguments[0] = event = vm.$handleEvent(event);
|
||||
vm.toPage("/pages/sub-pages/withdraw/index", {
|
||||
cate: 4
|
||||
});
|
||||
}
|
||||
}
|
||||
}, [vm._v("提现")])
|
||||
], 1),
|
||||
|
||||
// 标签切换
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "b-bg-white"
|
||||
}, [
|
||||
createVNode("u-tabs", {
|
||||
attrs: {
|
||||
list: vm.cateList,
|
||||
"is-scroll": false,
|
||||
current: vm.current,
|
||||
"active-color": "#333333",
|
||||
"inactive-color": "#666666",
|
||||
"bg-color": "transparent",
|
||||
"bar-style": {
|
||||
background: "#ea6254"
|
||||
},
|
||||
"bar-width": "80"
|
||||
},
|
||||
on: {
|
||||
change: function(event) {
|
||||
arguments[0] = event = vm.$handleEvent(event);
|
||||
vm.changeTab.apply(void 0, arguments);
|
||||
}
|
||||
}
|
||||
})
|
||||
], 1)
|
||||
], 1)
|
||||
];
|
||||
},
|
||||
proxy: true
|
||||
}]),
|
||||
model: {
|
||||
value: vm.dataList,
|
||||
callback: function(value) {
|
||||
vm.dataList = value;
|
||||
},
|
||||
expression: "dataList"
|
||||
}
|
||||
}, [
|
||||
// 列表内容
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "u-p-lr-10 u-p-t-20"
|
||||
}, vm._l(vm.dataList, (function(item, index) {
|
||||
return createVNode("v-uni-view", {
|
||||
key: index,
|
||||
staticClass: "b-flex-x b-flex-space u-p-20 card-box u-m-b-20"
|
||||
}, [
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "b-flex-x"
|
||||
}, [
|
||||
createVNode("v-uni-view", {}, [
|
||||
// 备注
|
||||
createVNode("v-uni-view", {
|
||||
staticClass: "u-m-b-10 b-text-32"
|
||||
}, [vm._v(vm._s(item.memo))]),
|
||||
|
||||
// 时间
|
||||
createVNode("v-uni-text", {
|
||||
staticClass: "b-text-black-dd"
|
||||
}, [vm._v(vm._s(item.created_at))])
|
||||
], 1)
|
||||
], 1),
|
||||
|
||||
// 金额(根据类型显示不同颜色)
|
||||
createVNode("v-uni-text", {
|
||||
class: [{
|
||||
"b-text-green": 0 == vm.current
|
||||
}, {
|
||||
"b-text-red": 1 == vm.current
|
||||
}]
|
||||
}, [
|
||||
vm._v(vm._s(0 == vm.current ? "+" + item.money : item.money))
|
||||
])
|
||||
], 1);
|
||||
})), 1)
|
||||
], 1);
|
||||
};
|
||||
|
||||
// 静态渲染函数
|
||||
var staticRenderFns = [];
|
||||
},
|
||||
|
||||
// ==================== 模块 c153: 样式导入 ====================
|
||||
"c153": function(module, exports, require) {
|
||||
"use strict";
|
||||
var style = require("d893");
|
||||
var styleDefault = require.n(style);
|
||||
styleDefault.a;
|
||||
},
|
||||
|
||||
// ==================== 模块 d893: 样式加载器 ====================
|
||||
"d893": function(module, exports, require) {
|
||||
var cssLoader = require("e156");
|
||||
cssLoader.__esModule && (cssLoader = cssLoader.default);
|
||||
|
||||
if ("string" === typeof cssLoader) {
|
||||
cssLoader = [[module.i, cssLoader, ""]];
|
||||
}
|
||||
|
||||
cssLoader.locals && (module.exports = cssLoader.locals);
|
||||
|
||||
var addStylesClient = require("967d").default;
|
||||
addStylesClient("197d05df", cssLoader, true, {
|
||||
sourceMap: false,
|
||||
shadowMode: false
|
||||
});
|
||||
},
|
||||
|
||||
// ==================== 模块 e156: CSS内容 ====================
|
||||
"e156": function(module, exports, require) {
|
||||
var api = require("c86c");
|
||||
exports = api(false);
|
||||
|
||||
exports.push([
|
||||
module.i,
|
||||
'@charset "UTF-8";' +
|
||||
'/* 提现按钮样式 */' +
|
||||
'.withdraw-btn[data-v-6dabb4ce]{' +
|
||||
'background:#ea6254;' +
|
||||
'color:#fff;' +
|
||||
'min-width:%?160?%;' +
|
||||
'height:%?60?%' +
|
||||
'}',
|
||||
""
|
||||
]);
|
||||
|
||||
module.exports = exports;
|
||||
}
|
||||
}
|
||||
]);
|
||||
Reference in New Issue
Block a user