许静 5 anos atrás
pai
commit
d15675c027

+ 7
- 2
config/config.js Ver arquivo

144
                   name: '客户列表',
144
                   name: '客户列表',
145
                   component: './customer/customerlist/index',
145
                   component: './customer/customerlist/index',
146
                 },
146
                 },
147
+                {
148
+                  path: '/customer/customerlist/customerDetail',
149
+                  name: '',
150
+                  component: './customer/customerlist/customerDetail',
151
+                },
147
                 {
152
                 {
148
                   path: '/customer/drift/list',
153
                   path: '/customer/drift/list',
149
                   name: '游客列表',
154
                   name: '游客列表',
310
                   name: '',
315
                   name: '',
311
                   component: './staff/list/editStaff',
316
                   component: './staff/list/editStaff',
312
                 },
317
                 },
313
-             
318
+
314
                 {
319
                 {
315
                   path: '/staff/RoleList',
320
                   path: '/staff/RoleList',
316
                   name: '角色管理',
321
                   name: '角色管理',
321
                   name: '',
326
                   name: '',
322
                   component: './staff/list/editRole',
327
                   component: './staff/list/editRole',
323
                 },
328
                 },
324
-             
329
+
325
               ],
330
               ],
326
             },
331
             },
327
             {
332
             {

+ 88
- 0
src/pages/customer/customerlist/customerDetail.jsx Ver arquivo

1
+import React, { useState, useEffect } from 'react';
2
+import { Form, Table } from 'antd';
3
+import { FormattedMessage } from 'umi-plugin-react/locale';
4
+import styles from './style.less';
5
+
6
+import router from 'umi/router';
7
+
8
+
9
+function header(props) {
10
+
11
+  /**
12
+   * @param {*} props
13
+   * @returns
14
+   */
15
+  const [data, setData] = useState([{ records: [] }])
16
+
17
+  const columns = [
18
+    {
19
+      title: '访问事件',
20
+      dataIndex: 'event',
21
+      key: 'event',
22
+      align: 'center',
23
+    },
24
+    {
25
+      title: '访问时间',
26
+      dataIndex: 'time',
27
+      key: 'time',
28
+      align: 'center',
29
+
30
+    },
31
+    {
32
+      title: '停留时间',
33
+      dataIndex: 'stayTime',
34
+      key: 'stayTime',
35
+      align: 'center',
36
+    },
37
+  ]
38
+  return (
39
+    <>
40
+      <div className={styles.cardBox}>
41
+        <div className={styles.leftBox}>
42
+          <p className={styles.tit}>置业顾问信息</p>
43
+          <img className={styles.touxiang} src="http://img0.imgtn.bdimg.com/it/u=4246326797,2657995307&fm=26&gp=0.jpg" />
44
+          <p className={styles.infoItem}>姓名:赵海伟</p>
45
+          <p className={styles.infoItem}>部门:营销部</p>
46
+          <p className={styles.infoItem}>岗位:营销经理</p>
47
+          <p className={styles.infoItem}>号码:13160056061 </p>
48
+          <p className={styles.infoItem}>公司:葛洲坝·南京中国府</p>
49
+          <p className={styles.infoItem}>所属项目:葛洲坝·南京中国府</p>
50
+        </div>
51
+        <div className={styles.rightBox}>
52
+          <p className={styles.tit}>客户信息</p>
53
+          <img className={styles.touxiang} src="http://img0.imgtn.bdimg.com/it/u=4246326797,2657995307&fm=26&gp=0.jpg" />
54
+          <div className={styles.right}>
55
+            <p className={styles.rightItem}>用户名称:董浩业</p>
56
+            <p className={styles.rightItem}>手机号码:15050893674</p>
57
+            <p className={styles.rightItem}>来访渠道:活动分享</p>
58
+          </div>
59
+          <p className={styles.rightItem}>访问时长:0秒</p>
60
+          <p className={styles.rightItem}>访问次数:</p>
61
+          <p className={styles.rightItem}>预约人数:</p>
62
+          <p className={styles.rightItem}>首次访问时间:</p>
63
+          <p className={styles.rightItem}>预约到访时间:</p>
64
+          <div className={styles.rightInfo}>
65
+            <p className={styles.rightItem}>国家:</p>
66
+            <p className={styles.rightItem}>省份:</p>
67
+            <p className={styles.rightItem}>城市:</p>
68
+            <p className={styles.rightItem}>详细信息:</p>
69
+            <p className={styles.rightItem}>意向项目:</p>
70
+            <p className={styles.rightItem}>价格区间:</p>
71
+            <p className={styles.rightItem}>客户说明:</p>
72
+            <p className={styles.rightItem}>客户描述:</p>
73
+            <p className={styles.rightItem}>需求类型:</p>
74
+            <p className={styles.rightItem}>物业类型:</p>
75
+          </div>
76
+        </div>
77
+      </div>
78
+      <div className={styles.recordBox}>
79
+        <p className={styles.tableName}>访问记录</p>
80
+        <Table dataSource={data.records} columns={columns} pagination={false} />
81
+      </div>
82
+
83
+    </>
84
+  )
85
+}
86
+const WrappedHeader = Form.create({ name: 'header' })(header);
87
+
88
+export default WrappedHeader

+ 31
- 25
src/pages/customer/customerlist/index.jsx Ver arquivo

4
 import request from '../../../utils/request';
4
 import request from '../../../utils/request';
5
 import apis from '../../../services/apis';
5
 import apis from '../../../services/apis';
6
 import Styles from './style.less';
6
 import Styles from './style.less';
7
+import router from 'umi/router';
7
 
8
 
8
 import Attribution from './components/attribution'
9
 import Attribution from './components/attribution'
9
 import IntegralRecord from './components/integralRecord'
10
 import IntegralRecord from './components/integralRecord'
27
   const [dataSource, setDataSource] = useState({ records: [] })
28
   const [dataSource, setDataSource] = useState({ records: [] })
28
 
29
 
29
   // 默认私客
30
   // 默认私客
30
-    // eslint-disable-next-line react-hooks/rules-of-hooks
31
+  // eslint-disable-next-line react-hooks/rules-of-hooks
31
   const [customerType, setCustomerType] = useState('private')
32
   const [customerType, setCustomerType] = useState('private')
32
 
33
 
33
   // 调整归属 ============  start
34
   // 调整归属 ============  start
95
   // 分页
96
   // 分页
96
   function onChange(pageNum) {
97
   function onChange(pageNum) {
97
     // eslint-disable-next-line react-hooks/rules-of-hooks
98
     // eslint-disable-next-line react-hooks/rules-of-hooks
98
-      getList({ pageNumber: pageNum, pageSize: 10, customerType })
99
+    getList({ pageNumber: pageNum, pageSize: 10, customerType })
99
   }
100
   }
100
 
101
 
101
   // 私客/公客切换
102
   // 私客/公客切换
127
     setGVisibleData({ visible: false, customerId: '', realtyConsultant: '' })
128
     setGVisibleData({ visible: false, customerId: '', realtyConsultant: '' })
128
     setStatusVisibleData({ visible: true, customerId: record.customerId, status: record.status })
129
     setStatusVisibleData({ visible: true, customerId: record.customerId, status: record.status })
129
   }
130
   }
131
+  function toCustomerDateil() {
132
+    router.push({
133
+      pathname: '/customer/customerlist/customerDetail',
134
+    });
135
+  }
130
 
136
 
131
   const columns = [
137
   const columns = [
132
     {
138
     {
133
       title: '头像',
139
       title: '头像',
134
       dataIndex: 'picture',
140
       dataIndex: 'picture',
135
       key: 'picture',
141
       key: 'picture',
136
-      render: (_, record) => <Avatar shape="square" src={customerType === 'private' ? record.picture : record.avatarurl } size={64} icon="user" />,
142
+      render: (_, record) => <Avatar shape="square" src={customerType === 'private' ? record.picture : record.avatarurl} size={64} icon="user" />,
137
     },
143
     },
138
     {
144
     {
139
       title: '姓名',
145
       title: '姓名',
140
       dataIndex: 'name',
146
       dataIndex: 'name',
141
       key: 'name',
147
       key: 'name',
142
       // eslint-disable-next-line no-nested-ternary
148
       // eslint-disable-next-line no-nested-ternary
143
-      render: (_, record) => <><sapn>{ customerType === 'private' ? record.name : record.nickname }</sapn></>,
149
+      render: (_, record) => <><sapn>{customerType === 'private' ? record.name : record.nickname}</sapn></>,
144
     },
150
     },
145
     {
151
     {
146
       title: '电话',
152
       title: '电话',
152
       dataIndex: 'sex',
158
       dataIndex: 'sex',
153
       key: 'sex',
159
       key: 'sex',
154
       // eslint-disable-next-line no-nested-ternary
160
       // eslint-disable-next-line no-nested-ternary
155
-      render: (_, record) => <><sapn>{ record.sex === 1 ? '男' : record.sex === 2 ? '女' : '未知' }</sapn></>,
161
+      render: (_, record) => <><sapn>{record.sex === 1 ? '男' : record.sex === 2 ? '女' : '未知'}</sapn></>,
156
     },
162
     },
157
     {
163
     {
158
       title: '置业顾问',
164
       title: '置业顾问',
161
       // eslint-disable-next-line no-nested-ternary
167
       // eslint-disable-next-line no-nested-ternary
162
       render: (_, record) => (
168
       render: (_, record) => (
163
         <>
169
         <>
164
-          <sapn>{ record.consultantName }</sapn>
165
-          <br/>
166
-          <sapn>{ record.consultTel }</sapn>
170
+          <sapn>{record.consultantName}</sapn>
171
+          <br />
172
+          <sapn>{record.consultTel}</sapn>
167
         </>
173
         </>
168
       ),
174
       ),
169
     },
175
     },
171
       title: '客户状态',
177
       title: '客户状态',
172
       dataIndex: 'reportRecommendStatus',
178
       dataIndex: 'reportRecommendStatus',
173
       key: 'reportRecommendStatus',
179
       key: 'reportRecommendStatus',
174
-       // eslint-disable-next-line no-nested-ternary
175
-       render: (_, record) => <><sapn>{ record.reportRecommendStatus === 0 ? '为报备' : record.reportRecommendStatus === 1 ? '报备' : record.reportRecommendStatus === 2 ? '推荐' : '' }</sapn></>,
180
+      // eslint-disable-next-line no-nested-ternary
181
+      render: (_, record) => <><sapn>{record.reportRecommendStatus === 0 ? '为报备' : record.reportRecommendStatus === 1 ? '报备' : record.reportRecommendStatus === 2 ? '推荐' : ''}</sapn></>,
176
     },
182
     },
177
     {
183
     {
178
       title: '操作',
184
       title: '操作',
181
       // eslint-disable-next-line no-nested-ternary
187
       // eslint-disable-next-line no-nested-ternary
182
       render: (_, record) => (
188
       render: (_, record) => (
183
         <>
189
         <>
184
-          <Button className={ customerType === 'private' ? Styles.text : Styles.displayS } type="link" onClick={() => showStatus(record)}>变更状态</Button>
190
+          <Button className={customerType === 'private' ? Styles.text : Styles.displayS} type="link" onClick={() => showStatus(record)}>变更状态</Button>
185
           &nbsp;&nbsp;
191
           &nbsp;&nbsp;
186
-          <Button className={ customerType === 'private' ? Styles.text : Styles.displayS } type="link" onClick={() => showGM(record)}>调整归属</Button>
187
-          <br/>
188
-          <Button className={ customerType === 'private' ? Styles.text : Styles.displayS } type="link">查看详情</Button>
192
+          <Button className={customerType === 'private' ? Styles.text : Styles.displayS} type="link" onClick={() => showGM(record)}>调整归属</Button>
193
+          <br />
194
+          <Button className={customerType === 'private' ? Styles.text : Styles.displayS} type="link" onClick={toCustomerDateil}>查看详情</Button>
189
           &nbsp;&nbsp;
195
           &nbsp;&nbsp;
190
-          <Button className={ customerType === 'private' ? Styles.text : Styles.displayS } type="link" onClick={ () => showRecord(record) }>积分记录</Button>
196
+          <Button className={customerType === 'private' ? Styles.text : Styles.displayS} type="link" onClick={() => showRecord(record)}>积分记录</Button>
191
         </>
197
         </>
192
       ),
198
       ),
193
     },
199
     },
245
         </Form.Item>
251
         </Form.Item>
246
       </Form>
252
       </Form>
247
 
253
 
248
-       <div style={{ marginTop: '20px', marginBottom: '20px' }}>
254
+      <div style={{ marginTop: '20px', marginBottom: '20px' }}>
249
         <Radio.Group value={customerType} onChange={radioButtonHandleSizeChange} buttonStyle="solid">
255
         <Radio.Group value={customerType} onChange={radioButtonHandleSizeChange} buttonStyle="solid">
250
-            <Radio.Button value="private">私客</Radio.Button>
251
-            <Radio.Button value="public">公客</Radio.Button>
256
+          <Radio.Button value="private">私客</Radio.Button>
257
+          <Radio.Button value="public">公客</Radio.Button>
252
         </Radio.Group>
258
         </Radio.Group>
253
-       </div>
259
+      </div>
254
       <Table dataSource={dataSource.records} columns={columns} pagination={{ total: dataSource.total, onChange }} />
260
       <Table dataSource={dataSource.records} columns={columns} pagination={{ total: dataSource.total, onChange }} />
255
 
261
 
256
-        {/* 调整归属 */}
257
-        <Attribution visibleData={gVisibleData} />
262
+      {/* 调整归属 */}
263
+      <Attribution visibleData={gVisibleData} />
258
 
264
 
259
-        {/* 积分记录 */}
260
-        <IntegralRecord visibleData={recordVisibleData} />
265
+      {/* 积分记录 */}
266
+      <IntegralRecord visibleData={recordVisibleData} />
261
 
267
 
262
-        {/* 变更状态 */}
263
-        <ChangeStatus visibleData={statusVisibleData} />
268
+      {/* 变更状态 */}
269
+      <ChangeStatus visibleData={statusVisibleData} />
264
     </>
270
     </>
265
   );
271
   );
266
 }
272
 }

+ 78
- 0
src/pages/customer/customerlist/style.less Ver arquivo

70
 .displayS {
70
 .displayS {
71
   display: none;
71
   display: none;
72
 }
72
 }
73
+
74
+
75
+// 客户详情样式
76
+.cardBox{
77
+  display: flex;
78
+  .leftBox{
79
+    width:342px;
80
+    min-width:342px;
81
+    height:511px;
82
+    background:rgba(255,255,255,1);
83
+    box-shadow:0px 0px 16px 2px rgba(0,0,0,0.12);
84
+    border-radius:8px;
85
+    display: inline-block;
86
+    margin-right: 30px;
87
+    padding: 30px;
88
+    overflow: hidden;
89
+  }
90
+  .rightBox{
91
+    width:-webkit-fill-available;
92
+    height:511px;
93
+    min-width: 800px;
94
+    background:rgba(255,255,255,1);
95
+    box-shadow:0px 0px 16px 2px rgba(0,0,0,0.12);
96
+    border-radius:8px;
97
+    display: inline-block;
98
+    padding: 30px;
99
+    overflow: hidden;
100
+    position: relative;
101
+  }
102
+  .tit{
103
+    font-size:24px;
104
+    font-weight:600;
105
+    color:#222;
106
+    margin: 10px 0 0 0;
107
+  }
108
+  .touxiang{
109
+    width: 120px;
110
+    width: 120px;
111
+    border-radius: 6px;
112
+    margin: 30px 0 20px 0;
113
+  }
114
+  .infoItem{
115
+    color:#666;
116
+    font-size: 19px;
117
+    margin: 0 0 10px 0;
118
+    
119
+  }
120
+  .rightItem{
121
+    color:#666;
122
+    font-size: 19px;
123
+    margin: 0 0 15px 0;
124
+  }
125
+  .right{
126
+    position: absolute;
127
+    top:108px;
128
+    left:170px;
129
+  }
130
+  .rightInfo{
131
+    position: absolute;
132
+    top:50px;
133
+    left:50%;
134
+  }
135
+  
136
+}
137
+.recordBox{
138
+  width:100%;
139
+  background:rgba(255,255,255,1);
140
+  box-shadow:0px 0px 16px 2px rgba(0,0,0,0.12);
141
+  border-radius:8px;
142
+  margin-top: 30px;
143
+  padding: 30px;
144
+  .tableName{
145
+    font-size:24px;
146
+    font-weight:600;
147
+    color:#222;
148
+  }
149
+}
150
+

+ 1
- 1
src/pages/integralMall/writeOff.jsx Ver arquivo

95
       router.push({
95
       router.push({
96
         pathname: '/integralMall/verifyList',
96
         pathname: '/integralMall/verifyList',
97
         query: {
97
         query: {
98
-          codeValue
98
+          telValue:codeValue
99
         },
99
         },
100
       });
100
       });
101
     }
101
     }