[baozhangchao] 3 年 前
コミット
5abd7c4998

+ 89
- 41
src/pages/ApplicationList/components/AppliCard/index.jsx ファイルの表示

@@ -4,68 +4,116 @@ import Taro from '@tarojs/taro';
4 4
 import './style.less'
5 5
 
6 6
 export default (props) => {
7
-  const { onClick, } = props;
7
+  const { onClick, item, copy } = props;
8
+
9
+  const cardStatus = (ite) => {
10
+    if (item.status === 0) {
11
+      return {
12
+        title: '未付款',
13
+        styleColor: ''
14
+
15
+      }
16
+    } else if (item.status == 1) {
17
+      return {
18
+        title: '审核中',
19
+        styleColor: ''
20
+      }
21
+    } else if (item.status == 2 && item.verifyStatus == 2) {
22
+      return {
23
+        title: '驳回',
24
+        styleColor: 'red'
25
+
26
+      }
27
+
28
+    } else if (item.status == 2 && item.verifyStatus == 1) {
29
+      return {
30
+        title: '待发卡',
31
+        styleColor: ''
32
+
33
+      }
34
+    } else if (item.status == 3) {
35
+      return {
36
+        title: '已完成',
37
+        styleColor: '#04bd02'
38
+
39
+      }
40
+    }
41
+
42
+  }
43
+
44
+  // 状态  如果 status 0 未付款 
45
+  //       如果1审核中   
46
+  //        驳回  status: 2 ||  verifyStatus: 2 驳回
47
+
48
+  //        待发卡  status: 2 ||  verifyStatus: 1 待发卡 
49
+
50
+  //        status 3
8 51
 
9 52
 
10 53
   return (
11 54
     <View className='ApplicationListBox'>
12 55
       <View className='ApplicationListBox-CardBox'>
13
-
14 56
         <View className='ApplicationListBox-CardBox-headerTop'>
15 57
           狗狗姓名
16 58
           <View className='ApplicationListBox-CardBox-headerTop-right'>
17
-            <View>我的二狗子</View>
59
+            <View>{item.petName}</View>
18 60
 
19
-            <Image src='https://gss0.baidu.com/7Po3dSag_xI4khGko9WTAnF6hhy/zhidao/pic/item/48540923dd54564e953f5e6cbede9c82d1584f08.jpg' />
61
+            <Image src={item.img1} />
20 62
           </View>
21 63
         </View>
22
-        {/* 状态
23
-
24
-待付款 
25
-审核中 > 驳回 点击去修改  /退款
26
-驳回原因
27
-
28
-待发卡
29
-已完成 
30
-
31
-        狗名字
32
-        时间
33
-        方式
34
-        状态
35
-        单号+快递公司
36
-*/}
37
-
38 64
         <View className='ApplicationListBox-CardBox-content'>
39 65
           <View>申请时间</View>
40
-          <View>2022-05-06 12:36</View>
66
+          <View>{item.createDate}</View>
41 67
         </View>
42 68
         <View className='ApplicationListBox-CardBox-content'>
43 69
           <View>审领方式</View>
44
-          <View>邮寄</View>
70
+          <View>{item.applyMethod == 1 ? '自取' : '邮寄'}</View>
45 71
         </View>
46 72
         <View className='ApplicationListBox-CardBox-content'>
47 73
           <View>状态</View>
48
-          <View>已完成</View>
74
+          <View style={{ color: cardStatus(item)?.styleColor }}>{cardStatus(item)?.title}</View>
49 75
         </View>
50
-        <View className='ApplicationListBox-CardBox-content'>
51
-          <View>邮政快递</View>
52
-          <View>3200222000</View>
53
-        </View>
54
-        <View>
76
+        {
77
+          cardStatus(item)?.title == '已完成' ?
78
+            <View className='ApplicationListBox-CardBox-content' onClick={() => { copy(item.trackingNo) }}>
79
+              <View>{item.trackingType}</View>
80
+              <View>{item.trackingNo}</View>
81
+            </View>
82
+            : <></>
83
+        }
84
+        {
85
+          cardStatus(item)?.title == '驳回' ?
86
+            <View>
87
+              <View className='ApplicationListBox-CardBox-refuse'>
88
+                <View>驳回原因</View>
89
+                <View>{item.rejectReason}</View>
90
+              </View>
91
+              <View style={{ margin: '0.5em 0 0.2em 0' }}>
92
+                <Button
93
+                  style={{ width: '135px', height: '35px', fontSize: '14px', backgroundColor: '#fbd804', borderRadius: '40px', color: '#000', border: '0px' }}
94
+                  class='weui-btn' type='primary'
95
+                  loading={false}
96
+                  onClick={() => { onClick(item.petId) }}
97
+                >重新填写</Button>
98
+              </View>
99
+            </View>
100
+            : <></>
101
+        }
55 102
 
56
-          <View className='ApplicationListBox-CardBox-refuse'>
57
-            <View>驳回原因</View>
58
-            <View>因地区政策原因,疫苗报告失效,请重新填写申请信息。</View>
59
-          </View>
60
-          <View style={{ margin: '0.5em 0 0.2em 0' }}>
61
-            <Button
62
-              style={{ width: '135px', height: '35px', fontSize: '14px', backgroundColor: '#fbd804', borderRadius: '40px', color: '#000', border: '0px' }}
63
-              class='weui-btn' type='primary'
64
-              loading={false}
65
-              onClick={onClick}
66
-            >重新填写</Button>
67
-          </View>
68
-        </View>
103
+        {
104
+          cardStatus(item)?.title == '未付款' ?
105
+            <View>
106
+              <View style={{ margin: '0.5em 0 0.2em 0' }}>
107
+                <Button
108
+                  style={{ width: '135px', height: '35px', fontSize: '14px', backgroundColor: '#fbd804', borderRadius: '40px', color: '#000', border: '0px' }}
109
+                  class='weui-btn' type='primary'
110
+                  loading={false}
111
+                  onClick={() => { onClick('pay', item.applyId) }}
112
+                >支付</Button>
113
+              </View>
114
+            </View>
115
+            : <></>
116
+        }
69 117
 
70 118
       </View>
71 119
 

+ 2
- 1
src/pages/ApplicationList/index.config.js ファイルの表示

@@ -1,10 +1,11 @@
1 1
 export default {
2
-  navigationBarTitleText: '申请状态列表',
2
+  navigationBarTitleText: '申请列表',
3 3
   disableScroll: true,
4 4
   navigationBarBackgroundColor: "#FBD804",
5 5
   navigationBarTextStyle: "black",
6 6
   backgroundColor: "#FBD804",
7 7
   usingComponents: {
8
+    "mp-loading": "weui-miniprogram/loading/loading"
8 9
 
9 10
   }
10 11
 

+ 51
- 15
src/pages/ApplicationList/index.jsx ファイルの表示

@@ -1,34 +1,70 @@
1 1
 import { ScrollView, View, Image, Button } from '@tarojs/components'
2
-import Taro from '@tarojs/taro';
2
+import Taro, { useDidShow } from '@tarojs/taro';
3 3
 import { useState, useEffect } from 'react';
4
-import { getOrder } from '../../services/dogAPI';
4
+import { getApplicationList, getOrder } from '../../services/dogAPI';
5 5
 import AppliCard from './components/AppliCard';
6 6
 import './style.less'
7 7
 
8 8
 export default (props) => {
9 9
   const id = Taro.getCurrentInstance().router.params.id;
10
-  const [orderInfo, setOrderInfo] = useState()
10
+  const [applionList, setApplionList] = useState([])
11
+  const [applionLoading, setApplionLoading] = useState(false)
11 12
 
12
-  useEffect(() => {
13
-    if (id) {
14
-      getOrder(id).then((e) => {
15
-        console.log('e', e);
16
-        setOrderInfo(e)
17
-      })
18
-    }
13
+  useDidShow(() => {
14
+    setApplionLoading(true)
19 15
 
20
-  }, [id])
16
+    getApplicationList({ pageSize: 500 }).then((e) => {
17
+      console.log('e', e);
18
+      setApplionList(e.records)
19
+      setApplionLoading(false)
21 20
 
22
-  const goSetDogLicense = () => {
23
-    Taro.navigateTo({
24
-      url: '/pages/setDogLicense/index'
21
+    })
22
+  }, [])
23
+  const trackingCopy = (value) => {
24
+    Taro.setClipboardData({
25
+      data: value,
26
+      success: e => {
27
+        Taro.showToast({
28
+          title: '快递单号已复制',
29
+          icon: 'success',
30
+          duration: 2000,
31
+        })
32
+      }
25 33
     })
26 34
   }
35
+  const goSetDogLicense = (e, Id) => {
36
+    if (e == 'pay') {
37
+      Taro.navigateTo({
38
+        url: `/pages/payPage/index?id=${Id}`
39
+      })
40
+    } else {
41
+      Taro.navigateTo({
42
+        url: `/pages/setDogLicense/index?type=first&petId=${Id}`
43
+      })
44
+    }
45
+
46
+  }
27 47
 
28 48
 
29 49
   return (
30 50
     <ScrollView scrollY style={{ height: '100vh' }}>
31
-      <AppliCard onClick={goSetDogLicense} />
51
+      {
52
+        applionLoading ? <mp-loading extClass="page-loading-circle" type="circle" show={applionLoading} /> :
53
+
54
+          <>
55
+
56
+            {
57
+              applionList.map((item, index) => {
58
+                return (
59
+                  <AppliCard key={index} item={item} onClick={goSetDogLicense} copy={trackingCopy} />
60
+
61
+                )
62
+
63
+              })
64
+            }
65
+          </>
66
+      }
67
+
32 68
 
33 69
       <View style={{ textAlign: 'center', margin: '6vw 0 3vw 0', color: '#858585', fontSize: '12px' }}>
34 70
         申请驳回,费用将原路退回支付账户!

+ 6
- 0
src/pages/ApplicationList/style.less ファイルの表示

@@ -0,0 +1,6 @@
1
+.page-loading-circle {
2
+  .weui-loading {
3
+    width: 96rpx;
4
+    height: 96rpx;
5
+  }
6
+}

+ 5
- 6
src/pages/dogCardDetail/index.jsx ファイルの表示

@@ -2,17 +2,16 @@ import { View, Image, ScrollView } from '@tarojs/components'
2 2
 import Taro from '@tarojs/taro';
3 3
 import { useEffect, useState } from 'react';
4 4
 import RatioItem from '@/components/RatioItem';
5
-import { getApplicationInfo } from '../../services/dogAPI';
5
+import { getDogCardInfo } from '../../services/dogAPI';
6 6
 
7 7
 import './style.less'
8 8
 
9 9
 export default (props) => {
10
-  const status = 2;
11 10
   const petId = Taro.getCurrentInstance().router.params.id
12 11
   const [applicationInfoDate, setApplicationInfoDate] = useState()
13 12
   useEffect(() => {
14 13
     if (petId) {
15
-      getApplicationInfo(petId).then((e) => {
14
+      getDogCardInfo(petId).then((e) => {
16 15
         setApplicationInfoDate(e)
17 16
 
18 17
       })
@@ -48,14 +47,14 @@ export default (props) => {
48 47
               </View>
49 48
               <View className='cell'>
50 49
                 <View className='lable'>性别</View>:
51
-                <View className='content'>{applicationInfoDate?.petSex}</View>
50
+                <View className='content'>{applicationInfoDate?.petSex == 1 ? '雄' : '雌'}</View>
52 51
               </View>
53 52
             </View>
54 53
             <View className='cardRight'>
55 54
               <RatioItem ratio='109:151'>
56 55
                 <Image
57 56
                   style={{ width: '100%' }}
58
-                  mode='center'
57
+                  mode='widthFix'
59 58
                   src={applicationInfoDate?.petImg1}
60 59
                 ></Image>
61 60
               </RatioItem>
@@ -63,7 +62,7 @@ export default (props) => {
63 62
           </View >
64 63
           <View className='cell' style={{ marginTop: '0' }}>
65 64
             <View className='lable'>状态</View>:
66
-            <View className={['state', 'color' + status]}>{applicationInfoDate?.status == 1 ? '正常' : applicationInfoDate?.status == 2 ? '挂失' : '过期'}</View>
65
+            <View className={['state', 'color' + applicationInfoDate?.status]}>{applicationInfoDate?.status == 1 ? '正常' : applicationInfoDate?.status == 2 ? '挂失' : '过期'}</View>
67 66
             {/* 挂失 续期 */}
68 67
           </View>
69 68
           <View className='cell'>

+ 2
- 1
src/pages/dogLicenseList/index.jsx ファイルの表示

@@ -25,8 +25,9 @@ export default (props) => {
25 25
   }
26 26
 
27 27
   const widgetView = (value) => {
28
+    console.log("🚀 ~ file: index.jsx ~ line 28 ~ widgetView ~ value", value)
28 29
     return (
29
-      <View className='user-box-DogListCard' onClick={() => { goLicenseInfo(value.petId) }}>
30
+      <View className='user-box-DogListCard' onClick={() => { goLicenseInfo(value.cardId) }}>
30 31
         <View className='user-box-DogListCard-DogImage'>
31 32
           {/* <ViewIcon icon='morentouxiang' size={50} color='#FBD804' /> */}
32 33
           <Image src={value.petImg1} />

+ 2
- 1
src/pages/index/index.jsx ファイルの表示

@@ -4,9 +4,10 @@ import Taro from '@tarojs/taro'
4 4
 import Banner from '@/components/Banner'
5 5
 import Notice from '@/components/Notice'
6 6
 import PageLoading from '@/components/PageLoading'
7
+import withBasic from '@/layouts/withBasic'
8
+
7 9
 import { useModel } from '@/store'
8 10
 import { getApplicationList, getBannerList } from '@/services/dogAPI'
9
-import withBasic from '@/layouts/withBasic'
10 11
 import MenuItem from './components/MenuItem'
11 12
 
12 13
 import './style.less'

+ 1
- 0
src/pages/payPage/index.config.js ファイルの表示

@@ -5,6 +5,7 @@ export default {
5 5
   navigationBarTextStyle: "black",
6 6
   backgroundColor: "#FBD804",
7 7
   usingComponents: {
8
+    "mp-loading": "weui-miniprogram/loading/loading"
8 9
 
9 10
   }
10 11
 

+ 38
- 27
src/pages/payPage/index.jsx ファイルの表示

@@ -1,5 +1,5 @@
1 1
 import { ScrollView, View, Button } from '@tarojs/components'
2
-import Taro from '@tarojs/taro';
2
+import Taro, { reLaunch } from '@tarojs/taro';
3 3
 import { useState, useEffect } from 'react';
4 4
 import { getOrder } from '@/services/dogAPI';
5 5
 import './style.less'
@@ -7,12 +7,15 @@ import './style.less'
7 7
 export default (props) => {
8 8
   const id = Taro.getCurrentInstance().router.params.id;
9 9
   const [orderInfo, setOrderInfo] = useState()
10
-
10
+  const [payLoading, setPayLoading] = useState(false)
11 11
   useEffect(() => {
12 12
     if (id) {
13
+      setPayLoading(true)
13 14
       getOrder(id).then((e) => {
14 15
         console.log('e', e);
15 16
         setOrderInfo(e)
17
+        setPayLoading(false)
18
+
16 19
       })
17 20
     }
18 21
 
@@ -20,19 +23,19 @@ export default (props) => {
20 23
 
21 24
   const pay = (params) => {
22 25
     Taro.hideLoading()
23
-    console.log("🚀 ~ file: index.jsx ~ line 92 ~ requestPayment ~ params", params)
24 26
     Taro.requestPayment({
25
-      // ...params,
26
-      // package: params.packageValue,
27
+      ...orderInfo.prepay,
28
+      package: orderInfo.prepay.packageValue,
27 29
       success: () => {
28 30
         Taro.showToast({
29 31
           title: "支付成功",
30 32
           icon: "success",
31 33
           duration: 1000,
32 34
         }).then(() => {
35
+          console.log('支付成功',);
33 36
           setTimeout(() => {
34 37
             Taro.reLaunch({
35
-              // url: `/pages/index/index?tab=2`
38
+              url: '/pages/ApplicationList/index'
36 39
             })
37 40
           }, 400)
38 41
         })
@@ -43,33 +46,41 @@ export default (props) => {
43 46
           icon: "none",
44 47
           duration: 2000,
45 48
         });
46
-        Taro.reLaunch({
47
-          // url: `/pages/MineUserAll/AllOrder/index?tabJump=1`
48
-        })
49
+        console.log('支付失败', e);
50
+
49 51
       },
50 52
     })
51 53
   }
52 54
 
53 55
   return (
54 56
     <ScrollView scrollY style={{ height: '100vh' }}>
55
-      <View className='payPageBox'>
56
-        <View className='payPageBox-payItemBox'>
57
-          <View className='payPageBox-payItemBox-left'></View>
58
-          <View className='payPageBox-payItemBox-content'>订单号: <View>32121321321</View></View>
59
-        </View>
60
-        <View className='payPageBox-payItemBox'>
61
-          <View className='payPageBox-payItemBox-leftText'>工本费: <View>20</View>元</View>
62
-        </View>
63
-        <View className='payPageBox-payItemBox'>
64
-          <View className='payPageBox-payItemBox-leftText'>快递费: <View>3221321</View>元</View>
65
-        </View>
66
-        <View className='payPageBox-payItemBox'>
67
-          <View className='payPageBox-payItemBox-leftText'>总金额: <View style={{ color: 'red' }}>20</View>元</View>
68
-        </View>
69
-      </View>
70
-      <View slot='button' style={{ margin: '4em 0 2em 0' }}>
71
-        <Button style={{ backgroundColor: '#fbd804', borderRadius: '40px', color: '#000', border: '0px' }} class='weui-btn' type='primary' loading={false} onClick={pay}>支付</Button>
72
-      </View>
57
+      {
58
+        payLoading ? <mp-loading extClass="page-loading-circle" type="circle" show={payLoading} /> :
59
+          <>
60
+            <View className='payPageBox'>
61
+              <View className='payPageBox-payItemBox'>
62
+                <View className='payPageBox-payItemBox-left'></View>
63
+                <View className='payPageBox-payItemBox-content'>订单号: <View>{orderInfo?.order?.orderNo}</View></View>
64
+              </View>
65
+              <View className='payPageBox-payItemBox'>
66
+                <View className='payPageBox-payItemBox-leftText'>下单时间: <View>{orderInfo?.order?.createDate}</View></View>
67
+              </View>
68
+              <View className='payPageBox-payItemBox'>
69
+                <View className='payPageBox-payItemBox-leftText'>工本费: <View>{orderInfo?.order?.productionCost / 100}</View>元</View>
70
+              </View>
71
+              <View className='payPageBox-payItemBox'>
72
+                <View className='payPageBox-payItemBox-leftText'>快递费: <View>{orderInfo?.order?.expressFee / 100}</View>元</View>
73
+              </View>
74
+              <View className='payPageBox-payItemBox'>
75
+                <View className='payPageBox-payItemBox-leftText'>总金额: <View style={{ color: 'red' }}>{orderInfo?.order?.charges / 100}</View>元</View>
76
+              </View>
77
+            </View>
78
+            <View slot='button' style={{ margin: '4em 0 2em 0' }}>
79
+              <Button style={{ backgroundColor: '#fbd804', borderRadius: '40px', color: '#000', border: '0px' }} class='weui-btn' type='primary' loading={false} onClick={pay}>支付</Button>
80
+            </View>
81
+          </>
82
+      }
83
+
73 84
     </ScrollView>
74 85
   )
75 86
 }

+ 7
- 0
src/pages/payPage/style.less ファイルの表示

@@ -1,3 +1,10 @@
1
+.page-loading-circle {
2
+  .weui-loading {
3
+    width: 96rpx;
4
+    height: 96rpx;
5
+  }
6
+}
7
+
1 8
 .payPageBox {
2 9
   width: 86%;
3 10
   background-color: #fff;

+ 82
- 32
src/pages/setDogLicense/index.jsx ファイルの表示

@@ -14,6 +14,7 @@ import { getCardLicenseInfo } from '../../services/dogAPI';
14 14
 export default (props) => {
15 15
   const { dogs, person } = useModel('userData')
16 16
   const [formData, setFormData] = useState()
17
+  const routerPetId = Taro.getCurrentInstance().router.params.petId;
17 18
 
18 19
   const [dogDate, setDogDate] = useState({ immunizationDate: null, petBirthday: null, petSex: [], petType: [] })
19 20
   const [mainDog, setMainDog] = useState([])
@@ -49,6 +50,7 @@ export default (props) => {
49 50
     })
50 51
   }, [])
51 52
 
53
+
52 54
   const getDogInfoFunction = (petId) => {
53 55
 
54 56
     getDogInfo(petId).then((e) => {
@@ -56,7 +58,7 @@ export default (props) => {
56 58
       const sex = [{ value: e?.sex, text: e?.sex == 1 ? '雄' : '雌' }];
57 59
       const petType = [{ value: 0, name: e?.petType }];
58 60
 
59
-      setDogDate({ ...dogDate, petBirthday: e?.birthday, petSex: sex, petType: petType })
61
+      setDogDate({ ...dogDate, petBirthday: e?.birthday, petSex: sex, petType: petType, })
60 62
       console.log('test', e);
61 63
 
62 64
     })
@@ -64,11 +66,12 @@ export default (props) => {
64 66
   const getMainDogChange = (value) => {
65 67
     console.log("🚀 ~ file: index.jsx ~ line 34 ~ getMainDogChange ~ value", value)
66 68
     const { petId } = value.detail.data
67
-    if (applyType == 'renewal' || (applyType == 'reissue')) {
69
+    if (applyType == 'renewal' || applyType == 'reissue') {
68 70
       setDogStatus(false)
69 71
       getDogInfoFunction(petId)
70 72
       getCardLicenseInfo(petId).then((res) => {
71 73
         console.log('狗子证件有效期', res);
74
+        setRenewalAndReissue(res)
72 75
       })
73 76
     }
74 77
     if (applyType == 'first') {
@@ -78,12 +81,21 @@ export default (props) => {
78 81
           getDogInfoFunction(petId)
79 82
         } else {
80 83
           setDogStatus(true)
81
-          Taro.showToast({
82
-            title: '当前狗狗已有证件!',
83
-            icon: 'error',
84
-            duration: 2000,
84
+          Taro.showModal({
85
+            title: '提示',
86
+            content: '当前狗狗已有证件,请勿重复申请!',
87
+            showCancel: false,
88
+            success: function (v) {
89
+              if (v.confirm) {
90
+                console.log('用户点击确定')
91
+                Taro.navigateBack({
92
+                  delta: 1
93
+                })
94
+              }
95
+            }
85 96
           })
86 97
 
98
+
87 99
         }
88 100
       })
89 101
     }
@@ -114,35 +126,58 @@ export default (props) => {
114 126
   const modeList = [
115 127
     {
116 128
       value: 1,
117
-      text: '邮寄',
129
+      text: '自取',
118 130
     },
119 131
     {
120 132
       value: 2,
121
-      text: '自取',
133
+      text: '邮寄',
122 134
     },
123 135
   ]
124 136
 
125 137
   // ...dogDate,
126 138
   const formSubmit = value => {
127
-    addlication({ ...value, applyType }).then((res) => {
128
-      console.log('dogInfo xinwe', res);
129
-      Taro.showToast({
130
-        title: '申请成功,等待审核',
131
-        icon: 'none',
132
-        duration: 1000
133
-      })
134
-      if (applyType == 'renewal') {
135
-        Taro.navigateBack({
136
-          delta: 1
139
+    if (applyType == 'renewal' || applyType == 'reissue') {
140
+      addlication({ ...value, applyType, petId: formData.petId, originCardNo: renewalAndReissue?.cardNo }).then((res) => {
141
+        console.log('dogInfo xinwe', res);
142
+        Taro.showToast({
143
+          title: '申请成功,等待审核',
144
+          icon: 'none',
145
+          duration: 1000
137 146
         })
138
-        return;
139
-      } else {
140
-        Taro.reLaunch({
141
-          url: `/pages/payPage/index?id=${res.applyId}`
147
+        if (applyType == 'renewal') {
148
+          Taro.navigateBack({
149
+            delta: 1
150
+          })
151
+          return;
152
+        } else {
153
+          Taro.reLaunch({
154
+            url: `/pages/payPage/index?id=${res.applyId}`
155
+          })
156
+        }
157
+
158
+      })
159
+    } else {
160
+      addlication({ ...value, applyType, petId: formData.petId }).then((res) => {
161
+        console.log('dogInfo xinwe', res);
162
+        Taro.showToast({
163
+          title: '申请成功,等待审核',
164
+          icon: 'none',
165
+          duration: 1000
142 166
         })
143
-      }
167
+        if (applyType == 'renewal') {
168
+          Taro.navigateBack({
169
+            delta: 1
170
+          })
171
+          return;
172
+        } else {
173
+          Taro.reLaunch({
174
+            url: `/pages/payPage/index?id=${res.applyId}`
175
+          })
176
+        }
177
+
178
+      })
179
+    }
144 180
 
145
-    })
146 181
   }
147 182
 
148 183
   const rules = {
@@ -151,7 +186,7 @@ export default (props) => {
151 186
     petBirthday: [{ required: true, message: '请选择狗狗生日' }],
152 187
     petColor: [{ required: true, message: '请选择狗狗毛色' }],
153 188
     petType: [{ required: true, message: '请选择犬种类别' }],
154
-    dogImg1: [{ required: true, message: '请上传狗狗照片' }],
189
+    img1: [{ required: true, message: '请上传狗狗照片' }],
155 190
     immunizationDate: [{ required: true, message: '请上输入最近免疫时间' }],
156 191
     immunizationCode: [{ required: true, message: '请输入免疫证号' }],
157 192
     immunizationImg: [{ required: true, message: '请上传免疫图片' }],
@@ -169,12 +204,27 @@ export default (props) => {
169 204
               <FormItem title='犬主姓名' required>
170 205
                 <View >{person?.nickName}</View>
171 206
               </FormItem>
172
-              <FormItem title='证件号' required>
173
-                <View >{person?.nickName}</View>
174
-              </FormItem>
175
-              <FormItem title='有效期' required>
176
-                <View >{person?.nickName}</View>
177
-              </FormItem>
207
+              {
208
+                applyType == 'first' ? <></>
209
+                  :
210
+                  <>
211
+                    <FormItem title='证件号' required>
212
+                      <View >{renewalAndReissue?.cardNo}</View>
213
+                    </FormItem>
214
+                    <FormItem title='有效期' required>
215
+                      {
216
+                        formData?.sex ?
217
+                          <View >
218
+
219
+                            {renewalAndReissue?.startDate}~{renewalAndReissue?.expireDate}</View>
220
+                          :
221
+                          <View></View>
222
+                      }
223
+
224
+                    </FormItem>
225
+                  </>
226
+              }
227
+
178 228
               <FormItem title='狗狗名称' required>
179 229
                 <s-picker name='petName' rangeKey='name' rangeValue='value' range={mainDog} value={formData?.name} onChange={getMainDogChange} />
180 230
               </FormItem>
@@ -201,7 +251,7 @@ export default (props) => {
201 251
                 <Input name='petColor' placeholder='请输入毛色' value={formData?.color} />
202 252
               </FormItem>
203 253
               <FormItem title='狗狗照片' required>
204
-                <uploader name='dogImg1' onFile={handleFile} value={formData?.image} />
254
+                <uploader name='img1' onFile={handleFile} value={formData?.image} />
205 255
               </FormItem>
206 256
               <FormItem title='最近免疫日期' required>
207 257
                 <Picker name='immunizationDate' mode='date' onChange={(e) => { onDateChange('immunizationDate', e.detail.value) }}>

+ 0
- 1
src/services/dogAPI.js ファイルの表示

@@ -108,7 +108,6 @@ export const getDogType = (id, data) => request(`/setting/dog_type`, { data, met
108 108
 
109 109
 
110 110
 
111
-
112 111
 /**
113 112
 * 消息列表
114 113
 * @param {*} data