dingxin 5 gadus atpakaļ
vecāks
revīzija
80cb80671f

+ 1
- 1
src/pages/building/list/add/components/base.jsx Parādīt failu

@@ -114,7 +114,7 @@ function AddBuilding(props) {
114 114
             {getFieldDecorator('buildingProjectType')(<BudildingProjectType />)}
115 115
           </Form.Item>
116 116
           <Form.Item label="均价" >
117
-            {getFieldDecorator('price')(<Input type="number" style={{ width: '210px' }}/>)}m²/元
117
+            {getFieldDecorator('price')(<Input type="number" style={{ width: '210px' }}/>)}元/
118 118
           </Form.Item>
119 119
           <Form.Item label="开盘时间"  >
120 120
             {getFieldDecorator('openingDate')(<DatePicker format="YYYY/MM/DD" />)}

+ 36
- 3
src/pages/customer/customerlist/index.jsx Parādīt failu

@@ -28,6 +28,8 @@ function body(props) {
28 28
 
29 29
   // eslint-disable-next-line react-hooks/rules-of-hooks
30 30
   const [dataSource, setDataSource] = useState({ records: [] })
31
+  // eslint-disable-next-line react-hooks/rules-of-hooks
32
+  // const [columns, setColumns] = useState(privateColumns)
31 33
 
32 34
   // 默认私客
33 35
   // eslint-disable-next-line react-hooks/rules-of-hooks
@@ -107,6 +109,7 @@ function body(props) {
107 109
 
108 110
     const { value } = e.target
109 111
     setCustomerType(value)
112
+    //setColumns(value === 'private' ? privateColumns : publicColumns)
110 113
     getList({ pageNumber: 1, pageSize: 10, customerType: value })
111 114
   }
112 115
 
@@ -168,7 +171,34 @@ function body(props) {
168 171
     link.click()
169 172
   }
170 173
 
171
-  const columns = [
174
+  const publicColumns = [
175
+    {
176
+      title: '头像',
177
+      dataIndex: 'picture',
178
+      key: 'picture',
179
+      align: 'center',
180
+      width: '15%',
181
+      render: (_, record) => <Avatar shape="square" src={customerType === 'private' ? record.picture : record.avatarurl} size={64} icon="user" />,
182
+    },
183
+    {
184
+      title: '姓名',
185
+      dataIndex: 'name',
186
+      key: 'name',
187
+      align: 'center',
188
+      width: '10%',
189
+      // eslint-disable-next-line no-nested-ternary
190
+      render: (_, record) => <><span>{customerType === 'private' ? record.name : record.nickname}</span></>,
191
+    },
192
+    {
193
+      title: '电话',
194
+      dataIndex: 'phone',
195
+      key: 'phone',
196
+      align: 'center',
197
+      width: '15%',
198
+    },
199
+  ]
200
+
201
+  const privateColumns = [
172 202
     {
173 203
       title: '头像',
174 204
       dataIndex: 'picture',
@@ -324,8 +354,11 @@ function body(props) {
324 354
           </Radio.Group>
325 355
         </AuthButton>
326 356
       </div>
327
-      <Table dataSource={dataSource.records} columns={columns} pagination={{ total: dataSource.total, onChange }} rowKey="customerList" />
328
-
357
+      {customerType === 'private' ? 
358
+        <Table dataSource={dataSource.records} columns={privateColumns} pagination={{ total: dataSource.total, onChange }} rowKey="customerList" /> :
359
+        <Table dataSource={dataSource.records} columns={publicColumns} pagination={{ total: dataSource.total, onChange }} rowKey="customerList" /> 
360
+      }
361
+      
329 362
       {/* 调整归属 */}
330 363
       <Attribution visibleData={gVisibleData} />
331 364
 

+ 2
- 2
src/pages/customer/recommendCustomer/audit.jsx Parādīt failu

@@ -91,7 +91,7 @@ function body(props) {
91 91
 
92 92
   return (
93 93
     <>
94
-      <Form {...tailFormItemLayout} onSubmit={e => handleSubmit(e, props)} style={{ width: '800px', margin: 'auto' }}>
94
+      <Form {...tailFormItemLayout} onSubmit={e => handleSubmit(e)} style={{ width: '800px', margin: 'auto' }}>
95 95
         <Form.Item label="客户ID" style={{ display: 'none' }}>
96 96
           {getFieldDecorator('customerId')(
97 97
             <Input
@@ -180,7 +180,7 @@ function body(props) {
180 180
         </Form.Item>
181 181
         <Form.Item style={{ display: 'flex', justifyContent: 'center' }}>
182 182
           <Button type="primary" htmlType="submit" className={Styles.SubmitButton}>
183
-            搜索
183
+            确定
184 184
           </Button>
185 185
           &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
186 186
           <Button onClick={() => router.go(-1)}>

+ 1
- 1
src/pages/customer/recommendCustomer/index.jsx Parādīt failu

@@ -169,7 +169,7 @@ function body(props) {
169 169
         <>
170 170
           {
171 171
             <AuthButton name="admin.customer.recommend.verify.id.put" noRight={null}>
172
-              {record.verifyStatus === 0 ? <span style={{ color: 'rgba(239,39,58,1)',cursor: 'pointer' }} onClick={() => toAudit(record.customerId)}>审核</span> : ''}
172
+              {record.verifyStatus === null ? <span style={{ color: 'rgba(239,39,58,1)',cursor: 'pointer' }} onClick={() => toAudit(record.customerId)}>审核</span> : ''}
173 173
             </AuthButton>
174 174
           }
175 175
         </>