Compare commits
1 Commits
9e24edad28
...
jwl-gift
| Author | SHA1 | Date | |
|---|---|---|---|
| 3d6252d5cb |
@@ -1,28 +0,0 @@
|
|||||||
{
|
|
||||||
"appid": "wx24c1b58020a5ce66",
|
|
||||||
"compileType": "miniprogram",
|
|
||||||
"libVersion": "3.3.3",
|
|
||||||
"packOptions": {
|
|
||||||
"ignore": [],
|
|
||||||
"include": []
|
|
||||||
},
|
|
||||||
"setting": {
|
|
||||||
"coverView": true,
|
|
||||||
"es6": true,
|
|
||||||
"postcss": true,
|
|
||||||
"minified": true,
|
|
||||||
"enhance": true,
|
|
||||||
"showShadowRootInWxmlPanel": true,
|
|
||||||
"packNpmRelationList": [],
|
|
||||||
"babelSetting": {
|
|
||||||
"ignore": [],
|
|
||||||
"disablePlugins": [],
|
|
||||||
"outputPath": ""
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"condition": {},
|
|
||||||
"editorSetting": {
|
|
||||||
"tabIndent": "insertSpaces",
|
|
||||||
"tabSize": 2
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
{
|
|
||||||
"description": "项目私有配置文件。此文件中的内容将覆盖 project.config.json 中的相同字段。项目的改动优先同步到此文件中。详见文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html",
|
|
||||||
"projectname": "jwl-applet",
|
|
||||||
"setting": {
|
|
||||||
"compileHotReLoad": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,65 +0,0 @@
|
|||||||
import request from '../request/index.js';
|
|
||||||
|
|
||||||
//查询活动列表
|
|
||||||
export function queryActivityList(data) {
|
|
||||||
return request({
|
|
||||||
url: 'activity/applet/activity/list',
|
|
||||||
method: 'get',
|
|
||||||
data,
|
|
||||||
noToken: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
//查询活动详情
|
|
||||||
export function queryActivityDetail(data) {
|
|
||||||
return request({
|
|
||||||
url: 'activity/applet/activity/detail',
|
|
||||||
method: 'get',
|
|
||||||
data,
|
|
||||||
noToken: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
//查询抽奖次数
|
|
||||||
export function queryLuckyNum(data) {
|
|
||||||
return request({
|
|
||||||
url: 'activity/applet/activity/lucky/num',
|
|
||||||
method: 'get',
|
|
||||||
data,
|
|
||||||
noToken: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
//查询中奖结果
|
|
||||||
export function queryLuckyResult(data) {
|
|
||||||
return request({
|
|
||||||
url: 'activity/applet/activity/lucky/result',
|
|
||||||
method: 'get',
|
|
||||||
data,
|
|
||||||
noToken: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
//录入中奖结果
|
|
||||||
export function saveWinner(data) {
|
|
||||||
return request({
|
|
||||||
url: 'activity/applet/activity/winner/save',
|
|
||||||
method: 'POST',
|
|
||||||
data,
|
|
||||||
noToken: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
//核销
|
|
||||||
export function receiveWinner(data) {
|
|
||||||
return request({
|
|
||||||
url: 'activity/applet/activity/winner/receive',
|
|
||||||
method: 'POST',
|
|
||||||
data,
|
|
||||||
noToken: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
//查询中奖记录
|
|
||||||
export function getLuckyRecord(data) {
|
|
||||||
return request({
|
|
||||||
url: 'activity/applet/activity/lucky/record',
|
|
||||||
method: 'get',
|
|
||||||
data,
|
|
||||||
noToken: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
@@ -31,16 +31,12 @@
|
|||||||
mapActions
|
mapActions
|
||||||
} from 'pinia' //引入映射函数
|
} from 'pinia' //引入映射函数
|
||||||
import useQuestionStore from '@/jtools/store/question' //引入store
|
import useQuestionStore from '@/jtools/store/question' //引入store
|
||||||
import useUserStore from '@/jtools/store/user'
|
|
||||||
import storage from '@/jtools/storage';
|
import storage from '@/jtools/storage';
|
||||||
import {
|
import {
|
||||||
querySysConfigList,
|
querySysConfigList,
|
||||||
} from '@/jtools/api/question';
|
} from '@/jtools/api/question';
|
||||||
import Subject1 from "./components/Subject1";
|
import Subject1 from "./components/Subject1";
|
||||||
import Subject2 from "./components/Subject2";
|
import Subject2 from "./components/Subject2";
|
||||||
import {
|
|
||||||
queryActivityList,
|
|
||||||
} from '@/jtools/api/activity';
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
Subject1,
|
Subject1,
|
||||||
@@ -56,7 +52,7 @@
|
|||||||
categoryList: [],
|
categoryList: [],
|
||||||
rightList: storage.get(`rightList_subject${this.subject}`) || [],
|
rightList: storage.get(`rightList_subject${this.subject}`) || [],
|
||||||
wrongList: storage.get(`wrongList_subject${this.subject}`) || [],
|
wrongList: storage.get(`wrongList_subject${this.subject}`) || [],
|
||||||
activityList: ['https://cdn.uviewui.com/uview/swiper/swiper1.png']
|
activityList: ['https://cdn.uviewui.com/uview/swiper/swiper1.png']
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
@@ -69,7 +65,6 @@
|
|||||||
if(this.subject=='2'||this.subject=='3'){
|
if(this.subject=='2'||this.subject=='3'){
|
||||||
this.$refs.subjectRef.getDiverType()
|
this.$refs.subjectRef.getDiverType()
|
||||||
}
|
}
|
||||||
this.queryActivityList();
|
|
||||||
},
|
},
|
||||||
onHide(){
|
onHide(){
|
||||||
this.show=false
|
this.show=false
|
||||||
@@ -124,40 +119,10 @@
|
|||||||
}, 100)
|
}, 100)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
//查询活动列表
|
|
||||||
queryActivityList(){
|
|
||||||
// console.log(this.user)
|
|
||||||
// console.log(useUserStore().userInfo)
|
|
||||||
// this.activityList = null;
|
|
||||||
// uni.request({
|
|
||||||
// url: 'http://localhost:8089/applet/activity/list',
|
|
||||||
// method: 'get',
|
|
||||||
// data: {'schoolId': useUserStore().userInfo.schoolId}
|
|
||||||
// }).then(resp => {
|
|
||||||
// console.log(".....")
|
|
||||||
// console.log(resp)
|
|
||||||
// if(resp.data.code == 200) {
|
|
||||||
// this.activityList = resp.data.data
|
|
||||||
// console.log("*****")
|
|
||||||
// console.log(resp.data)
|
|
||||||
// console.log(resp.data.data)
|
|
||||||
// console.log(this.activityList)
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
queryActivityList({schoolId: this.user.schoolId}).then(resp => {
|
|
||||||
this.activityList = resp.data;
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 去活动
|
// 去活动
|
||||||
handleToActivity(index) {
|
handleToActivity(index) {
|
||||||
let detailId;
|
|
||||||
this.activityList.find((item, index1) => {
|
|
||||||
if(index === index1){
|
|
||||||
detailId = item.detailId;
|
|
||||||
}
|
|
||||||
})
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/index/activity?detailId='+detailId,
|
url: '/pages/index/activity'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user