This commit is contained in:
2021-10-25 16:23:23 +08:00
parent 2bc9ea63c0
commit ad67333bbf
17 changed files with 202 additions and 218 deletions

View File

@@ -240,7 +240,7 @@ var render = function() {
4,
"t1-0",
_vm._s(
_vm.isAuth ? "能量球" + _vm.account.coin : "查看能量球"
_vm.isAuth ? "通证" + _vm.account.coin : "查看通证"
)
)
)
@@ -264,9 +264,7 @@ var render = function() {
6,
"t1-0",
_vm._s(
_vm.isAuth
? "能量碎片" + _vm.account.crystal
: "查看能量碎片"
_vm.isAuth ? "积分" + _vm.account.crystal : "查看积分"
)
)
)
@@ -2313,17 +2311,10 @@ var _default = { components: { lF2: _limeF.default }, data: function data() {ret
certification: false, company: false, vip: false } };}, onShow: function onShow() {this.isAuth = this.$store.state.token != '';this.getIndex();}, methods: { // 求助信息
showHelp: function showHelp(key) {uni.showModal({ title: '提示', content: this.help[key], showCancel: false, confirmColor: '#8b64fd' });}, // 查看钱包账户
navAccount: function navAccount(pathName) {__f__("log", 1111, " at pages/index/index.vue:178");if (!this.isAuth) {this.$Router.push({ name: 'Login' });return;}this.$Router.push({ name: pathName });}, // 发权证
issueGoosd: function issueGoosd() {var _this = this;var typeAuth = '',pathName = '';if (this.userAuth.certification && this.userAuth.company && this.userAuth.vip) {this.$Router.push({ name: 'goodsManagement' });return;} else if (!this.userAuth.certification) {typeAuth = '暂未完成个人认证,无法发布商品权证';pathName = 'Personal';} else if (!this.userAuth.vip) {typeAuth = '暂未开通平台VIP会员节点无法发布商品权证';pathName = 'vipIndex';} else if (!this.userAuth.company) {typeAuth = '企业未认证或企业认证审核中,无法发布商品权证';pathName = 'setting';}uni.showModal({ title: '提示', content: typeAuth, cancelColor: '#555', cancelText: '稍后', confirmText: pathName === 'vipIndex' ? '去开通' : '去认证', confirmColor: '#8b64fd', success: function success(res) {__f__("log", pathName, " at pages/index/index.vue:218");if (res.confirm) {// if (pathName === 'setting') {
// this.$Router.pushTab({
// name: pathName
// })
// return
// }
if (pathName === 'vipIndex') {__f__("log", _this.userAuth.identity, " at pages/index/index.vue:227");_this.$Router.push({ name: 'vipIndex', params: { identity_id: _this.userAuth.identity } });return;}_this.$Router.push({ name: pathName });}} });}, // 领取能量碎片
issueGoosd: function issueGoosd() {var _this = this;var typeAuth = '',pathName = '';if (this.userAuth.certification && this.userAuth.company && this.userAuth.vip) {this.$Router.push({ name: 'goodsManagement' });return;} else if (!this.userAuth.certification) {typeAuth = '暂未完成个人认证,无法发布商品权证';pathName = 'Personal';} else if (!this.userAuth.vip) {typeAuth = '暂未开通平台VIP会员节点无法发布商品权证';pathName = 'vipIndex';} else if (!this.userAuth.company) {typeAuth = '企业未认证或企业认证审核中,无法发布商品权证';pathName = 'setting';}uni.showModal({ title: '提示', content: typeAuth, cancelColor: '#555', cancelText: '稍后', confirmText: pathName === 'vipIndex' ? '去开通' : '去认证', confirmColor: '#8b64fd', success: function success(res) {if (res.confirm) {if (pathName === 'vipIndex') {__f__("log", _this.userAuth.identity, " at pages/index/index.vue:220");_this.$Router.push({ name: 'vipIndex', params: { identity_id: _this.userAuth.identity } });return;}_this.$Router.push({ name: pathName });}} });}, // 领取积分
ledCrystal: function ledCrystal(index) {var _this2 = this; // 播放音频
var innerAudioContext = uni.createInnerAudioContext();innerAudioContext.autoplay = true;innerAudioContext.src = __webpack_require__(/*! @/static/mp3/crystal.mp3 */ 43); // 请求接口
(0, _chain.thawlog)({ thaw_id: this.crystalArr[index].log_id, all_ids: this.allIds }).then(function (res) {uni.showToast({ image: __webpack_require__(/*! @/static/icons/crystal-icon.png */ 44), title: '+' + _this2.crystalArr[index].amount, duration: 2000 });_this2.$set(_this2.account, 'crystal', res.crystal);_this2.ids = res.all_ids;if (JSON.stringify(res.last) === '[]') {_this2.$set(_this2.crystalArr, index, { amount: null });return;}_this2.$set(_this2.crystalArr, index, res.last);}).catch(function (err) {uni.showToast({ icon: 'none',
title: err });
(0, _chain.thawlog)({ thaw_id: this.crystalArr[index].log_id, all_ids: this.allIds }).then(function (res) {uni.showToast({ image: __webpack_require__(/*! @/static/icons/crystal-icon.png */ 44), title: '+' + _this2.crystalArr[index].amount, duration: 2000 });_this2.$set(_this2.account, 'crystal', res.crystal);_this2.ids = res.all_ids;if (JSON.stringify(res.last) === '[]') {_this2.$set(_this2.crystalArr, index, { amount: null });return;}_this2.$set(_this2.crystalArr, index, res.last);}).catch(function (err) {uni.showToast({ icon: 'none', title: err });
});
},
@@ -7002,8 +6993,8 @@ var _default = { data: function data() {return { task: [], sign: { signArr: [],
(0, _crystal.task)().then(function (res) {uni.hideLoading();_this.task = res;}).catch(function (err) {uni.showToast({ icon: 'none', title: err.message });}); // 读取配置信息
(0, _user.userIndex)().then(function (res) {_this.energyShard = res.help_doc.energy_shard;}).catch(function (err) {uni.showToast({ title: err.message, icon: 'none' });}); // 获取水晶签到信息
this.signInfo();}, methods: { // 水晶签到信息
signInfo: function signInfo() {var _this2 = this;(0, _crystal.sign)().then(function (res) {_this2.sign.signArr = res.lists;_this2.sign.nextTask = res.next_task;_this2.sign.signCan = res.can_sign;}).catch(function (err) {uni.showToast({ icon: 'none', title: err });});}, // 能量碎片提示信息
showHelp: function showHelp() {uni.showModal({ title: '能量碎片', confirmColor: '#8b64fd', content: this.energyShard.description, showCancel: false });}, // 签到
signInfo: function signInfo() {var _this2 = this;(0, _crystal.sign)().then(function (res) {_this2.sign.signArr = res.lists;_this2.sign.nextTask = res.next_task;_this2.sign.signCan = res.can_sign;}).catch(function (err) {uni.showToast({ icon: 'none', title: err });});}, // 积分提示信息
showHelp: function showHelp() {uni.showModal({ title: '积分', confirmColor: '#8b64fd', content: this.energyShard.description, showCancel: false });}, // 签到
signClick: function signClick() {var _this3 = this;(0, _crystal.operateSign)().then(function (res) {_this3.sign.signSuccess = res.task_crystals; // 获取水晶签到信息
_this3.sign.signShow = true;_this3.signInfo();}).catch(function (err) {uni.showToast({ icon: 'none', title: err });});},
@@ -8867,9 +8858,9 @@ var _junyiH5Copy = _interopRequireDefault(__webpack_require__(/*! @/js_sdk/junyi
},
// 友情提示信息
showHelp: function showHelp(type) {
var title = '能量球',
var title = '通证',
content = this.helpDoc.energy_ball.description;
if (type == 'chip') title = '能量碎片';
if (type == 'chip') title = '积分';
if (type == 'chip') content = this.helpDoc.energy_shard.description;
uni.showModal({
title: title,
@@ -14634,7 +14625,7 @@ __webpack_require__.r(__webpack_exports__);
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });exports.default = void 0;
/* WEBPACK VAR INJECTION */(function(__f__) {Object.defineProperty(exports, "__esModule", { value: true });exports.default = void 0;
@@ -14886,6 +14877,7 @@ var _uploading = __webpack_require__(/*! @/apis/interfaces/uploading */ 97);func
type: 'app' }).
then(function (res) {
var payConfig = JSON.parse(res);
__f__("log", payConfig, 'console.log(res)', " at pages/vip/vip.vue:253");
uni.requestPayment({
provider: 'wxpay',
orderInfo: _objectSpread({}, payConfig),
@@ -14900,8 +14892,9 @@ var _uploading = __webpack_require__(/*! @/apis/interfaces/uploading */ 97);func
},
fail: function fail(payErr) {
__f__("log", payErr, 'console.log(payErr)', " at pages/vip/vip.vue:268");
uni.showToast({
title: '支付已被取消',
title: '支付失败,原因:' + payErr.errMsg,
icon: 'none' });
} });
@@ -14997,6 +14990,7 @@ var _uploading = __webpack_require__(/*! @/apis/interfaces/uploading */ 97);func
});
} } };exports.default = _default;
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/vue-cli-plugin-uni/lib/format-log.js */ 24)["default"]))
/***/ }),
/* 95 */
@@ -32727,9 +32721,7 @@ var render = function() {
"4-" + $30,
"t0-0",
_vm._s(
item.coin
? " (" + item.coin + "个能量球) "
: ""
item.coin ? " (" + item.coin + "个通证) " : ""
)
)
)
@@ -33187,7 +33179,7 @@ exports.cmsWithdraw = cmsWithdraw;var keyrules = function keyrules() {
};
// 能量球转红包前置,获取能量球的基本信息
// 通证转红包前置,获取通证的基本信息
exports.keyrules = keyrules;var accountCashs = function accountCashs(data) {
return (0, _index.request)({
url: 'user/account/cashs',
@@ -34243,12 +34235,12 @@ var _withdraws = __webpack_require__(/*! @/apis/interfaces/withdraws */ 292); //
//
//
//
var _default = { data: function data() {return { balance: 0, // 钱包能量球数量
var _default = { data: function data() {return { balance: 0, // 钱包通证数量
tax: 0, // 当前手续费
cost: 1, // 每个能量球的价格
cost: 1, // 每个通证的价格
total: 0, // 约合人民币
card: '', // 银行卡号
withdraw_input: '', // 提现能量球数量
withdraw_input: '', // 提现通证数量
bank_accounts: 0, bankInfo: {} };}, onLoad: function onLoad() {this.getInfo();}, onShow: function onShow() {if (uni.getStorageSync('refresh')) {this.bankInfo = {};this.getInfo();}}, methods: { // 提现基本信息
getInfo: function getInfo() {var _this = this;(0, _withdraws.cashsCreate)().then(function (res) {_this.withdraw_input = Number(res.balance);_this.balance = res.balance;_this.cost = res.cost;_this.total = Number(res.balance) * Number(res.cost);uni.setStorageSync('refresh', false);}).catch(function (err) {
uni.showToast({
@@ -34257,7 +34249,7 @@ var _default = { data: function data() {return { balance: 0, // 钱包能量球
});
},
// 输入提现能量球数量
// 输入提现通证数量
inputNum: function inputNum(e) {
var number = Number(e.detail.value);
if (number <= Number(this.balance)) {
@@ -34304,7 +34296,7 @@ var _default = { data: function data() {return { balance: 0, // 钱包能量球
if (data.amount === 0) {
uni.showToast({
title: '请输入能量球数量',
title: '请输入通证数量',
icon: 'none' });
return;
@@ -34444,7 +34436,7 @@ exports.withdrawsIndex = withdrawsIndex;var withdrawsIndexLists = function withd
};
// 能量碎片记录
// 积分记录
exports.withdrawsIndexLists = withdrawsIndexLists;var userAccoutScores = function userAccoutScores(data) {
return (0, _index.request)({
url: 'user/account/scores',
@@ -34453,7 +34445,7 @@ exports.withdrawsIndexLists = withdrawsIndexLists;var userAccoutScores = functio
};
// 能量球转红包前置
// 通证转红包前置
exports.userAccoutScores = userAccoutScores;var cashsCreate = function cashsCreate() {
return (0, _index.request)({
url: 'user/account/cashs/create',
@@ -34461,7 +34453,7 @@ exports.userAccoutScores = userAccoutScores;var cashsCreate = function cashsCrea
};
// 能量球转红包
// 通证转红包
exports.cashsCreate = cashsCreate;var accountCashs = function accountCashs(data) {
return (0, _index.request)({
url: 'user/account/cashs',
@@ -34837,14 +34829,14 @@ var _withdraws = __webpack_require__(/*! @/apis/interfaces/withdraws */ 292); //
//
//
//
var _default = { data: function data() {return { balance: 0, // 钱包能量球金额
var _default = { data: function data() {return { balance: 0, // 钱包通证金额
tax: 0, // 当前手续费
cost: 1, // 每个能量球的价格
cost: 1, // 每个通证的价格
total: 0, // 约合人民币
card: '', // 银行卡号
withdraw_input: '', // 提现能量球金额
withdraw_input: '', // 提现通证金额
bank_accounts: 0, bankInfo: {} };}, onLoad: function onLoad() {this.getInfo();}, onShow: function onShow() {if (uni.getStorageSync('refresh')) {this.bankInfo = {};this.getInfo();}}, methods: { // 提现基本信息
getInfo: function getInfo() {var _this = this;(0, _withdraws.withdrawsIndexCreate)().then(function (res) {_this.balance = res.balance;_this.tax = res.tax;_this.cost = res.cost;_this.bank_accounts = res.bank_accounts.length;_this.withdraw_input = Number(res.balance);_this.total = Number(res.balance) * Number(res.cost);uni.setStorageSync('refresh', false);}).catch(function (err) {uni.showToast({ title: err.message, icon: 'none' });});}, // 输入提现能量球金额
getInfo: function getInfo() {var _this = this;(0, _withdraws.withdrawsIndexCreate)().then(function (res) {_this.balance = res.balance;_this.tax = res.tax;_this.cost = res.cost;_this.bank_accounts = res.bank_accounts.length;_this.withdraw_input = Number(res.balance);_this.total = Number(res.balance) * Number(res.cost);uni.setStorageSync('refresh', false);}).catch(function (err) {uni.showToast({ title: err.message, icon: 'none' });});}, // 输入提现通证金额
inputNum: function inputNum(e) {var number = Number(e.detail.value);
__f__("log", number, this.balance, " at pages/wallet/extractRed.vue:87");
if (number <= Number(this.balance)) {
@@ -34902,7 +34894,7 @@ var _default = { data: function data() {return { balance: 0, // 钱包能量球
}
if (data.amount === 0) {
uni.showToast({
title: '请输入能量球金额',
title: '请输入通证金额',
icon: 'none' });
return;