From c476915fdcb57387459ce6da1b43a502f4168628 Mon Sep 17 00:00:00 2001
From: yiming <m13691596795@163.com>
Date: 星期一, 29 四月 2024 09:38:54 +0800
Subject: [PATCH] 标题

---
 pages/cart/index.wxml |  147 +++++++++++++++++++++----------------------------
 1 files changed, 63 insertions(+), 84 deletions(-)

diff --git a/pages/cart/index.wxml b/pages/cart/index.wxml
index 0da4120..ff79a21 100644
--- a/pages/cart/index.wxml
+++ b/pages/cart/index.wxml
@@ -1,89 +1,68 @@
-<scroll-view scroll-y="{{true}}" class="outsideContentBox">
+<import src="index.skeleton.wxml" />
+<template is="skeleton" wx:if="{{loading}}" />
 
+<!-- loading
+hidden -->
+<view hidden="{{hidden}}">
+  <scroll-view scroll-y="{{true}}" class="outsideContentBox" bindscrolltolower="onScrollToLower">
 
+    <view>
 
-
-
-
-
-  <view>
-
-    <!-- <checkbox-group bindchange="HandelItemChange"> -->
-    <view wx:if="{{shoppingCartData.length <= 0}}" class="noDataBox">
-      <t-empty icon="folder-open" description="鏆傛棤鏁版嵁" font-size="80" />
-    </view>
-    <!-- <button bind:tap="onLogin"> 鍘荤櫥褰�</button> -->
-    <t-swipe-cell wx:for="{{shoppingCartData}}" wx:key="index" wx:for-item="item" wx:for-index="index">
-
-
-
-
-      <!-- <view class="contentBox"> -->
-      <!-- <view class="contentCheckbox">
-          <checkbox value="{{item.id}}" checked="{{item.checked}}"></checkbox>
-        </view> -->
-      <view class="itemWarp">
-        <t-cell bordered="{{false}}">
-          <view slot="title" class="titleBox">
-            <!-- <view class="labelBox">
-            <view class="eBook" wx:if="{{item.type == 'product'}}">鐢靛瓙涔�</view>
-            <view wx:if="{{item.type == 'item'}}" class="cloudLearning">浜戝涔�</view>
-          </view>
-          <view class="boosName">
-            {{item.productMonWithLinkDto.product.name}}
-          </view> -->
-
-            <view wx:if="{{item.type == 'product'}}" style="width: 386rpx;">
-
-              <view>
-                <text class="eBook">鐢靛瓙涔�</text> <text class="boosName">{{item.productMonWithLinkDto.product.name}}</text>
-              </view>
-            </view>
-
-
-            <view wx:if="{{item.type == 'item'}}" style="width: 386rpx;">
-
-              <view>
-                <text class="cloudLearning">浜戝涔�</text> <text class="boosName">{{item.productMonWithLinkDto.product.name}}</text>
-              </view>
-            </view>
-
-
-
-
-
-
-
-
-          </view>
-          <view slot="description" class="descriptionBox">
-            <view>
-              <view class="textBox" wx:if="{{item.type == 'product'}}">鍥句功鏈嶅姟-鐢靛瓙涔�</view>
-              <view class="textBox" wx:if="{{item.type == 'item'}}">鍥句功鏈嶅姟-浜戝涔�</view>
-            </view>
-            <view wx:if="{{item.saleMethod.price != 0}}">
-              锟{item.saleMethod.price}}
-            </view>
-            <view wx:else class="descriptionBox"> 绔嬪嵆棰嗗彇</view>
-          </view>
-          <view slot="left-icon" class="left-icon">
-            <view class="contentCheckbox">
-              <t-checkbox icon="rectangle" value=" {{item.id}}" data-item="{{item}}" checked="{{item.checked}}" bindchange="HandelItemChange" />
-            </view>
-            <view class="left-image">
-              <image src="{{item.imgUrl}}" class="imageStyle" mode="aspectFit" />
-            </view>
-          </view>
-        </t-cell>
+      <!-- <checkbox-group bindchange="HandelItemChange"> -->
+      <view wx:if="{{shoppingCartData.length <= 0}}" class="noDataBox">
+        <t-empty icon="folder-open" description="鏆傛棤鏁版嵁" font-size="80" />
       </view>
-      <view slot="right" class="btn delete-btn" bind:tap="onDelete" data-item="{{item}}">鍒犻櫎</view>
-    </t-swipe-cell>
-    <view class="bottom-box">
-      <t-loading theme="circular" size="40rpx" class="wrapper" wx:if="{{isMore == true}}" />
-      <text wx:if="{{isMore == false}}">娌℃湁鏇村浜�</text>
+      <!-- <button bind:tap="onLogin"> 鍘荤櫥褰�</button> -->
+      <t-swipe-cell wx:for="{{shoppingCartData}}" wx:key="index" wx:for-item="item" wx:for-index="index" opened="{{swipeOpened}}">
+        <view class="itemWarp">
+          <t-cell bordered="{{false}}">
+            <view slot="title" class="titleBox">
+              <view wx:if="{{item.type == 'product'}}" style="width: 386rpx;">
+                <view class="boosName">
+                  <text class="eBook">鐢靛瓙涔�</text>
+                  <text> {{item.name}}</text>
+                </view>
+              </view>
+              <view wx:if="{{item.type == 'item'}}" style="width: 386rpx;">
+                <view class="boosName">
+                  <text class="cloudLearning">浜戝涔�</text>
+                  <text> {{item.name}}</text>
+                </view>
+              </view>
+            </view>
+            <view slot="description" class="descriptionBox">
+              <view>
+                <view class="textBox" wx:if="{{item.type == 'product'}}">鍥句功鏈嶅姟-鐢靛瓙涔�</view>
+                <view class="textBox" wx:if="{{item.type == 'item'}}">鍥句功鏈嶅姟-浜戝涔�</view>
+              </view>
+              <view wx:if="{{item.saleMethod.price != 0}}">
+                锟{price}}
+              </view>
+              <view wx:else class="descriptionBox"> 绔嬪嵆棰嗗彇</view>
+            </view>
+            <view slot="left-icon" class="left-icon">
+              <view class="contentCheckbox">
+                <t-checkbox icon="rectangle" value=" {{item.id}}" data-item="{{item}}" checked="{{item.checked}}" bindchange="HandelItemChange" />
+              </view>
+              <view class="left-image" data-item="{{item}}" bind:tap="onBook">
+                <image wx:if="{{item.imgUrl}}" src="{{item.imgUrl}}" class="imageStyle" mode="aspectFit" />
+                <image wx:else src="/static/images/default-book-img.png" class="imageStyle" mode="aspectFit" />
+              </view>
+            </view>
+          </t-cell>
+        </view>
+        <view slot="right" class="btn delete-btn" bind:tap="onDelete" data-item="{{item}}">鍒犻櫎</view>
+      </t-swipe-cell>
+      <view wx:if="{{shoppingCartData.length > 0}}" class="bottom-box">
+        <t-loading theme="circular" size="40rpx" class="wrapper" wx:if="{{isMore == true}}" />
+        <text wx:if="{{isMore == false}}">娌℃湁鏇村浜�</text>
+      </view>
     </view>
-  </view>
 
+
+
+    <t-toast id="t-toast" />
+  </scroll-view>
   <view class="bottomBox">
     <view class="checkGroupBox">
       <checkbox-group bindchange="bottomChange">
@@ -93,10 +72,10 @@
     <view class="settlementBox">
       <view class="totalPrice">鎬讳环:<text class="totalPriceText">锟{totalPrice}}</text></view>
       <view class="buttonBox">
-        <t-button class="tButtonBox" size="small" shape="round" bind:tap="goPaymentPage">鍘荤粨绠�({{selectedCount}})</t-button>
+        <t-button class="tButtonBox" size="small" shape="round" bind:tap="goPaymentPage">
+          <view>鍘荤粨绠�({{selectedCount}})</view>
+        </t-button>
       </view>
     </view>
   </view>
-
-  <t-toast id="t-toast" />
-</scroll-view>
\ No newline at end of file
+</view>
\ No newline at end of file

--
Gitblit v1.9.1