Sfoglia il codice sorgente

Merge branch 'master' of http://git.ycjcjy.com/zhiyuxing/estateagents-admin-manager

许静 5 anni fa
parent
commit
2ddce75acb

+ 6
- 1
config/config.js Vedi File

@@ -139,6 +139,11 @@ export default {
139 139
               name: '客户管理',
140 140
               component: '../layouts/BlankLayout',
141 141
               routes: [
142
+                {
143
+                  path: '/customer/customerlist/list',
144
+                  name: '客户列表',
145
+                  component: './customer/customerlist/index',
146
+                },
142 147
                 {
143 148
                   path: '/customer/drift/list',
144 149
                   name: '游客列表',
@@ -332,7 +337,7 @@ export default {
332 337
 
333 338
   proxy: {
334 339
     '/api/': {
335
-      target: 'http://192.168.0.84:8080/',
340
+      target: 'http://localhost:8080/',
336 341
       changeOrigin: true,
337 342
       // pathRewrite: { '^/server': '' },
338 343
     },

+ 6
- 2
src/pages/channel/addChannel.jsx Vedi File

@@ -37,7 +37,10 @@ const header = props => {
37 37
       if (!err) {
38 38
         console.log('Received values of form: ', values);
39 39
         // eslint-disable-next-line max-len
40
-        addChannel({ channelName: values.channelName, channelContact: values.channelContact, contactTel: values.contactTel })
40
+        addChannel({ channelName: values.channelName,
41
+                     channelContact: values.channelContact,
42
+                     contactTel: values.contactTel,
43
+                     explain: values.explain })
41 44
       }
42 45
     });
43 46
   }
@@ -63,7 +66,8 @@ const header = props => {
63 66
           })(<Input className={channels.inpuit} />)}
64 67
         </Form.Item>
65 68
         <Form.Item label="说明描述">
66
-       <TextArea className={channels.inpuitTxt} rows={8} />
69
+        {getFieldDecorator('explain', {
70
+        })(<TextArea className={channels.inpuitTxt} rows={8} />)}
67 71
         </Form.Item>
68 72
         <Form.Item wrapperCol={{ span: 15, offset: 7 }}>
69 73
           <Button type="primary" htmlType="submit">

+ 55
- 19
src/pages/channel/brokerList.jsx Vedi File

@@ -61,8 +61,8 @@ const columns = [
61 61
   },
62 62
   {
63 63
     title: '电话',
64
-    dataIndex: 'tel',
65
-    key: 'tel',
64
+    dataIndex: 'phone',
65
+    key: 'phone',
66 66
     align: 'center',
67 67
   },
68 68
   {
@@ -94,46 +94,82 @@ function toEditGoods() {
94 94
     },
95 95
   });
96 96
 }
97
+
97 98
 const header = props => {
98 99
   // eslint-disable-next-line react-hooks/rules-of-hooks
99 100
   const [data, setData] = useState({})
101
+
102
+  // eslint-disable-next-line react-hooks/rules-of-hooks
103
+  const [queryData, setQueryData] = useState({})
100 104
 //   const [page, changePage] = useState({})
101 105
   // eslint-disable-next-line react-hooks/rules-of-hooks
102 106
   useEffect(() => {
103
-    request({
107
+    getList()
108
+  }, [])
109
+      function getList(params) {
110
+      request({
104 111
         url: '/api/admin/channel/broker',
105 112
         method: 'GET',
106
-        params: { pageNum: 1, pageSize: 10 },
113
+        params: { ...params },
107 114
     // eslint-disable-next-line no-shadow
108 115
     }).then(data => {
109 116
         console.log(data)
110 117
         setData(data)
111 118
     })
112
-  }, [])
119
+    }
120
+  // const getList = e => {
121
+  //   request({
122
+  //       url: '/api/xxx',
123
+  //       method: 'GET',
124
+  //       params: {},
125
+  //   // eslint-disable-next-line no-shadow
126
+  //   }).then(data => {
127
+  //       setData(data)
128
+  //   })
129
+  // }
130
+ // 查询
131
+ function queryList() {
132
+  getList({ ...queryData, pageNum: 1, pageSize: 10, channelId: localStorage.getItem('value') })
133
+}
134
+    // 分页
135
+    function onChange(pageNumber) {
136
+      // eslint-disable-next-line react-hooks/rules-of-hooks
137
+        getList({ pageNum: pageNumber, pageSize: 10 })
138
+    }
139
+    // 获取input的值
140
+    function onInputChangePhone (e) {
141
+      // const InputValue = e.target.name.x.value;
142
+      setQueryData({ ...queryData, name: e.target.value })
143
+   }
113 144
 
114
-  const getList = e => {
115
-    request({
116
-        url: '/api/xxx',
117
-        method: 'GET',
118
-        params: {},
119
-    // eslint-disable-next-line no-shadow
120
-    }).then(data => {
121
-        setData(data)
122
-    })
145
+   function onInputChangeName (e) {
146
+    // const InputValue = e.target.name.x.value;
147
+    setQueryData({ ...queryData, phone: e.target.value })
148
+  }
149
+  function refurbishList () {
150
+    getList({ pageNum: 1, pageSize: 10 })
151
+  }
152
+  // eslint-disable-next-line no-undef
153
+  function handleClick() {
154
+    alert('11', this)
155
+    console.log('this is:', this);
123 156
   }
124
-
125 157
 return (
126 158
   <>
127 159
     <div className={ channels.searchBox }>
128 160
       <div>
129 161
         <span className={ channels.selectName }>姓名</span>
130
-        <Input style ={{ width: 150 }} />
162
+        <Input onChange = { onInputChangePhone } style ={{ width: 150 }} />
131 163
         <span className={ channels.selectName }>电话</span>
132
-        <Input style ={{ width: 150 }}/>
164
+        <Input onChange = { onInputChangeName } style ={{ width: 150 }} />
165
+        <Input value={handleClick} style ={{ width: 150 }} />
133 166
       </div>
134
-      <Button className={channels.about}>查询</Button>
167
+      <div>
168
+      <Button className={channels.about} onClick={() => queryList() }>查询</Button>
169
+      <Button onClick={() => refurbishList() }>重置</Button>
170
+    </div>
135 171
     </div>
136
-    <Table dataSource={data.records} columns={columns} />
172
+    <Table dataSource={data.records} columns={columns} pagination={{ pageSize: 10, total: data.total, onChange }} />
137 173
   </>
138 174
 )
139 175
 }

+ 33
- 10
src/pages/channel/channelList.jsx Vedi File

@@ -1,5 +1,5 @@
1 1
 import React, { useState, useEffect } from 'react';
2
-import { Input, Menu, Dropdown, Button, Icon, message, Table, Divider, Tag, Select } from 'antd';
2
+import { Input, Menu, Dropdown, Button, Icon, message, Table, Divider, Tag, Select, Pagination } from 'antd';
3 3
 import { FormattedMessage } from 'umi-plugin-react/locale';
4 4
 import channels from './channelList.less';
5 5
 import router from 'umi/router';
@@ -81,12 +81,12 @@ const columns = [
81 81
     dataIndex: '',
82 82
     key: '',
83 83
     align: 'center',
84
-    render: () => <a style={ { color: '#66B3FF' } }>编辑</a>,
84
+    render: (text, record) => <a style={ { color: '#66B3FF' } } onClick= {() => toedit(record.channelId)} >编辑</a>,
85 85
   },
86 86
 ];
87 87
 
88
-// 跳转到编辑商品
89
-function toEditGoods() {
88
+// 跳转到添加页面
89
+function toAdd() {
90 90
   router.push({
91 91
     pathname: '/channel/addChannel',
92 92
     query: {
@@ -94,14 +94,21 @@ function toEditGoods() {
94 94
     },
95 95
   });
96 96
 }
97
+  // 跳编辑页面
98
+  function toedit(channelId) {
99
+    // alert(channelId)
100
+    router.push({
101
+      pathname: '/channel/editChannel',
102
+      query: {
103
+        id: channelId,
104
+      },
105
+    });
106
+  }
97 107
 
98 108
 const header = props => {
99 109
   // eslint-disable-next-line react-hooks/rules-of-hooks
100 110
   const [data, setData] = useState({ channelNmae: [], result: [] })
101 111
   // eslint-disable-next-line react-hooks/rules-of-hooks
102
-  // const [queryData, setQueryData] = useState({ pageNum: 1, pageSize: 10 })
103
-  //   const [page, changePage] = useState({})
104
-  // eslint-disable-next-line react-hooks/rules-of-hooks
105 112
   useEffect(() => {
106 113
     getList({ pageNum: 1, pageSize: 10 })
107 114
   }, [])
@@ -130,6 +137,23 @@ const header = props => {
130 137
  function reset() {
131 138
   getList({ pageNum: 1, pageSize: 10 })
132 139
  }
140
+
141
+ // 跳编辑页
142
+ function toEdit() {
143
+  router.push({
144
+    pathname: '/integralMall/editGoods',
145
+    query: {
146
+      a: 'b',
147
+    },
148
+  });
149
+}
150
+
151
+  // 分页
152
+  function onChange(pageNumber) {
153
+    // eslint-disable-next-line react-hooks/rules-of-hooks
154
+      getList({ pageNum: pageNumber, pageSize: 9 })
155
+  }
156
+
133 157
   return (
134 158
     <>
135 159
       <div className={channels.searchBox}>
@@ -142,15 +166,14 @@ const header = props => {
142 166
               )}
143 167
               {/* {listItems} */}
144 168
           </Select>
145
-
146 169
         </dvi>
147 170
         <div >
148 171
         <Button style ={{ backgroundColor: '#00bfff' } } onClick={() => queryList() }>查询</Button>
149 172
         <Button onClick={() => reset() }>重置</Button>
150 173
         </div>
151 174
       </div>
152
-      <Button className={channels.addBtn} onClick={toEditGoods}>新增</Button>
153
-      <Table dataSource={data.result.records} columns={columns} />
175
+      <Button className={channels.addBtn} onClick={toAdd}>新增</Button>
176
+      <Table dataSource={data.result.records} columns={columns} pagination={{ pageSize: 10, total: data.result.total, onChange }} />
154 177
   </>
155 178
   )
156 179
 }

+ 17
- 18
src/pages/channel/recommendClients.jsx Vedi File

@@ -106,31 +106,30 @@ const header = props => {
106 106
 //   const [page, changePage] = useState({})
107 107
   // eslint-disable-next-line react-hooks/rules-of-hooks
108 108
   useEffect(() => {
109
-    request({
110
-        url: '/api/admin/customer/recommend/recommender',
111
-        method: 'GET',
112
-        params: { pageNum: 1, pageSize: 10 },
113
-    // eslint-disable-next-line no-shadow
114
-    }).then(data => {
115
-        console.log(data)
116
-        setData(data)
117
-    })
109
+    getList({ pageNumber: 1, pageSize: 10 })
118 110
   }, [])
119 111
 
120
-  const getList = e => {
112
+  function getList(params) {
121 113
     request({
122
-        url: '/api/xxx',
123
-        method: 'GET',
124
-        params: {},
125
-    // eslint-disable-next-line no-shadow
126
-    }).then(data => {
127
-        setData(data)
128
-    })
114
+      url: '/api/admin/customer/recommend/recommender',
115
+      method: 'GET',
116
+      params: { ...params },
117
+  // eslint-disable-next-line no-shadow
118
+  }).then(data => {
119
+      console.log(data)
120
+      setData(data)
121
+  })
129 122
   }
130 123
 
124
+
125
+   // 分页
126
+ function onChange(pageNum) {
127
+      // eslint-disable-next-line react-hooks/rules-of-hooks
128
+        getList({ pageNumber: pageNum, pageSize: 9 })
129
+    }
131 130
 return (
132 131
   <>
133
-    <Table dataSource={data.records} columns={columns} />
132
+  <Table dataSource={data.records} columns={columns} pagination={{ pageSize: 10, total: data.total, onChange }} />
134 133
   </>
135 134
 )
136 135
 }

+ 211
- 0
src/pages/customer/customerlist/index.jsx Vedi File

@@ -0,0 +1,211 @@
1
+import React, { useState, useEffect } from 'react';
2
+import { Form, Icon, Input, Button, DatePicker, Select, Card, Row, Col, Pagination, Alert, Table, Avatar, Radio } from 'antd';
3
+import moment from 'moment';
4
+import request from '../../../utils/request';
5
+import apis from '../../../services/apis';
6
+import Styles from './style.less';
7
+
8
+
9
+const { Option } = Select;
10
+// eslint-disable-next-line @typescript-eslint/no-unused-vars
11
+const { Meta } = Card;
12
+
13
+const tempDate = [{ code: 's101' }]
14
+
15
+/**
16
+ *
17
+ *
18
+ * @param {*} props
19
+ * @returns
20
+ */
21
+function body(props) {
22
+  const { getFieldDecorator } = props.form
23
+
24
+  // eslint-disable-next-line react-hooks/rules-of-hooks
25
+  const [dataSource, setDataSource] = useState({ records: [] })
26
+
27
+  // 默认私客
28
+    // eslint-disable-next-line react-hooks/rules-of-hooks
29
+  const [customerType, setCustomerType] = useState('private')
30
+
31
+  // eslint-disable-next-line react-hooks/rules-of-hooks
32
+  useEffect(() => {
33
+    getList({ pageNumber: 1, pageSize: 10, customerType })
34
+  }, [])
35
+
36
+  function getList(params) {
37
+    // 网路请求
38
+    request({ ...apis.customer.customerRecommend, params: { ...params } }).then(res => {
39
+      setDataSource(res)
40
+    }).catch(err => {
41
+      // eslint-disable-next-line no-unused-expressions
42
+      <Alert
43
+        style={{
44
+          marginBottom: 24,
45
+        }}
46
+        message={err}
47
+        type="error"
48
+        showIcon
49
+      />
50
+    })
51
+  }
52
+
53
+  // 提交事件
54
+  function handleSubmit(e) {
55
+    e.preventDefault();
56
+    props.form.validateFields((err, values) => {
57
+      if (!err) {
58
+        getList({ pageNum: 1, pageSize: 10, customerType, ...values })
59
+      }
60
+    });
61
+  }
62
+
63
+  // Change 事件
64
+  function handleSelectChange(e) {
65
+    // eslint-disable-next-line no-console
66
+    console.log(e)
67
+  }
68
+
69
+  // 分页
70
+  function onChange(pageNum) {
71
+    // eslint-disable-next-line react-hooks/rules-of-hooks
72
+      getList({ pageNumber: pageNum, pageSize: 10, customerType })
73
+  }
74
+
75
+  // 私客/公客切换
76
+  function radioButtonHandleSizeChange(e) {
77
+    const { value } = e.target
78
+    setCustomerType(value)
79
+    getList({ pageNumber: 1, pageSize: 10, customerType: value })
80
+  }
81
+
82
+  const columns = [
83
+    {
84
+      title: '头像',
85
+      dataIndex: 'picture',
86
+      key: 'picture',
87
+      render: (_, record) => <Avatar shape="square" src={customerType === 'private' ? record.picture : record.avatarurl } size={64} icon="user" />,
88
+    },
89
+    {
90
+      title: '姓名',
91
+      dataIndex: 'name',
92
+      key: 'name',
93
+      // eslint-disable-next-line no-nested-ternary
94
+      render: (_, record) => <><sapn>{ customerType === 'private' ? record.name : record.nickname }</sapn></>,
95
+    },
96
+    {
97
+      title: '电话',
98
+      dataIndex: 'phone',
99
+      key: 'phone',
100
+    },
101
+    {
102
+      title: '性别',
103
+      dataIndex: 'sex',
104
+      key: 'sex',
105
+      // eslint-disable-next-line no-nested-ternary
106
+      render: (_, record) => <><sapn>{ record.sex === 1 ? '男' : record.sex === 2 ? '女' : '未知' }</sapn></>,
107
+    },
108
+    {
109
+      title: '置业顾问',
110
+      dataIndex: 'consultantName',
111
+      key: 'consultantName',
112
+      // eslint-disable-next-line no-nested-ternary
113
+      render: (_, record) => (
114
+        <>
115
+          <sapn>{ record.consultantName }</sapn>
116
+          <br/>
117
+          <sapn>{ record.consultTel }</sapn>
118
+        </>
119
+      ),
120
+    },
121
+    {
122
+      title: '客户状态',
123
+      dataIndex: 'reportRecommendStatus',
124
+      key: 'reportRecommendStatus',
125
+       // eslint-disable-next-line no-nested-ternary
126
+       render: (_, record) => <><sapn>{ record.reportRecommendStatus === 0 ? '为报备' : record.reportRecommendStatus === 1 ? '报备' : record.reportRecommendStatus === 2 ? '推荐' : '' }</sapn></>,
127
+    },
128
+    {
129
+      title: '操作',
130
+      dataIndex: 'customerId',
131
+      key: 'customerId',
132
+      // eslint-disable-next-line no-nested-ternary
133
+      render: (_, record) => (
134
+        <>
135
+          <sapn className={ customerType === 'private' ? Styles.text : Styles.displayS }>变更状态</sapn>
136
+          &nbsp;&nbsp;
137
+          <sapn className={  customerType === 'private' ? Styles.text : Styles.displayS }>调整归属</sapn>
138
+          <br/>
139
+          <sapn className={ Styles.text }>查看详情</sapn>
140
+          &nbsp;&nbsp;
141
+          <sapn className={ Styles.text }>积分记录</sapn>
142
+        </>
143
+      ),
144
+    },
145
+  ]
146
+
147
+  return (
148
+    <>
149
+      <Form layout="inline" onSubmit={e => handleSubmit(e, props)}>
150
+        <Form.Item>
151
+          {getFieldDecorator('buildingId')(
152
+            <Select style={{ width: '180px' }} placeholder="意向项目" onChange={handleSelectChange}>
153
+              <Option value="male">male</Option>
154
+            </Select>,
155
+          )}
156
+        </Form.Item>
157
+        <Form.Item>
158
+          {getFieldDecorator('reportRecommendStatus')(
159
+            <Select style={{ width: '180px' }} placeholder="状态" onChange={handleSelectChange}>
160
+              <Option value={0}>未报备</Option>
161
+              <Option value={1}>报备</Option>
162
+              <Option value={2}>推荐</Option>
163
+            </Select>,
164
+          )}
165
+        </Form.Item>
166
+        <Form.Item>
167
+          {getFieldDecorator('name')(
168
+            <Input
169
+              prefix={<Icon type="text" style={{ color: 'rgba(0,0,0,.25)' }} />}
170
+              placeholder="姓名"
171
+            />,
172
+          )}
173
+        </Form.Item>
174
+        <Form.Item>
175
+          {getFieldDecorator('tel')(
176
+            <Input
177
+              prefix={<Icon type="text" style={{ color: 'rgba(0,0,0,.25)' }} />}
178
+              placeholder="电话"
179
+            />,
180
+          )}
181
+        </Form.Item>
182
+        <Form.Item>
183
+          {getFieldDecorator('consultName')(
184
+            <Input placeholder="置业顾问" />,
185
+          )}
186
+        </Form.Item>
187
+        <Form.Item>
188
+          {getFieldDecorator('consultTel')(
189
+            <Input placeholder="置业顾问电话" />,
190
+          )}
191
+        </Form.Item>
192
+        <Form.Item>
193
+          <Button type="primary" htmlType="submit" className={Styles.SubmitButton}>
194
+            搜索
195
+          </Button>
196
+        </Form.Item>
197
+      </Form>
198
+
199
+       <div style={{ marginTop: '20px', marginBottom: '20px' }}>
200
+        <Radio.Group value={customerType} onChange={radioButtonHandleSizeChange} buttonStyle="solid">
201
+            <Radio.Button value="private">私客</Radio.Button>
202
+            <Radio.Button value="public">公客</Radio.Button>
203
+        </Radio.Group>
204
+       </div>
205
+      <Table dataSource={dataSource.records} columns={columns} pagination={{ total: dataSource.total, onChange }} />
206
+    </>
207
+  );
208
+}
209
+const WrappedBody = Form.create({ name: 'body' })(body);
210
+
211
+export default WrappedBody

+ 69
- 0
src/pages/customer/customerlist/style.css Vedi File

@@ -0,0 +1,69 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.text {
7
+  color: #ef273a;
8
+}
9
+.SelectFrom {
10
+  width: 180px;
11
+  background: #ffffff;
12
+  border-radius: 7px;
13
+  border: 1px solid #dbdbdb;
14
+}
15
+.addButton {
16
+  background: #50be00;
17
+  border-radius: 4px;
18
+  border: 0px;
19
+  margin: 10px 0px;
20
+}
21
+.cardText {
22
+  font-size: 18px;
23
+  color: #333;
24
+  line-height: 24px;
25
+  display: flex;
26
+  align-items: center;
27
+  position: relative;
28
+}
29
+.cardItem {
30
+  font-size: 18px;
31
+  font-weight: 400;
32
+  color: #666;
33
+  line-height: 24px;
34
+  display: flex;
35
+  align-items: center;
36
+}
37
+.ediText {
38
+  font-size: 18px;
39
+  color: #ff925c;
40
+  line-height: 24px;
41
+  position: absolute;
42
+  right: 0;
43
+}
44
+.title {
45
+  display: inline-block;
46
+  width: 84px;
47
+  justify-content: space-between;
48
+  text-align: justify;
49
+  text-align-last: justify;
50
+}
51
+.address {
52
+  width: 400px;
53
+  height: 24px;
54
+  text-overflow: ellipsis;
55
+  white-space: nowrap;
56
+  overflow: hidden;
57
+}
58
+.pitchButton {
59
+  border-color: #ff7e48;
60
+  background-color: #ff7e48;
61
+  color: #ffffff;
62
+}
63
+.noButton {
64
+  border-color: #ff7e48;
65
+  color: #ff7e48;
66
+}
67
+.displayS {
68
+  display: none;
69
+}

+ 72
- 0
src/pages/customer/customerlist/style.less Vedi File

@@ -0,0 +1,72 @@
1
+.SubmitButton {
2
+  background: rgba(239,39,58,1);
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.text {
7
+  color: rgba(239,39,58,1);
8
+}
9
+.SelectFrom {
10
+  width: 180px;
11
+  background: #ffffff;
12
+  border-radius: 7px;
13
+  border: 1px solid #dbdbdb;
14
+}
15
+.addButton {
16
+  background: #50be00;
17
+  border-radius: 4px;
18
+  border: 0px;
19
+  margin: 10px 0px;
20
+}
21
+.cardText {
22
+  font-size: 18px;
23
+  color: #333;
24
+  line-height: 24px;
25
+  display: flex;
26
+  align-items: center;
27
+  position: relative;
28
+
29
+}
30
+.cardItem{
31
+  font-size: 18px;
32
+  font-weight: 400;
33
+  color: #666;
34
+  line-height: 24px;
35
+  display: flex;
36
+  align-items: center;  
37
+}
38
+.ediText {
39
+  font-size: 18px;
40
+  color: #ff925c;
41
+  line-height: 24px;
42
+  position: absolute;
43
+  right: 0;
44
+}
45
+.title{
46
+  display: inline-block;
47
+  width: 84px;
48
+  justify-content: space-between;
49
+  text-align: justify;
50
+  text-align-last:justify
51
+}
52
+
53
+.address { 
54
+  width: 400px;
55
+  height: 24px; 
56
+  text-overflow: ellipsis; 
57
+  white-space: nowrap;
58
+  overflow: hidden;
59
+}
60
+
61
+.pitchButton { 
62
+  border-color: rgba(255,126,72,1);
63
+  background-color: rgba(255,126,72,1);
64
+  color: rgba(255,255,255,1); 
65
+}
66
+.noButton {
67
+  border-color: rgba(255,126,72,1);
68
+  color: rgba(255,126,72,1);
69
+}
70
+.displayS {
71
+  display: none;
72
+}

+ 69
- 0
src/pages/customer/customerlist/style.wxss Vedi File

@@ -0,0 +1,69 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.text {
7
+  color: #ef273a;
8
+}
9
+.SelectFrom {
10
+  width: 180px;
11
+  background: #ffffff;
12
+  border-radius: 7px;
13
+  border: 1px solid #dbdbdb;
14
+}
15
+.addButton {
16
+  background: #50be00;
17
+  border-radius: 4px;
18
+  border: 0px;
19
+  margin: 10px 0px;
20
+}
21
+.cardText {
22
+  font-size: 18px;
23
+  color: #333;
24
+  line-height: 24px;
25
+  display: flex;
26
+  align-items: center;
27
+  position: relative;
28
+}
29
+.cardItem {
30
+  font-size: 18px;
31
+  font-weight: 400;
32
+  color: #666;
33
+  line-height: 24px;
34
+  display: flex;
35
+  align-items: center;
36
+}
37
+.ediText {
38
+  font-size: 18px;
39
+  color: #ff925c;
40
+  line-height: 24px;
41
+  position: absolute;
42
+  right: 0;
43
+}
44
+.title {
45
+  display: inline-block;
46
+  width: 84px;
47
+  justify-content: space-between;
48
+  text-align: justify;
49
+  text-align-last: justify;
50
+}
51
+.address {
52
+  width: 400px;
53
+  height: 24px;
54
+  text-overflow: ellipsis;
55
+  white-space: nowrap;
56
+  overflow: hidden;
57
+}
58
+.pitchButton {
59
+  border-color: #ff7e48;
60
+  background-color: #ff7e48;
61
+  color: #ffffff;
62
+}
63
+.noButton {
64
+  border-color: #ff7e48;
65
+  color: #ff7e48;
66
+}
67
+.displayS {
68
+  display: none;
69
+}

+ 1
- 0
src/pages/customer/drift/index.jsx Vedi File

@@ -3,6 +3,7 @@ import { Table, Avatar, Alert } from 'antd';
3 3
 
4 4
 import request from '../../../utils/request';
5 5
 import apis from '../../../services/apis';
6
+import Styles from './style.less'
6 7
 
7 8
 function costomerDrift() {
8 9
   // eslint-disable-next-line react-hooks/rules-of-hooks

+ 57
- 0
src/pages/customer/drift/style.less Vedi File

@@ -0,0 +1,57 @@
1
+.SubmitButton {
2
+  background: rgba(239,39,58,1);
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.SelectFrom {
7
+  width: 180px;
8
+  background: #ffffff;
9
+  border-radius: 7px;
10
+  border: 1px solid #dbdbdb;
11
+}
12
+.addButton {
13
+  background: #50be00;
14
+  border-radius: 4px;
15
+  border: 0px;
16
+  margin: 10px 0px;
17
+}
18
+.cardText {
19
+  font-size: 18px;
20
+  color: #333;
21
+  line-height: 24px;
22
+  display: flex;
23
+  align-items: center;
24
+  position: relative;
25
+
26
+}
27
+.cardItem{
28
+  font-size: 18px;
29
+  font-weight: 400;
30
+  color: #666;
31
+  line-height: 24px;
32
+  display: flex;
33
+  align-items: center;  
34
+}
35
+.ediText {
36
+  font-size: 18px;
37
+  color: #ff925c;
38
+  line-height: 24px;
39
+  position: absolute;
40
+  right: 0;
41
+}
42
+.title{
43
+  display: inline-block;
44
+  width: 84px;
45
+  justify-content: space-between;
46
+  text-align: justify;
47
+  text-align-last:justify
48
+}
49
+
50
+.address { 
51
+  width: 400px;
52
+  height: 24px; 
53
+  text-overflow: ellipsis; 
54
+  white-space: nowrap;
55
+  overflow: hidden;
56
+}
57
+

+ 11
- 10
src/pages/customer/independentList/index.jsx Vedi File

@@ -93,16 +93,6 @@ function body(props) {
93 93
       dataIndex: 'phone',
94 94
       key: 'phone',
95 95
     },
96
-    {
97
-      title: '类型',
98
-      dataIndex: 'personTtype',
99
-      key: 'personType',
100
-    },
101
-    {
102
-      title: '所属渠道',
103
-      dataIndex: 'qudao',
104
-      key: 'qudao',
105
-    },
106 96
     {
107 97
       title: '性别',
108 98
       dataIndex: 'gender',
@@ -110,6 +100,17 @@ function body(props) {
110 100
       // eslint-disable-next-line no-nested-ternary
111 101
       render: (_, record) => <><sapn>{ record.gender === '1' ? '男' : record.gender === '2' ? '女' : '未知' }</sapn></>,
112 102
     },
103
+    {
104
+      title: '类型',
105
+      dataIndex: 'personType',
106
+      key: 'personType',
107
+      render: (_, record) => <><sapn>{ record.channelName !== null ? '渠道经纪人' : '独立经纪人' }</sapn></>,
108
+    },
109
+    {
110
+      title: '所属渠道',
111
+      dataIndex: 'channelName',
112
+      key: 'channelName',
113
+    },
113 114
     {
114 115
       title: '操作',
115 116
       dataIndex: 'customerId',

+ 54
- 0
src/pages/customer/independentList/style.css Vedi File

@@ -0,0 +1,54 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.SelectFrom {
7
+  width: 180px;
8
+  background: #ffffff;
9
+  border-radius: 7px;
10
+  border: 1px solid #dbdbdb;
11
+}
12
+.addButton {
13
+  background: #50be00;
14
+  border-radius: 4px;
15
+  border: 0px;
16
+  margin: 10px 0px;
17
+}
18
+.cardText {
19
+  font-size: 18px;
20
+  color: #333;
21
+  line-height: 24px;
22
+  display: flex;
23
+  align-items: center;
24
+  position: relative;
25
+}
26
+.cardItem {
27
+  font-size: 18px;
28
+  font-weight: 400;
29
+  color: #666;
30
+  line-height: 24px;
31
+  display: flex;
32
+  align-items: center;
33
+}
34
+.ediText {
35
+  font-size: 18px;
36
+  color: #ff925c;
37
+  line-height: 24px;
38
+  position: absolute;
39
+  right: 0;
40
+}
41
+.title {
42
+  display: inline-block;
43
+  width: 84px;
44
+  justify-content: space-between;
45
+  text-align: justify;
46
+  text-align-last: justify;
47
+}
48
+.address {
49
+  width: 400px;
50
+  height: 24px;
51
+  text-overflow: ellipsis;
52
+  white-space: nowrap;
53
+  overflow: hidden;
54
+}

+ 1
- 1
src/pages/customer/independentList/style.less Vedi File

@@ -1,5 +1,5 @@
1 1
 .SubmitButton {
2
-  background: #3a91d5;
2
+  background: rgba(239,39,58,1);
3 3
   border-radius: 7px;
4 4
   border: 0px;
5 5
 }

+ 54
- 0
src/pages/customer/independentList/style.wxss Vedi File

@@ -0,0 +1,54 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.SelectFrom {
7
+  width: 180px;
8
+  background: #ffffff;
9
+  border-radius: 7px;
10
+  border: 1px solid #dbdbdb;
11
+}
12
+.addButton {
13
+  background: #50be00;
14
+  border-radius: 4px;
15
+  border: 0px;
16
+  margin: 10px 0px;
17
+}
18
+.cardText {
19
+  font-size: 18px;
20
+  color: #333;
21
+  line-height: 24px;
22
+  display: flex;
23
+  align-items: center;
24
+  position: relative;
25
+}
26
+.cardItem {
27
+  font-size: 18px;
28
+  font-weight: 400;
29
+  color: #666;
30
+  line-height: 24px;
31
+  display: flex;
32
+  align-items: center;
33
+}
34
+.ediText {
35
+  font-size: 18px;
36
+  color: #ff925c;
37
+  line-height: 24px;
38
+  position: absolute;
39
+  right: 0;
40
+}
41
+.title {
42
+  display: inline-block;
43
+  width: 84px;
44
+  justify-content: space-between;
45
+  text-align: justify;
46
+  text-align-last: justify;
47
+}
48
+.address {
49
+  width: 400px;
50
+  height: 24px;
51
+  text-overflow: ellipsis;
52
+  white-space: nowrap;
53
+  overflow: hidden;
54
+}

+ 2
- 2
src/pages/customer/recommendCustomer/index.jsx Vedi File

@@ -119,8 +119,8 @@ function body(props) {
119 119
     },
120 120
     {
121 121
       title: '状态',
122
-      dataIndex: 'createDate',
123
-      key: 'createDate',
122
+      dataIndex: 'verifyStatus',
123
+      key: 'verifyStatus',
124 124
       render: (_, record) => <><sapn>{ record.verifyStatus === 0 ? '未通过': record.verifyStatus === 1 ? '已通过' : record.verifyStatus === 2 ? '已驳回' : '' }</sapn></>,
125 125
     },
126 126
     {

+ 54
- 0
src/pages/customer/recommendCustomer/style.css Vedi File

@@ -0,0 +1,54 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.SelectFrom {
7
+  width: 180px;
8
+  background: #ffffff;
9
+  border-radius: 7px;
10
+  border: 1px solid #dbdbdb;
11
+}
12
+.addButton {
13
+  background: #50be00;
14
+  border-radius: 4px;
15
+  border: 0px;
16
+  margin: 10px 0px;
17
+}
18
+.cardText {
19
+  font-size: 18px;
20
+  color: #333;
21
+  line-height: 24px;
22
+  display: flex;
23
+  align-items: center;
24
+  position: relative;
25
+}
26
+.cardItem {
27
+  font-size: 18px;
28
+  font-weight: 400;
29
+  color: #666;
30
+  line-height: 24px;
31
+  display: flex;
32
+  align-items: center;
33
+}
34
+.ediText {
35
+  font-size: 18px;
36
+  color: #ff925c;
37
+  line-height: 24px;
38
+  position: absolute;
39
+  right: 0;
40
+}
41
+.title {
42
+  display: inline-block;
43
+  width: 84px;
44
+  justify-content: space-between;
45
+  text-align: justify;
46
+  text-align-last: justify;
47
+}
48
+.address {
49
+  width: 400px;
50
+  height: 24px;
51
+  text-overflow: ellipsis;
52
+  white-space: nowrap;
53
+  overflow: hidden;
54
+}

+ 1
- 1
src/pages/customer/recommendCustomer/style.less Vedi File

@@ -1,5 +1,5 @@
1 1
 .SubmitButton {
2
-  background: #3a91d5;
2
+  background: rgba(239,39,58,1);
3 3
   border-radius: 7px;
4 4
   border: 0px;
5 5
 }

+ 54
- 0
src/pages/customer/recommendCustomer/style.wxss Vedi File

@@ -0,0 +1,54 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.SelectFrom {
7
+  width: 180px;
8
+  background: #ffffff;
9
+  border-radius: 7px;
10
+  border: 1px solid #dbdbdb;
11
+}
12
+.addButton {
13
+  background: #50be00;
14
+  border-radius: 4px;
15
+  border: 0px;
16
+  margin: 10px 0px;
17
+}
18
+.cardText {
19
+  font-size: 18px;
20
+  color: #333;
21
+  line-height: 24px;
22
+  display: flex;
23
+  align-items: center;
24
+  position: relative;
25
+}
26
+.cardItem {
27
+  font-size: 18px;
28
+  font-weight: 400;
29
+  color: #666;
30
+  line-height: 24px;
31
+  display: flex;
32
+  align-items: center;
33
+}
34
+.ediText {
35
+  font-size: 18px;
36
+  color: #ff925c;
37
+  line-height: 24px;
38
+  position: absolute;
39
+  right: 0;
40
+}
41
+.title {
42
+  display: inline-block;
43
+  width: 84px;
44
+  justify-content: space-between;
45
+  text-align: justify;
46
+  text-align-last: justify;
47
+}
48
+.address {
49
+  width: 400px;
50
+  height: 24px;
51
+  text-overflow: ellipsis;
52
+  white-space: nowrap;
53
+  overflow: hidden;
54
+}

+ 54
- 0
src/pages/customer/report/style.css Vedi File

@@ -0,0 +1,54 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.SelectFrom {
7
+  width: 180px;
8
+  background: #ffffff;
9
+  border-radius: 7px;
10
+  border: 1px solid #dbdbdb;
11
+}
12
+.addButton {
13
+  background: #50be00;
14
+  border-radius: 4px;
15
+  border: 0px;
16
+  margin: 10px 0px;
17
+}
18
+.cardText {
19
+  font-size: 18px;
20
+  color: #333;
21
+  line-height: 24px;
22
+  display: flex;
23
+  align-items: center;
24
+  position: relative;
25
+}
26
+.cardItem {
27
+  font-size: 18px;
28
+  font-weight: 400;
29
+  color: #666;
30
+  line-height: 24px;
31
+  display: flex;
32
+  align-items: center;
33
+}
34
+.ediText {
35
+  font-size: 18px;
36
+  color: #ff925c;
37
+  line-height: 24px;
38
+  position: absolute;
39
+  right: 0;
40
+}
41
+.title {
42
+  display: inline-block;
43
+  width: 84px;
44
+  justify-content: space-between;
45
+  text-align: justify;
46
+  text-align-last: justify;
47
+}
48
+.address {
49
+  width: 400px;
50
+  height: 24px;
51
+  text-overflow: ellipsis;
52
+  white-space: nowrap;
53
+  overflow: hidden;
54
+}

+ 1
- 1
src/pages/customer/report/style.less Vedi File

@@ -1,5 +1,5 @@
1 1
 .SubmitButton {
2
-  background: #3a91d5;
2
+  background: rgba(239,39,58,1);
3 3
   border-radius: 7px;
4 4
   border: 0px;
5 5
 }

+ 54
- 0
src/pages/customer/report/style.wxss Vedi File

@@ -0,0 +1,54 @@
1
+.SubmitButton {
2
+  background: #ef273a;
3
+  border-radius: 7px;
4
+  border: 0px;
5
+}
6
+.SelectFrom {
7
+  width: 180px;
8
+  background: #ffffff;
9
+  border-radius: 7px;
10
+  border: 1px solid #dbdbdb;
11
+}
12
+.addButton {
13
+  background: #50be00;
14
+  border-radius: 4px;
15
+  border: 0px;
16
+  margin: 10px 0px;
17
+}
18
+.cardText {
19
+  font-size: 18px;
20
+  color: #333;
21
+  line-height: 24px;
22
+  display: flex;
23
+  align-items: center;
24
+  position: relative;
25
+}
26
+.cardItem {
27
+  font-size: 18px;
28
+  font-weight: 400;
29
+  color: #666;
30
+  line-height: 24px;
31
+  display: flex;
32
+  align-items: center;
33
+}
34
+.ediText {
35
+  font-size: 18px;
36
+  color: #ff925c;
37
+  line-height: 24px;
38
+  position: absolute;
39
+  right: 0;
40
+}
41
+.title {
42
+  display: inline-block;
43
+  width: 84px;
44
+  justify-content: space-between;
45
+  text-align: justify;
46
+  text-align-last: justify;
47
+}
48
+.address {
49
+  width: 400px;
50
+  height: 24px;
51
+  text-overflow: ellipsis;
52
+  white-space: nowrap;
53
+  overflow: hidden;
54
+}

+ 4
- 0
src/services/apis.js Vedi File

@@ -76,5 +76,9 @@ export default {
76 76
       method: 'GET',
77 77
       url: `${prefix}/customer/agents`,
78 78
     },
79
+    customerRecommend: {
80
+      method: 'GET',
81
+      url: `${prefix}/customer/recommend`,
82
+    },
79 83
   },
80 84
 }