Kaynağa Gözat

fix: bugFixed 2022-10-23

wangyuan 2 yıl önce
ebeveyn
işleme
1347209998

+ 1 - 0
pages/address/address.js

@@ -87,6 +87,7 @@ Page({
    * 编辑地址
    */
   handleEdit(e) {
+    console.log(e);
     var value = e.currentTarget.dataset.item
     var editProvice = value.province
     var editCity = value.city

+ 5 - 7
pages/addressAdd/addressAdd.js

@@ -16,14 +16,7 @@ Page({
     regionIndex: [0,0,0]
   },
 
-  onShow () {
-    this.setData({
-      region: []
-    })
-  },
-
   onLoad (options) {
-    this.getRegionFn()
     if (options.type && options.type == 0) {
       wx.setNavigationBarTitle({
         title: '编辑地址',
@@ -36,6 +29,10 @@ Page({
         contactName: options.contactName,
         detailAddress: options.detailAddress
       })
+    } else {
+      this.setData({
+        region: []
+      })
     }
   },
 
@@ -117,6 +114,7 @@ Page({
   },
   // 提交表单验证
   valid () {
+    console.log(this.data.region);
     var valid = false
     if (this.data.contactName == '') {
       wx.showToast({

+ 24 - 6
pages/appointment/appointment.js

@@ -32,7 +32,8 @@ Page({
     durationTwo: false,
     durationTwoBusy: false,
     durationThree: false,
-    durationThreeBusy: false
+    durationThreeBusy: false,
+    allDayBusy: false
   },
 
   /**
@@ -66,13 +67,13 @@ Page({
   },
 
   // 获取当天可预约的次数
-  getResetNumberFn (data) {
+  getResetNumberFn (cDate, index) {
     var that = this
     var data = {
       province: this.data.province,
       city: this.data.city,
       county: this.data.county,
-      appointmentDate: data
+      appointmentDate: cDate
     }
     wx.showLoading({
       title: '加载中...',
@@ -81,9 +82,14 @@ Page({
     getResetNumber(data).then(res => {
       wx.hideLoading()
       const response = res.data.carDurationConfigs
-      console.log(response)
+      const allBusy = response.find(item => {
+        return item.isBusy == false
+      })
+      if (allBusy == undefined) {
+        console.log(index,cDate, '约满')
+        that.handleAllDayBusy(cDate)
+      }
       response.forEach(item => {
-        console.log(item);
         if (item.duration == 1) {
           that.setData({
             durationOne: item.isBusy,
@@ -113,6 +119,18 @@ Page({
     })
   },
 
+  handleAllDayBusy (cDate) {
+    const _weekList = this.data.weekList
+    _weekList.forEach(item => {
+      if (item.dateStr == cDate) {
+        item.date = '约满'
+      }
+    })
+    this.setData({
+      weekList: _weekList
+    })
+  },
+
   onPullDownRefresh () {
     wx.vibrateShort({
       type: 'medium'
@@ -308,7 +326,7 @@ Page({
           choseDate: cDate,
           timeActive: ''
         })
-        this.getResetNumberFn(cDate)
+        this.getResetNumberFn(cDate,index)
       }
     }
   },

+ 12 - 6
pages/appointment/appointment.wxml

@@ -70,16 +70,22 @@
       </view>
       <view class="time-list ittflex">
         <view class="time-a time-item time-nurse  {{timeActive == '1' ? 'time-active' : ''}} {{durationOneBusy ? 'time-item-disabled' : ''}}" data-time="1" data-dis="{{durationOneBusy}}" bindtap="handleTime">
-          <text class="t-text">8:00-12:00</text>
-          <text class="time-nurse-text" wx:if="{{durationOne}}">剩余紧张</text>
+          <text class="t-text">08:30-12:00</text>
+          <text class="time-nurse-text" wx:if="{{durationOne}}">
+            <text>{{durationOneBusy ? '约满':'剩余紧张'}}</text>
+          </text>
         </view>
         <view class="time-b time-item time-nurse {{timeActive == '2' ? 'time-active' : ''}} {{durationTwoBusy ? 'time-item-disabled' : ''}}" data-dis="{{durationTwoBusy}}" data-time="2" bindtap="handleTime">
-          <text class="t-text">13:00-18:00</text>
-          <text class="time-nurse-text" wx:if="{{durationTwo}}">剩余紧张</text>
+          <text class="t-text">12:30-17:00</text>
+          <text class="time-nurse-text" wx:if="{{durationTwo}}">
+            <text>{{durationTwoBusy ? '约满':'剩余紧张'}}</text>
+          </text>
         </view>
         <view class="time-c time-item time-nurse {{timeActive == '3' ? 'time-active' : ''}} {{durationThreeBusy ? 'time-item-disabled' : ''}}" data-dis="{{durationThreeBusy}}" data-time="3" bindtap="handleTime">
-          <text class="t-text">18:00-21:00</text>
-          <text class="time-nurse-text" wx:if="{{durationThree}}">剩余紧张</text>
+          <text class="t-text">18:30-21:30</text>
+          <text class="time-nurse-text" wx:if="{{durationThree}}">
+            <text>{{durationThreeBusy ? '约满':'剩余紧张'}}</text>
+          </text>
         </view>
       </view>
     </view>

+ 3 - 3
pages/myAppointment/myAppointment.wxml

@@ -15,9 +15,9 @@
       <view class="top date ittflex-jcb">
         <text class="top-date">
           <text class="app-str">{{item.appointmentTimeStr}}</text>
-          <text wx:if="{{item.duration == 1}}">8:00-12:00</text>
-          <text wx:if="{{item.duration == 2}}">13:00-18:00</text>
-          <text wx:if="{{item.duration == 3}}">18:00-21:00</text>
+          <text wx:if="{{item.duration == 1}}">08:30-12:00</text>
+          <text wx:if="{{item.duration == 2}}">12:30-17:00</text>
+          <text wx:if="{{item.duration == 3}}">18:30-21:30</text>
         </text>
         <!-- status 1 待服务,2,3 已取消  4: 已完成 5.超时 -->
         <text class="status s-wait" wx:if="{{item.status == 1}}">待服务</text>

+ 4 - 3
pages/reportDetail/reportDetail.js

@@ -8,7 +8,7 @@ Page({
   data: {
     reportid: '',
     name: '评估说明', // 默认展示: 评估说明 小结 ReportTotal, 系统:用具体的中文名称
-    systemName: ['评估说明','检测小结','循环系统', '呼吸系统', '消化系统','泌尿系统', '血液系统', '内分泌系统', '营养代谢', '神经系统', '免疫系统', '运动系统', '感官系统', '理化因素', '情绪压力'],
+    systemName: ['评估说明','检测小结','循环系统', '呼吸系统', '消化系统','泌尿系统', '血液系统', '内分泌系统', '营养代谢', '神经系统', '免疫系统', '运动系统', '感官系统', '理化因素', '情绪压力'],
     leftNavActive: 0, // 0 小结 1 系统
     summaryList: [],
     systemList: [],
@@ -52,12 +52,10 @@ Page({
     })
     getReport(data).then(res => {
       wx.hideLoading()
-      console.log(that.data.name);
       if (that.data.name == 'ReportTotal' || that.data.name == '精神及心理') {
         that.setData({
           summaryList: res.data || []
         })
-        console.log(that.data.summaryList);
       } else {
         that.handleRespose(res.data)
       }
@@ -137,6 +135,9 @@ Page({
         if (navName == '泌尿系统') {
           navName = '泌尿与生殖系统'
         }
+        if (navName == '营养代谢') {
+          navName = '营养与代谢'
+        }
         that.setData({
           name: navName
         })

+ 6 - 6
pages/reportDetail/reportDetail.wxml

@@ -19,27 +19,27 @@
       <view class="sub-menu-item">1.疾病风险评估</view>
       <view class="appraise-title b-item suppose-item">建议</view>
       <view class="b-item b-item-xunhaun ittflex-jcb">
-        <text class="light-text">循环系统</text>
+        <text class="deep-text">循环系统</text>
         <text class="deep-text">营养代谢</text>
       </view>
       <view class="b-item b-item-huxi ittflex-jcb">
-        <text class="light-text">呼吸系统</text>
+        <text class="deep-text">呼吸系统</text>
         <text class="deep-text">神经系统</text>
       </view>
       <view class="b-item b-item-xiaohua ittflex-jcb">
-        <text class="light-text">消化系统</text>
+        <text class="deep-text">消化系统</text>
         <text class="deep-text">免疫系统</text>
       </view>
       <view class="b-item b-item-miniao ittflex-jcb">
-        <text class="light-text">泌尿系统</text>
+        <text class="deep-text">泌尿系统</text>
         <text class="deep-text">运动系统</text>
       </view>
       <view class="b-item b-item-xuexie ittflex-jcb">
-        <text class="light-text">血液系统</text>
+        <text class="deep-text">血液系统</text>
         <text class="deep-text">感官系统</text>
       </view>
       <view class="b-item b-item-neifenmi ittflex-jcb">
-        <text class="light-text">内分泌系统</text>
+        <text class="deep-text">内分泌系统</text>
         <text class="deep-text">理化因素</text>
       </view>
       <view class="sub-menu-item">2.情绪与心理</view>