Commit d655033c authored by Damon's avatar Damon
parents 54d3979d 4be9741b
......@@ -11,11 +11,6 @@ export default {
// 微信小程序平台编号,空--家维广场,1--自营平台
wxAppNo: 1,
//授权提示 图标
icon_auth_notice: "https://qn-static.banshouhui.com/auth_notice.png",
//授权提示新 图标
icon_auth_notice_new:
"https://qn-static.banshouhui.com/auth_notice_new.png",
// 服务规范教程视频
service_standard: {
course1: {
......@@ -47,8 +42,6 @@ export default {
// 授权用户信息
authUserInfo: "",
// 用户入驻信息
settledInfo: {},
navHeight: 0, //导航栏高度
rpxScreenHeight: 0, // 照相视框高度
safeHeight: 0, // 安全高度
......@@ -81,7 +74,7 @@ export default {
// 版本更新
await this.updateApp();
// 系统自动登录
// 系统自动登录::每次运行小程序重新获取用户信息
await this.autoLogin();
this.deleteTempImg()
......@@ -116,11 +109,6 @@ export default {
getSystemInfo() {
try {
let a = wx.getSystemInfoSync();
// this.globalData.platform = systemInfo.platform, this.globalData.pixelRatio = a.pixelRatio,
// this.globalData.statusBarHeight = a.statusBarHeight, this.globalData.navHeight = a.statusBarHeight / a.screenWidth * 750 + 90,
// this.globalData.rpxScreenHeight = a.screenHeight / a.screenWidth * 750, this.globalData.screenWidth = a.screenWidth,
// this.globalData.screenHeight = a.screenHeight;
this.globalData.navHeight =
(a.statusBarHeight / a.screenWidth) * 750 + 90;
this.globalData.rpxScreenHeight =
......@@ -155,8 +143,8 @@ export default {
async autoLogin() {
let that = this;
// 如果token不为空,则跳过自动登录
if (that.vuex_token) {
return;
if(that.vuex_token) {
return false
}
await login.oauth().then(async (res) => {
if (res.code) {
......@@ -196,6 +184,7 @@ export default {
this.$u.vuex("vuex_user", null);
this.$u.vuex("vuex_wx_uid", "");
}
this.$u.vuex("vuex_settled", null);
},
/* 版本更新 */
......
......@@ -97,6 +97,7 @@ const install = (Vue, vm) => {
vm.$u.vuex('vuex_token', '');
vm.$u.vuex('vuex_user', null);
vm.$u.vuex('vuex_wx_uid', '');
vm.$u.vuex("vuex_settled", null);
toLoginPage()
case 403://没有权限访问
case 500:
......
......@@ -318,8 +318,9 @@
border: none;
}
button[disabled]:not([type]) {
background: #d1d4d4;
color: #ffffff;
background: #FFFFFF;
color: #CCCCCC;
border: 2rpx solid #F4F5F7;
}
}
}
......
......@@ -172,20 +172,6 @@
this.getLocation()
}
},
// onPullDownRefresh() {
// console.log('------下拉刷新------')
// // 下拉刷洗
// this.initSettleInfo()
// },
// onReachBottom() {
// console.log('----------底部-------------', this.currentLoadStatus)
// if (this.currentLoadStatus != 'loadmore') return
// this.currentLoadStatus == 'loading'
// this.loadOrderList()
// },
// onPageScroll(obj) {
// console.log('---------scroll---------', obj)
// },
methods: {
getData() {
this.getOrderCount()
......@@ -274,9 +260,6 @@
}
});
},
onRestore() {
this.triggered = "restore";
},
reachBottom() {
if (this.vuex_token) {
if (this.currentLoadStatus != 'loadmore') return
......@@ -284,9 +267,6 @@
this.loadOrderList()
}
},
onPulling(e) {
console.log("onpulling", e);
},
onRefresh() {
if (this._freshing) return;
this._freshing = true;
......@@ -294,14 +274,6 @@
},
onRestore() {
this.triggered = 'restore'; // 需要重置
console.log("onRestore");
},
onAbort() {
console.log("onAbort");
},
// clickSwiper(index) {},
handleScroll() {
console.log("-----scroll-------");
},
/* 立即入驻 */
immediatelyIn() {
......
......@@ -446,7 +446,6 @@ export default {
},
onPulling(e) {
return true;
console.log("onpulling", e);
},
onRefresh() {
if (this._freshing) return;
......@@ -458,7 +457,6 @@ export default {
},
onRestore() {
this.triggered = "restore"; // 需要重置
console.log("onRestore");
},
onAbort() {
console.log("onAbort");
......@@ -657,10 +655,6 @@ export default {
this.examList[i].examId = res.data.id;
this.examList[i].examStatus = res.data.examStatus; //i;//
this.examList[i].questionTime = res.data.questionTime;
console.log(
this.examList[i].questionTime,
"每题考试时间"
);
let examResult = res.data.examLevelResult;
this.examList[i].status =
examResult != "" ? examResult : "未通过";
......@@ -675,25 +669,20 @@ export default {
// examStatus 用户考试状态 0考试中 1考试完成 2未参与
that.exam = res.data;
console.log(that.exam);
if (res.data.examStatus == 2) {
console.log("examStatus " + i + " 2");
return;
}
if (res.data.examStatus == 1) {
console.log("examStatus " + i + " 1");
that.examList[i].isComplete =
this.examList[i].status == "通过";
that.examScore = res.data.examScore;
return;
}
if (res.data.examStatus == 0) {
console.log("examStatus " + i + " 0");
that.userExamId = res.data.id;
}
})
.catch((err) => {
console.log("getUserExamInfo err" + err);
uni.hideLoading();
uni.showToast({
icon: "none",
......
......@@ -21,7 +21,7 @@
<view class="list-view">
<u-cell-group :border="false">
<view v-for="(item, index) in items" :key="index">
<u-cell-item :value="item.value" :border-bottom="false" @click="handleClick(index)">
<u-cell-item :value="item.value" :border-bottom="false" @click="handleClick(item.pathName)">
<image slot="icon" :src="qnPath + item.icon" :style="item.imageStyle"></image>
<view slot="title" class="item-title">{{item.title}}</view>
<view slot="value" class="item-value">{{value}}</view>
......@@ -49,56 +49,64 @@
},
computed: {
settled() {
return this.vuex_settled && this.vuex_settled.record || null
return this.vuex_token && this.vuex_settled && this.vuex_settled.record || null
},
avatar() {
return this.vuex_settled && this.vuex_settled.avatar || ''
return this.vuex_settled && this.vuex_settled.avatar
},
name() {
return this.settled && (this.settled.id_card_name
|| this.settled.nickname || this.settled.name) || ''
|| this.settled.nickname || this.settled.name)
},
mobile() {
return this.settled && this.settled.mobile || ''
return this.settled && this.settled.mobile
},
items() {
return [{
return [
{
pathName: 'wallet',
title: '我的钱包',
value: '',
icon: 'qianbao.png',
imageStyle: 'width:34rpx;height:32rpx'
},
{
pathName: 'deposit',
title: '配件押金',
value: '',
icon: 'yajin.png',
imageStyle: 'width:32rpx;height:32rpx'
},
{
pathName: 'contract',
title: '我的合同',
value: '',
icon: 'hetong.png',
imageStyle: 'width:34rpx;height:32rpx'
},
{
pathName: 'cert',
title: '我的证件',
value: '',
icon: 'zhengjian.png',
imageStyle: 'width:36rpx;height:28rpx'
},
{
pathName: 'address',
title: '收货地址',
value: '',
icon: 'wddizhi.png',
imageStyle: 'width:32rpx;height:32rpx'
},
{
pathName: 'warehouse',
title: '我的仓库',
value: '',
icon: 'cangku.png',
imageStyle: 'width:36rpx;height:32rpx'
},
{
pathName: 'customer',
title: '联系客服',
value: this.serviceTel,
icon: 'lxkefu.png',
......@@ -109,9 +117,6 @@
telTip() {
return this.mobile && '已绑定手机'|| '绑定手机号'
},
pages() {
return ['wallet', 'deposit', 'contract', 'cert', 'address', 'warehouse', 'customer']
},
headImageUrl() {
return this.avatar || this.placeholderImage
},
......@@ -138,10 +143,10 @@
let self = this
app.getBaseInfo(self);
},
handleClick(index) {
handleClick(path) {
if(this.vuex_token) {
this.$u.route({
url: 'pages/mine/' + this.pages[index] + '/index'
url: 'pages/mine/' + path + '/index'
})
} else {
this.$u.route({url: "pages/login/index"})
......@@ -239,8 +244,9 @@
.list-view {
background-color: #FFFFFF;
border-radius: 16rpx 16rpx 0 0;
border-radius: 32rpx 32rpx 0 0;
overflow: hidden;
padding-top: 16rpx;
.item-title {
font-size: 32rpx;
......
......@@ -24,7 +24,7 @@
<scroll-view scroll-y style="height: 100%;width: 100%;" @scrolltolower="reachBottom" scroll-anchoring
scroll-y="true" refresher-enabled="true" :refresher-triggered="triggered" :refresher-threshold="100"
refresher-background="#F4F5F7" @refresherpulling="triggered = true" @refresherrefresh="onRefresh"
@refresherrestore="onRestore" @refresherabort="onAbort">
@refresherrestore="onRestore">
<NoOrder v-if="noMore" type="black" :customStyle="noOrderCustomStyle" />
<template v-else>
<view v-for="(item, index) in orderList" :key="item.orderId">
......@@ -315,9 +315,6 @@
url: 'pages/order/search'
})
},
onPulling(e) {
console.log("onpulling", e);
},
onRefresh() {
if (this._freshing) return;
this._freshing = true;
......@@ -329,11 +326,7 @@
},
onRestore() {
this.triggered = 'restore'; // 需要重置
console.log("onRestore");
},
onAbort() {
console.log("onAbort");
}
}
};
</script>
......
......@@ -217,7 +217,6 @@ export default {
return;
}
if (res.data.data.examStatus == 1) {
console.log("111111111111111111111111111");
that.isComplete = true;
that.examScore = res.data.data.examScore;
return;
......@@ -285,11 +284,6 @@ export default {
// this.endTime = timestamp + time * 1000;
this.currentTime = parseInt(time * 1000); //this.formatTimeToMini(timestamp);//endTime-currentTime再格式化时间显示
that.getNext();
console.log(
this.endTime,
this.currentTime,
"总时间"
);
}
} else {
uni.showToast({
......@@ -361,15 +355,12 @@ export default {
}
if (res.data.code == 200) {
that.currentItem = res.data.data;
console.log(that.currentItem);
that.progress = res.data.data.progress;
if (res.data.data.isQuestion) {
let str = res.data.data.question.content;
var wz = str.indexOf(".");
let str1 = str.substring(wz + 1);
console.log(that.currentItem);
that.currentItem.question.content = str1.replace('*', '');
console.log(str1, "切割的字符串");
}
if (res.data.data.answerList) {
that.handleData();
......@@ -423,12 +414,6 @@ export default {
if (this.everyTime > 0) {
this.timer = setTimeout(this.startCounting, 1000);
console.log(
"endTime:" + this.endTime,
"everyTime:" + this.everyTime,
"currentTime:" + this.currentTime,
"答案:" + this.userAnswerIds
);
} else {
clearTimeout(this.timer);
this.everyTime = 90;
......@@ -438,16 +423,7 @@ export default {
itemClick: function (currentItem, ikey) {
this.isSelect = true;
// console.log('选点点击--处理前--this.currentItem:')
// console.log(this.currentItem)
// console.log('选点点击--处理前--ikey:')
// console.log(ikey)
// console.log('选点点击--处理前--题目类型,1单选,2多选,3简答:')
// console.log(this.currentItem.question.answerType)
//answerType 题目类型,1单选,2多选,3简答,
//answerType 题目类型,1单选,2多选,3简答
for (let i = 0; i < this.currentItem.answerList.length; i++) {
var item = this.currentItem.answerList[i];
......@@ -481,9 +457,6 @@ export default {
//有选答案
this.isSelect = isSelect;
// console.log('选点点击--处理后--this.currentItem.answerList:')
// console.log(this.currentItem.answerList)
},
// 点击下一步
handleClick() {
......@@ -531,7 +504,6 @@ export default {
// if(this.userAnswerIds.length == 1)
this.userAnswerIds =
this.userAnswerIds + "," + item.id;
console.log(this.userAnswerIds, "答案答案");
}
//*/
} else {
......
......@@ -127,12 +127,10 @@ export default {
},
success: (res) => {
console.log("标识符1", res.data);
uni.hideLoading();
if (res.data.code == 200) {
if (res.data.data.userExamId) {
this.userExamId = res.data.data.userExamId;
console.log("这个是个标识符", this.userExamId);
}
}
},
......
......@@ -41,7 +41,6 @@ export default {
onLoad(a) {
this.examId = a.examId;
this.userExamId = a.userExamId;
console.log("userExamId是", this.userExamId);
this.getCourseResult();
},
onUnload() {
......@@ -54,7 +53,6 @@ export default {
.getExamResult(this.examId)
.then((res) => {
if (res.code != 200) {
console.log("getUserExamInfo 200 err");
uni.showToast({
icon: "none",
title: "获取考试结果失败",
......@@ -65,7 +63,6 @@ export default {
this.score = this.result.examScore;
})
.catch((err) => {
console.log("getUserExamInfo err" + err);
uni.hideLoading();
uni.showToast({
icon: "none",
......
......@@ -45,7 +45,6 @@ export default {
onLoad(a) {
this.userExamId = a.userExamId;
this.examId = a.examId;
console.log("userExamId是", this.userExamId);
this.getCourseResult();
},
onUnload() {
......@@ -58,7 +57,6 @@ export default {
.getExamResult(this.examId)
.then((res) => {
if (res.code != 200) {
console.log("getUserExamInfo 200 err");
uni.showToast({
icon: "none",
title: "获取考试结果失败",
......@@ -69,7 +67,6 @@ export default {
this.score = this.result.examScore;
})
.catch((err) => {
console.log("getUserExamInfo err" + err);
uni.hideLoading();
uni.showToast({
icon: "none",
......@@ -81,7 +78,6 @@ export default {
getAgain: function () {
let examId = this.examId;
let routes = getCurrentPages(); // 获取当前打开过的页面路由数组
console.log(routes.length);
uni.navigateTo({
url: "/pages/learn/assessment?examId=" + examId,
});
......
......@@ -121,8 +121,6 @@
},
methods: {
scroll: function(e) {
console.log('--scroll--')
console.log(e)
this.old.scrollTop = e.detail.scrollTop
},
goNext(info) {
......@@ -150,8 +148,6 @@
}else{
this.scrollValue = 0
}
console.log('--移动距离--')
console.log(this.scrollValue)
},
onPlayerTimeupdate(player) {
let intCurrentTime = parseInt(player.detail.currentTime);
......@@ -220,8 +216,6 @@
}
if (res.data) {
this.sectionInfo = res.data
console.log("----节信息----")
console.log(this.sectionInfo)
this.nextSectionId = this.sectionInfo.nextSectionId
let wareVal = this.sectionInfo.ware
this.courseTitle = res.data.name
......@@ -237,7 +231,6 @@
let coureWareList = res.data.courseware
this.courseSrc = coureWareList[0].src
this.videoTotalTime = parseInt(JSON.parse(coureWareList[0].info).time) - 1;
console.log('视频时长信息:' + this.videoTotalTime)
}
}
})
......
......@@ -209,6 +209,7 @@ export default {
this.$u.vuex('vuex_user', null);
this.$u.vuex('vuex_wx_uid', '');
}
this.$u.vuex('vuex_settled', null);
},
setLoginStatus(authed = true) {
......
......@@ -4,7 +4,7 @@
:border-bottom="false" title-bold></u-navbar>
<view class="wallet-content-view">
<view class="header-view">
<image class="header-image" mode="widthFix" :src="qianbaobeijing"></image>
<image class="header-image" :src="qianbaobeijing"></image>
</view>
<view class="survey-view">
<view class="survey-top-view">
......@@ -35,7 +35,7 @@
</view>
</view>
<view class="content-list-right">
<text class="content-list-right-text">点击查看</text>
<text class="content-list-right-text">{{ item.value }}</text>
<u-icon name="arrow-right"></u-icon>
</view>
</view>
......@@ -90,11 +90,13 @@
return [{
title: '结算账单',
content: '展示您已提现的账单信息',
icon: this.imageUrl + 'jiesuan.png'
icon: this.imageUrl + 'jiesuan.png',
value: '点击查看'
}, {
title: '收入流水',
content: this.statementContent,
icon: this.imageUrl + 'liushui.png'
icon: this.imageUrl + 'liushui.png',
value: '查看全部'
}]
},
items() {
......@@ -191,9 +193,10 @@
position: absolute;
width: 100%;
padding-top: 10rpx;
padding-left: 6rpx;
padding-left: 14rpx;
.header-image {
width: 100%;
width: 730rpx;
height: 420rpx;
}
}
......
......@@ -73,7 +73,7 @@
return this.loading || this.info.payableRecordExtendDtos && this.info.payableRecordExtendDtos.length
},
banner() {
return this.imageUrl + 'Bill.png'
return this.imageUrl + 'receipt.png'
},
},
onLoad() {
......
......@@ -73,7 +73,7 @@
}
},
endTime() {
this.$u.DateTimeFormat(new Date().getTime(), 'YYYY-MM-DD')
this.moment().format('YYYY-MM-DD')
},
items() {
return {
......@@ -90,7 +90,7 @@
return process.uniEnv.qn_base_url
},
banner() {
return this.imageUrl + 'Bill.png'
return this.imageUrl + 'receipt.png'
},
hasInfo() {
return this.loading || this.data.statementList && this.data.statementList.length
......
......@@ -32,7 +32,7 @@
<view class="width-80 center">{{ item.outAmount }}</view>
<view class="width-140 create-time">{{ (item.updateTime || item.createTime) | datefmt('YYYY.MM.DD HH:mm:ss')}}</view>
</view>
<u-loadmore :status="status" @loadmore="loadRecord" />
<u-loadmore class="load-more" :status="status" @loadmore="loadRecord" />
</view>
</view>
</view>
......@@ -180,4 +180,7 @@
.break {
word-break:break-all;
}
.load-more {
margin-top: 20rpx;
}
</style>
......@@ -108,7 +108,7 @@
self.loadStatus = res.data.total > self.orderList.length ? 'loadmore' : 'nomore'
}
} else {
self.$u.toast(res.message);
self.$u.toast('请求失败');
}
self.loaded = true
});
......
......@@ -2,7 +2,6 @@ import {
mapState
} from 'vuex'
import store from "@/store/index"
console.log(store, store.state, 'store')
// 尝试将用户在根目录中的store/index.js的vuex的state变量,全部加载到全局变量中
let $uStoreKey = [];
......
......@@ -63,6 +63,5 @@ const store = new Vuex.Store({
}
}
})
console.log(store,'store----------------')
export default store
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment