Commit dadbd96b authored by 罗超's avatar 罗超

2

parent 276e6eea
...@@ -164,7 +164,6 @@ ...@@ -164,7 +164,6 @@
let { let {
proxy proxy
} = getCurrentInstance(); } = getCurrentInstance();
proxy.$isLogin();
let data = reactive({ let data = reactive({
ActiveMsg: { ActiveMsg: {
pageIndex: 1, pageIndex: 1,
...@@ -241,11 +240,6 @@ ...@@ -241,11 +240,6 @@
onShow() { onShow() {
this.getActivityData(); this.getActivityData();
}, },
onLoad() {
uni.setNavigationBarTitle({
title: "首页",
});
},
onShareAppMessage() { onShareAppMessage() {
return { return {
title: "甲小鹤", title: "甲小鹤",
......
...@@ -189,13 +189,10 @@ ...@@ -189,13 +189,10 @@
provide, provide,
} from "vue"; } from "vue";
export default { export default {
components: {
},
onLoad(options) {
},
setup(props) { setup(props) {
let {
proxy
} = getCurrentInstance();
let data = reactive({ let data = reactive({
stars: 2 stars: 2
}) })
...@@ -209,6 +206,9 @@ ...@@ -209,6 +206,9 @@
uni.switchTab({ uni.switchTab({
url: '/pages/index/index' url: '/pages/index/index'
}); });
},
getTest(){
} }
} }
onMounted(() => { onMounted(() => {
......
...@@ -68,13 +68,12 @@ ...@@ -68,13 +68,12 @@
}) })
}, },
swiperChange(val) { swiperChange(val) {
console.log(63, val.detail.current,'study', data.StudyList.length) data.current=val.detail.current
if (data.current <= data.StudyList.length) { if (data.current <= data.StudyList.length) {
methods.completeRead(val.detail.current) methods.completeRead(val.detail.current)
} else if (data.current > data.StudyList.length && data.current <= data.ReviewList.length) { } else if (data.current <= (data.ReviewList.length+data.StudyList.length)) {
methods.completeReview(val.detail.current) methods.completeReview(val.detail.current)
} }
const total = data.StudyList.length + data.ReviewList.length + 1 const total = data.StudyList.length + data.ReviewList.length + 1
if (val.detail.current + 1 == total && total > 1) { if (val.detail.current + 1 == total && total > 1) {
uni.navigateTo({ uni.navigateTo({
...@@ -83,18 +82,16 @@ ...@@ -83,18 +82,16 @@
} }
}, },
completeRead(n) { completeRead(n) {
console.log(74, n) data.readMsg.StudyNum = n
// data.readMsg.StudyNum = n proxy.$request('/AppletWords/SetStuWordsPrep', data.readMsg).then(res => {
// proxy.$request('/AppletWords/SetStuWordsPrep', data.readMsg).then(res => { console.log(74, res)
// c })
// })
}, },
completeReview(n) { completeReview(n) {
console.log(75, n-data.StudyList.length) data.readMsg.ReviewNum = n-data.StudyList.length
// data.readMsg.ReviewNum = n proxy.$request('/AppletWords/SetStuWordsReview', data.reviewMsg).then(res => {
// proxy.$request('/AppletWords/SetStuWordsReview', data.reviewMsg).then(res => { console.log(75, res)
})
// })
} }
} }
......
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