소스 검색

更新应用的appid,调整首页悬浮按钮位置,修改书架页面的书籍编辑功能显示,优化书籍详情跳转逻辑,提升用户体验。

yangwenlan 1 년 전
부모
커밋
11a6f4059f
5개의 변경된 파일8개의 추가작업 그리고 6개의 파일을 삭제
  1. 1 1
      app.js
  2. 2 2
      pages/bookshelf/bookshelf.wxml
  3. 1 1
      pages/index/index.js
  4. 3 1
      pages/index/index.wxml
  5. 1 1
      project.config.json

+ 1 - 1
app.js

@@ -39,7 +39,7 @@ App({
       wx.login({
         success: res => {
           userLogin({
-            "appid": "wxa7a33088566e1292",
+            "appid": "wxa13166979d7011c4",
             "channel": 1,
             "srcType": "0",
             "srcAppId": "",

+ 2 - 2
pages/bookshelf/bookshelf.wxml

@@ -5,9 +5,9 @@
     <view class="tab {{activeTab === 'history' ? 'active' : ''}}" bindtap="switchTab" data-tab="history">
       阅读记录
     </view>
-    <view class="tab {{activeTab === 'edit' ? 'active' : ''}}" bindtap="switchTab" data-tab="edit">
+    <!-- <view class="tab {{activeTab === 'edit' ? 'active' : ''}}" bindtap="switchTab" data-tab="edit">
       编辑书架
-    </view>
+    </view> -->
   </view>
 
   <!-- 书籍列表 -->

+ 1 - 1
pages/index/index.js

@@ -103,7 +103,7 @@ Page({
     const windowWidth = wx.getSystemInfoSync().windowWidth;
     const rpxToPx = windowWidth / 750; // rpx到px的转换比例
     const btnWidth = 90 * rpxToPx; // 悬浮按钮宽度,90rpx转换为px
-    const moveX = -(btnWidth + 40); // 只漏出10px
+    const moveX = -(btnWidth + 35); // 只漏出10px
     
     this.recentBookAnimator.translateX(moveX).step();
     this.setData({

+ 3 - 1
pages/index/index.wxml

@@ -36,7 +36,9 @@
         circular="true"
         class="banner-swiper">
         <swiper-item wx:for="{{bannerList}}" wx:key="id">
-          <image src="{{item.cover}}" mode="aspectFill" bindtap="onBannerTap" data-item="{{item}}"/>
+          <image src="{{item.cover}}" mode="aspectFill" bindtap="goToBookDetail" data-book-id="{{item.id}}"
+          data-wx-book-id="{{item.wxBookId}}"
+          data-chapter-id="{{item.chapterId}}"/>
         </swiper-item>
       </swiper>
     </view>

+ 1 - 1
project.config.json

@@ -24,5 +24,5 @@
     "tabIndent": "auto",
     "tabSize": 2
   },
-  "appid": "wxa7a33088566e1292"
+  "appid": "wxa13166979d7011c4"
 }