斜塘答题

master
lion 2 years ago
parent 8b78f09e2c
commit 702b54106e

@ -490,7 +490,7 @@
width:10rpx;
height:50rpx;
border-radius: 10rpx;
background-color: red;
background-color: green;
vertical-align: middle;
margin-right:20rpx
}

@ -1,5 +1,5 @@
<template>
<view class="wrap">
<template>
<view class="wrap">
<view class="index1" :animation="animationData" ref="apiAnimateDemo">
<view v-for="(item,index) in animations">
<gal-css-animate v-if="item.show" :animateName="item.name"
@ -9,7 +9,7 @@
timingFunction="ease-in">
<u-image :fade="false" :src="item.content" :width="item.width" :height="item.height"></u-image>
</gal-css-animate>
</view>
</view>
</view>
<view class="index2" :animation="animationData1" @click="towhere(true)">
<view :animation="animationData20" class="logo20">
@ -27,16 +27,16 @@
<view :animation="animationData24" class="logo24">
<u-image :fade="false" :src="logo24" width="135rpx" height="100rpx"></u-image>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
</view>
</view>
</template>
<script>
export default {
data() {
return {
isLogin:false,//
isEnd:false,//
animations: [{
name: 'fadeIn',
duration: '1s',
@ -79,7 +79,7 @@
show:false,
width:'750rpx',
height:'802rpx'
}
}
],
logo20:require('../../static/index/2logo20.png'),
logo21:require('../../static/index/2logo1.png'),
@ -106,21 +106,17 @@
height:'100rpx'
},
],
}
},
onLoad() {
userInfo:{}
}
},
onLoad() {
// this.play2(0)
// this.getUserInfo()
this.play(3)
},
methods: {
// getUserInfo(){
// let userinfo = uni.getStorageSync('userInfo')
// if(userinfo){
// this.isLogin = true
// }
// },
this.userInfo = uni.getStorageSync('userInfo')
this.getConfig()
this.play(3)
},
methods: {
play(index){
//
if(index<0){
@ -143,13 +139,14 @@
})
animation20.opacity(1).step()
this.animationData20 = animation20.export()
//
// logo xietang
var animation24 = uni.createAnimation({
duration: 2500,
timingFunction: 'ease-in'
})
this.animationData24 = animation24.export()
// s
//
var animation1 = uni.createAnimation({
duration: 2000,
timingFunction: 'ease-in',
@ -170,7 +167,7 @@
var animation21 = uni.createAnimation({
duration: 1000,
timingFunction: 'ease-in',
delay:2000
delay:1000
})
animation21.height("255rpx").step()
this.animationData21 = animation21.export()
@ -178,7 +175,7 @@
var animation22 = uni.createAnimation({
duration: 1000,
timingFunction: 'ease-in',
delay:3000
delay:2000
})
animation22.height("457rpx").step()
this.animationData22 = animation22.export()
@ -186,20 +183,59 @@
var animation23 = uni.createAnimation({
duration: 1000,
timingFunction: 'ease-in',
delay:4000
delay:3000
})
animation23.opacity(1).step()
this.animationData23 = animation23.export()
this.towhere()
},
getConfig(){
// /
let that = this
this.util.request({
api: '/api/mobile/user/wechat-login-url',
method: 'GET',
data:{
activity_tag:'bbfc'
},
utilSuccess: (res) => {
that.isEnd = that.isCurrentTimeBetween(res.start_time,res.end_time)
let config = res.config
config.map(item=>{
if(item.key==='active_tip'){
uni.setStorageSync('active_tip',item.value)
}
})
uni.setStorageSync('activeConfig',res)
uni.setStorageSync('isEnd',that.isEnd)
// this.userInfo = res;
// uni.setStorageSync("userInfo",res)
},
utilFail: (res) => {
// this.util.toast(res)
uni.clearStorageSync()
}
})
},
isCurrentTimeBetween(startTime, endTime) {
let that = this
const now = that.$moment().valueOf()
const start = that.$moment(startTime).valueOf();
const end =that.$moment(endTime).valueOf();
console.log("123",now,start,end)
return now >= start && now <= end;
},
towhere(isclick){
let userinfo = uni.getStorageSync('userInfo')
let url = '/pages/login/index'
if(userinfo){
url = '/pages/me/me'
let url = '/pages/me/me'
console.log("userinfo.mobile",userinfo.mobile)
console.log("this.util.isNull(userinfo.mobile)",this.util.isNull(userinfo.mobile))
if(this.util.isNull(userinfo.mobile)){
url = '/pages/login/index'
}
console.log(userinfo,url,isclick)
console.log("url",url)
// return
//
if(isclick){
uni.navigateTo({
url:url
@ -209,58 +245,58 @@
uni.navigateTo({
url:url
})
},8000)
},4500)
}
}
}
}
</script>
<style>
page {
height: 100%;
overflow: hidden;
position: relative;
}
.wrap {
width: 100%;
height: 100%
}
.index1 {
width: 100%;
height: 100%;
background-image: url('../../static/index/bg.png');
}
}
}
</script>
<style>
page {
height: 100%;
overflow: hidden;
position: relative;
}
.wrap {
width: 100%;
height: 100%
}
.index1 {
width: 100%;
height: 100%;
background-image: url('../../static/index/bg.png');
position: absolute;
/* display: none; */
background-size: 100% 100%;
top:0;
left:0;
z-index:2;
overflow: hidden;
}
overflow: hidden;
}
.logo0{
position: absolute;
top: 0;
left: 0;
}
.logo {
position: absolute;
top: 10%;
left: 235rpx;
}
.logo1 {
position: absolute;
}
.logo {
position: absolute;
top: 10%;
left: 235rpx;
}
.logo1 {
position: absolute;
bottom: 520rpx;
left: 60rpx;
}
.logo2 {
position: absolute;
bottom: 0rpx;
left: 0rpx;
left: 60rpx;
}
.logo2 {
position: absolute;
bottom: 0rpx;
left: 0rpx;
}
.index2 {
width: 100%;
@ -314,5 +350,5 @@
top: 50%;
left: 50%;
transform: translate(-50%,-50%); */
}
}
</style>

@ -1,5 +1,5 @@
<template>
<view class="wrap">
<template>
<view class="wrap">
<view class="index1" :animation="animationData" ref="apiAnimateDemo">
<view v-for="(item,index) in animations">
<gal-css-animate v-if="item.show" :animateName="item.name"
@ -9,7 +9,7 @@
timingFunction="ease-in">
<u-image :fade="false" :src="item.content" :width="item.width" :height="item.height"></u-image>
</gal-css-animate>
</view>
</view>
</view>
<view class="index2" :animation="animationData1" @click="towhere(true)">
<view :animation="animationData20" class="logo20">
@ -27,62 +27,61 @@
<view :animation="animationData24" class="logo24">
<u-image :fade="false" :src="logo24" width="135rpx" height="100rpx"></u-image>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
</view>
</view>
</template>
<script>
export default {
data() {
return {
isLogin:false,//
isEnd:false,//
animations: [{
name: 'fadeIn',
duration: '1s',
timer: 1000,
isEnd:false,//
animations: [{
name: 'fadeIn',
duration: '1s',
timer: 1000,
content: require('../../static/index/shine.png'),
autoplay:false,
class:'logo0',
show:false,
width:'750rpx',
height:'1650rpx'
height:'1650rpx'
},{
name: 'heartBeat',
duration: '1.5s',
timer: 1000,
content: require('../../static/index/logo.png'),
autoplay:false,
class:'logo',
show:false,
width:'285rpx',
height:'202rpx'
},
// {
// name: 'heartBeat',
// duration: '1.5s',
// timer: 1000,
// content: require('../../static/index/logo.png'),
// autoplay:false,
// class:'logo',
// show:false,
// width:'285rpx',
// height:'202rpx'
// },
{
name: 'fadeIn',
duration: '1s',
timer: 1000,
content: require('../../static/index/logo1.png'),
{
name: 'fadeIn',
duration: '1s',
timer: 1000,
content: require('../../static/index/logo12.png'),
autoplay:false,
class:'logo1',
show:false,
width:'242rpx',
height:'432rpx'
},
{
name: 'fadeInUp',
duration: '1s',
timer: 1000,
content: require('../../static/index/logo2.png'),
width:'671rpx',
height:'336rpx'
},
{
name: 'fadeInUp',
duration: '1s',
timer: 1000,
content: require('../../static/index/logo22.png'),
autoplay:false,
class:'logo2',
show:false,
width:'750rpx',
height:'605rpx'
}
height:'802rpx'
}
],
logo20:require('../../static/index/2logo.png'),
logo20:require('../../static/index/2logo20.png'),
logo21:require('../../static/index/2logo1.png'),
logo22:require('../../static/index/2logo2.png'),
logo23:require('../../static/index/2logo3.png'),
@ -107,17 +106,24 @@
height:'100rpx'
},
],
userInfo:{}
}
},
onLoad() {
userInfo:{}
}
},
onLoad() {
// this.play2(0)
// this.getUserInfo()
this.userInfo = uni.getStorageSync('userInfo')
this.getConfig()
this.play(2)
},
methods: {
this.play(3)
},
methods: {
// getUserInfo(){
// let userinfo = uni.getStorageSync('userInfo')
// if(userinfo){
// this.isLogin = true
// }
// },
play(index){
//
if(index<0){
@ -140,14 +146,13 @@
})
animation20.opacity(1).step()
this.animationData20 = animation20.export()
//
// logo xietang
var animation24 = uni.createAnimation({
duration: 2500,
timingFunction: 'ease-in'
})
this.animationData24 = animation24.export()
//
// s
var animation1 = uni.createAnimation({
duration: 2000,
timingFunction: 'ease-in',
@ -168,7 +173,7 @@
var animation21 = uni.createAnimation({
duration: 1000,
timingFunction: 'ease-in',
delay:1000
delay:2000
})
animation21.height("255rpx").step()
this.animationData21 = animation21.export()
@ -176,7 +181,7 @@
var animation22 = uni.createAnimation({
duration: 1000,
timingFunction: 'ease-in',
delay:2000
delay:3000
})
animation22.height("457rpx").step()
this.animationData22 = animation22.export()
@ -184,7 +189,7 @@
var animation23 = uni.createAnimation({
duration: 1000,
timingFunction: 'ease-in',
delay:3000
delay:4000
})
animation23.opacity(1).step()
this.animationData23 = animation23.export()
@ -214,7 +219,7 @@
},
utilFail: (res) => {
// this.util.toast(res)
uni.clearStorageSync()
// uni.clearStorageSync()
}
})
},
@ -248,56 +253,56 @@
})
},4500)
}
}
}
}
</script>
<style>
page {
height: 100%;
overflow: hidden;
position: relative;
}
.wrap {
width: 100%;
height: 100%
}
.index1 {
width: 100%;
height: 100%;
background-image: url('../../static/index/bg.png');
}
}
}
</script>
<style>
page {
height: 100%;
overflow: hidden;
position: relative;
}
.wrap {
width: 100%;
height: 100%
}
.index1 {
width: 100%;
height: 100%;
background-image: url('../../static/index/bg.png');
position: absolute;
/* display: none; */
background-size: 100% 100%;
top:0;
left:0;
z-index:2;
overflow: hidden;
}
overflow: hidden;
}
.logo0{
position: absolute;
top: 0;
left: 0;
}
.logo {
position: absolute;
top: 10%;
left: 235rpx;
}
.logo1 {
position: absolute;
bottom: 670rpx;
left: 270rpx;
}
.logo2 {
position: absolute;
bottom: 0rpx;
left: 0rpx;
}
.logo {
position: absolute;
top: 10%;
left: 235rpx;
}
.logo1 {
position: absolute;
bottom: 520rpx;
left: 60rpx;
}
.logo2 {
position: absolute;
bottom: 0rpx;
left: 0rpx;
}
.index2 {
width: 100%;
@ -351,5 +356,5 @@
top: 50%;
left: 50%;
transform: translate(-50%,-50%); */
}
}
</style>

@ -47,7 +47,10 @@
<view class="tiptitle">
</view>
<view class="tipcenter">
<u-image :fade="false" :src="loginSuccess" width="156rpx" height="38rpx"></u-image>
<u-image style="padding-top:40rpx" :fade="false" :src="loginSuccess" width="156rpx" height="38rpx"></u-image>
<view style="padding-top:40rpx">
<view v-html="active_tip"></view>
</view>
</view>
<view class="answerBtn">
<view @click="openMe"></view>

@ -54,14 +54,14 @@
<view class="text">最高得分</view>
</view>
</view>
<view>
<view style="padding-bottom:40rpx">
<view class="panel1 panel2" v-for="(item,index) in askList">
<view class="left">
<view class="num">
{{item.score}}<span></span></view>
</view>
<view class="right">
<view class="num">{{countList[index]}}次答题</view>
<view class="num">{{numberToChinese(index+1)}}次答题</view>
<view class="text">{{item.created_at?item.created_at.substring(0,16):''}}</view>
</view>
</view>
@ -91,7 +91,7 @@ export default {
userInfo: {},
answercount:0,
askList:[],
countList:["一","二"],
countList:["一","二","三","四","五","六","七","八","九","十"],
};
},
@ -113,6 +113,30 @@ export default {
}
})
},
numberToChinese(num) {
const chineseDigits = ['零','一', '二', '三', '四', '五', '六', '七', '八', '九'];
const chineseUnits = ['', '十', '百', '千', '万', '亿'];
const numStr = num.toString();
const numLength = numStr.length;
let result = '';
for (let i = 0; i < numLength; i++) {
const digit = parseInt(numStr[i]);
const unit = chineseUnits[numLength - i - 1];
if (digit !== 0) {
result += chineseDigits[digit] + unit;
} else {
if (unit === '十' || unit === '百' || unit === '千') {
result += chineseDigits[digit];
}
}
}
return result;
}
},
onLoad() {
this.userInfo = uni.getStorageSync("userInfo")

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1,2 +1,2 @@
<!DOCTYPE html><html lang=zh-CN><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><title>xietang-answer-h5</title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/h5xtdt/static/index.2da1efab.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/h5xtdt/static/js/chunk-vendors.1e1087a7.js></script><script src=/h5xtdt/static/js/index.f49212e5.js></script></body></html>
<!DOCTYPE html><html lang=zh-CN><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><title>百步芳草 与理同行</title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/h5xtdt/static/index.2da1efab.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/h5xtdt/static/js/chunk-vendors.1e1087a7.js></script><script src=/h5xtdt/static/js/index.206902d3.js></script></body></html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 272 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.8 KiB

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 278 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 813 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 272 KiB

After

Width:  |  Height:  |  Size: 321 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 627 B

@ -1,2 +1,2 @@
<!DOCTYPE html><html lang=zh-CN><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><title>xietang-answer-h5</title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/h5xtdt/static/index.2da1efab.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/h5xtdt/static/js/chunk-vendors.1e1087a7.js></script><script src=/h5xtdt/static/js/index.5b01f2b5.js></script></body></html>
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/h5xtdt/static/index.2da1efab.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/h5xtdt/static/js/chunk-vendors.1e1087a7.js></script><script src=/h5xtdt/static/js/index.f49212e5.js></script></body></html>

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save