Quellcode durchsuchen

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

傅行帆 vor 5 Jahren
Ursprung
Commit
4cb135c431

+ 2
- 2
config/config.js Datei anzeigen

83
   targets: {
83
   targets: {
84
     ie: 11,
84
     ie: 11,
85
   },
85
   },
86
-  publicPath: './',
87
-  // publicPath: 'https://njcjweb.oss-accelerate.aliyuncs.com/admin/',
86
+  // publicPath: './',
87
+  publicPath: 'https://njcjweb.oss-accelerate.aliyuncs.com/admin/',
88
   history: 'hash',
88
   history: 'hash',
89
   devtool: isAntDesignProPreview ? 'source-map' : false,
89
   devtool: isAntDesignProPreview ? 'source-map' : false,
90
   // umi routes: https://umijs.org/zh/guide/router.html
90
   // umi routes: https://umijs.org/zh/guide/router.html

+ 5
- 5
package.json Datei anzeigen

67
     "redux": "^4.0.1",
67
     "redux": "^4.0.1",
68
     "swiper": "^5.3.6",
68
     "swiper": "^5.3.6",
69
     "umi": "^2.13.3",
69
     "umi": "^2.13.3",
70
-    "umi-plugin-pro-block": "^1.3.2",
71
-    "umi-plugin-react": "^1.9.5",
70
+    "umi-plugin-pro-block": "^1.3.6",
71
+    "umi-plugin-react": "^1.15.3",
72
     "umi-request": "^1.0.8",
72
     "umi-request": "^1.0.8",
73
     "wangeditor": "^3.1.1"
73
     "wangeditor": "^3.1.1"
74
   },
74
   },
108
     "pro-download": "1.0.1",
108
     "pro-download": "1.0.1",
109
     "slash2": "^2.0.0",
109
     "slash2": "^2.0.0",
110
     "stylelint": "^10.1.0",
110
     "stylelint": "^10.1.0",
111
-    "umi-plugin-ga": "^1.1.3",
112
-    "umi-plugin-pro": "^1.0.2",
111
+    "umi-plugin-ga": "^1.1.6",
112
+    "umi-plugin-pro": "^1.0.3",
113
     "umi-types": "^0.3.8",
113
     "umi-types": "^0.3.8",
114
-    "webpack-theme-color-replacer": "^1.2.15"
114
+    "webpack-theme-color-replacer": "^1.3.7"
115
   },
115
   },
116
   "optionalDependencies": {
116
   "optionalDependencies": {
117
     "puppeteer": "^1.17.0"
117
     "puppeteer": "^1.17.0"

+ 6
- 2
src/components/Navigate/index.jsx Datei anzeigen

16
             )
16
             )
17
         }
17
         }
18
 
18
 
19
-    } else {
19
+    } else if (onClick) {
20
         return (
20
         return (
21
-            <a onClick={onClick} href={to} style={{ color: '#1D74D9' }}>{children}</a>
21
+            <span onClick={onClick} style={{ color: '#1D74D9' }}>{children}</span>
22
         )
22
         )
23
 
23
 
24
+    } else {
25
+        return (
26
+            <span style={{ color: '#1D74D9' }}>{children}</span>
27
+        )
24
     }
28
     }
25
 
29
 
26
 
30
 

+ 4
- 2
src/pages/activity/ActivityList.jsx Datei anzeigen

35
   useEffect(() => {
35
   useEffect(() => {
36
 
36
 
37
     if (localStorage.getItem("activePageParams")) {
37
     if (localStorage.getItem("activePageParams")) {
38
-      props.form.setFieldsValue(JSON.parse(localStorage.getItem("activePageParams")));
39
-      // const { getFieldDecorator } = JSON.parse(localStorage.getItem("pageParams"))
40
 
38
 
39
+      const localStorageValue = JSON.parse(localStorage.getItem("activePageParams"))
40
+      localStorageValue.time = localStorageValue.time ? moment(localStorageValue.time) : ''
41
+
42
+      props.form.setFieldsValue(localStorageValue);
41
       getList(JSON.parse(localStorage.getItem("activePageParams")))
43
       getList(JSON.parse(localStorage.getItem("activePageParams")))
42
     } else {
44
     } else {
43
       localStorage.setItem("activePageParams", JSON.stringify({ pageNum: 1, pageSize: 10 }));
45
       localStorage.setItem("activePageParams", JSON.stringify({ pageNum: 1, pageSize: 10 }));

+ 1
- 1
src/pages/activity/helpActivity/helpRecord.jsx Datei anzeigen

267
   const { helpActivityId } = props.location.query
267
   const { helpActivityId } = props.location.query
268
   useEffect(() => {
268
   useEffect(() => {
269
     console.log('customerType', customerType)
269
     console.log('customerType', customerType)
270
-    getList({ pageNumber: 1, pageSize: 10, status: customerType, helpActivityId })
270
+    getList({ pageNum: 1, pageSize: 10, status: customerType, helpActivityId })
271
   }, [])
271
   }, [])
272
 
272
 
273
   function getList(params) {
273
   function getList(params) {

+ 5
- 1
src/pages/activity/helpActivity/list.jsx Datei anzeigen

21
 
21
 
22
   useEffect(() => {
22
   useEffect(() => {
23
     if (localStorage.getItem("helpActivePageParams")) {
23
     if (localStorage.getItem("helpActivePageParams")) {
24
-      props.form.setFieldsValue(JSON.parse(localStorage.getItem("helpActivePageParams")));
24
+      // props.form.setFieldsValue(JSON.parse(localStorage.getItem("helpActivePageParams")));
25
       // const { getFieldDecorator } = JSON.parse(localStorage.getItem("pageParams"))
25
       // const { getFieldDecorator } = JSON.parse(localStorage.getItem("pageParams"))
26
+      const localStorageValue = JSON.parse(localStorage.getItem("helpActivePageParams"))
27
+      localStorageValue.startTime = localStorageValue.startTime ? moment(localStorageValue.startTime) : ''
28
+      localStorageValue.endTime = localStorageValue.endTime ? moment(localStorageValue.endTime) : ''
26
 
29
 
30
+      props.form.setFieldsValue(localStorageValue);
27
       getList(JSON.parse(localStorage.getItem("helpActivePageParams")))
31
       getList(JSON.parse(localStorage.getItem("helpActivePageParams")))
28
     } else {
32
     } else {
29
       localStorage.setItem("helpActivePageParams", JSON.stringify({ pageNum: 1, pageSize: 10 }));
33
       localStorage.setItem("helpActivePageParams", JSON.stringify({ pageNum: 1, pageSize: 10 }));

+ 6
- 2
src/pages/building/list/index.jsx Datei anzeigen

181
   // eslint-disable-next-line react-hooks/rules-of-hooks
181
   // eslint-disable-next-line react-hooks/rules-of-hooks
182
   useEffect(() => {
182
   useEffect(() => {
183
     if (localStorage.getItem("pageParams")) {
183
     if (localStorage.getItem("pageParams")) {
184
-      props.form.setFieldsValue(JSON.parse(localStorage.getItem("pageParams")));
184
+
185
       // const { getFieldDecorator } = JSON.parse(localStorage.getItem("pageParams"))
185
       // const { getFieldDecorator } = JSON.parse(localStorage.getItem("pageParams"))
186
-      getList(JSON.parse(localStorage.getItem("pageParams")))
186
+      const localStorageValue = JSON.parse(localStorage.getItem("pageParams"))
187
+      localStorageValue.startDate = localStorageValue.startDate ? moment(localStorageValue.startDate) : ''
188
+      props.form.setFieldsValue(localStorageValue);
189
+
190
+      getList({ pageNum: 1, pageSize: 9, ...JSON.parse(localStorage.getItem("pageParams")) })
187
     } else {
191
     } else {
188
       getList({ pageNum: 1, pageSize: 9 })
192
       getList({ pageNum: 1, pageSize: 9 })
189
     }
193
     }

+ 0
- 2
src/pages/customer/customerlist/components/BatchAssistConsultant.jsx Datei anzeigen

89
 
89
 
90
    // 分页
90
    // 分页
91
   onChange(pageNum) {
91
   onChange(pageNum) {
92
-    console.log(this.state.visibleData.buildingName,"222222222222222222222222")
93
     this.getList({ pageNumber: pageNum, pageSize: 5, buildingId: this.state.visibleData.buildingName ||this.props.visibleData.buildingId})
92
     this.getList({ pageNumber: pageNum, pageSize: 5, buildingId: this.state.visibleData.buildingName ||this.props.visibleData.buildingId})
94
 
93
 
95
     // this.getUserList({ pageNumber: pageNum, pageSize: 5, buildingId: this.state.visibleData.buildingName })
94
     // this.getUserList({ pageNumber: pageNum, pageSize: 5, buildingId: this.state.visibleData.buildingName })
97
 
96
 
98
   // 提交
97
   // 提交
99
   submitGm(record) {
98
   submitGm(record) {
100
-    console.log(this.state.visibleData.buildingName,"3333333333333333333")
101
     // 网路请求
99
     // 网路请求
102
     request({ ...apis.customer.batchConsultantAssist, data: { userId: record.userId
100
     request({ ...apis.customer.batchConsultantAssist, data: { userId: record.userId
103
       ,buildingId:this.state.visibleData.buildingName  || this.props.visibleData.buildingId
101
       ,buildingId:this.state.visibleData.buildingName  || this.props.visibleData.buildingId

+ 29
- 9
src/pages/customer/customerlist/index.jsx Datei anzeigen

77
     if (localStorage.getItem("state")) {
77
     if (localStorage.getItem("state")) {
78
       console.log(localStorage.getItem("state"), 'state')
78
       console.log(localStorage.getItem("state"), 'state')
79
       if (JSON.parse(localStorage.getItem("state")) == 'private') {
79
       if (JSON.parse(localStorage.getItem("state")) == 'private') {
80
-        props.form.setFieldsValue(JSON.parse(localStorage.getItem("priPageParams")));
81
-        getList({ ...JSON.parse(localStorage.getItem("priPageParams")) })
80
+        const localStorageValue = JSON.parse(localStorage.getItem("priPageParams"))
81
+        localStorageValue.startCreateDate = localStorageDate(localStorageValue.startCreateDate)
82
+        localStorageValue.endCreateDate = localStorageDate(localStorageValue.endCreateDate)
83
+        props.form.setFieldsValue(localStorageValue);
84
+        getList({ pageNumber: 1, pageSize: 10, ...JSON.parse(localStorage.getItem("priPageParams")) })
82
       } else {
85
       } else {
83
         setCustomerType('public')
86
         setCustomerType('public')
84
-        props.form.setFieldsValue(JSON.parse(localStorage.getItem("pubPageParams")));
85
-        getList({ ...JSON.parse(localStorage.getItem("pubPageParams")) })
87
+        const localStorageValue = JSON.parse(localStorage.getItem("pubPageParams"))
88
+        localStorageValue.startCreateDate = localStorageDate(localStorageValue.startCreateDate)
89
+        localStorageValue.endCreateDate = localStorageDate(localStorageValue.endCreateDate)
90
+        props.form.setFieldsValue(localStorageValue);
91
+        getList({ pageNumber: 1, pageSize: 10, ...JSON.parse(localStorage.getItem("pubPageParams")) })
86
       }
92
       }
87
 
93
 
88
     } else {
94
     } else {
93
 
99
 
94
   function getList(params) {
100
   function getList(params) {
95
     // 网路请求
101
     // 网路请求
102
+    console.log(params, '111111111111111')
103
+    if (params.startCreateDate) {
104
+      params.startCreateDate = moment(params.startCreateDate).format('YYYY-MM-DD HH:mm:ss');
105
+    }
106
+    if (params.endCreateDate) {
107
+      params.endCreateDate = moment(params.endCreateDate).format('YYYY-MM-DD HH:mm:ss');
108
+    }
96
     request({ ...apis.customer.customerRecommend, params: { ...params } }).then(res => {
109
     request({ ...apis.customer.customerRecommend, params: { ...params } }).then(res => {
97
       if (params.customerType === 'private') {
110
       if (params.customerType === 'private') {
98
         setDataSource(res)
111
         setDataSource(res)
155
     console.log(e)
168
     console.log(e)
156
   }
169
   }
157
 
170
 
171
+  const localStorageDate = (date) => date ? moment(date) : ''
172
+
158
   // 分页
173
   // 分页
159
   function onChange(pageNum) {
174
   function onChange(pageNum) {
160
     // eslint-disable-next-line react-hooks/rules-of-hooks
175
     // eslint-disable-next-line react-hooks/rules-of-hooks
185
     localStorage.setItem("state", JSON.stringify(value))
200
     localStorage.setItem("state", JSON.stringify(value))
186
     if (value === 'private') {
201
     if (value === 'private') {
187
       if (localStorage.getItem("priPageParams")) {
202
       if (localStorage.getItem("priPageParams")) {
188
-        props.form.setFieldsValue(JSON.parse(localStorage.getItem("priPageParams")));
189
-
203
+        const localStorageValue = JSON.parse(localStorage.getItem("priPageParams"))
204
+        localStorageValue.startCreateDate = localStorageDate(localStorageValue.startCreateDate)
205
+        localStorageValue.endCreateDate = localStorageDate(localStorageValue.endCreateDate)
206
+        props.form.setFieldsValue(localStorageValue);
190
         getList(JSON.parse(localStorage.getItem("priPageParams")))
207
         getList(JSON.parse(localStorage.getItem("priPageParams")))
191
       } else {
208
       } else {
192
         localStorage.setItem("priPageParams", JSON.stringify({ pageNumber: 1, pageSize: 10, customerType: value }))
209
         localStorage.setItem("priPageParams", JSON.stringify({ pageNumber: 1, pageSize: 10, customerType: value }))
196
     } else {
213
     } else {
197
 
214
 
198
       if (localStorage.getItem("pubPageParams")) {
215
       if (localStorage.getItem("pubPageParams")) {
199
-        props.form.setFieldsValue(JSON.parse(localStorage.getItem("pubPageParams")));
200
-        // const { getFieldDecorator } = JSON.parse(localStorage.getItem("pageParams"))
201
-        getList({ customerType, ...JSON.parse(localStorage.getItem("pubPageParams")) })
216
+        const localStorageValue = JSON.parse(localStorage.getItem("pubPageParams"))
217
+        localStorageValue.startCreateDate = localStorageDate(localStorageValue.startCreateDate)
218
+        localStorageValue.endCreateDate = localStorageDate(localStorageValue.endCreateDate)
219
+        props.form.setFieldsValue(localStorageValue);
220
+
221
+        getList( {pageNumber: 1, pageSize: 10, customerType, ...JSON.parse(localStorage.getItem("pubPageParams")) })
202
       } else {
222
       } else {
203
         localStorage.setItem("pubPageParams", JSON.stringify({ pageNumber: 1, pageSize: 10, customerType: 'public' }))
223
         localStorage.setItem("pubPageParams", JSON.stringify({ pageNumber: 1, pageSize: 10, customerType: 'public' }))
204
         getList({ pageNumber: 1, pageSize: 10, customerType: 'public' })
224
         getList({ pageNumber: 1, pageSize: 10, customerType: 'public' })

+ 10
- 6
src/pages/eContract/businessConfig/list.jsx Datei anzeigen

1
 import React, { useState, useEffect } from 'react';
1
 import React, { useState, useEffect } from 'react';
2
 import { Form, Input, Button, Icon, Select, message, Table, Divider, Tag, Pagination, Modal, DatePicker } from 'antd';
2
 import { Form, Input, Button, Icon, Select, message, Table, Divider, Tag, Pagination, Modal, DatePicker } from 'antd';
3
 import { FormattedMessage } from 'umi-plugin-react/locale';
3
 import { FormattedMessage } from 'umi-plugin-react/locale';
4
-import styles from '../../style/GoodsList.less';
5
 import router from 'umi/router';
4
 import router from 'umi/router';
6
 import moment from 'moment';
5
 import moment from 'moment';
6
+import AuthButton from '@/components/AuthButton';
7
+import withActions from '@/components/ActionList';
8
+import EditIcon from '@/components/EditIcon';
9
+import styles from '../../style/GoodsList.less';
7
 import SelectCity from '../../../components/SelectButton/CitySelect'
10
 import SelectCity from '../../../components/SelectButton/CitySelect'
8
 import BuildSelect from '../../../components/SelectButton/BuildSelect'
11
 import BuildSelect from '../../../components/SelectButton/BuildSelect'
9
 import apis from '../../../services/apis';
12
 import apis from '../../../services/apis';
10
 import request from '../../../utils/request';
13
 import request from '../../../utils/request';
11
-import AuthButton from '@/components/AuthButton';
14
+
12
 
15
 
13
 const { Option } = Select;
16
 const { Option } = Select;
14
 const { MonthPicker, RangePicker, WeekPicker } = DatePicker;
17
 const { MonthPicker, RangePicker, WeekPicker } = DatePicker;
116
       dataIndex: 'handle',
119
       dataIndex: 'handle',
117
       key: 'handle',
120
       key: 'handle',
118
       align: 'center',
121
       align: 'center',
119
-      render: (text, record) => (
122
+      render: withActions((text, record) => [
120
         <AuthButton name="admin.eContractBusiness.detail.get" noRight={null}>
123
         <AuthButton name="admin.eContractBusiness.detail.get" noRight={null}>
121
-          <a style={{ color: '#66B3FF' }} onClick={toDetail(record)} >查看详情</a>
122
-        </AuthButton>
123
-      ),
124
+           <EditIcon text="查看详情" type="look" onClick={toDetail(record)} />
125
+          {/* <a style={{ color: '#66B3FF' }} onClick={toDetail(record)} >查看详情</a> */}
126
+        </AuthButton>,
127
+      ])
124
     },
128
     },
125
   ];
129
   ];
126
   
130
   

+ 24
- 34
src/pages/eContract/manage/list.jsx Datei anzeigen

1
 import React, { useState, useEffect } from 'react';
1
 import React, { useState, useEffect } from 'react';
2
-import { Form, Input, Button, Icon, Select, message, Table, Divider, Tag, Pagination, Modal, DatePicker } from 'antd';
3
-import { FormattedMessage } from 'umi-plugin-react/locale';
4
-import styles from '../../style/GoodsList.less';
2
+import { Form, Input, Button, Icon, Select, Table, Pagination, DatePicker } from 'antd';
5
 import router from 'umi/router';
3
 import router from 'umi/router';
6
 import moment from 'moment';
4
 import moment from 'moment';
7
-import SelectCity from '../../../components/SelectButton/CitySelect'
8
-import BuildSelect from '../../../components/SelectButton/BuildSelect'
5
+import withActions from '@/components/ActionList';
6
+import EditIcon from '@/components/EditIcon';
7
+import AuthButton from '@/components/AuthButton';
8
+import styles from '../../style/GoodsList.less';
9
 import apis from '../../../services/apis';
9
 import apis from '../../../services/apis';
10
 import request from '../../../utils/request';
10
 import request from '../../../utils/request';
11
 
11
 
12
 
12
 
13
-import AuthButton from '@/components/AuthButton';
14
-
15
-const { Option } = Select;
16
-const { MonthPicker, RangePicker, WeekPicker } = DatePicker;
13
+const { RangePicker } = DatePicker;
17
 
14
 
18
 const header = props => {
15
 const header = props => {
19
-
20
   const [data, setData] = useState({})
16
   const [data, setData] = useState({})
21
 
17
 
22
-
23
   useEffect(() => {
18
   useEffect(() => {
24
-
25
     getList({ pageNum: 1, pageSize: 10 });
19
     getList({ pageNum: 1, pageSize: 10 });
26
-
27
-
28
   }, [])
20
   }, [])
29
 
21
 
30
   // 查询列表
22
   // 查询列表
41
       router.push({
33
       router.push({
42
         pathname: '/eContract/manage/edit',
34
         pathname: '/eContract/manage/edit',
43
         query: {
35
         query: {
44
-          id: id,
36
+          id,
45
         },
37
         },
46
       });
38
       });
47
-      return
39
+
48
     }
40
     }
49
   }
41
   }
50
 
42
 
121
       dataIndex: 'handle',
113
       dataIndex: 'handle',
122
       key: 'handle',
114
       key: 'handle',
123
       align: 'center',
115
       align: 'center',
124
-      render: (text, row) => (
116
+      render: withActions((text, record) => [
125
         <AuthButton name="admin.eContractManager.detail.get" noRight={null}>
117
         <AuthButton name="admin.eContractManager.detail.get" noRight={null}>
126
-          <a style={{ color: '#66B3FF' }} onClick={toDetail(row.contractId)} >查看详情</a>
127
-        </AuthButton>
128
-      ),
118
+          <EditIcon text="查看详情" type="look" onClick={toDetail(record.contractId)} />
119
+        </AuthButton>,
120
+      ]),
129
     },
121
     },
130
   ];
122
   ];
131
 
123
 
145
     e.preventDefault();
137
     e.preventDefault();
146
     props.form.validateFields((err, values) => {
138
     props.form.validateFields((err, values) => {
147
       if (!err) {
139
       if (!err) {
148
-        let {archivesDate, ...submitValue} = values
149
-        if(null != archivesDate && archivesDate.length > 0){
140
+        const { archivesDate, ...submitValue } = values
141
+        if (null != archivesDate && archivesDate.length > 0) {
150
           const [archivesStartDate, archivesEndDate] = archivesDate
142
           const [archivesStartDate, archivesEndDate] = archivesDate
151
           submitValue.archivesStartDate = moment(archivesStartDate).format('YYYY-MM-DD');
143
           submitValue.archivesStartDate = moment(archivesStartDate).format('YYYY-MM-DD');
152
           submitValue.archivesEndDate = moment(archivesEndDate).format('YYYY-MM-DD');
144
           submitValue.archivesEndDate = moment(archivesEndDate).format('YYYY-MM-DD');
153
-        }   
145
+        }
154
         console.log(submitValue)
146
         console.log(submitValue)
155
         getList({ pageNum: 1, pageSize: 10, ...submitValue })
147
         getList({ pageNum: 1, pageSize: 10, ...submitValue })
156
       }
148
       }
157
     });
149
     });
158
   }
150
   }
159
 
151
 
160
-  //重置搜索
152
+  // 重置搜索
161
   function handleReset() {
153
   function handleReset() {
162
     props.form.resetFields();
154
     props.form.resetFields();
163
     getList({ pageNum: 1, pageSize: 10 })
155
     getList({ pageNum: 1, pageSize: 10 })
164
   }
156
   }
165
 
157
 
166
 
158
 
167
-
168
   const { getFieldDecorator } = props.form
159
   const { getFieldDecorator } = props.form
169
   return (
160
   return (
170
 
161
 
200
               <option value="">全部</option>
191
               <option value="">全部</option>
201
               <option value="1">是</option>
192
               <option value="1">是</option>
202
               <option value="0">否</option>
193
               <option value="0">否</option>
203
-
204
-            </Select>
194
+            </Select>,
205
           )}
195
           )}
206
         </Form.Item>
196
         </Form.Item>
207
         <Form.Item>
197
         <Form.Item>
210
               <option value="">全部</option>
200
               <option value="">全部</option>
211
               <option value="1">是</option>
201
               <option value="1">是</option>
212
               <option value="0">否</option>
202
               <option value="0">否</option>
213
-            </Select>
203
+            </Select>,
214
           )}
204
           )}
215
         </Form.Item>
205
         </Form.Item>
216
         <Form.Item>
206
         <Form.Item>
219
               <option value="">全部</option>
209
               <option value="">全部</option>
220
               <option value="1">是</option>
210
               <option value="1">是</option>
221
               <option value="0">否</option>
211
               <option value="0">否</option>
222
-            </Select>
212
+            </Select>,
223
           )}
213
           )}
224
         </Form.Item>
214
         </Form.Item>
225
 
215
 
226
         <Form.Item>
216
         <Form.Item>
227
-        
217
+
228
           {getFieldDecorator('archivesDate')(
218
           {getFieldDecorator('archivesDate')(
229
-            <RangePicker placeholder={['归档开始时间', '归档结束时间']} />
219
+            <RangePicker placeholder={['归档开始时间', '归档结束时间']} />,
230
           )}
220
           )}
231
         </Form.Item>
221
         </Form.Item>
232
         <Form.Item>
222
         <Form.Item>
242
           </AuthButton>
232
           </AuthButton>
243
         </Form.Item>
233
         </Form.Item>
244
       </Form>
234
       </Form>
245
-  
246
-    
247
-         <Table style={{ marginTop: '30px' }} dataSource={data.records} columns={columns} pagination={false} rowKey="activityList" />
235
+
236
+
237
+      <Table style={{ marginTop: '30px' }} dataSource={data.records} columns={columns} pagination={false} rowKey="activityList" />
248
       <div style={{ display: 'flex', justifyContent: 'flex-end', marginTop: '30px' }}>
238
       <div style={{ display: 'flex', justifyContent: 'flex-end', marginTop: '30px' }}>
249
         <Pagination showQuickJumper defaultCurrent={1} total={data.total} onChange={changePageNum} current={data.current} />
239
         <Pagination showQuickJumper defaultCurrent={1} total={data.total} onChange={changePageNum} current={data.current} />
250
       </div>
240
       </div>

+ 5
- 3
src/pages/eContract/template/list.jsx Datei anzeigen

9
 import apis from '../../../services/apis';
9
 import apis from '../../../services/apis';
10
 import request from '../../../utils/request';
10
 import request from '../../../utils/request';
11
 import AuthButton from '@/components/AuthButton';
11
 import AuthButton from '@/components/AuthButton';
12
+import withActions from '@/components/ActionList';
13
+import EditIcon from '@/components/EditIcon';
12
 // import RaiseHelpDoc from '../edit/components/RaiseHelpDoc';
14
 // import RaiseHelpDoc from '../edit/components/RaiseHelpDoc';
13
 
15
 
14
 const { Option } = Select;
16
 const { Option } = Select;
105
       dataIndex: '',
107
       dataIndex: '',
106
       key: '',
108
       key: '',
107
       align: 'center',
109
       align: 'center',
108
-      render: (text, record) => (
110
+      render: withActions((text, record) => [(
109
           <AuthButton name="admin.eContractTemplate.detail.get" noRight={null}>
111
           <AuthButton name="admin.eContractTemplate.detail.get" noRight={null}>
110
-            <a style={{ color: '#66B3FF' }} onClick={toDetail(record)} >查看详情</a>
112
+            <EditIcon type="look" text="查看详情" onClick={toDetail(record)}></EditIcon>
111
           </AuthButton>
113
           </AuthButton>
112
-      ),
114
+      ),])
113
     },
115
     },
114
   ];
116
   ];
115
   const getSignList = dynamicId => {
117
   const getSignList = dynamicId => {

+ 6
- 3
src/pages/h5SampleManager/h5Demand/list.jsx Datei anzeigen

1
 import React, { useState, useEffect } from 'react';
1
 import React, { useState, useEffect } from 'react';
2
 import { Form, Input, Button, Icon, Select, message, Table, Divider, Tag, Pagination, Modal, DatePicker } from 'antd';
2
 import { Form, Input, Button, Icon, Select, message, Table, Divider, Tag, Pagination, Modal, DatePicker } from 'antd';
3
 import { FormattedMessage } from 'umi-plugin-react/locale';
3
 import { FormattedMessage } from 'umi-plugin-react/locale';
4
-import styles from '../../style/GoodsList.less';
5
 import router from 'umi/router';
4
 import router from 'umi/router';
6
 import moment from 'moment';
5
 import moment from 'moment';
6
+import styles from '../../style/GoodsList.less';
7
 import SelectCity from '../../../components/SelectButton/CitySelect'
7
 import SelectCity from '../../../components/SelectButton/CitySelect'
8
 import BuildSelect from '../../../components/SelectButton/BuildSelect'
8
 import BuildSelect from '../../../components/SelectButton/BuildSelect'
9
 import apis from '../../../services/apis';
9
 import apis from '../../../services/apis';
11
 import BatchDel from './components/BatchDel';
11
 import BatchDel from './components/BatchDel';
12
 import AddDemand from './components/AddDemand';
12
 import AddDemand from './components/AddDemand';
13
 import AuthButton from '@/components/AuthButton';
13
 import AuthButton from '@/components/AuthButton';
14
+import withActions from '@/components/ActionList';
15
+import EditIcon from '@/components/EditIcon';
14
 
16
 
15
 const { Option } = Select;
17
 const { Option } = Select;
16
 const { MonthPicker, RangePicker, WeekPicker } = DatePicker;
18
 const { MonthPicker, RangePicker, WeekPicker } = DatePicker;
106
       dataIndex: 'handle',
108
       dataIndex: 'handle',
107
       key: 'handle',
109
       key: 'handle',
108
       align: 'center',
110
       align: 'center',
109
-      render: (text, record) => (
111
+      render: withActions((text, record) =>[ (
110
         <AuthButton name="admin.h5Demand.detail.get" noRight={null}>
112
         <AuthButton name="admin.h5Demand.detail.get" noRight={null}>
111
-          <a style={{ color: '#66B3FF' }} onClick={toDetail(record)} >查看详情</a>
113
+          <EditIcon type="look" text="查看详情" onClick={toDetail(record)}></EditIcon>
112
         </AuthButton>
114
         </AuthButton>
115
+      )]
113
       ),
116
       ),
114
     },
117
     },
115
   ];
118
   ];

+ 2
- 2
src/pages/record/share/countList.jsx Datei anzeigen

168
           </Form.Item>
168
           </Form.Item>
169
           <Form.Item>
169
           <Form.Item>
170
             <span style={{marginRight:'10px'}}>分享时间:</span>
170
             <span style={{marginRight:'10px'}}>分享时间:</span>
171
-                {getFieldDecorator('shareTime')(
172
-                  <RangePicker placeholder={['开始时间','结束时间']} />
171
+                {getFieldDecorator('shareTime',{initialValue : [moment(),moment()],})(
172
+                  <RangePicker placeholder={['开始时间','结束时间']}/>
173
                 )}
173
                 )}
174
           </Form.Item>
174
           </Form.Item>
175
           <Form.Item style={{position:'absolute',right:'38px'}}>
175
           <Form.Item style={{position:'absolute',right:'38px'}}>

+ 17
- 18
src/pages/statistical/activity/sharePersonNum.jsx Datei anzeigen

147
 
147
 
148
     if (props.location.query.queryDate) {
148
     if (props.location.query.queryDate) {
149
       console.log(queryDate, "props.location.query.queryDateprops.location.query.queryDate")
149
       console.log(queryDate, "props.location.query.queryDateprops.location.query.queryDate")
150
-      startDate = moment(props.location.query.queryDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss')+'.000Z';
151
-      endDate = moment(props.location.query.queryDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss')+'.999Z';
150
+      startDate = moment(props.location.query.queryDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss') + '.000Z';
151
+      endDate = moment(props.location.query.queryDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss') + '.999Z';
152
       console.log(startDate, endDate, "endDateendDateendDateendDateendDateendDate")
152
       console.log(startDate, endDate, "endDateendDateendDateendDateendDateendDate")
153
     } else {
153
     } else {
154
-      startDate = moment(props.location.query.startDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss')+'.000Z';
155
-      endDate = moment(props.location.query.endDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss')+'.999Z';
154
+      startDate = moment(props.location.query.startDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss') + '.000Z';
155
+      endDate = moment(props.location.query.endDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss') + '.999Z';
156
     }
156
     }
157
 
157
 
158
     console.log(startDate)
158
     console.log(startDate)
224
     activityType = this.props.location.query.activityType;
224
     activityType = this.props.location.query.activityType;
225
 
225
 
226
     if (this.props.location.query.queryDate) {
226
     if (this.props.location.query.queryDate) {
227
-      startDate = moment(this.props.location.query.queryDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss')+'.000Z';
228
-      endDate = moment(this.props.location.query.queryDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss')+'.999Z';
227
+      startDate = moment(this.props.location.query.queryDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss') + '.000Z';
228
+      endDate = moment(this.props.location.query.queryDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss') + '.999Z';
229
     } else {
229
     } else {
230
-      startDate = moment(this.props.location.query.startDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss')+'.000Z';
231
-      endDate = moment(this.props.location.query.endDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss')+'.999Z';
230
+      startDate = moment(this.props.location.query.startDate).hours(0).minutes(0).seconds(0).milliseconds(0).format('YYYY-MM-DDTHH:mm:ss') + '.000Z';
231
+      endDate = moment(this.props.location.query.endDate).hours(23).minutes(59).seconds(59).milliseconds(999).format('YYYY-MM-DDTHH:mm:ss') + '.999Z';
232
     }
232
     }
233
     this.setState({
233
     this.setState({
234
       formData: {
234
       formData: {
297
 
297
 
298
     return (
298
     return (
299
       <>
299
       <>
300
+        <div align="right" style={{ marginBottom: '16px' }}><Button onClick={this.goback}>返回</Button></div>
300
         <div>
301
         <div>
301
           <span style={{ marginLeft: '20px' }}>分享内容:{this.state.activityName}</span>
302
           <span style={{ marginLeft: '20px' }}>分享内容:{this.state.activityName}</span>
302
         </div>
303
         </div>
323
             </Button>
324
             </Button>
324
             <Button onClick={e => this.handleReset()} style={{ marginLeft: '30px' }}>重置</Button>
325
             <Button onClick={e => this.handleReset()} style={{ marginLeft: '30px' }}>重置</Button>
325
           </Form.Item>
326
           </Form.Item>
326
-        </Form>
327
-        <div>
328
-          <Button type="primary" style={{ float: 'right', margin: '20px 0', marginLeft: '20px', zIndex: 1 }} onClick={this.goback}>
329
-            返回
330
-            </Button>
331
           <AuthButton name="admin.statistical.activity.export" noRight={null}>
327
           <AuthButton name="admin.statistical.activity.export" noRight={null}>
332
-            <Button type="primary" style={{ float: 'right', margin: '20px 0', zIndex: 1 }} onClick={this.exportActivityStats}>
328
+            <Button type="primary" style={{ float: 'right', zIndex: 1, marginTop: '25px' }} onClick={this.exportActivityStats}>
333
               导出
329
               导出
334
             </Button>
330
             </Button>
335
           </AuthButton>
331
           </AuthButton>
332
+        </Form>
333
+        <div>
334
+
336
           <Table style={{ marginTop: '20px' }} dataSource={this.state.tableData} columns={columns} pagination={{ total: this.state.total }} onChange={this.handleTableChange} scroll={{ y: 500 }}></Table>
335
           <Table style={{ marginTop: '20px' }} dataSource={this.state.tableData} columns={columns} pagination={{ total: this.state.total }} onChange={this.handleTableChange} scroll={{ y: 500 }}></Table>
337
         </div>
336
         </div>
338
         <Prompt message={location =>
337
         <Prompt message={location =>
339
-        location.pathname.startsWith("/statistical/activity")
340
-          ? true
341
-          : localStorage.removeItem("tabState")} />
342
-    </>
338
+          location.pathname.startsWith("/statistical/activity")
339
+            ? true
340
+            : localStorage.removeItem("tabState")} />
341
+      </>
343
     )
342
     )
344
 
343
 
345
   }
344
   }

+ 3
- 2
src/utils/request.js Datei anzeigen

20
   410: '请求的资源被永久删除,且不会再得到的。',
20
   410: '请求的资源被永久删除,且不会再得到的。',
21
   422: '当创建一个对象时,发生一个验证错误。',
21
   422: '当创建一个对象时,发生一个验证错误。',
22
   500: '服务器发生错误,请检查服务器。',
22
   500: '服务器发生错误,请检查服务器。',
23
-  502: '网关错误。',
23
+  502: '连接服务超时',
24
   503: '服务不可用,服务器暂时过载或维护。',
24
   503: '服务不可用,服务器暂时过载或维护。',
25
   504: '网关超时。',
25
   504: '网关超时。',
26
 };
26
 };
70
       const errorText = codeMessage[response.status] || response.statusText;
70
       const errorText = codeMessage[response.status] || response.statusText;
71
       const { status, url } = response;
71
       const { status, url } = response;
72
       notification.error({
72
       notification.error({
73
-        message: `请求错误 ${status}: ${url}`,
73
+        // message: `连接超时,请刷新或重新登录 ${status}: ${url}`,
74
+        message: `连接超时,请刷新或重新登录 ${status}: ${url}`,
74
         description: errorText,
75
         description: errorText,
75
       });
76
       });
76
       throw new Error(response.statusText);
77
       throw new Error(response.statusText);