yujialong 2 weeks ago
parent 50c331d799
commit f9cae6dd3f
  1. 3
      src/app.config.ts
  2. 3
      src/pages/Customer/index.less
  3. 4
      src/pages/Customer/index.tsx
  4. 25
      src/pages/Home/index.tsx
  5. 6
      src/pages/Subscribe/index.tsx

@ -67,5 +67,6 @@ export default defineAppConfig({
"version": "2.5.2",
"provider": "wxa75efa648b60994b"
}
}
},
"requiredBackgroundModes": ["audio", "location"]
})

@ -4,7 +4,4 @@ page {
.pic {
width: 100vw;
height: 100vh;
// width: 300rpx;
// height: 300rpx;
}

@ -1,7 +1,6 @@
import { Image } from '@tarojs/components'
import Taro, { useShareAppMessage, useShareTimeline } from '@tarojs/taro'
import './index.less'
// import pic from '../../assets/images/1.png'
export default function Customer() {
@ -21,8 +20,7 @@ export default function Customer() {
return (
<Image
src='https://oss.jm-kid.com/wx_5colorflower/icons/customer.svg'
// src={pic}
src='https://oss.jm-kid.com/wx_5colorflower/icons/customer.jpeg'
className='pic'
mode='aspectFill'
show-menu-by-longpress

@ -257,6 +257,31 @@ export default function Home() {
}
const handleBannerClick = (item: any, index: number) => {
// Taro.playBackgroundAudio({
// dataUrl: 'https://alivod.jimeikid.com/sv/3e516a3e-191bb3c3cd6/3e516a3e-191bb3c3cd6.mp3',
// title: '儿童古诗',
// coverImgUrl: 'https://files.jimeikid.com/commodity/b92a701ad285416189e16a6dd406efb1.png'
// })
// const backgroundAudioManager = Taro.getBackgroundAudioManager()
// backgroundAudioManager.title = '此时此刻'
// backgroundAudioManager.epname = '此时此刻'
// backgroundAudioManager.singer = '许巍'
// backgroundAudioManager.coverImgUrl = 'https://y.gtimg.cn/music/photo_new/T002R300x300M000003rsKF44GyaSk.jpg?max_age=2592000'
// backgroundAudioManager.src = 'https://alivod.jimeikid.com/sv/3e516a3e-191bb3c3cd6/3e516a3e-191bb3c3cd6.mp3'
// const innerAudioContext = Taro.createInnerAudioContext()
// innerAudioContext.autoplay = true
// innerAudioContext.src = 'https://storage.360buyimg.com/jdrd-blog/27.mp3'
// innerAudioContext.onPlay(() => {
// console.log('开始播放')
// })
// innerAudioContext.onError((res) => {
// console.log(res.errMsg)
// console.log(res.errCode)
// })
// return
if(item.is_subscribed === 0){
//提醒用户登录
setisLoginOpen(true)

@ -118,7 +118,7 @@ export default function Subscribe() {
if(!singleArr.some((arr_item : any) => arr_item === sec_item)){
sec_item.isFree = 0
sec_item.MallLink = item.MallLink || ''
// sec_item.MallLink = item.MallLink || ''
singleArr.push(sec_item)
c++
}
@ -188,7 +188,7 @@ export default function Subscribe() {
if(!singleArr.some((arr_item : any) => arr_item === sec_item)){
sec_item.isFree = 0
sec_item.MallLink = item.MallLink || ''
// sec_item.MallLink = item.MallLink || ''
singleArr.push(sec_item)
}
}
@ -284,7 +284,7 @@ export default function Subscribe() {
if(!singleArr.some((arr_item : any) => arr_item.PrdtId === sec_item.PrdtId)){
sec_item.isFree = 0
sec_item.MallLink = item.MallLink || ''
// sec_item.MallLink = item.MallLink || ''
singleArr.push(sec_item)
c++
}

Loading…
Cancel
Save