浏览代码

静态页面

1002884655 3 年前
父节点
当前提交
83b746f9bb
共有 1 个文件被更改,包括 33 次插入13 次删除
  1. 33
    13
      src/pages/mine/components/EditUserDetailBasicInfo/index.jsx

+ 33
- 13
src/pages/mine/components/EditUserDetailBasicInfo/index.jsx 查看文件

1
-import React, { useState, useEffect } from 'react'
1
+import { useState, useEffect } from 'react'
2
 import './index.scss'
2
 import './index.scss'
3
-import Taro from '@tarojs/taro'
4
-import { ScrollView, Image, Input } from '@tarojs/components'
3
+import { ScrollView, Input, Picker } from '@tarojs/components'
5
 
4
 
6
 export default function EditUserDetailBasicInfo (props) {
5
 export default function EditUserDetailBasicInfo (props) {
7
-  const { Data = {}, close = () => {} } = props
6
+  const { Data = {}, close = () => { } } = props
7
+
8
+  const [FormData, setFormData] = useState({ ...Data })
9
+
10
+  const [SexList] = useState([
11
+    {name: '男', id: 1},
12
+    {name: '女', id: 2}
13
+  ])
14
+  const [AgeRange] = useState(['18-25', '26-30', '30-35', '36-45', '46-50', '50-60', '60以上'])
15
+  const [IncomeRange] = useState(['10万以下', '10-15万', '15-20万', '20-30万', '30-50万', '50-75万', '75-100万', '100万以上'])
16
+  const [BuyTimeRange] = useState(['1月以内', '1至3月', '半年以内', '一年以内', '一年以上'])
17
+
18
+  const PickerChange = (e, type) => {
19
+
20
+  }
8
 
21
 
9
   return (
22
   return (
10
     <view className='components EditUserDetailBasicInfo'>
23
     <view className='components EditUserDetailBasicInfo'>
11
-      <ScrollView scroll-y={true} refresher-enabled={false} refresher-background='#fff'>
24
+      <ScrollView scroll-y refresher-enabled={false} refresher-background='#fff'>
12
         <view className='PageContent'>
25
         <view className='PageContent'>
13
 
26
 
14
           <text>姓名</text>
27
           <text>姓名</text>
35
           <text>性别</text>
48
           <text>性别</text>
36
           <view className='FormLine flex-h'>
49
           <view className='FormLine flex-h'>
37
             <view className='flex-item'>
50
             <view className='flex-item'>
38
-              <text>请选择</text>
51
+              <Picker range-key='name' onChange={PickerChange.bind(this, 'sex')} value={0} range={SexList}>
52
+                <text>请选择</text>
53
+              </Picker>
39
             </view>
54
             </view>
40
             <text className='iconfont icon-jiantoudown'></text>
55
             <text className='iconfont icon-jiantoudown'></text>
41
           </view>
56
           </view>
57
           <text>年龄段</text>
72
           <text>年龄段</text>
58
           <view className='FormLine flex-h'>
73
           <view className='FormLine flex-h'>
59
             <view className='flex-item'>
74
             <view className='flex-item'>
60
-              <text>请选择</text>
75
+              <Picker onChange={PickerChange.bind(this, 'age')} value={0} range={AgeRange}>
76
+                <text>请选择</text>
77
+              </Picker>
61
             </view>
78
             </view>
62
             <text className='iconfont icon-jiantoudown'></text>
79
             <text className='iconfont icon-jiantoudown'></text>
63
           </view>
80
           </view>
72
           <text>家庭年收入范围</text>
89
           <text>家庭年收入范围</text>
73
           <view className='FormLine flex-h'>
90
           <view className='FormLine flex-h'>
74
             <view className='flex-item'>
91
             <view className='flex-item'>
75
-              <text>请选择</text>
92
+              <Picker onChange={PickerChange.bind(this, 'income')} value={0} range={IncomeRange}>
93
+                <text>请选择</text>
94
+              </Picker>
76
             </view>
95
             </view>
77
             <text className='iconfont icon-jiantoudown'></text>
96
             <text className='iconfont icon-jiantoudown'></text>
78
           </view>
97
           </view>
101
           <text>预计购房时间</text>
120
           <text>预计购房时间</text>
102
           <view className='FormLine flex-h'>
121
           <view className='FormLine flex-h'>
103
             <view className='flex-item'>
122
             <view className='flex-item'>
104
-              <text>请选择</text>
123
+              <Picker onChange={PickerChange.bind(this, 'time')} value={0} range={BuyTimeRange}>
124
+                <text>请选择</text>
125
+              </Picker>
105
             </view>
126
             </view>
106
             <text className='iconfont icon-jiantoudown'></text>
127
             <text className='iconfont icon-jiantoudown'></text>
107
           </view>
128
           </view>
109
           <text>客户咨询重点</text>
130
           <text>客户咨询重点</text>
110
           <view className='FormLine flex-h'>
131
           <view className='FormLine flex-h'>
111
             <view className='flex-item'>
132
             <view className='flex-item'>
112
-              <Input placeholder='请填写  如:地段、交通、社区配套、户型、价格等'></Input>
133
+              <Input placeholder='请填写  如:地段、交通、社区配套、户型、价格等'></Input>
113
             </view>
134
             </view>
114
           </view>
135
           </view>
115
 
136
 
116
           <text>购房动机</text>
137
           <text>购房动机</text>
117
           <view className='FormLine flex-h'>
138
           <view className='FormLine flex-h'>
118
             <view className='flex-item'>
139
             <view className='flex-item'>
119
-              <text>请选择</text>
140
+              <Input placeholder='请填写 如结婚、养老、二孩、改善、学区、投资等'></Input>
120
             </view>
141
             </view>
121
-            <text className='iconfont icon-jiantoudown'></text>
122
           </view>
142
           </view>
123
 
143
 
124
           <text>客户抗性分析</text>
144
           <text>客户抗性分析</text>
125
           <view className='FormLine flex-h'>
145
           <view className='FormLine flex-h'>
126
             <view className='flex-item'>
146
             <view className='flex-item'>
127
-              <Input placeholder='请填写  如:地段、交通、社区配套、户型、价格等'></Input>
147
+              <Input placeholder='请填写  如:地段、交通、社区配套、户型、价格等'></Input>
128
             </view>
148
             </view>
129
           </view>
149
           </view>
130
 
150