登录封装完成

This commit is contained in:
2022-05-09 10:03:33 +08:00
parent 5bae62d34d
commit e7a130533d
19 changed files with 604 additions and 70 deletions
+3
View File
@@ -20,6 +20,9 @@
text-align: center;
line-height: 44px;
}
.search_input{
width: 300px;
}
}
.products{
flex:1;
+1 -23
View File
@@ -10,7 +10,7 @@ import { goLink } from '@/common/common'
import { useEffect, useState } from 'react'
import Taro, { useDidShow, usePullDownRefresh, useRouter } from '@tarojs/taro'
import useManualPullDownRefresh from '@/use/useManualPullDownRefresh'
import useUserInfo from '@/use/useUserInfo'
export default () => {
const tabs_list = [
@@ -47,31 +47,9 @@ export default () => {
}, 1000)
}
const goto = function (e) {
var t = this
Taro.navigateTo({
url: '/pages/details/index',
events: {
// 为指定事件添加一个监听器,获取被打开页面传送到当前页面的数据
backFromTargetPage: function (backData) {
console.log('好啦,可以在这里写你的逻辑了', backData)
if (backData.from == 'page2') {
// 监听到 page2 返回
console.log('好啦,可以在这里写你的逻辑了', backData)
t.setData({
isBackFromPage2: !0
})
}
}
}
})
}
return (
<MoveBtn onClick={() => setShowShopCart(!showShopCart)}>
<View className={styles.main}>
<View onClick={(e) => goto(e)}>aaa</View>
<Swiper/>
<View className={styles.search}>
<View className={styles.search_collect}>我的收藏</View>