--增加判断对象为空方法

--增加表单检索方法
--增加公司资料编辑页面
--增加码单管理页面
--增加码单添加页面
--编辑个人资料、地址管理、码单管理引入图标
This commit is contained in:
li tong bao
2022-04-25 18:09:23 +08:00
parent fa9a6b5d98
commit c6c3b8e21c
27 changed files with 8807 additions and 8643 deletions
+3
View File
@@ -0,0 +1,3 @@
export default {
navigationBarTitleText: '码单管理'
}
+92
View File
@@ -0,0 +1,92 @@
.weight-list-manager{
height: 100vh;
.weight-list-scroll-view{
height: 100%;
box-sizing: border-box;
position: relative;
scroll-view{
height: 100%;
box-sizing: border-box;
}
.weight-list-list{
width: 704px;
height: 156px;
background: #ffffff;
border-radius: 20px;
box-shadow: 2px 4px 12px 0px rgba(0,0,0,0.16);
padding: 30px;
box-sizing: border-box;
margin: 18px auto 0;
border: 1px solid #ffffff;
}
.weight-list-list:hover{
border: 1px solid #68b4ff;
box-shadow: 0px 0px 10px 0px rgba(0,122,255,0.27);
}
.weight-list-list:last-child{
margin-bottom: 300px;
}
.weight-list-user{
font-size: 28px;
font-family: Microsoft YaHei, Microsoft YaHei-Bold;
font-weight: 700;
text-align: left;
color: #000000;
display: flex;align-items: center;
}
.weight-list-list-default{
width: 58px;
height: 28px;
background: #cde5ff;
border-radius: 6px;
font-size: 20px;
font-weight: 400;
text-align: center;
color: #007aff;
margin-left: 30px;
}
.weight-list-list-phone{
font-size: 24px;
font-weight: 400;
color: #ababab;
margin-left: 30px;
}
.weight-list-edit .icon-bianji{
font-size: 40px;
}
.weight-list-list-info{
font-size: 24px;
font-weight: 400;
color: #3c3c3c;
}
.weight-list-list-bottom{
display: flex;justify-content: space-between;
margin-top: 18px;
}
.add-weight-list{
width: 668px;
height: 82px;
background: #007aff;
border-radius: 40px;
font-size: 32px;
font-weight: 400;
color: #ffffff;
display: flex;align-items: center;justify-content: center;
position: absolute;bottom: 8%;left: 50%;
transform: translateX(-50%);
}
.weight-list-no-data{
font-size: 24px;
font-weight: 400;
text-align: center;
color: #707070;
height: 100%;
padding-top: 40%;
box-sizing: border-box;
}
}
}
+65
View File
@@ -0,0 +1,65 @@
import { Button, Navigator, ScrollView, Text, View } from "@tarojs/components"
import { memo, useState } from "react"
import "./index.scss"
const weightListManager = ()=>{
return(
<View className="weight-list-manager">
<WeightList />
</View>
)
}
interface Params{
refresherEnabled?: boolean,//是否开启刷新
onSelect?: (item:any,index:number)=>void,//列表选择
}
// 码单列表
const WeightList = memo((props:Params)=>{
// 处理刷新
const [refreshState, setRefreshState] = useState(false);
const handleRefresh = ()=>{
setRefreshState(true);
setTimeout(()=>{
setRefreshState(false);
},500)
}
const data = Array.from({length:15});
return (
<View className="weight-list-scroll-view">
<ScrollView scrollY refresherEnabled={props.refresherEnabled} enhanced refresherTriggered={refreshState} onRefresherRefresh={handleRefresh}>
{
data.length>0?
data.map((item,index)=>{
return(
<View onClick={()=>props.onSelect&&props.onSelect(item,index)} className="weight-list-list">
<View className="weight-list-user">
XL纺织
<Text className="weight-list-list-default">默认</Text>
{/* <Text className="weight-list-list-phone">1656488999</Text> */}
</View>
<View className="weight-list-list-bottom">
<View className="weight-list-list-info">
**省**市**区**街道****仓库
<Text className="weight-list-list-phone">181****9790</Text>
</View>
<Navigator url="/pages/weightListAdd/index?type=edit" hoverClass="none" className="weight-list-edit">
<Text className="iconfont icon-bianji"></Text>
</Navigator>
</View>
</View>
);
}):
<View className="weight-list-no-data">暂未添加地址</View>
}
</ScrollView>
<Navigator url="/pages/weightListAdd/index?type=add" hoverClass="none" className="add-weight-list">添加新码单信息</Navigator>
</View>
)
})
export default weightListManager;