leon 1 anno fa
parent
commit
a28b64a4ef

+ 17 - 15
src/features/trackTimeDuration/components/SetSchedule.weapp.tsx

@@ -117,7 +117,7 @@ export default function Component() {
     const resource = common.resources.filter((item: any) => {
       return item.code == 'follow_wx_pub'
     })
-    
+
 
     // Taro.showModal({
     //   title: '提示',
@@ -153,14 +153,14 @@ export default function Component() {
         // global.checkData()
         global.indexPageRefresh()
 
-        popScheduleAlert(scenario, startTime)
+        // popScheduleAlert(scenario, startTime)
         // console.log('set schedule 3 navi back')
-        // Taro.navigateBack({ delta: 3 }).then(res => {
+        Taro.navigateBack({ delta: 3 }).then(res => {
 
-        // })
-        // setTimeout(() => {
-        //   global.popScheduleAlert(scenario, startTime)
-        // }, 1000)
+        })
+        setTimeout(() => {
+          global.popScheduleAlert(scenario, startTime)
+        }, 800)
       }).catch(e => {
         setBtnDisable(false)
       })
@@ -228,10 +228,12 @@ export default function Component() {
       setBtnDisable(false)
       // dispatch(setStep('fast'))
       // // global.checkData()
-      // Taro.navigateBack({ delta: 4 })
+      Taro.navigateBack({ delta: 4 })
       // console.log('set schedule 4 navi back')
 
-      popMixScheduleAlert(scenario.schedule.fast.start_time, startTime)
+      setTimeout(() => {
+        global.popMixScheduleAlert(scenario.schedule.fast.start_time, startTime)
+      }, 800)
 
 
 
@@ -273,9 +275,9 @@ export default function Component() {
         confirm: () => {
           // Taro.navigateBack({ delta: 3 })
           followWxPub()
-          setTimeout(()=>{
-            Taro.navigateBack({ delta: 3})
-          },1000)
+          setTimeout(() => {
+            Taro.navigateBack({ delta: 3 })
+          }, 1000)
         }
       })
     }
@@ -308,11 +310,11 @@ export default function Component() {
           Taro.navigateBack({ delta: 4 })
         },
         confirm: () => {
-          
+
           followWxPub()
-          setTimeout(()=>{
+          setTimeout(() => {
             Taro.navigateBack({ delta: 4 })
-          },1000)
+          }, 1000)
         }
 
       })

+ 3 - 3
src/utils/native_permission_check.tsx

@@ -62,7 +62,7 @@ export const uploadPermissions = () => {
                                 camera: statuses[PERMISSIONS.IOS.CAMERA],
                                 location_always: statuses[PERMISSIONS.IOS.LOCATION_ALWAYS],
                                 location_when_in_use: statuses[PERMISSIONS.IOS.LOCATION_WHEN_IN_USE],
-                                notification: 'granted'
+                                notification: 'authorized'
                             }
                         })
                     }
@@ -86,7 +86,7 @@ export const uploadPermissions = () => {
                         camera: statuses[PERMISSIONS.IOS.CAMERA],
                         location_always: statuses[PERMISSIONS.IOS.LOCATION_ALWAYS],
                         location_when_in_use: statuses[PERMISSIONS.IOS.LOCATION_WHEN_IN_USE],
-                        notification: 'blocked'
+                        notification: 'not_determined'
                     }
                 })
             }
@@ -97,7 +97,7 @@ export const uploadPermissions = () => {
                     camera: statuses[PERMISSIONS.IOS.CAMERA],
                     location_always: statuses[PERMISSIONS.IOS.LOCATION_ALWAYS],
                     location_when_in_use: statuses[PERMISSIONS.IOS.LOCATION_WHEN_IN_USE],
-                    notification: 'blocked'
+                    notification: 'not_determined'
                 }
             })
         })