瀏覽代碼

调整样式

bayi 2 年之前
父節點
當前提交
544f74ba67
共有 5 個文件被更改,包括 27 次插入5 次删除
  1. 1 0
      components/authority/index.less
  2. 3 0
      components/authority/index.wxss
  3. 14 1
      pages/reading/index.js
  4. 8 2
      pages/searchFriend/index.wxml
  5. 1 2
      utils/request.js

+ 1 - 0
components/authority/index.less

@@ -4,6 +4,7 @@
   padding-bottom: 100px;
 
   .module {
+    margin-bottom: 20rpx;
     .topic {
       font-size: 38rpx;
       font-weight: bold;

+ 3 - 0
components/authority/index.wxss

@@ -3,6 +3,9 @@
   padding: 0rpx 20rpx;
   padding-bottom: 100px;
 }
+.authority .module {
+  margin-bottom: 20rpx;
+}
 .authority .module .topic {
   font-size: 38rpx;
   font-weight: bold;

+ 14 - 1
pages/reading/index.js

@@ -102,12 +102,25 @@ Page({
     // 录音授权
     wx.getSetting({
       success(res) {
+        console.log(res);
         if (!res.authSetting['scope.record']) {
           wx.authorize({
             scope: 'scope.record',
             success() {
               // 用户已经同意小程序使用录音功能,后续调用接口不会弹窗询问
-              wx.getRecorderManager()
+            },
+            fail() {
+              wx.showModal({
+                title: '授权提示',
+                content: '请先开启录音功能',
+                success(res) {
+                  wx.openSetting({
+                    success(res) {
+                     
+                    }
+                  })
+                }
+              })
             }
           })
         }

+ 8 - 2
pages/searchFriend/index.wxml

@@ -20,8 +20,14 @@
         </view>
       </view>
       <view class="state">
-        <view class="stateText {{item.isEachOther?'already':'yet'}}">
-          {{item.isEachOther?'已关注':'关注'}}
+        <!-- <view class="stateText {{item.isEachOther?'already':'yet'}}">
+          {{item.isEachOther&&item.isFans?'互相关注':item.isEachOther&&!item.isFans?'已关注':item.isEachOther&&item.isFans?'':''}}
+        </view> -->
+        <view class="stateText already" wx:if="{{item.isEachOther}}">
+          {{item.isFans?'互相关注':'已关注'}}
+        </view>
+        <view class="stateText yet" wx:else>
+          {{item.isFans?'回关':'关注'}}
         </view>
       </view>
     </view>

+ 1 - 2
utils/request.js

@@ -34,7 +34,7 @@ function request(url, method, data, oldBaseUrl = false) {
         } = result
         if (code == '200') {
           reslove(data)
-        } else if (code == '1102' || code == '1204') {
+        } else if (code == '1102') {
           console.log(code, '<=====code1', message);
           wx.clearStorage()
         } else if (code) {
@@ -44,7 +44,6 @@ function request(url, method, data, oldBaseUrl = false) {
             icon: "none",
             duration: 3000
           })
-          // reject(message)
         }
       },
       fail: (res) => {