Sfoglia il codice sorgente

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

魏超 5 anni fa
parent
commit
573c5b7503

+ 1
- 1
src/components/SelectButton/BuildSelect.jsx Vedi File

@@ -32,7 +32,7 @@ const BuildingSelect = props => {
32 32
   }, [])
33 33
 
34 34
   const getCityList = e => {
35
-    request({ ...apis.building.getList, params: { pageNum: 1, pageSize: 999 } }).then(data => {
35
+    request({ ...apis.building.buildingSelect, params: { pageNum: 1, pageSize: 999 } }).then(data => {
36 36
         setData(data.records)
37 37
         // 默认选中第一个
38 38
         if (props.checkFirst) {

+ 7
- 3
src/pages/carouselFigure/advertisingList.jsx Vedi File

@@ -183,8 +183,12 @@ const deleteCarouse = (contentId) => () =>{
183 183
 
184 184
   }
185 185
   
186
-  const changePageNum = (pageNumber) => {
187
-      getList({ pageNum: pageNumber, pageSize: 10, showType: 'screen' })
186
+  const changePageNum = (pageNumber, props) => {
187
+    props.form.validateFields((err, values) => {
188
+      if (!err) {
189
+        getList({ pageNum: pageNumber, pageSize: 10, ...values, showType: 'screen' })
190
+      }
191
+    });
188 192
   }
189 193
 
190 194
   // 提交事件
@@ -262,7 +266,7 @@ const handleSubmit = (e, props) => {
262 266
       </AuthButton>
263 267
       <Table dataSource={data.records} columns={columns} pagination={false} rowKey="advertisingList"/>
264 268
       <div style={{ display: 'flex', justifyContent: 'flex-end', marginTop: '30px' }}>
265
-        <Pagination showQuickJumper defaultCurrent={1} total={data.total} onChange={changePageNum} current={data.current}/>
269
+        <Pagination showQuickJumper defaultCurrent={1} total={data.total} onChange={e => changePageNum(e,props)} current={data.current}/>
266 270
       </div>
267 271
     </>
268 272
   )

+ 8
- 3
src/pages/carouselFigure/carouselFigureList.jsx Vedi File

@@ -183,8 +183,13 @@ const deleteCarouse = (contentId) => () =>{
183 183
 
184 184
   }
185 185
   
186
-  const changePageNum = (pageNumber) => {
187
-      getList({ pageNum: pageNumber, pageSize: 10, showType: 'banner' })
186
+  const changePageNum = (pageNumber, props) => {
187
+      props.form.validateFields((err, values) => {
188
+        if (!err) {
189
+          console.log('提交数据: ', values)
190
+          getList({ pageNum: pageNumber, pageSize: 10, ...values, showType: 'banner' })
191
+        }
192
+      });
188 193
   }
189 194
 
190 195
   // 提交事件
@@ -262,7 +267,7 @@ const handleSubmit = (e, props) => {
262 267
       </AuthButton>
263 268
       <Table dataSource={data.records} columns={columns} pagination={false} rowKey="carouseFigureList"/>
264 269
       <div style={{ display: 'flex', justifyContent: 'flex-end', marginTop: '30px' }}>
265
-        <Pagination showQuickJumper defaultCurrent={1} total={data.total} onChange={changePageNum} current={data.current}/>
270
+        <Pagination showQuickJumper defaultCurrent={1} total={data.total} onChange={e => changePageNum(e,props)} current={data.current}/>
266 271
       </div>
267 272
     </>
268 273
   )

+ 5
- 1
src/pages/carouselFigure/editAdvertising.jsx Vedi File

@@ -259,7 +259,11 @@ import SelectH5 from './SelectH5';
259 259
     const handleSubmit = val => {
260 260
       val.showType = 'screen'
261 261
       if(!val.isHaveActive&&val.targetId) {
262
-        val.contentType='h5'
262
+        if(val.contentType){
263
+            console.log(1)
264
+        }else{
265
+          val.contentType='h5'
266
+        }
263 267
       }
264 268
       if(contentId){
265 269
         request({ ...apis.carsuseFigure.updataExtendContent,urlData:{id: contentId}, data: val,}).then((data) => {

+ 5
- 1
src/pages/carouselFigure/editCarousel.jsx Vedi File

@@ -292,7 +292,11 @@ const { MonthPicker, RangePicker, WeekPicker } = DatePicker;
292 292
       const handleSubmit = val => {
293 293
         val.showType = 'banner'
294 294
         if(!val.isHaveActive&&val.targetId) {
295
-          val.contentType='h5'
295
+          if(val.contentType){
296
+              console.log(1)
297
+          }else{
298
+            val.contentType='h5'
299
+          }
296 300
         }
297 301
         if (contentId) {
298 302
           request({ ...apis.carsuseFigure.updataExtendContent, urlData: { id: contentId }, data: val }).then(data => {